Re: [q-lang-users] Newbie questions and comments
Brought to you by:
agraef
From: Albert G. <Dr....@t-...> - 2005-03-17 18:33:10
|
Hi, Tim, Tim Haynes wrote: > Yup. No need to slave to the functional purity, here. (For example, I get > the impression the libxml binding is impure - if you see `||' as a > side-effect sequential operator, you get snippets of code that look like > "destructively append a node here, || now return the new tree".) Yup, actually the xml module is a fairly thin wrapper around libxml, so the manipulation of the xml trees indeed involves side-effects. > Well, there *are* no undefined variables, you just get a symbol-name back Yes, that's one of Q's ideosyncrasies you just have to get used to. (Not the worst one, I'm afraid. ;-) > One bug-bear I have atm is still the debugger. I've got a classic weak-type > problem, writing something that handles lists and tuples (a prototype > generic FSM for my own amusement), and somewhere along the lines I've got > my datatypes in a twist in the middle of a recursive call, and I just can't > make head or tail of the debugging... Sometimes printf is your best friend. But what's wrong with the debugger? This topic comes up every once in a while, so I'll be glad to improve it. But how? > A random question: is there anything in Q like haskell's $ ? Ie., a > right-associative do-very-little operator that obviates surplus > parentheses? > > | foo (bar (qux X)) == foo $ bar $ qux X Nope, not yet. Want one in the next release? :) Albert -- Dr. Albert Gr"af Dept. of Music-Informatics, University of Mainz, Germany Email: Dr....@t-..., ag...@mu... WWW: http://www.musikwissenschaft.uni-mainz.de/~ag |