|Should data filtering be done while building the parse tree or after t firstname.lastname@example.org (Costello, Roger L.) (2013-06-03)|
|Re: Should data filtering be done while building the parse tree or aft bobduff@shell01.TheWorld.com (Robert A Duff) (2013-06-06)|
|From:||Robert A Duff <bobduff@shell01.TheWorld.com>|
|Date:||Thu, 06 Jun 2013 12:10:05 -0400|
|Organization:||The World Public Access UNIX, Brookline, MA|
|Posted-Date:||06 Jun 2013 12:33:55 EDT|
> Should I embed filtering rules into the grammar -- perform filtering as I
> build the parse tree?
> Or, should I build the parse tree and then have an application perform
> filtering on the parse tree?
I think the second approach is usually simpler. Separation of concerns.
A parser is working with text (or a sequence of tokens, or whatever).
A syntax tree is an easier data structure to work with for doing
Return to the
Search the comp.compilers archives again.