PEAR  
Search package by name
 

Package Management
Package Management

 

Package Search
Package Search

 

Channel Management
Channel Management

 

Configuration
Configuration

 
Warning: This package management website is not protected with a password, this is a MAJOR security risk. Please read the README.
Package PHP_ParserGenerator
Installed - no -
Latest 0.1.7
License New BSD License
Summary translate grammar files in Lemon Parser Generator format into a PHP 5 parser
Description Translate a grammar file in the lemon parser generator format
into a PHP 5-based parser

There are a few PHP-specific changes to the lemon parser generator.

- %extra_argument is removed, as class constructor can be used to
pass in extra information
- %token_type and company are irrelevant in PHP, and so are removed
- %declare_class is added to define the parser class name and any
implements/extends information
- %include_class is added to allow insertion of extra class information
such as constants, a class constructor, etc.

Other changes make the parser more robust, and also make reporting
syntax errors simpler. Detection of expected tokens eliminates some
problematic edge cases where an unexpected token could cause the parser
to simply accept input.

Otherwise, the file format is identical to the Lemon parser generator
Dependencies
PHP Version: 5.1.0 or newer
PEAR Package: pear.php.net/PEAR 1.4.3 or newer
Options
install Install package
More extra info Extended Package Information
manual pear.php.net Developer Documentation
manual pear.php.net Package Manual