> Now. If the leftmost-longest match is usable for my problem, I am fine > with C + regexp(6). If not I only see the possibility to use > perl/python nowadays (if I don't want to go mad like above).
There is another option: yacc. I'm not saying it's simpler than perl or python, but it's not much harder and it's more a more general tool. The resulting code will be fast, if you care. > My question then is: wouldn't it be better to switch to the > leftmost-first paradigm, hence open possible use of (non-)greedy > operators, and in a way contribute to an accord with perl/python > syntax? And use a good algorithm for that all? But maybe it's not > worth and the current state is just sufficient... Switching semantics in existing tools is rarely a good idea. Too many things break. If anyone is going to do this, and it won't be me, then it needs to be done in a way that doesn't break anything, like when UNIX switched from basic to extended regular expressions and added a -e option to grep. -- John Stalker School of Mathematics Trinity College Dublin tel +353 1 896 1983 fax +353 1 896 2282
