IRC channel logs

2015-12-25.log

back to list of logs

<nalaginrut>morning guilers~
<wleslie>nalaginrut: happy Friday!
<nalaginrut>heya
<wleslie>what's new?
<nalaginrut>wleslie: artanis-0.1.1 coming soon ;-)
<wleslie>sweet
<cmhobbs>so i got a wild hair and i think i want to tinker with building an implementation of conway's game of life in guile. is there a simple graphics library i can use or would it just be best to do text output?
<lfam>cmhobbs: Cool project! I don't know enough to recommend a library but I'm looking forward to your implementation! I love the game of life
<alezost>just to mention: in emacs there is "M-x life"
<lfam>haha of course
<cmhobbs>naturally
<cmhobbs>anyway, it's a sufficiently complex problem to introduce me to the language
<cmhobbs>i keep dragging my feet with guile and i never get anywhere. i hope this solidifies my udnerstanding
<cmhobbs>understanding*
<daviid`>cmhobbs: try https://dthompson.us/pages/software/sly.html
<cmhobbs>daviid`, i considered sly
<cmhobbs>i'll dig up its docs
<cmhobbs>which sfri provides multidimensional arrays?
<cmhobbs>63, maybe?
<cmhobbs>looking at http://srfi.schemers.org/srfi-63/srfi-63.html now
<cmhobbs>25 appears useful as well
<daviid`>cmhobbs: also look at this lib: https://notabug.org/lloda/guile-ploy
<cmhobbs>daviid`, thanks
<cmhobbs>what is GOOPS? it's mentioned in guile-ploy
<daviid`>see section 8 of the manaul
<daviid`>* manual
<cmhobbs>thanks
<cmhobbs>searching the web for guile things often yield poor results. the ref manual has been my constant companion
<daviid`>cmhobbs: also look here: http://www.stklos.net/Doc/html/stklos-ref-8.html#STklos-Object-System
<cmhobbs>ack, why would you slap object oriented things on top of a functional language?
<cmhobbs>jumping on the clos train?
<daviid`>cmhobbs: when you ned oop, obviously :) and clos is the best oo system ever invented by human being, so we're luck [almost, goops has bugs, but they will be solved]
<daviid`>* need oop ...
<cmhobbs>ha
<cmhobbs>i use oop every day and i get very tired of it
<cmhobbs>ruby pays my bills :/
<daviid`>what oop do you [have to] use?
<daviid`>don't know ruby, thanks god
<daviid`>:)
<daviid`>cmhobbs: wrt oop, if you do need it, use goops, don't [even try to] write your own, but if you don't need it, well just don't :)
<cmhobbs>that's not something i think i'd care to undertake
<cmhobbs>self inflicted papercuts between my toes sounds more fun
<daviid`>:) cool
<cmhobbs>i need to make more use of geiser than i do
<cmhobbs>does 'foo represent a symbol called foo? is that what the single quote before a series of characters is?
<madsy>cmhobbs: ' is a shorthand for QUOTE which is a special form
<madsy>QUOTE tells guile to not evaluate the symbol further, but take the symbol literally
<cmhobbs>great
<madsy>Suppose you call a function like this: (foo bar baz). It looks like you're passing symbols to the function, but what happens is that the arguments bar and baz are evaluated. So you end up passing what the symbols refer to.
<cmhobbs>oooooh, alright!
<cmhobbs>i follow
<madsy>But (foo 'bar 'baz) would actually pass the symbols bar and baz to foo as parameters
<madsy>To make it more confusing, the value the symbol refers to can itself be a symbol :)
<cmhobbs>well, i'm making progress
<cmhobbs>managed to build a multi-dimensional array to represent board state and i'm able to set arbitrary life or death in that array
<cmhobbs>simple stuff but i barely have guile under my belt. trying to get all this in muscle memory
<cmhobbs>on to printing out the board state in some useful manner now
<cmhobbs>it's all in geiser, though. i need to get this into a source file before i have too much
<madsy>Create a module. It's easy and makes your code cleaner
<cmhobbs>that's the plan
<cmhobbs>one step at a time, though
<cmhobbs>i barely know how to use guile
<madsy>If you use emacs with geiser, I hearthily recommend paredit and rainbow-parens :)
<cmhobbs>so far my plan is to 1. implement board state (nearly there), 2. build functions for each condition of the game of life, 3. iterate each element of the board through those conditions, 4. display it somehow (probably printing some unicode characters), 5. split it up into modules
<cmhobbs>i may already be using paredit and rainbow-parens, i'm not sure
<cmhobbs>i installed a bunch of stuff at one point or another
<cmhobbs>my emacs is a bloated mess