Commit graph

1699 commits

Author SHA1 Message Date
CrazyMiaoo
9df15fc26b Add gcc global register for aarch64 2019-04-22 14:29:30 +03:00
Dmitry Stogov
150c5e04e9 Merge branch 'PHP-7.4'
* PHP-7.4:
  Removed tests that always (or almost always) true
2019-04-15 13:19:39 +03:00
Dmitry Stogov
cb3cfc9ff8 Removed tests that always (or almost always) true 2019-04-15 13:18:16 +03:00
Dmitry Stogov
55cc280429 Backported call frame initialization improvement 2019-04-12 02:35:42 +03:00
Dmitry Stogov
39505764ad Merge branch 'PHP-7.4'
* PHP-7.4:
  Replace "ZEND_CALL_CTOR" hack by additional live-range
2019-04-12 01:01:47 +03:00
Dmitry Stogov
88a2268d6b Replace "ZEND_CALL_CTOR" hack by additional live-range 2019-04-12 00:49:45 +03:00
Dmitry Stogov
cc900edd77 Simplify call frame initialization 2019-04-11 02:08:32 +03:00
Dmitry Stogov
2a310b24d6 Merge branch 'PHP-7.4'
* PHP-7.4:
  Repare SWITCH VM
2019-04-09 01:17:36 +03:00
Dmitry Stogov
fe0a0897ba Merge branch 'PHP-7.3' into PHP-7.4
* PHP-7.3:
  Repare SWITCH VM
2019-04-09 01:17:10 +03:00
Joe Watkins
ade73c360c
Merge branch 'PHP-7.4'
* PHP-7.4:
  typo
2019-04-05 07:57:54 +02:00
Markus Staab
87b62fe7bc
typo 2019-04-05 07:57:43 +02:00
Dmitry Stogov
5b34c87d18 Merge branch 'PHP-7.4'
* PHP-7.4:
  Optimized "smart branch" instructions
2019-04-05 00:26:20 +03:00
Dmitry Stogov
d6848625d7 Optimized "smart branch" instructions 2019-04-05 00:25:45 +03:00
Nikita Popov
513b76794b Make zpp failures always throw, independent of strict_types
Previously zend_parse_parameters (and FastZPP) would handle invalid
arguments depending on strict_types: With strict_types=1, a TypeError
is thrown, with strict_types=0 a warning is thrown and (usually) NULL
is returned. Additionally, some functions (constructors always and
other methods sometimes) opt-it to throwing regardless of strict_types.

This commit changes zpp to always generate a TypeError exception in
PHP 8.
2019-03-11 11:32:20 +01:00
Nikita Popov
472f577679 Merge branch 'PHP-7.4'
[ci skip]
2019-03-01 16:14:20 +01:00
c9s
7c351ba65c Fix out-dated docs and typo
[ci skip]
2019-03-01 16:14:11 +01:00
Nikita Popov
dae056420d Merge branch 'PHP-7.4' 2019-02-20 12:12:27 +01:00
Nikita Popov
a92db42568 Use "modify" error message for FUNC_ARG fetch as well
Avoid differences based on whether a W or FUNC_ARG fetch is performed.
2019-02-20 11:54:22 +01:00
Peter Kokot
18295b396f Merge branch 'PHP-7.4'
* PHP-7.4:
  Fix typos in code comments in Zend/ [skip ci]
2019-02-18 17:56:38 +01:00
Tyson Andre
da3316ff0f Fix typos in code comments in Zend/ [skip ci] 2019-02-18 17:56:28 +01:00
Nikita Popov
faaf510fa4 Merge branch 'PHP-7.4' 2019-02-14 14:02:32 +01:00
Nikita Popov
adf2f39745 Fix build without global regs 2019-02-14 14:01:39 +01:00
Nikita Popov
924142fef0 Merge branch 'PHP-7.4' 2019-02-14 12:51:39 +01:00
David Walker
e63febb1c7 Fixed bug #75921
Ensure that the "creating default object from empty value" warning is
always thrown. Previously some cases were missing the warning, in
particular those going through FETCH_OBJ_W rather than a dedicated
opcode (like ASSIGN_OBJ).

One slightly unfortunate side-effect of this change is that something
like $a->b->c = 'd' will now generate two warnings rather than one
when $a is null (one for property b, one for property c).
2019-02-14 12:50:25 +01:00
Dmitry Stogov
e17667abd5 Merge branch 'PHP-7.4'
* PHP-7.4:
  More accurate handling of global registers (allow VM with single global register)
