![](https://s.togetter.com/static/web/img/placeholder.gif)
shiro: それは敢えて#<undef>にしてるわけじゃなくて ,(values) って式自体がもともと不正なんで何が出てきても不思議は無い(たまたま#<undef>だった)ってことなんだけど、誤解のもとかなあ。 http://bit.ly/9AOuvq
2010-10-26 16:01:16![](https://s.togetter.com/static/web/img/placeholder.gif)
(び): 値を返さない、のと未定義値を返す、の違いがちょっとまだわからない http://bit.ly/dARV9u
2010-10-26 16:01:25![](https://s.togetter.com/static/web/img/placeholder.gif)
shiro: gosh> `(,(sqrt 2) ,(values)) (1.4142135623730951 1.4142135623730951) http://bit.ly/bxsEYn
2010-10-26 16:01:39![](https://s.togetter.com/static/web/img/placeholder.gif)
shiro: (values)は0個の値が許されてるところに使うのはOK。(unquote <式>) では<式>はひとつの値を返さないとならない。したがって ,(values) つまり (unquote (values)) は不正。 http://bit.ly/acTdqo
2010-10-26 16:02:52![](https://s.togetter.com/static/web/img/placeholder.gif)
shiro: Gaucheでは(values)は戻り値が無いので、戻り値レジスタに変化がない。その直後に戻り値を無理やり読み出そうとしたら、その前にあった戻り値が見える。Cでauto変数を初期化せずに読んでるのと一緒。 http://bit.ly/aV0ce4
2010-10-26 16:03:54![](https://s.togetter.com/static/web/img/placeholder.gif)
shiro: まあ、言語としては値の数の不整合が起きたところで例外あげた方が親切だしわかりやすくはあるよね。チェックするぶんだけ重くなるけど。そのへん、GaucheはC言語的文化を引きずってるかも (自分の足を撃ちたきゃ撃てる、って意味… http://bit.ly/bHvQEK
2010-10-26 16:07:02![](https://s.togetter.com/static/web/img/placeholder.gif)
でも複数式を書けるブロック(whenとか)が全部副作用のための印だって言うならlambdaも副作用の印に見えるよね
2010-10-26 16:07:59![](https://s.togetter.com/static/web/img/placeholder.gif)
shiro: でも試してみて#<undef>が帰ってきたら、ああ#<undef>が帰ってくるものなんだなあ、って思っちゃうよねえ。 http://bit.ly/bYE2Ek
2010-10-26 16:09:28![](https://s.togetter.com/static/web/img/placeholder.gif)
shiro: 複数式が、というより「戻り値が当てにできない」ってとこ>副作用の印 RT: @nitro_idiot: でも複数式を書けるブロック(whenとか)が全部副作用のための印だって言うならlambdaも副作用の印に見えるよね http://bit.ly/bhuay3
2010-10-26 16:10:22![](https://s.togetter.com/static/web/img/placeholder.gif)
shiro: そういう意味ではbeginはちょっと例がまずかったか。あと、そのような理由から教育に使う時はlambdaの中の式はひとつに制限すべし、ということを言う人もいる (複数式並べたかったら陽にbeginつかえ、と) http://bit.ly/bNcGtg
2010-10-26 16:11:36![](https://s.togetter.com/static/web/img/placeholder.gif)
(when (hoge) (format t "~a" fuga) fuga) を (and (hoge) (progn (format t "~a" fuga) fuga)) と書けと言われてもなぁ
2010-10-26 16:13:52![](https://s.togetter.com/static/web/img/placeholder.gif)
shiro: 読者が極めて限られるような RT: @golden_lucky: Schemeベストプラクティスという本で1章をまるまる#fと'()の話に割り当てたら、ベストセラーになるかな http://bit.ly/8X26f5
2010-10-26 16:17:54![](https://s.togetter.com/static/web/img/placeholder.gif)
nitro_idiot@twitter: なるほど。whenの使い方の問題ですね http://bit.ly/d13zTB
2010-10-26 16:19:13