Tomáš Votruba
f3b19c19ef
[PHP 7.4] Add support for arrow functions ( #602 )
...
Per RFC https://wiki.php.net/rfc/arrow_functions_v2 .
2019-05-09 14:17:28 +02:00
Tomas Votruba
9de96821f7
Add support for ??= operator
...
Introduced in PHP 5.4, represented using an AssignOp\Coalesce node.
2019-02-09 11:16:26 +01:00
Lars Moelleken
b7e6361536
updates via "rectorphp/rector" ( #573 )
...
- "global" -> remove unused "use" statements
- "phpunit" -> fix "@covers" comments
- "phpunit" -> replace "->will($this->returnValue()" with "->willReturn()"
- "UseTest.php" -> add missing namespace
- "composer.json" -> use "autoload-dev"
- remove -> "require_once" usage in the tests (use autoload-dev via composer.json)
-> most of the changes are done automatically by "https://github.com/rectorphp/rector "
2019-01-19 11:18:00 +01:00
Nikita Popov
a5c726bfbf
Make sure heredoc end label not followed by label char
2018-09-21 11:44:39 +02:00
Nikita Popov
83766c8c0e
Partial support for flexible heredoc/nowdoc
...
This only implements the token emulation part, it does not yet
handle the indentation stripping.
Emulating this feature on old PHP versions is really tough and is
not going to work perfectly, but hopefully this implementation is
"good enough".
2018-09-21 11:16:00 +02:00
TomasVotruba
b58157f024
add strict_types to tests + fix explode type
2017-11-03 13:24:19 +01:00
TomasVotruba
af12807451
[cs] apply same to tests
2017-08-13 21:14:28 +02:00
Nikita Popov
bc21514ecf
Move token constants into separate class
...
As these are shared between Php5 and Php7 parsers they should be
in some common place, otherwise we'd have to always reference either
one or the other.
2015-06-13 18:39:55 +02:00
Nikita Popov
ab80054e97
Add support for "yield from"
2015-04-26 11:56:02 +02:00
Nikita Popov
251e689283
Add support for spaceship operator (<=>) [PHP 7]
...
Added as Expr\BinaryOp\Spaceship.
2015-03-12 23:13:31 +01:00
Nikita Popov
01f4be6b4d
Add support for null coalesce operator (??) [PHP 7]
...
Added as Expr\BinaryOp\Coalesce.
2015-03-12 22:45:56 +01:00
nikic
8507af6f4a
Add missing require in tests
...
Test files aren't autoloaded, so this was order-dependent.
2014-11-27 21:01:56 +01:00
nikic
7c98ad6f9b
Support file offsets in emulative lexer as well
...
Also run normal lexer tests against emulative lexer and fix a bug
in __halt_compiler() handling found as a result.
2014-11-27 20:57:38 +01:00
nikic
66fd29cb58
Use stricter assertions where possible
2014-09-30 20:38:09 +02:00
nikic
cda6f575f0
Add support for pow operator (PHP 5.6)
2014-03-26 19:18:16 +01:00
nikic
96f1151ab2
Add support for variadic parameters (PHP 5.6)
2014-03-26 18:23:30 +01:00
nikic
f82862ec9c
Port library to use namespaces, with BC for old names
2014-02-06 20:29:35 +01:00