grammar_parser 7.x-2.2

New features
Unsupported

This is a significant release that supports the PHP 5.4 syntax currently used in Drupal 8, including traits and array short syntax.

grammar_parser 7.x-2.1

Bug fixes
Unsupported

This is a minor release that primarily fixes two bugs related to namespaces.

Bugs
====
Add support for operators that may begin a statement: +, -, ~, and !.
Issue #1903304: Correct parsing of nested "function call" without parentheses.
Issue #1899502: Handle use statements with multiple classes and aliases.

grammar_parser 7.x-2.0

New features
Bug fixes
Unsupported

This is a major release that supports all of the syntax used in Drupal 8 with namespaces and anonymous functions, and improves the API versioning for better support by projects that rely on this library.

Features
========
Parsing and rewriting
---------------------
Add support for all PHP 5.3 language items including namespace expressions and anonymous functions.
Revise the object representation of grammar structure for greater consistency.
Enhance alternative syntax parsing with conditional, for, and foreach statements.
Implement parsing of template files with a mixture of PHP and HTML syntax.
Rewrite array parsing and rewriting to handle multiple preservation settings and generate more consistent grammar structure.
Enhance whitespace preservation options for parsing and rewriting.
Allow for one-line conditional with no braces.
Allow for comments and whitespace in statement headers, lists, and expressions.
Allow for no braces with a single statement body (for, foreach).
Add support for nop blocks (consisting of only a semicolon).
Improve pretty printing by increasing the indent after first newline when preserve newline is enabled.
Implement a detached or nested body (enclosed by curly braces).
Add support for include() in expressions (e.g. function call parameters).
Change default output of PGPClass items with an empty body (remove space between braces).

grammar_parser 7.x-2.x-dev

New features

Start of new branch that will implement:
- remaining items from PHP 5.3, such as namespace, use, goto, and label
- parse template files with inline HTML and PHP code
- preserve all whitespace and comments in source snippet

grammar_parser 7.x-1.2

New features
Unsupported

Commits in this release.

b88801a Enhance traverse2() to optionally return a list of operands as indicated by the callback.
d5d80f6 Enhance stripComments() to recurse.
678cfcf Add a trim function; replace calls to PHP trim().
122b4e7 Add a routine to return a parameter variable at the specified index in a function call.
e72837e Add routine to find a function whose body includes a specified line number.
bc488a8 #886568: Handle nested brace expressions in a special string expression.
a3e630e #1198264: Add a README file.
39f34bd Initialize statements property to handle empty files. (Improve on prior commit.)
250b10f Rename class files (remove "grammar_parser" prefix).
804d219 Rename class files (remove "grammar_parser" prefix).
57a2a30 Use statements property for consistency.
669836f Remove PGPWriter::snippetToString() (identical to toString() method).
3de273d Initialize statements property to handle empty files.
920f31d Add PGPArray::toArray() to return the elements of the array consisting solely of plain text.
73934aa Restrict checking for appended comment to '}' and ';' tokens.
4bd9aed Revert PHP 5.3 requirement.
1860dce Replace calls to is_a() by instanceof operator.
575d10f Only list files with class declarations.
653d15f Require PHP 5.3 or better.
f18b092 Maintain list of class nodes (like functions and calls).
459b66d Stripping CVS keywords

grammar_parser 7.x-1.1

New features
Bug fixes
Unsupported

See CHANGELOG.txt for more information.
Fixes (in the Coder issue queue):
#982380: Coder Upgrade not working

grammar_parser 7.x-1.0

Unsupported

First official release. See CHANGELOG.txt for more information.

grammar_parser 7.x-1.x-dev

Development release (which is always a stable release).

The module will work with any version of Drupal running in PHP 5.2 or greater.

Subscribe with RSS Subscribe to Releases for Grammar Parser