IRC channel logs


back to list of logs

<toideng>hello all
<toideng>(equal? (cons 'a #nil) (cons 'a '()))
<toideng>-> #f
<toideng>is this intended?..
<toideng>is there any (built-in / idiomatic, sure i can recur on a list) way to check lists for equality ignoring what kind of nil is terminating them?..
<toideng>(the source of my confusion initially was that both `(cons 'a '())` and '(cons 'a #nil)` displayed in REPL as `(a)`)
***karlosz_ is now known as karlosz
***karlosz_ is now known as karlosz
<mwette>toideng: I believe #nil is not intended to be used in Scheme code
<toideng>thank you, i'll take note of that
<mwette>in elisp mode, guile says (eq nil '()) => #t
<mwette>if I transfer (eq nil '()) to tree-il then to scheme I get: ((@ (language elisp runtime function-slot) eq) #nil (quote ()))
<mwette>so maybe you can (define xx-eq? (@ (language elisp runtime function-slot) eq))
<mwette>^ (meant () in elisp, not '())
<lilyp>sneek, later tell mwette: the correct way to check for this kind of nil is null?
<lilyp>sneek later tell toideng: the correct way to check for this kind of nil is null?
<sneek>Will do.
<lilyp>sneek: botsnack
<jpoiret>lilyp: thanks for the @@ answer yesterday
<ArneBab>Go just switched to pdqsort as quicksort implementation. Would that be an option for Guile, too?
<dsmith-work>UGT Greetings, Guilers
<dsmith-work>The other day, someone reported that formatting #f with ~f had a less than desirable message.
<dsmith-work>The curious thing to me is that ~f expects a float or a string.
<dsmith-work>A string? What?
<dsmith-work>scheme@(guile-user)> (format #f "~f~%" "123")
<dsmith-work>$1 = "123.0\n"
<dsmith-work>I had no idea.
<dsmith-work>But it's right there in the docs.
***Guest742 is now known as chrislck
<spk121>dsmith-work: i never noticed that one
<stis>Happy hacking greetings guilers!
<lechner>Hi, what's everyone's favorite tool to format Guile code, please? Is there something with lighter weight than M-x indent-region in Emacs's scheme-mode? Maybe in zile?