dxml 0.2.0 released

Jonathan M Davis newsgroup.d at jmdavisprog.com
Wed Feb 14 10:32:24 UTC 2018


On Wednesday, February 14, 2018 10:14:44 Kagamin via Digitalmars-d-announce 
wrote:
> It looks like EntityRange requires forward range, is it ok for a
> parser?

It's very difficult in general to write a parser that isn't at least a
forward range, because without that, you're stuck at only one character of
look ahead unless you play a lot of games with putting data from the input
range in a buffer so that you can keep it around to look at it again after
you've looked farther ahead.

Honestly, pure input ranges are borderline useless for a _lot_ of cases.
It's generally only the cases where you only care about operating on each
element individually irrespective of what's going on with other elements in
the range that pure input ranges are really useable, and parsing definitely
doesn't fall into that camp.

- Jonathan M Davis



More information about the Digitalmars-d-announce mailing list