Stefan Kamphausen <ska2...@googlemail.com> writes: > To anyone with some understanding of programming and a basic > understanding how `if' looks like in lisps the following lines would > be at least astonishing
Other lisps (I know of) don't have this problem, because in Common Lisp or Emacs Lisp, nil is the only false value, and there's no way to create a new nil value that's not identical to nil. Scheme is similar in having only #t and #f as boolean values with no possibility of creating new instances of #t and #f. > user=> (if some-thing "then" "else") > "then" > user=> (if (= some-thing false) "then" "else") > "then" > > How can some-thing evaluate to true but be equal (in whatever sense = > defines equality) to false? some-thing doesn't evaluate to true, it evaluates to *logical* true, i.e., it is neither nil or false (where *is* means identity). Bye, Tassilo -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegroups.com Note that posts from new members are moderated - please be patient with your first post. To unsubscribe from this group, send email to clojure+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/clojure?hl=en