| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
| |
zval_update_constant* functions
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This commit disallows the use of trailing positional arguments
after argument unpacking was used. The following calls are no
longer valid:
fn(...$array, $var);
fn(...$array1, $var, ...$array2);
However, all of the following continue to be valid:
fn($var, ...$array);
fn(...$array1, ...$array2);
fn($var, ...$array1, ...$array2);
The reason behind this change is a stack allocation issue pointed
out by Dmitry: As of PHP 5.5 the stack necessary for pushing
arguments is precomputed and preallocated, as such the individual
SEND opcodes no longer verify that there is enough stack space.
The unpacked arguments will occupy some of that preallocated
space and as such following positional arguments could write past
a stack page boundary.
An alternative resolution for this issue is to ensure that there
is enough space for the remaining arguments in the UNPACK opcode.
However making this allocation precise (rather than using a
conversative over-estimate) would require some effort. Given that
this particular aspect of the feature wasn't very popular in the
first place, it doesn't seem worth the effort.
|
|
|
|
|
|
|
|
| |
Instead of storing the argument number in the znode of the parameter
list, store it in fcall->arg_num. This mainly cleans up the parameter
parsing code, which previously had to duplicate all rules (this
becomes more excessive as more features are added, e.g. named params
would already require a minimum of 14 rules...)
|
|
|
|
|
|
| |
Instead of directly pushing the zend_function* onto the
function_call_stack, push this structure. This allows us to store
additional data on this stack.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
class Foo {
private $val = 'Random, meaningless data';
public function count() { return 42; }
public function __debugInfo() {
return ['count' => $this->count()];
}
}
$f = new Foo;
var_dump($f);
|
|
|
|
| |
RFC: https://wiki.php.net/rfc/argument_unpacking
|
| |
|
| |
|
|
|
|
| |
allocation new empty string each time. (Some extensions might need to be fixed using str_efree() instead of efree() to support interned strings).
|
| |
|
|
|
|
|
|
| |
commit 611da37617749c81ab22b1e44a0cc1f294cc493a
Author: Igor Wiedler <igor@wiedler.ch>
Date: Sat Nov 9 13:48:23 2013 -0500
|
|
|
|
| |
reference. Constant expessions have to be evaluated in context of defining class).
|
|\
| |
| |
| | |
igorw-use-function
|
| | |
|
| |\
| | |
| | |
| | |
| | | |
* lgnome/use-function:
Only check user functions for filenames.
|
| | | |
|
| |\ \
| | |/
| | | |
FIX ALL THE THINGS
|
| | | |
|
| | | |
|
| | |
| | |
| | |
| | | |
functions.
|
| | | |
|
| |\ \
| | |/
| |/|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
* upstream/PHP-5.6: (399 commits)
Fixed issue #115 (path issue when using phar). Fixed issue #149 (Phar mount points not working with OPcache enabled).
Added tests for PHAR/OPCahce incompatibilities
Update NEWS
Fixed bug #65947 (basename is no more working after fgetcsv in certain situation)
Update NEWS
Fixed Bug #66043 (Segfault calling bind_param() on mysqli)
NEWS entry
NEWS entry
Fix bug #65946 - pdo_sql_parser.c permanently converts values bound to strings
bump API versions
Add a couple more test cases to parse_url() tests
fix missing change from 'tcp_socket' to the more common 'server'
fix many parallel test issues
Cleanup temp test file
Revert "Fixed issue #115 (path issue when using phar)."
Update LiteSpeed SAPI code to V6.4
Fixed typo in Makefile.frag
updated NEWS
Remove outdate codes, make it clearer, although just a bit..
Update NEWS
...
Conflicts:
Zend/zend_compile.h
|
| | | |
|
| | |
| | |
| | |
| | |
| | |
| | | |
It was wrongly assumed the namespace has to be looked up in a case
sensitive manner too. Fixed the lookup to use a lower case
represenation of the import name.
|
| | | |
|
| | | |
|
| | | |
|
| | | |
|
| | | |
|
| | |
| | |
| | |
| | |
| | |
| | | |
* Keep track of defined function and const filenames
* Prohibit use function foo if function foo exists
* Prohibit use const foo if const foo exists
|
| | | |
|
| | |
| | |
| | |
| | |
| | | |
The function zend_add_ns_func_name_literal is called if the parser finds a function that is not in the global or current namespace. It assumes such a function will have a \\ in it, which is no longer true with the use function patch. The code change above removes that assumption and makes the test work:
PASS use and use function with the same alias [Zend/tests/use_function/conflicting_use_alias.phpt]
|
| | | |
|
| | |
| | |
| | |
| | |
| | | |
So far 'use function' applied to both constants and functions. This
patch correctly separates the two.
|
| | |
| | |
| | |
| | |
| | |
| | | |
This is specified as the use_function RFC:
* https://wiki.php.net/rfc/use_function
|
|\ \ \ |
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
Yield return values now use IS_VAR rather than IS_TMP_VAR. This
fixes the issue with list() and should also be faster as it avoids
doing a zval copy.
|
|\ \ \ \
| | | | |
| | | | |
| | | | |
| | | | | |
Conflicts:
Zend/zend_extensions.h
|
| | | | | |
|
| |\ \ \ \
| | |_|_|/
| |/| | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
const_scalar_exprs
* 'const_scalar_exprs' of github.com:bwoebi/php-src:
Removed operations on constant arrays. They make no sense as constants are not allowed to be arrays. And as just properties are allowed to; no problem, we still don't need operations on any constant array.
Added a few more operators
Whitespace fix
converted several switches to ifs and made more opcache friendly
Fatal error about self referencing constants fixed
Fixed mem leaks, added tests and ternary operator
Working commit for constant scalar expressions (with constants). Tests will follow.
Conflicts:
Zend/Makefile.am
configure.in
win32/build/config.w32
|
| | | | | |
|
| | | | |
| | | | |
| | | | |
| | | | | |
Tests will follow.
|
|/ / / / |
|
|\ \ \ \
| |/ / /
|/| | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
* pull-request/500:
limit virtual_cwd_activate() duplicated call to ZTS only
reverted the previous commit, both calls are needed in TS mode
virtual_cwd_activate() should be called only in one place
back to do_alloca()
removed unnecessary call
simplify the state free macros
compact the code to preserve the error info after state freeing
back to do_alloca(), reverted the wrong replacement
enabled windows to use stack in both ts/nts mode, some more fixes
moved to do_alloca() usage where appropriate
fixed invalid free
fixed virtual cwd header in phar
updated NEWS
fixed all the places where last error could be lost
preserve the error code
applied and fixed the original patch
initial move on renaming files and fixing includes
Conflicts:
ext/opcache/ZendAccelerator.c
|
| | | | |
|
|/ / / |
|
|\ \ \
| |/ / |
|
| |\ \ |
|