Kelbt v.0.12

Advertisement
Advertisement

Kelbt project can generate backtracking LALR parsers. Standard LALR parser generators emit an error upon encountering a conflict in the parse tables. Kelbt forges onward, generating parsers which handle conflicts by backtracking at runtime. Kelbt is able to generate a parser for any context-free grammar and therefore implements a generalized parsing method. Kelbt is different from other backtracking LR systems in two ways. First, it elevates backtracking to the level of semantic actions by introducing a class of actions called undo actions. Undo actions are invoked as the backtracker undoes parsing and allow the user to revert any side effects of forward semantic actions. This makes it possible to backtrack over language constructs which must modify global state in preparation for handling context dependencies. Second, Kelbt enables a user-controlled parsing strategy which approximates that of generalized recursive-descent parsing. This makes it easy for the user to resolve language ambiguities by ordering the grammar productions of a nonterminal according to their precedence. It is approximate in the sense that for most grammars the equivalent of an ordered choice parsing strategy is achieved. In cases where productions are parsed out of the order given, there is a simple grammar transformation which remedies the problem. See the CASCON paper for more details. As a proof of concept, Kelbt has been used to write a partial C++ parser (included) which is composed of strictly a scanner, a name lookup stage and a grammar with standard semantic actions and semantic undo actions. Enhancements: - The -l option was added for turning off line directives in generated code. - The class keyword was added. - This indicates that a nonterminal or the token type is a C++ class, and should have its constructors and destructors called. - The shortest statement was added. - This allows one to force a shortest match of a list of items. - The semantics of commit was changed. - It now forces a full commit rather than a scoped commit. - Many other improvements were made.

Kelbt project can generate backtracking LALR ...

 
  • GPL
  • 215 Kb
  • 152
 
 

Review Kelbt

  • captcha
 


Development - Other software of Adrian Thurston

  • Aapl C++ Template Library  v.2.14Aapl is a C++ template library for generic programming. Aapl supports different generic programming paradigms by providing variations of standard data structures. For example, a by-value linked list template may be used to store a user supplied type ...
  • Ragel  v.6.5Ragel 6.5 offers users with an effective yet beneficial tool which is designed to compile executable finite state machines from regular languages. Ragel targets C, C++, Objective-C, D, Java and Ruby. Ragel state machines can not only recognize byte ...
  • Ragel State Machine Compiler  v.5.23Ragel State Machine Compiler compiles finite state machines from regular languages into executable C/C++/Objective-C code. Ragel state machines can not only recognize byte sequences as regular expression machines do, but can also execute code at ...


Development - New Development software

  • DbForge Studio for SQL Server  v.5.8dbForge Studio for SQL Server is an integrated environment for SQL Server development, management, administration, data reporting, analysis, version-control database changes and test data generation.
  • SentiMask SDK Trial  v.2.0.193121Real-time 3D face motion capture and tracking SDK for development of augmented reality apps, digital character facial expression control or mapping animated avatars on users face. Works on common PC with webcam or Android smartphone.
  • Radmin VPN  v.1.1.3909Radmin VPN - is a free and easy-to-use software product to create virtual private network (VPN). The program allows users to establish a secure connection between computers over the Internet as if they were connected over a LAN.
  • REKURSIO  v.1.2.1REKURSIO is a free xml editor that can surprise you with the speed of working with large files and the original approach to processing tabular data. In the 64-bit version of the application, you can work with documents larger than 100 megabytes.
  • KeepTime: A Musicians Metronome  v.2Makes it easy to select the sounds you want to hear to help you keep time with your music playing. In addition to playing a sound on every beat (according to the timing signature you choose) you can also elect to play a different sound on the first ...
  • Kernel PowerPoint - Repair Files  v.4.05.01Kernel for PowerPoint - recovers corrupted PowerPoint presentation files corrupted due to unexpected system shutdown, software crash, virus attacks. During repairing process a complete scan of the damaged powerpoint file is performed to locate and ...