[antlr-interest] Counted Strings
Sam Barnett-Cormack
s.barnett-cormack at lancaster.ac.uk
Mon Nov 7 10:10:38 PST 2011
Not really in the scope of LL(*). Usually pretty easy to parse by hand,
really.
ANTLR can be twisted into a shape that will handle this, IIRC, but it's
not using it as it's intended to be used, not a sensible way to solve
the problem, and just generally not worth it.
Sam
On 07/11/2011 18:06, Mark Woodworth wrote:
> I am a beginner at Antlr, but I am very excited to use it to translate
> barcode label printer formats.
>
> Many of the label printer data formats include counted strings: a field in
> the header of an input line gives the length of a following data field
> (which may contain the regular line separator characters as data.)
> This gives them a simple form of data transparency.
>
> Could someone point me in the direction of how to write a parsing rule for
> this situation? My quick review of the Definitive Guide and the web site
> have missed it.
> Or is this not in the scope of LL(*) parsers? (That would be sad.)
>
> Thanks,
> Mark Woodworth
> mwoodworth at numinagroup.com
>
> List: http://www.antlr.org/mailman/listinfo/antlr-interest
> Unsubscribe: http://www.antlr.org/mailman/options/antlr-interest/your-email-address
More information about the antlr-interest
mailing list