2019-02-12 17:39:55 +03:00
Dmitry Stogov
626bc3a2de More accurate handling of global registers (allow VM with single global register) 2019-02-12 17:39:02 +03:00
Nikita Popov
a302d11610 Don't silence fatal errors with @ 2019-02-11 16:17:55 +01:00
Nikita Popov
4f0abd8465 Merge branch 'PHP-7.4' 2019-02-08 12:44:19 +01:00
Nikita Popov
0d4471fd28 Fix double free if post inc of typed property throws
We either need to add an extra ref because the copy is used as the
retval, which is freed by HANDLE_EXCEPTION, or we need to undef it
(done here).
2019-02-08 12:43:11 +01:00
Dmitry Stogov
f45e0ce928 Remove ZEND_OVERLOADED_FUNCTION and corresponding call_method object handler 2019-02-07 21:05:46 +03:00
Dmitry Stogov
91ef4124e5 Refactor zend_object_handlers API to pass zend_object* and zend_string* insted of zval(s). 2019-02-04 13:20:25 +03:00
Peter Kokot
623911f993 Merge branch 'PHP-7.4'
* PHP-7.4:
  Remove local variables
2019-02-03 21:23:18 +01:00
Peter Kokot
92ac598aab Remove local variables
This patch removes the so called local variables defined per
file basis for certain editors to properly show tab width, and
similar settings. These are mainly used by Vim and Emacs editors
yet with recent changes the once working definitions don't work
anymore in Vim without custom plugins or additional configuration.
Neither are these settings synced across the PHP code base.

A simpler and better approach is EditorConfig and fixing code
using some code style fixing tools in the future instead.

This patch also removes the so called modelines for Vim. Modelines
allow Vim editor specifically to set some editor configuration such as
syntax highlighting, indentation style and tab width to be set in the
first line or the last 5 lines per file basis. Since the php test
files have syntax highlighting already set in most editors properly and
EditorConfig takes care of the indentation settings, this patch removes
these as well for the Vim 6.0 and newer versions.

With the removal of local variables for certain editors such as
Emacs and Vim, the footer is also probably not needed anymore when
creating extensions using ext_skel.php script.

Additionally, Vim modelines for setting php syntax and some editor
settings has been removed from some *.phpt files.  All these are
mostly not relevant for phpt files neither work properly in the
middle of the file.
2019-02-03 21:03:00 +01:00
Nikita Popov
aad39879f2 Remove bareword fallback for constants
Access to undefined constants will now always result in an Error
exception being thrown.

This required quite a few test changes, because there were many
buggy tests that unintentionally used bareword fallback in combination
with error suppression.
2019-01-31 13:52:06 +01:00
Nikita Popov
3d39479f4d Remove support for case-insensitive constants
The only remaining case-insensitive constants are null, true and
false, which are handled explicitly.

In the future we may convert them from constants to reserved keywords.
2019-01-31 13:52:06 +01:00
Nikita Popov
9c5ab992ac Merge branch 'PHP-7.4' 2019-01-31 09:40:01 +01:00
Nikita Popov
340c6d3927 Revert "Don't silence fatal errors with @"
This reverts commit abd36289e2.

This wasn't ready for merging yet, there are still some test
failures.
2019-01-31 09:39:10 +01:00
Joe Watkins
839bdf12ee
Merge branch 'PHP-7.4'
* PHP-7.4:
  Don't silence fatal errors with @
2019-01-31 07:11:18 +01:00
Nikita Popov
abd36289e2
Don't silence fatal errors with @ 2019-01-31 07:11:05 +01:00
Zeev Suraski
a81202ac49 Adios, yearly copyright ranges 2019-01-30 11:48:28 +01:00
Zeev Suraski
02557f87bc Adios, yearly copyright ranges 2019-01-30 11:23:29 +02:00
Nikita Popov
6c73b50cf6 Remove static calls to non-static methods 2019-01-30 09:19:02 +01:00
Dmitry Stogov
c69d830d45 Micro-optimization 2019-01-18 12:43:42 +03:00
Dmitry Stogov
77db3d524e Optimize zend_handle_fetch_obj_flags() 2019-01-18 01:22:14 +03:00
Dmitry Stogov
8661b6dd5d Reduce slow code size 2019-01-16 14:26:32 +03:00
Dmitry Stogov
fd27fd4a15 Fixed and improved incorrect usage of value_type argument. 2019-01-16 11:06:19 +03:00
Dmitry Stogov
0b21a4ba45 Separated zend_assign_to_typed_prop() 2019-01-16 02:13:43 +03:00
Dmitry Stogov
a5446cc01c Reuse zend_incdec_typed_ref() and separate zend_incdec_typed_prop() 2019-01-16 00:22:34 +03:00
Dmitry Stogov
938ba93f4a Separated zend_binary_assign_op_typed_ref() and zend_binary_assign_op_typed_prop() helpers 2019-01-15 18:49:05 +03:00
Dmitry Stogov
239305d12e Fixed uninitialized result of PRE_INC/PRE_DEC in case of exception.
Separated increment/decrement of typed reference into helper.
2019-01-15 18:03:46 +03:00