IRC channel logs

2016-03-15.log

back to list of logs

<JeanLouis>yes
<mark_weaver>it's super-easy to write
<JeanLouis>like "string\\n"?
<mark_weaver>I'm not sure it's of very wide applicability
<JeanLouis>I am new to Guile, it looks sane in comparison to Perl.
<mark_weaver>heh, that's faint praise :)
<JeanLouis>and I feel I will be able to replace many functions, subroutines that I need
<mark_weaver>but we try to keep it sane
<JeanLouis>mark_weaver: you are developing it?
<mark_weaver>I'm one of three co-maintainers of Guile
<mark_weaver>although it has a long history. most of it existed before I came along to help
<mark_weaver>the other two maintainers are wingo and civodul
<JeanLouis>yes very nice. I appreciate this very much. That Guile is in Guix as main language from beginning is great.
<JeanLouis>It reminds me of computing in old times, turn on the PC, there was BASIC.
<mark_weaver>yes, that was the case on the first computers I owned!
<JeanLouis>of course, on small computers like C+4 or C=64, TRS-80, it was similar.
<JeanLouis>There was also BASIC on PCs, or alternatively, one could boot DOS.
<JeanLouis>Now, I can boot Guile and eventually keep a script online, and run it. Voila.
<mark_weaver>although you know what Edsger Dijkstra said about BASIC: "It is practically impossible to teach good programming to students that have had a prior exposure to BASIC: as potential programmers they are mentally mutilated beyond hope of regeneration."
<JeanLouis>he was joking
<mark_weaver>heh, I think at best, he was only half-joking :)
<JeanLouis>I remember well, I wrote something like HEX viewer and assembly translator in BASIC, to write in machine code.
<mark_weaver>the first computer I used was the TRS-80 model 1, and then I owned the TRS-80 pocket computer, and later the Apple II plus. all three of these had BASIC built in.
<JeanLouis>Computer was re-branded, I was thinking CPU is like for C=64, but it was actually I guess, 6520C or something.
<mark_weaver>fortunately, I graduated to Pascal before too long
<JeanLouis>So anything we wrote in machine code, blocked the computer... and we had long time to load the code again through tape recorder.
<mark_weaver>you're probably thinking of the 6502
<JeanLouis>Until I got the actual CPU definition from the military base.
<JeanLouis>maybe I don't remember. My computer looked very much like this one: https://en.wikipedia.org/wiki/Radio_Shack_Color_Computer
<JeanLouis>re-branded as "Misedo"
<mark_weaver>ah, you and I probably started at about the same time
<mark_weaver>around 1980
<JeanLouis>It was nice Motorola CPU inside. I wrote just simple things in Machine code.
<JeanLouis>There was not big/small letters, then we poked by discovery and found that if we poke certain value to certain byte, we get actually small letters on screen.
<JeanLouis>Imagine, full computer club, 2-3 people poking by hand value by value from 0 - 65535
<mark_weaver>heh
<JeanLouis>I remember I wrote an interrupt, that could not be reset. And we had suddenly small letters on screen.
<mark_weaver>nice!
<mark_weaver>The Apple II plus that I had couldn't display lowercase letters, at least not in the text mode, so the editor showed uppercase letters in reverse video.
<JeanLouis>I was convinced everybdy likes programming, until before some time I have realized, the civilization did not advance. It went back few steps.
<JeanLouis>yes, like that was on this one: https://en.wikipedia.org/wiki/File:TRS-80_Color_Computer_1-white_case.jpg it was white.
<JeanLouis>I was thinking everyone will want to modify their own software. But it is not so.
<JeanLouis>I remember, when we were loading games to Spectrum ZX we had to be silent, or game would not load from tape recorder...
<mark_weaver>heh :)
<JeanLouis>and I had also Apple //c, nice handy, with small green monitor and Lotus 1,2,3 there, with excellent documentation, I could learn spreadsheet work without problems.
<rain1>the ZX is really fun :D
<JeanLouis>sadly I could not have it in time. When I was 8 years, I could only program in my head, by learning tasks from newspapers.
<mark_weaver>I like Eben Moglen's take on our evolution from using language to talk to computers to now using GUIs: "I wrote an internal appreciation about that computer [the Apple Lisa] in which I said this is a catastrophe. This is the end of language in relation to computers. This is the implementation of the”cave man" interface: you point, and you grunt. And if we reduce the interaction between human beings and computers to pointing and
<mark_weaver>grunting, then we miss the role of language in the evolution of human mind and human consciousness. Language is what makes our brains bigger. If we don’t use languages to relate to computers, neither their brains nor our brains will grow in the way that they are supposed to grow."
<JeanLouis>he referred to computer language?
<JeanLouis>Nicey: https://en.wikipedia.org/wiki/File:ZXSpectrum48k.jpg
<mark_weaver>I think he was referring to the move from command-line interfaces to point-and-click GUI interfaces
<JeanLouis>oh yes, that is crazy insane.
<JeanLouis>I know many would kill me now.
<mark_weaver>haha
<JeanLouis>I will make computer club in Tanzania, maybe 5-10 computers, and teach people Guile. But before that, I must learn it.
<mark_weaver>nice! I think Scheme is a great language for teaching people new to programming.
<mark_weaver>the syntax is so trivial that there's not much to learn there, you jump right to the important concepts.
<JeanLouis>I remember very well, offices had only BASIC, Pascal, like that. And every office ought to write their own invoicing, book-keeping, reports. So, there was one-two persons responsible for programming in such companies, and they simply did it. It was not sooo hard. My God.
<JeanLouis>Today? What do we have today? Computer is bought, there is not even a manual with it.
<JeanLouis>I remember, with PC, there were 2 manuals, big books, heavy, MS-DOS and GW-Basic.
<mark_weaver>my Apple II came with full schematics and ROM assembly code listings.
<JeanLouis>Each command was explained well. So I appreciate all efforts of Stallman and FSF to make manuals, infos, nice for the future of people.
<mark_weaver>yes, free documentation is crucial
<JeanLouis>you see... of course, people had more interest for informatics at the time. Today? There is no interest. So I guess we are step back.
<JeanLouis>The programming sense is not growing with the growth of computers, computing devices, etc.
<JeanLouis>and why? I guess we all know why. Due to proprietary software and its culture.
<mark_weaver>I suspect that in absolute numbers, the number of people interested in those details is higher now than before.
<JeanLouis>The culture of forcing people by not giving them knowledge, to be users, not creators.
<JeanLouis>you mean today there is more interested people in programming? Sure, in comparison. But there are too many new devices.
<mark_weaver>however, those people are now only a tiny percentage of the people who buy computers with no such interest, and that wasn't the case before.
<JeanLouis>In the city where I am, I don't know anyone programming anything.
<JeanLouis>I remember before, if somebody had a computer, he programmed something, no matter what.
<mark_weaver>and meanwhile, a culture of secrecy has grown in corporate culture around technical details of their machines.
<mark_weaver>right, I remember that too
<JeanLouis>oh yes, the secret hardware, to be sold as such. I feel like we are in matrix being created...
<JeanLouis>or science fiction, futurist movies. We are now in 1984 my friend.
<mark_weaver>I recently bought a computer that also came with full schematics: the Novena. I had to wait 35 years after the Apple II to buy such a computer.
<mark_weaver>yes, definitely, 1984 is here
<mark_weaver>I believe the consequences for future human freedom is quite serious.
<mark_weaver>that is why I focus my energies on helping the GNU project
<JeanLouis>I look at Novena, is it fully free hardware?
<Jookia>No but it rusn fully free software aside from ROMas
<Jookia>ROMs*
<mark_weaver>the design of the circuit board is free as in freedom
<mark_weaver>but the designs of the individual chips are not free, or even available, unfortunately.
<JeanLouis>yes, but very nice.
<mark_weaver>however, most of the chips were chosen to be the best available in terms of being well documented.
<JeanLouis> https://www.crowdsupply.com/purism/librem-15 this one also looks free
<JeanLouis>how much is Novena?
<mark_weaver>the exception being the FPGA, where they probably could have made a better selection
<mark_weaver>JeanLouis: https://www.crowdsupply.com/sutajio-kosagi/novena
<JeanLouis>not cheap for me...
<mark_weaver>the documentation and designs are here: http://www.kosagi.com/w/index.php?title=Novena_Main_Page
<Jookia>mark_weaver: Actually from what I know no FPGAs were cracked at the time of making the board
<mark_weaver>JeanLouis: unfortunately, the prices of computers only come down when the quantities produced are very large
<mark_weaver>Jookia: oh? could be, I'm not sure off-hand.
<JeanLouis>good to know, I did not know it exists!
<Jookia>purism isn't free
<JeanLouis>alright, good day/night... my time zone is +1
<mark_weaver>JeanLouis: okay, sleep well!
<mark_weaver>it was nice to commiserate with you :)
<JeanLouis>ccc, commiserate...
<JeanLouis>how to say (if () (do something) (do nothing)), what do I put for do nothing?
<JeanLouis>aha nothing must be there, solved
<Jookia>I think you can just use when/unless for that?
<JeanLouis>ah I ma not that far... will see later
<roelj>JeanLouis: It's really this easy: (when () (do something))
<JeanLouis>I see, but I am learning basics... when is later....
<roelj>Ok
<Jookia>I really need to look in to Guile more, but the imperative programming parts throw me off
<JeanLouis>yes? How comes?
<JeanLouis>I see so many possibilities... wasted years in Perl...
<Jookia>I'm more of a Haskeller
<JeanLouis>aha yes, I see many good software in haskell
<JeanLouis>guile is preferred extension language for GNU...
<JeanLouis>I want to use it myself -- and to teach others, so that people may extend available software.
<JeanLouis>I guess gnucash could be extended with guile, did not try, but that is important software package for accounting.
<JeanLouis>result can be that gnucash is adopted in many countries for local accounting
<JeanLouis>it's ok for people in US/EU -- but many countries never heard of "free software".
<JeanLouis>accountants charging businessmen high monthly fees... I think how to help people.
<JeanLouis>just realized that (newline) is not a string
<wingo>moin
<wingo>ACTION wrote down some plans today for top-level inlining and cross-module inlining
<civodul>oh, that's a serious change :-)
<wingo>:)
<wingo>it's doable. i think we could add a field to modules indicating whether their bindings can be inlined
<wingo>it would be off in guile-user, maybe on in guile, and there would be restrictions on what sorts of things are inlinable
<wingo>anyway, will type it up at some point, maybe someone wants to take it :)
<civodul>right, something akin to 'declare' in some implementations
<taylan>ACTION dreamed of that ages ago but it was just words and mumbling unfortunately http://taylanub.github.io/doc/guile-optimize-2.txt
<dsmith-work>JeanLouis: Ya, the first machine I owned was a C64. And the first thing I did was hex dump/entry so i could write machine code.
<dsmith-work>Tuesday Greetings, Guilers
<rain1>hello!
<mark_weaver>hi dsmith-work!
<mark_weaver>btw, have you noticed that sneek has been gone for a long time?
<mark_weaver>(since Feb 25)
<JeanLouis>is there any way to checp for the IP address?
<rain1>which ip address?
<JeanLouis>I just think to check for IP like (is-ip? xxx.xx.xx.xx.)
<rain1>ah
<rain1>i suppose thaht you could use regex
<rain1>the guile library just talks to a c library
<JeanLouis>at this stage... I dont know yet
<rain1>il l show you what i mean just asec
<rain1> https://www.gnu.org/software/guile/manual/html_node/Regexp-Functions.html#Regexp-Functions
<taylan>cheating: (false-if-error (inet-aton "address"))
<rain1>(string-match "[0-9][0-9][0-9][0-9]" "blah2002")
<taylan>reliable regexp for IP is pretty difficult
<rain1>oh thats clever
<rain1>I thought it was just numbers and dots
<taylan>well consider 300.300.300.300
<rain1>oh good point!
<JeanLouis>taylan: inet-aton looks promising to me. But I don't have false-if-error
<taylan>maybe it was false-if-exception
<taylan>yup
<JeanLouis>that yes, thanks much
<JeanLouis>I get this working: (if (not (false-if-exception (inet-aton... but I feel there is simpler way?
<rain1>(define (ip-address? str) (false-if-exception (inet-aton str)))
<rain1>then you can write: (if (not (if-address? ..
<JeanLouis>is there something like (not (false-if-exception?
<rain1>oh mine is wrong
<rain1>(define (ip-address? str) (not (false-if-exception (inet-aton str))))
<JeanLouis>then again I need to use if... not that i shorten anything or re-use.
<JeanLouis>ok I will just (if (not (false-if-exception...
<daviid>note that the manual says inet-aton is deprecated in favor of inet-pton
<JeanLouis>`inet-aton' is deprecated. Use `inet-pton' instead.
<JeanLouis>I see this now. In my script... yes
<JeanLouis>rain1: I see you tend to define new commands, of course, but then I am thinking, how can other people easily understand the program... you know what I mean?
<rain1>yes
<rain1>Try to define procedures with clear names
<rain1>it helps to break a program into logical parts
<JeanLouis>you know, since I started learning Guile, in the real world, I see houses, cars, but they evaluate to something... is it happening only to me?
<rain1>haha
<JeanLouis>rain1: btw, my GPG2 is working well with mutt.
<rain1>maybe i should try mutt
<JeanLouis>you don't use it?
<rain1>not really, nobody to talk to with gpg :)
<JeanLouis>I hope guile has extensions for gpg
<rain1>the shroud program interfaces with gpg
<rain1>could use that for inspiration
<JeanLouis>yes, some days, weeks later...
<JeanLouis>for me, language is dead until it start communicating...
<dsmith-work>mark_weaver: No!
<dsmith-work>sneek: botsnack
<sneek>:)
<dsmith-work>mark_weaver: Seem to be there...
<dsmith-work>sneek: guile help cons
<sneek>`cons' is a procedure in the (guile) module.
<sneek>- Scheme Procedure: cons x y
<sneek> Return a newly allocated pair whose car is X and whose cdr is Y.
<sneek> The pair is guaranteed to be different (in the sense of `eq?') from
<sneek> every previously existing object.
<civodul>sneek & dsmith-work are back, yay! :-)
<sneek>I'll keep that in mind.
<mark_weaver>it's good to have you back, sneek!
<mark_weaver>sneek: botsnack
<sneek>:)
<dsmith-work>sneek: dsmith-work?
<dsmith-work>sneek: & dsmith-work?
<sneek>Someone once said & dsmith-work is back, yay! :-)
<dsmith-work>sneek: forget & dsmith-work
<sneek>Consider it forgotten.
<nalaginrut>ACTION just called Artanis from guile-lua-rebirth, works fine!
<nalaginrut>so Artanis is also a Lua web framework now, thanks Guile compiler tower
<rain1>wow :O
<daviid>nalaginrut: I noticed recently that artanis is mssing on wikipedia, web framework comparison, maybe worth the [your] effort foran entry there ...
<daviid>brb
<nalaginrut>daviid: actually I've written one, but they said it's unaccepted if there's no standalone wiki page for Artanis first
<nalaginrut>;-(
<nalaginrut>they don't accept external link
<amz3>héllo guilers!
<rain1>hey amz :)
<janneke>hi amz3
<YumYumYum>Can someone explain to me how I load a library or file in the same directory as the file being run? I am new to scheme, and I can't get this to work...
<davexunit>YumYumYum: you most likely want to be using the module system, but to answer your specific question, something like: (load (string-append (dirname (current-filename)) "/foo.scm"))
<YumYumYum>davexunit: okay. I'll read up on the module system. Is there any way to not stray too far from r6rs/r5rs using the module system?
<davexunit>YumYumYum: the main module system is guile specific, but you can use the r6rs module system
<wingo>ACTION brain dump on semantics of cross-module inlining: http://article.gmane.org/gmane.lisp.guile.devel/18228
***holomorph is now known as spcmnster
***spcmnster is now known as spcmnstr
***spcmnstr is now known as holomorph