[REBOL] Re: Parse limitation ?
From: petr:krenzelok:trz:cz at: 8-Oct-2003 16:39
Gabriele Santilli wrote:
>Hi Petr,
>
>On Wednesday, October 8, 2003, 2:06:58 PM, you wrote:
>
>PK> I would just like to point out, that 'first directive or tu/thru [a | b
>PK> | c] was proposed for parse enahncement some time ago, but then some
>PK> parse gurus (e.g. Gabriele) admitted, that parse would have to work
>PK> other way internally and that it is not easy achievable (am I right,
>PK> Gabriele?)
>
>The point is, that internally PARSE would be forced to do the
>equivalent of:
>
> [any [a | b | c | skip]]
>
ah, but that is char-by-char execution ...
>so even if it could be a bit faster than the above I don't think
>it would be of great help. More readable, maybe... so it's
>something I could add to compile-rules, if I get some time to work
>on it.
>
>In this particular case, I wouldn't use this construct at all,
>since it's much better to have a more complete grammar
>
yes, exactly - but I think such grammar to simply achieve what was
requested will not be easy for novices. The tool (REBOL) should support
our thinking pattern - and the most easy on is to "skip" "to | thru"
certain string - no matter what is in between.
If someone is up-to writing complete html parser, building DOM object,
then maybe we are near seeing rebol based web-browser? :-)
-pekr-