Commit Graph

7966 Commits

Author SHA1 Message Date
Stanislav Malyshev
cfd5ea4301 Merge branch 'PHP-5.5' into PHP-5.6
* PHP-5.5:
  Replace invalid code with a proper #error
2013-12-08 15:53:41 -08:00
Stanislav Malyshev
744f35d2ab Merge branch 'PHP-5.4' into PHP-5.5
* PHP-5.4:
  Replace invalid code with a proper #error
2013-12-08 15:52:56 -08:00
Lior Kaplan
c062c18d42 Replace invalid code with a proper #error
This code creates a nasty error as mentioned in bugs #31131, #37062
Patch taken from Debian's PHP package: 044-strtod_arm_fix
2013-12-08 15:49:22 -08:00
Ard Biesheuvel
bec62af141 Merge branch 'PHP-5.4' into PHP-5.5 2013-12-11 08:50:53 +01:00
Ard Biesheuvel
8f1fee61e2 Zend: fix overflow handling bug in non-x86 fast_add_function()
The 'result' argument of fast_add_function() may alias with either
of its operands (or both). Take care not to write to 'result' before
reading op1 and op2.
2013-12-11 08:50:20 +01:00
Ferenc Kovacs
e3ebe995c9 Merge branch 'PHP-5.6' 2013-12-06 11:07:36 +01:00
Ferenc Kovacs
562fa252ad Merge branch 'use-function' of git://github.com/igorw/php-src into igorw-use-function 2013-12-06 05:39:49 +01:00
Sebastian Bergmann
48cc47d55a Leftover: Bump version to 5.7.0 2013-12-03 07:42:37 +01:00
Dmitry Stogov
86c806a36e Merge branch 'PHP-5.6'
* PHP-5.6:
  Fixed ability to build non-specialized GOTO VM
2013-12-02 11:03:57 +04:00
Dmitry Stogov
9447181d0c Merge branch 'PHP-5.5' into PHP-5.6
* PHP-5.5:
  Fixed ability to build non-specialized GOTO VM
2013-12-02 11:03:17 +04:00
Dmitry Stogov
7efcbecda9 Merge branch 'PHP-5.4' into PHP-5.5
* PHP-5.4:
  Fixed ability to build non-specialized GOTO VM

Conflicts:
	Zend/zend_vm_gen.php
2013-12-02 11:02:40 +04:00
Dmitry Stogov
9ed605892d Fixed ability to build non-specialized GOTO VM 2013-12-02 10:59:32 +04:00
Nikita Popov
1acee05579 Merge branch 'PHP-5.6' 2013-12-01 13:48:09 +01:00
Nikita Popov
b3546e64bd Merge branch 'PHP-5.5' into PHP-5.6 2013-12-01 13:45:22 +01:00
Nikita Popov
02dca18b90 Fix bug #65764
I'm not exactly sure whether this is the right way to fix it. The
question is whether Generator::throw() on a newborn generator (i.e.
a generator that is not yet at yield expression) should first advance to
the first yield and throw the exception there or whether it should
instead throw the exception in the caller's context.

The old behavior was to throw it at the start of the function (i.e.
the very first opcode), which causes issues like the one in #65764.
Effectively it's impossible to properly handle the exceptions in this
case.

