为什么Clojure之父说Scheme的真假坏了? [英] Why did father of Clojure say that Scheme's true/false are broken?
问题描述
在这个 Rich 发布:
<块引用>Scheme #t 几乎完全毫无意义,作为 Scheme 条件测试#f/非#f,而不是#f/#t.我不认为值 #f 有很多用处无论如何,并基于条件这意味着写很多(如果(不是(null? x))... where (if x... will do在 Clojure/CL 中,以及大量的当表达能力下降时处理序列、过滤器等
该消息中的链接也很有价值,尽管第二个可能有点诗意.
In this video, Rich Hickey introduced Clojure for Lisp programmers.
At time 01:10:42, he talked about nil/false/end-of-sequence/'() among Clojure/Common Lisp/Scheme/Java. He said: "Scheme has true and false, but they are broken."
I don't understand why he said that and why does he consider it's "broken"?
It strikes me you'd rather see it from the horse's mouth, so here's a choice extract from a message Rich posted:
Scheme #t is almost completely meaningless, as Scheme conditionals test for #f/non-#f, not #f/#t. I don't think the value #f has much utility whatsoever, and basing conditionals on it means writing a lot of (if (not (null? x))... where (if x... will do in Clojure/CL, and a substantial reduction in expressive power when dealing with sequences, filters etc.
The links in that message are also worthwhile, though the second one may be a bit poetic.
这篇关于为什么Clojure之父说Scheme的真假坏了?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!