mirror of
https://github.com/danog/PHP-Parser.git
synced 2024-12-11 17:09:41 +01:00
91295a0790
When parsing on PHP 7 we will no longer be able to deal with code that contains invalid octal literals. Currently we'll fatal, after engine exceptions land we'll throw an exception instead.
44 lines
622 B
Plaintext
44 lines
622 B
Plaintext
Different integer syntaxes
|
|
-----
|
|
<?php
|
|
|
|
0;
|
|
1;
|
|
@@{ PHP_INT_MAX }@@;
|
|
@@{ PHP_INT_MAX + 1 }@@;
|
|
0xFFF;
|
|
0xfff;
|
|
0XfFf;
|
|
0777;
|
|
0b111000111000;
|
|
-----
|
|
array(
|
|
0: Scalar_LNumber(
|
|
value: 0
|
|
)
|
|
1: Scalar_LNumber(
|
|
value: 1
|
|
)
|
|
2: Scalar_LNumber(
|
|
value: @@{ PHP_INT_MAX }@@
|
|
)
|
|
3: Scalar_DNumber(
|
|
value: @@{ PHP_INT_MAX + 1 }@@
|
|
)
|
|
4: Scalar_LNumber(
|
|
value: 4095
|
|
)
|
|
5: Scalar_LNumber(
|
|
value: 4095
|
|
)
|
|
6: Scalar_LNumber(
|
|
value: 4095
|
|
)
|
|
7: Scalar_LNumber(
|
|
value: 511
|
|
)
|
|
8: Scalar_LNumber(
|
|
value: 3640
|
|
)
|
|
)
|