Top Level :: Tools and Utilities
:: zephir_parser
:: 2.8.0
:: Windows
zephir_parser 2.8.0 for Windows
| Package Information |
| Summary |
Zephir code parser. |
| Maintainers |
Anton Vasiliev <
anton at phalcon dot io >
(lead)
[wishlist]
[details]
|
| License |
MIT |
| Description |
Zephir Parser is a code parser, delivered as a C extension for the PHP language. |
| Homepage |
https://github.com/zephir-lang/php-zephir-parser
|
Release notes
Version 2.8.0
(stable)
|
### Added - Support PHP attribute syntax on every declaration PHP allows for a class member: `#[Attr]`, `#[Attr(1, "s", key: "v")]` and `#[A, B(2)]` on a class, interface, trait, function, property, class constant, method and parameter (including closure and interface-method parameters). The host node gains an `attributes` key, appended last and omitted entirely when the declaration carries none, so every node that parsed before keeps its exact shape. `#[A] #[B]` and `#[A, B]` produce the same flat list, since the grouping carries no meaning in PHP either. Arguments reuse the call-argument non-terminal, so a named argument (`key: expr`) needs no special form and the grammar accepts more than a constant expression, leaving the compiler to name the sub-expression it cannot fold. The canonical order is docblock then attributes; the reverse is tolerated ([zephir-lang/zephir#2466](https://github.com/zephir-lang/zephir/issues/2466)).
### Changed - `#[` is a new token. A bare `#` remains a scanner error, and `#[` inside a string, a comment, a docblock or a `%{ ... }%` cblock is still part of that literal. - An attribute named after one of Zephir's case-insensitive keywords is accepted for the eleven that are plausible attribute names (`Deprecated`, `Final`, `Internal`, `Readonly`, `Static`, `Default`, `Case`, `Empty`, `Void`, `Reverse`, `Inline`) and normalized to that canonical spelling. A keyword whose terminal matches two spellings, such as `float`, has no such rule and must be written qualified. |
|
In case of missing DLLs, consider to contact the
Windows Internals List
(subscribe first).
| Dependencies for release 2.8.0 |
|
PHP Version: PHP version 8.5.99 or older PHP Version: PHP 7.0.0 or newer PEAR Package: PEAR 1.10 or newer
|
|
|