BoB: Best of Both in Compiler Construction Bottom-up Parsing with Top-down Semantic Evaluation

Wolfgang Dichler, Heinz Dobler


Compilers typically use either a top-down or a bottom-up strategy for parsing as well as semantic evaluation. Both strategies have advantages and disadvantages: bottom-up parsing supports LR(k) grammars but is limited to S- or LR-attribution while top-down parsing is restricted to LL(k) grammars but supports L-attribution. The goal of the work described herein was to combine the advantages of both strategies. The result is the compiler generator BoB, mainly a preprocessor for Flex and Bison (modern versions of Lex and Yacc). BoB processes compiler descriptions written in Cocol4BoB which supports L-attributed LALR(1) grammars and generates input files for Flex and Bison. Compilers generated by the BoB-Flex and Bison toolchain use bottom-up parsing and top-down semantic evaluation. So developers do not have to struggle with LL(1) conflicts and can use inherited as well as synthesized attributes in semantic actions. Another benefit of BoB is its simple yet powerful compiler description language.


Bottom-Up Parsing; Top-Down Semantic Evaluation; Attributed Grammars; Compilers and Compiler Generators

Full Text:


Lululemon Black Friday cheap nfl jerseys Lululemon factory Outlet ny Black Friday discount tiffany outlet wholesale soccer jerseys online oakley black friday cheap nhl jerseys china cheap nfl jerseys north face black friday sale cheap nfl jerseys online Jordans Black Friday Sale 2015 Cheap Moncler Cyber Monday moncler outlet cheap soccer jerseys moncler outlet black friday cheap authentic nfl jerseys north face cyber monday Louboutin Black Friday canada wholesale cheap nfl jerseys lululemon cyber monday 2015 cheap nfl jerseys from china 2015 Cheap Moncler Black Friday Sale Moncler Cyber Monday 2015 cheap jerseys Lululemon Cyber Monday Sale jordans cyber monday deals 2015 Black Friday deals Lululemon 2015 jordan black friday 2015 Moncler Jackets Black Friday Sale 2015 Louboutin Pas Cher Black Friday 2015 Canada Lululemon north face black friday cheap wholesale soccer jerseys