Re: [q-lang-users] RFC: Conditional syntax
Brought to you by:
agraef
From: Albert G. <Dr....@t-...> - 2006-05-31 03:51:10
|
Hi Keith, Keith Trenton wrote: > 1. Wrt the <ifelse> function, I prefer keeping "ifelse X Y Z"; it is clean and concise. You can use both. Internally "if X then Y else Z" and "ifelse X Y Z" are exactly the same. The former will be used for unparsing now (keeping in line with the philosophy that the pretty-printer should unparse expressions with as much syntactic sugar as possible), but I can easily take that out again; it's just the pretty-printing, so it doesn't really matter as long it's re-parseable. It's already implemented and in CVS now. I don't see any problems arising from the new syntax, but I can easily back it out if it's necessary or if enough ppl complain. > 2. Wrt multi-way and matching conditionals, I prefer your option (1); however, I would be equally happy if BOTH options (1) and (2) were implemented. I personally dislike curly braces "{}" (they remind me of my Perl days ;-); however, option (2) is consistent with the new stream syntax, so I can live with it (but I prefer using Lispy-parens). Yeah, (1) looks nicer for me, too (although I prefer (2) for technical reasons). And the listof/streamof special forms also take tuples for the sequences of clauses, so it would be consistent with that. Other opinions? > 3. Wrt grouping inside tuples, etc., I can only say, "cool". Yes, I think that the grouping thing would be quite useful for other purposes, too, so I'd probably implement it anyway. > Or does that date me too much? Being an old hand myself, I don't know. Isn't "cool" "leet" anymore? Or do we all have to write "kewl" now? ;-) Cheers, Albert -- Dr. Albert Gr"af Dept. of Music-Informatics, University of Mainz, Germany Email: Dr....@t-..., ag...@mu... WWW: http://www.musikinformatik.uni-mainz.de/ag |