kuzha の後置制御構文
後置制御構文が実装し終わりました。/if /while /for /let /catch /finally /lock /case の7種類があります。
kz> "hi" puts /if 123 == 123; > hi kz> (x = "hi") puts /while x == void; > hi kz> i puts /for i in 0..3; > 0 1 2 3 kz> i puts /let i = "hi"; > hi kz> throw "hi" /catch ex do ex puts; > hi kz> "h" put /finally "i" puts; > hi kz> "hi" puts /lock "abc"; > hi kz> x puts /case $["hello" "hi"] of $["hello" x]; > hi
TODO: case 文がコンテキスト分離されていないので分離しておく。