For now I choose the variant where the generator advances to the
first yield before throwing, as that's consistent with how all other
methods on the Generator object currently behave. This does not
necessarily match the behavior in other languages, e.g. Python would throw
the exception in the caller's context. But then our send() method already
has this kind of deviation, so it stays internally consistent at least.
2013-12-01 13:37:56 +01:00
Nikita Popov
508738251f Merge branch 'PHP-5.6' 2013-11-30 13:41:22 +01:00
Nikita Popov
e2a8d7dc17 Merge branch 'PHP-5.5' into PHP-5.6 2013-11-30 13:40:17 +01:00
Nikita Popov
b4f00be6c4 Cleanup generator closing code a bit
All code dealing with unfinished execution cleanup is now in a separate
function (previously most of it was run even when execution was properly
finished.

Furthermore some code dealing with unclean shutdowns has been removed,
which is no longer necessary, because we no longer try to clean up in
this case.
2013-11-30 13:38:21 +01:00
Nikita Popov
9589cae8cb Fixed bug #66041: list() fails to unpack yielded ArrayAccess object
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.
2013-11-30 13:08:31 +01:00
Nikita Popov
2e0a960e97 Merge branch 'PHP-5.6' 2013-11-29 23:59:21 +01:00
ArunSK
2e6d830590 Fixed unused value compiler warning 2013-11-29 23:58:41 +01:00
Dmitry Stogov
f65e652f9f Merge branch 'PHP-5.6'
* PHP-5.6:
  Added validation of class names in the autoload process
2013-11-29 12:55:38 +04:00
Dmitry Stogov
2cb0e1e4c1 Merge branch 'PHP-5.5' into PHP-5.6
* PHP-5.5:
  Added validation of class names in the autoload process

Conflicts:
	NEWS
2013-11-29 12:55:11 +04:00
Dmitry Stogov
967abd6153 Merge branch 'PHP-5.4' into PHP-5.5
* PHP-5.4:
  Added validation of class names in the autoload process
2013-11-29 12:54:22 +04:00
Dmitry Stogov
2d31eadbbf Added validation of class names in the autoload process 2013-11-29 12:53:02 +04:00
Dmitry Stogov
77cdda452d Merge branch 'PHP-5.6'
* PHP-5.6:
  Avoid interned hash key duplication and hash key length recaclulation
2013-11-29 00:59:26 +04:00
Dmitry Stogov
6c2a806820 Avoid interned hash key duplication and hash key length recaclulation 2013-11-29 00:57:49 +04:00
Dmitry Stogov
a1193b23b6 Merge branch 'PHP-5.6'
* PHP-5.6:
  Removed unused "pHashFunction" argument in _zend_hash_init() and family (must be 99% source compatible)
2013-11-28 18:42:57 +04:00
Dmitry Stogov
5d25762646 Removed unused "pHashFunction" argument in _zend_hash_init() and family (must be 99% source compatible) 2013-11-28 18:40:46 +04:00
Dmitry Stogov
5d6b20f66b Merge branch 'PHP-5.6' of git.php.net:php-src into PHP-5.6
* 'PHP-5.6' of git.php.net:php-src:
  Updated NEWS for Constant Scalar Exprs RFC
  Moved arrays again to "static_scalar:" & little cleanup
  Renaming
  Constant expressions refactoring
  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.
2013-11-28 17:04:54 +04:00
Dmitry Stogov
609efa2623 Merge branch 'master' of git.php.net:php-src
* 'master' of git.php.net:php-src:
  Updated NEWS for Constant Scalar Exprs RFC
  Moved arrays again to "static_scalar:" & little cleanup
  Renaming
  Constant expressions refactoring
  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.
2013-11-28 17:03:59 +04:00
Dmitry Stogov
7fa9032d0b Merge branch 'PHP-5.6'
* PHP-5.6:
  Some rare deprecated cases replaced by ZEND_ASSERT() (some extensions might need to be fixed)
  Removed duplicated hash function implementation (100% source compatible)
2013-11-28 17:03:28 +04:00
Dmitry Stogov
b63b81815f Some rare deprecated cases replaced by ZEND_ASSERT() (some extensions might need to be fixed) 2013-11-28 17:02:01 +04:00
Dmitry Stogov
aa427a10d4 Removed duplicated hash function implementation (100% source compatible) 2013-11-28 17:01:10 +04:00
Bob Weinand
be5b98ef0d Merge branch 'PHP-5.6' 2013-11-28 13:53:00 +01:00
Bob Weinand
d36cf90291 Merge branch 'const_scalar_exprs' into PHP-5.6
Conflicts:
	Zend/zend_extensions.h
2013-11-28 13:41:42 +01:00
Dmitry Stogov
fe451e9a72 Merge branch 'PHP-5.6'
* PHP-5.6:
  Don't check argument types for internal functions without type hinting
2013-11-28 11:45:47 +04:00
Dmitry Stogov
57c1335fec Don't check argument types for internal functions without type hinting 2013-11-28 11:44:14 +04:00
Dmitry Stogov
45d399b96e Merge branch 'PHP-5.6'
* PHP-5.6:
  Fixed tests
2013-11-27 21:04:23 +04:00
Dmitry Stogov
fcb98cbce8 Fixed tests 2013-11-27 21:04:00 +04:00
Dmitry Stogov
fca64efd62 Merge branch 'PHP-5.6'
* PHP-5.6:
  Removed deprecated AI_SET_PTR()s
2013-11-27 20:32:21 +04:00
Dmitry Stogov
43e3933fa3 Removed deprecated AI_SET_PTR()s 2013-11-27 20:30:35 +04:00
Dmitry Stogov
a3cb536d24 Merge branch 'PHP-5.6'
* PHP-5.6:
  Fixed bug #65969 (Chain assignment with T_LIST failure)
2013-11-27 14:56:48 +04:00
Dmitry Stogov
a908afeaa5 Merge branch 'PHP-5.5' into PHP-5.6
* PHP-5.5:
  Fixed bug #65969 (Chain assignment with T_LIST failure)

Conflicts:
	NEWS
	Zend/zend_vm_def.h
	Zend/zend_vm_execute.h
2013-11-27 14:56:18 +04:00
Dmitry Stogov
92b76680e9 Merge branch 'PHP-5.4' into PHP-5.5
* PHP-5.4:
  Fixed bug #65969 (Chain assignment with T_LIST failure)

Conflicts:
	NEWS
	Zend/zend_vm_def.h
	Zend/zend_vm_execute.h
2013-11-27 14:39:40 +04:00
Dmitry Stogov
16d59aa171 Fixed bug #65969 (Chain assignment with T_LIST failure) 2013-11-27 14:26:34 +04:00
krakjoe
a0e3cb08e6 Merge branch 'PHP-5.6' of https://git.php.net/repository/php-src into PHP-5.6 2013-11-20 16:26:21 +00:00
krakjoe
1a1e83a5d9 export more Zend API 2013-11-20 16:24:22 +00:00
Anatol Belski
6f2d32fd1f Merge branch 'PHP-5.6'
* PHP-5.6:
  permanently deactivate that place, not on runtime only
2013-11-20 10:12:29 +01:00
Anatol Belski
c694d1df7b Merge branch 'PHP-5.5' into PHP-5.6
* PHP-5.5:
  permanently deactivate that place, not on runtime only
2013-11-20 10:12:06 +01:00
Anatol Belski
18b2b2a0bc Merge branch 'PHP-5.4' into PHP-5.5
* PHP-5.4:
  permanently deactivate that place, not on runtime only
2013-11-20 10:11:39 +01:00
Anatol Belski
b902a25cc3 permanently deactivate that place, not on runtime only
besides the two "if" checks, this fixes static analyze which is sometimes
broken because of this
2013-11-20 10:09:11 +01:00
Kalle Sommer Nielsen
9e3551ba1f Eliminated the TSRMLS_FETCH() in zend_set_memory_limit() 2013-11-18 01:36:17 +01:00
krakjoe
f046189e34 export more Zend API 2013-11-17 22:39:31 +00:00
Igor Wiedler
611da37617 use ZVAL_ZVAL to init ZVAL from ZVAL 2013-11-09 13:48:23 -05:00
Igor Wiedler
eb063e0075 Merge remote-tracking branch 'lgnome/use-function' into use-function
* lgnome/use-function:
  Only check user functions for filenames.
2013-11-08 21:50:04 -05:00
Adam Harvey
cc049e6450 Only check user functions for filenames. 2013-11-08 21:49:05 -05:00
Igor Wiedler
719db1a7b2 Merge pull request #4 from LawnGnome/use-function
FIX ALL THE THINGS
2013-11-08 18:39:29 -08:00
Adam Harvey
da553a8166 Fix constant resolution. 2013-11-08 21:37:38 -05:00
Adam Harvey
95675dfba9 Remove now unused function_filenames struct. 2013-11-08 21:32:09 -05:00
Adam Harvey
1ea01f55db Look in the function_table instead of function_filenames for actually declared
functions.
2013-11-08 21:29:23 -05:00
Adam Harvey
9711c58bc4 Stop PHP from modifying the lowercase function name in place. 2013-11-08 20:26:46 -05:00
Igor Wiedler
24e0b99103 Merge remote-tracking branch 'upstream/PHP-5.6' into use-function
* 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
2013-11-08 19:14:58 -05:00
Bob Weinand
152898ff28 Moved arrays again to "static_scalar:" & little cleanup 2013-11-07 16:39:47 +01:00
Dmitry Stogov
e0135014c3 Renaming 2013-11-07 10:22:49 +04:00
Dmitry Stogov
9647c61dc1 Constant expressions refactoring 2013-11-06 22:21:07 +04:00
Ferenc Kovacs
117955daf6 bump API versions 2013-11-06 14:03:24 +01:00
Dmitry Stogov
af600c240d Merge branch 'const_scalar_exprs' of github.com:bwoebi/php-src into 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
2013-11-06 15:41:33 +04:00
Ferenc Kovacs
929bf11e91 bump API versions 2013-11-06 11:17:58 +01:00
Anatol Belski
c675980046 Merge branch 'pull-request/500'
* 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
2013-11-05 19:23:23 +01:00
Bob Weinand
18e2b1a9a9 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.
2013-11-03 12:28:00 +01:00
Bob Weinand
ad967e1329 Added a few more operators 2013-11-03 01:58:39 +01:00
Anatol Belski
699f07ba44 limit virtual_cwd_activate() duplicated call to ZTS only 2013-11-02 13:32:31 +01:00
Bob Weinand
82cd3779f4 Whitespace fix 2013-11-01 16:49:23 +01:00
Bob Weinand
b45043a1b7 converted several switches to ifs and made more opcache friendly 2013-11-01 16:16:58 +01:00
Anatol Belski
9df78bf9fd reverted the previous commit, both calls are needed in TS mode 2013-11-01 01:20:57 +01:00
Anatol Belski
6aedfac7f7 virtual_cwd_activate() should be called only in one place 2013-11-01 00:56:22 +01:00
Anatol Belski
f1c2f8f9f1 removed unnecessary call 2013-10-31 21:38:24 +01:00
Bob Weinand
b56c1ca95e Fatal error about self referencing constants fixed 2013-10-31 19:05:29 +01:00
Bob Weinand
466c5dd1fe Fixed mem leaks, added tests and ternary operator 2013-10-31 18:21:37 +01:00
Anatol Belski
4d430ecb02 simplify the state free macros 2013-10-31 17:39:17 +01:00
Bob Weinand
2361745806 Working commit for constant scalar expressions (with constants).
Tests will follow.
2013-10-31 08:57:12 +01:00
Dmitry Stogov
3b2ca392f1 Removed unnecessary GC checks 2013-10-31 11:33:39 +04:00
Anatol Belski
abb962d54d compact the code to preserve the error info after state freeing 2013-10-30 20:46:08 +01:00
Anatol Belski
e17de5e9fd Merge branch 'bug50333' of github.com:weltling/php-src into bug50333 2013-10-29 17:15:40 +01:00
Nikita Popov
d86b5f01ac Avoid copy in func_get_arg()
Complements dmitry's change to func_get_args()
2013-10-28 19:51:31 +01:00
Dmitry Stogov
592be912c2 Merge branch 'PHP-5.5'
* PHP-5.5:
  Use zval* instead of zval**

Conflicts:
	Zend/zend_vm_def.h
	Zend/zend_vm_execute.h
2013-10-28 15:23:10 +04:00
Dmitry Stogov
2d14cc2a49 Use zval* instead of zval** 2013-10-28 14:44:07 +04:00
Dmitry Stogov
9bbdc90ed2 Merge branch 'PHP-5.5'
* PHP-5.5:
  Improved performance of func_get_args() by eliminating useless copying

Conflicts:
	NEWS
2013-10-28 13:19:08 +04:00
Dmitry Stogov
91b8a6752e Improved performance of func_get_args() by eliminating useless copying 2013-10-28 13:17:55 +04:00
Anatol Belski
25dc4af392 enabled windows to use stack in both ts/nts mode, some more fixes 2013-10-24 08:48:09 -07:00
Anatol Belski
08f6a76b92 moved to do_alloca() usage where appropriate 2013-10-24 05:12:37 -07:00
Nikita Popov
a1ae79e114 Fix assignment in dummy_encoding_list_parser 2013-10-19 23:25:31 +02:00
Nikita Popov
64caedd927 Use zend_error_noreturn for all E_COMPILE_ERRORs 2013-10-19 23:22:20 +02:00
Xinchen Hui
30d64b0efb Merge branch 'PHP-5.4' into PHP-5.5 2013-10-19 13:27:36 +08:00
Michael Wallner
1fe1f7305b use $YACC instead of 'bison' as suggested by Yasuo
Conflicts:
	Zend/acinclude.m4
2013-10-19 13:27:24 +08:00
Anatol Belski
2786a2a1ab fixed all the places where last error could be lost
whereby this commit should be applied to master anyway
2013-10-18 07:00:05 -07:00
Anatol Belski
515ef09b62 preserve the error code
otherwise it'd be cleared by a subsequent calls
2013-10-18 05:01:16 -07:00
ArunSK
6b90f23787 fixed typo and few grammar mistakes 2013-10-17 22:00:40 -04:00
Anatol Belski
cf6ab0e915 applied and fixed the original patch
initial work on the patch import done
2013-10-17 10:40:43 +02:00
Anatol Belski
e30b2aae5a initial move on renaming files and fixing includes 2013-10-17 09:43:52 +02:00
Nikita Popov
d51553e399 Merge branch 'PHP-5.5' 2013-10-16 18:39:13 +02:00
Nikita Popov
865f221627 Merge branch 'PHP-5.4' into PHP-5.5 2013-10-16 18:37:49 +02:00
bwoebi
4c0bb6d76e Fixed bug #65911 ($this not usable as static property)
In context of static accesses like classname::$this, the string
"$this" should not be handled like a $this variable, but as an
identifier for a static variable.
2013-10-16 18:33:14 +02:00
Igor Wiedler
602fef0e52 Clarify type of use in error messages 2013-10-14 23:32:11 +02:00
Igor Wiedler
e23ad4eeb2 Add "Done" output to distinguish hard from soft failures 2013-10-14 23:21:06 +02:00
Nikita Popov
ff46b6f633 Merge branch 'PHP-5.5' 2013-10-04 13:15:45 +02:00
Nikita Popov
536260f2c5 Fix bug #65821: By-ref foreach on property access of string offset segfaults
This removes the now unnecessary ZEND_FETCH_ADD_LOCK on the
container of a property fetch of a by-reference foreach.
2013-10-04 13:13:46 +02:00
Nikita Popov
cbf0683c6f Merge branch 'PHP-5.5' 2013-09-29 20:19:40 +02:00
Nikita Popov
6b68f44e6b Fix bug #64979: Wrong behavior of static variables in closure generators 2013-09-29 20:18:12 +02:00
Nikita Popov
9529b8f5c4 Merge branch 'PHP-5.5' 2013-09-29 18:01:42 +02:00
Nikita Popov
1d1fb69c8b Merge branch 'PHP-5.4' into PHP-5.5 2013-09-29 18:01:18 +02:00
Nikita Popov
f0c926564c Fix bug #65322: compile time errors won't trigger auto loading
Also fixes duplicate bugs #54054 and #42098.

Furthermore this fixes incorrect error messages thrown from code
running inside an error handler when a compilation is in progress.
The error file and line are now correctly associated with the
file/line of the executor, rather than the compiler.
2013-09-29 17:58:25 +02:00
Nikita Popov
0ceea8a2e8 Don't track parameter number in separate znode
We already track it in the op array already.
2013-09-26 19:43:32 +02:00
Nikita Popov
0d7a638866 Implement variadic function syntax
As per RFC: https://wiki.php.net/rfc/variadics
2013-09-26 18:39:17 +02:00
Remi Collet
c760ff1615 Merge branch 'PHP-5.5'
* PHP-5.5:
  Make message and format arguments const char * to avoid build warning about invalid cast.
2013-09-23 13:23:00 +02:00
Remi Collet
f7eff9cd41 Make message and format arguments const char * to avoid
build warning about invalid cast.
2013-09-23 13:21:57 +02:00
Michael Wallner
98e4ecb6f0 fix Zend/tests/ns_040.phpt failing
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.
2013-09-19 10:51:57 +02:00
Xinchen Hui
be581ec66d Exclude bison 3.0 by Mike 2013-09-17 16:54:27 +08:00
Nikita Popov
bdfa03d79d Save a TSRMLS_FETCH() for zval_ptr_dtor in executor
This gives me about 9% improvement on Zend/bench.php for a zts build.
2013-09-14 23:02:26 +02:00
Nikita Popov
8748e146b9 Fix intl build 2013-09-14 01:37:09 +02:00
Nikita Popov
91a9569d85 Fix two warnings 2013-09-13 20:01:23 +02:00
Nikita Popov
96b1c2145c Provide more macros for handling of interned strings
* str_erealloc behaves like erealloc for normal strings, but will
   use emalloc+memcpy for interned strings.
 * str_estrndup behaves like estrndup for normal strings, but will
   not copy interned strings.
 * str_strndup behaves like zend_strndup for normal strings, but
   will not copy interned strings.
 * str_efree_rel behaves like efree_rel for normal strings, but
   will not free interned strings.
 * str_hash will return INTERNED_HASH for interned strings and
   compute it using zend_hash_func for normal strings.
2013-09-13 19:42:10 +02:00
Nikita Popov
d2950ac279 Make use of Z_*VAL and ZVAL_* in language scanner 2013-09-13 15:08:01 +02:00
Nikita Popov
00799319f9 Make consistent use of Z_*VAL macros in compiler 2013-09-13 15:07:47 +02:00
Nikita Popov
ef9e003b0c Small cleanup in class name resolution of compiler
* The fetch_type and check_ns_name parameters of
   zend_resolve_class_name were unused and are now removed.
 * ZEND_FETCH_CLASS_GLOBAL is no longer used (no code actually
   checking for it).
 * The checks for usage of "namespace" as class name were
   unnecessary as that situation can't occur anyways.
2013-09-13 12:18:39 +02:00
Xinchen Hui
825c1f239b Merge branch 'PHP-5.5' 2013-09-02 16:16:15 +08:00
Xinchen Hui
b2ee1b629e Merge branch 'PHP-5.4' into PHP-5.5 2013-09-02 16:16:07 +08:00
Xinchen Hui
6c48c6bc78 Typo.... 2013-09-02 16:15:52 +08:00
Xinchen Hui
f33bdf68b1 Merge branch 'PHP-5.5' 2013-09-02 16:03:10 +08:00
Xinchen Hui
dd1cbd140b Merge branch 'PHP-5.4' into PHP-5.5 2013-09-02 16:02:59 +08:00
Xinchen Hui
ed038d2ee3 Add a XFAIL test for #64896 2013-09-02 16:02:24 +08:00
Gustavo André dos Santos Lopes
d515455589 Implement phase 1 of rfc/incompat_ctx
Just changing the error level of the message from E_STRICT to
E_DEPRECATED. This comes one version later than the timeline
mentioned in the RFC.

Oddly, there were no tests for this ‘feature’. I added a simple
one.
2013-09-02 01:53:06 +02:00
Nikita Popov
47ee470992 Make use of direct returns in some places 2013-08-31 13:16:50 +02:00
Nikita Popov
0856714576 Always pass return_value_ptr to internal functions
Previous some places passed return_value_ptr only if the function
returned by reference. Now return_value_ptr is always set, even
for functions returning by-value.

This allows you to return zvals without copying their contents. For
this purpose two new macros RETVAL_ZVAL_FAST and RETURN_ZVAL_FAST
are added:

    RETVAL_ZVAL_FAST(zv); /* Analog to RETVAL_ZVAL(zv, 1, 0) */
    RETURN_ZVAL_FAST(zv); /* Analog to RETURN_ZVAL(zv, 1, 0) */

These macros behave similarly to the non-FAST versions with
copy=1 and dtor=0, with the difference that the FAST versions
will try return the zval without copying by utilizing return_value_ptr.
2013-08-31 13:16:41 +02:00
Anthony Ferrara
612e77e5c9 Fix issue with global fallback not in global space 2013-08-30 11:55:43 -04:00
Anthony Ferrara
d7e3aca9c9 Fix issue with global fallback when not in global space 2013-08-30 11:53:57 -04:00
Xinchen Hui
a607a08e09 Merge branch 'PHP-5.5' 2013-08-30 11:23:24 +08:00
Xinchen Hui
e4fe53e200 Merge branch 'PHP-5.4' into PHP-5.5 2013-08-30 11:20:46 +08:00
Xinchen Hui
7da6498342 Fixed bug #60598 (cli/apache sapi segfault on objects manipulation) 2013-08-30 11:20:24 +08:00
Igor Wiedler
e14a769c56 Add test for conditional function declaration 2013-08-29 17:16:18 +02:00
Dmitry Stogov
462f2167ae Merge branch 'PHP-5.5'
* PHP-5.5:
  Fixed bug #61759 (class_alias() should accept classes with leading backslashes). (Julien)
  Fixed bug #61759 (class_alias() should accept classes with leading backslashes). (Julien)

Conflicts:
	NEWS
2013-08-29 11:20:12 +04:00
Dmitry Stogov
0f3977bc0f Merge branch 'PHP-5.4' into PHP-5.5
* PHP-5.4:
  Fixed bug #61759 (class_alias() should accept classes with leading backslashes). (Julien)
  Fixed bug #61759 (class_alias() should accept classes with leading backslashes). (Julien)

Conflicts:
	NEWS
2013-08-29 11:19:02 +04:00
Dmitry Stogov
dfc6feb6e8 Fixed bug #61759 (class_alias() should accept classes with leading backslashes). (Julien) 2013-08-29 11:16:56 +04:00
Xinchen Hui
0ea00936be Merge branch 'PHP-5.5' 2013-08-29 14:02:53 +08:00
Xinchen Hui
e356d790cc Merge branch 'PHP-5.4' into PHP-5.5 2013-08-29 14:02:34 +08:00
Xinchen Hui
747daa5354 Avoid compiler warning 2013-08-29 14:02:15 +08:00
Xinchen Hui
f0cb67402f Merge branch 'PHP-5.4' into PHP-5.5 2013-08-29 14:01:54 +08:00
Adam Harvey
72027cd084 Fix bug #65579 (Using traits with get_class_methods causes segfault).
Specifically, this checks if there are trait aliases defined in the class scope
before attempting to dereference the first trait alias. This handles the case
where a trait alias was used in a child trait but no aliases exist in the
concrete class.
2013-08-28 20:33:42 -07:00
Xinchen Hui
72f80b2997 Merge branch 'PHP-5.5' 2013-08-27 15:45:27 +08:00