<daviid>muradm: l1 is a procedure, who's body returns the immutable list composed of the 1 2 and 3 elements - l2 is a procedure that returns a new list at each call, hence they will never be equal to any previous incantation ... <daviid>muradm: you really ned to learn scheme and look in the manual <muradm>daviid: yes i figured out the difference between (list ..) and '(..) no issue with that. i wonder where '(1 2 3) is stored to pass (eq? ..) test <muradm>daviid: that exactly what i'm doing :) <daviid>muradm: perfect, now you have to accept that's how it is :) <muradm>daviid: manual didn't answer my question <daviid>'... Return #t if x and y are the same object,' <daviid>it even gives the exact same example then the one you pasted <muradm>(define (l1) '(1 2 3)) (define (l3) '(1 2 3)) (eq? (l1) (l3)) returns #f <daviid>exactly, they are not the same object <daviid>they are twice an immutable (new) representation of the immutable list composed of 1 2 and 3 <muradm>(define (l1) '(1 2 3)) (eq? (l1) (l1)) returns #t <muradm>so my question is where '(1 2 3) is store to be different in l1 and l3 and same for l1 and same for (eq? '(1 2 3) '(1 2 3)) <muradm>there should be some kind of object cache? basically l1 and l3 looks like dependend type <muradm>what is this behavior would be called in guile? <daviid>muradm: ask in #scheme, this question has nothing todo with guile in particular, and they have more time to help nbeginners ... <muradm>guile> (eq? '(1 2 3) '(1 2 3)) => #t <muradm>chicken> (eq? '(1 2 3) '(1 2 3)) => #f <muradm>asked in #scheme as you suggested <jpoiret>in any case, you shouldn't use eq? to compare lists ***Furor is now known as Colere
<chrislck>muradm: I am not a scheme expert; you can consider the '(1 2 3) is stored within the procedure definition for l1, and l3 has its own '(1 2 3) <chrislck>another r7rs-vs-guile question: is (define-module) a guileism and (define-library) the r7rs equivalent? <chrislck>ditto guile's (use-module) is equivalent to r7rs (import) ? ***X-Scale` is now known as X-Scale
***chris is now known as Guest3103
***chris is now known as Guest5160
***Guest5160 is now known as chrislck
***X-Scale` is now known as X-Scale
***rgherdt_ is now known as rgherdt