From PEG to a practical parser

Transcribe Parsing Expression Grammar into a parser written in Java.

Add a Review
2 Downloads (This Week)
Last Update:
Download Mouse-1.7.tar.gz
Browse All Files
Windows Mac Linux

Description

This is a tool to transcribe Parsing Expression Grammar into a parser written in Java.

Parsing Expression Grammar (PEG) is a new way to specify recursive-descent parsers with limited backtracking. The use of backtracking lifts the LL(1) restriction usually imposed by top-down parsers. In addition, PEG can define parsers with integrated lexing.

Unlike some existing parser generators for PEG, the tool does not produce a complex and storage-hungry "packrat parser", but a collection of transparent recursive procedures. It is named "Mouse" to set it apart from pack rats.

An integral feature of "Mouse" is the mechanism for specifying semantics (also in Java). This makes "Mouse" a convenient tool if one needs an ad-hoc language processor. Being written in Java, the processor is operating-system independent.

Included in the package are PEGs for Java and C.

From PEG to a practical parser Web Site

Categories

Compilers

License

Apache License V2.0

Features

  • New in version 1.7: 'deferred actions' to construct messages that can be revoked in case of backtracking. The feature uses lambda expressions of Java, which means it requires Java version 1.8 (JSE 8).
  • The manual is revised, with added references to new literature about converting EBNF to PEG.

KEEP ME UPDATED

Write a Review

User Reviews

Be the first to post a review of From PEG to a practical parser!

Additional Project Details

Intended Audience

Information Technology, Developers

User Interface

Command-line

Programming Language

Java

Registered

2010-04-05
Screenshots can attract more users to your project.
Features can attract more users to your project.