help-bison
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: opinion on back end architecture


From: Urdaneta, Alfonso E (N-Summitt Technologies)
Subject: RE: opinion on back end architecture
Date: Fri, 05 Dec 2003 14:04:53 -0500

the language has, for example, 2 ways to assign a value to a variable,
where value can be integer, string, etc.

calculate <identifier> value 
fill <identifier> value

(these are greatly simplified btw).

I have 

calculate.yy
fill.yy
etc.

each of which have a grammar for that particular statement type.  each
grammar then has actions that call classed like Calculate, Fill, etc.
for the specific things that they do.  the thing is that I might find
(for example) an integer while processing a fill statement or a
calculate statement, so by having multiple parsers, I make sure the
right parser gets the integer.  

By separating them this way I end up with a simpler grammar, but with a
lot more code, and I'm not entirely sure this is a good thing.  

--
alfonso e. urdaneta




reply via email to

[Prev in Thread] Current Thread [Next in Thread]