[antlr-interest] ANTLR3 tutorial
Martin Probst
mail at martin-probst.com
Thu Aug 3 13:18:50 PDT 2006
Hi,
>> First, you should at all times avoid tricking people into writing
>> a parser for XML. There is absolutely no reason for this. None
>> whatsoever. There are XML parsers out there for all languages and
>> a variety of different profiles, SAX, DOM, XML Pull, whatever.
>> They are highly optimized and it's extremely unlikely you get
>> something faster using ANTLR.
>
> Actually, for a specific DTD I can beat any general thingie...plus
> those tools are typical memory pigs are I thought were known to be
> slow! ;)
Well, that depends largely on what you have. E.g. a SAX parser, which
is actually more of a lexer, will be very hard to beat. And the
automata that are constructed by schema typed things shouldn't be all
that slow either. What do you mean with "those tools"? DOM is
actually quite a memory hog, but in almost all use cases you don't
really need it.
Martin
More information about the antlr-interest
mailing list