Anatol Belski
a97f764472
bring back the division by zero warning
2015-07-05 20:18:17 +02:00
Aaron Piotrowski
1a0ddf988c
Switch code on thrown Errors to 0, update related tests
2015-07-03 17:53:42 -05:00
Xinchen Hui
e8f992c163
Catch the specifical exception
2015-07-03 11:18:53 +08:00
Aaron Piotrowski
68baa539dc
Allow integer default for float type
2015-07-02 18:07:24 -05:00
Bob Weinand
007d7ac7ca
Use DivisionByZeroError instead of exception for %/intdiv()
2015-07-02 02:20:58 +02:00
Bob Weinand
f9724b93f6
Remove warning upon division by zero
2015-07-02 02:20:58 +02:00
Aaron Piotrowski
f7565a93d8
Add tests for dynamic static call to instance method
2015-06-30 07:07:17 +02:00
Bob Weinand
dd2e6e866d
Fix test failures from previous commit
...
(I really don't get that issue in phar... if there's a better fix, it's welcome...)
2015-06-30 07:02:56 +02:00
Dmitry Stogov
0b35e4a3be
Revert "Fixed last previously broken tests"
...
This reverts commit 79b1832dd5
.
2015-06-29 13:05:14 +03:00
Dmitry Stogov
642c379092
Prevent attempts of compile-time evaluation of invalid operators (e.g. division/modulo by zero and shift by negative number)
2015-06-29 12:58:07 +03:00
Dmitry Stogov
1bba4452e7
Reverted wrong fb08798c9f
2015-06-29 12:20:09 +03:00
Dmitry Stogov
8e923197b4
Fixed bug #69955 (Segfault when trying to combine [] and assign-op on ArrayAccess object). (Laruence)
2015-06-29 11:17:56 +03:00
Bob Weinand
79b1832dd5
Fixed last previously broken tests
2015-06-29 01:00:12 +02:00
Bob Weinand
e5fae77969
Show full signature upon inheritance mismatch
2015-06-29 01:00:12 +02:00
Bob Weinand
fb08798c9f
Fix bug #69957 (Different ways of handling div/mod by zero)
2015-06-28 18:22:59 +02:00
Bob Weinand
e96ad43ae6
Forgot to git add rope leak test
2015-06-28 15:44:53 +02:00
Bob Weinand
2894bc5bb8
Use ZEND_INIT_STATIC_METHOD_CALL for literals of form "classname::method"
2015-06-26 19:55:13 +02:00
Aaron Piotrowski
1d704a05ee
Fix closure leak test
2015-06-26 16:30:01 +02:00
Aaron Piotrowski
8bd95b8cdc
Fix test duplication, add more tests
2015-06-26 16:30:01 +02:00
Bob Weinand
1335ebd068
Fix Closure leak in aborted INIT_DYNAMIC_FCALL
2015-06-26 05:10:58 +02:00
Aaron Piotrowski
bc0df38e88
Added more indirect call tests, remove invalid test
2015-06-25 19:46:28 -05:00
Dmitry Stogov
90976c9978
Moved test to correct place
2015-06-25 11:22:21 +03:00
Nikita Popov
ea5c66ec93
Avoid op_num = -1 in unfinished generator cleanup
...
Also add two tests showing that the -1 substraction in the
computation of op_num is really necessary.
2015-06-23 20:17:30 +02:00
Dmitry Stogov
7a01c44ab2
Fixed bug #69905 (null ptr deref and segfault in ZEND_FETCH_DIM_RW_SPEC_VAR_UNUSED_HANDLER)
2015-06-23 16:26:40 +03:00
Nikita Popov
8a83aed458
Drop duplicate object-to-type notices
...
We already generate a recoverable fatal for these earlier, no need
to throw an additional notice.
2015-06-22 16:25:32 +02:00
Bob Weinand
3c288b12b4
Fix bad run_time_cache with Closure::call()
...
This also fixes a memory "leak" (memory is allocated on unbounded arena without limits) on each new Closure instantiation.
Closures with same scope now all share the same run_time_cache (as long as it is arena allocated)
2015-06-21 16:39:44 +02:00
Bob Weinand
115e9288bb
Fix segfault with scalar passed to typehint with not loaded class
2015-06-21 01:35:22 +02:00
Bob Weinand
ffe0f470d6
Fix bad test (oops)
2015-06-20 18:59:47 +02:00
Nikita Popov
6a4877ee17
Add test for previous commit
2015-06-20 18:38:59 +02:00
Bob Weinand
7adc0ae631
Fix potential writes into wrong memory, ensure vm_stack integrity
...
Fixes also a segfault on stack frames > 1 << 18 bytes
Stack frames, when reallocated, need to be marked as top frame of current stack page
2015-06-20 18:29:09 +02:00
Nikita Popov
e8217a2727
Fix bug #69891
2015-06-20 17:23:58 +02:00
Nikita Popov
9589d26ef3
Merge branch 'PHP-5.6'
...
Conflicts:
Zend/zend_hash.c
2015-06-20 16:50:37 +02:00
Nikita Popov
e09d3155a1
Merge branch 'PHP-5.5' into PHP-5.6
2015-06-20 16:40:53 +02:00
Nikita Popov
5fe078abba
Fixed bug #69892
2015-06-20 16:40:14 +02:00
Nikita Popov
9fa70dbd29
Fixed bug #69889
...
There is one case that requires further discussion:
$foo = "test";
var_dump($foo[0.0] ?? "default");
var_dump(isset($foo[0.0]) ? $foo[0.0] : "default");
Here the former will currently return "t", while the latter also
returns "t" and additionally throws a notice.
I think we need to revisit the behavior of invalid types for string
offset access in PHP 7, as currently there is some mismatch between
what isset() does and what the access itself supports.
2015-06-20 15:09:58 +02:00
Xinchen Hui
89fda08473
This test should be kept
2015-06-19 23:13:23 +08:00
Xinchen Hui
235c7edb8b
Revert "Fix bug #69871 (short-circuiting failure with smart_branch)"
...
This reverts commit fae6bedea5
.
2015-06-19 23:03:23 +08:00
Bob Weinand
fae6bedea5
Fix bug #69871 (short-circuiting failure with smart_branch)
2015-06-18 15:59:00 +02:00
Aaron Piotrowski
4fb362704c
Add tests with invalid Error construction params
2015-06-17 19:49:02 -05:00
Anatol Belski
e665b27623
fix c/p test title
2015-06-18 00:33:16 +02:00
Anatol Belski
577c1f3e95
preserve the orig class name when extending the ErrorException
2015-06-18 00:30:16 +02:00
Anatol Belski
8486505651
more tests
2015-06-18 00:15:34 +02:00
Christoph M. Becker
653c869348
Fix #61362 : Exception::getTraceAsString and ::__toString scramble Unicode
...
The logic in smart_str_append_escaped() relies on unsigned values of c, so we
have to declare it as such.
2015-06-17 22:31:07 +02:00
Anatol Belski
269acaa363
Merge branch 'pull-request/1284'
...
* pull-request/1284:
Rename interface macros
Fix typo in UPGRADING
Move definition of Throwable to zend_exceptions.h/c
Check for zend_ce_throwable instead
Fix some missed tests
Add Throwable tests
Fix previous exception type check
Updated UPGRADING with RFC link
Changed AssertionException to AssertionError
Update exception error messages
Throwable method signatures.
Update exception names in tests after formatting changes.
Merge exception formatting changes.
Make zend_get_exception_base static.
Fix a few missed tests.
Fix handler double copy.
Updated tests to reflect exception class changes.
Remodel exceptions based on Throwable interface
2015-06-17 21:55:03 +02:00
Bob Weinand
52e9a772a3
Fully fixing all the affected const expr cases (see bug #69832 )
2015-06-16 16:53:30 +02:00
Dmitry Stogov
3180b8e100
Fixed bug #69802 (Reflection on Closure::__invoke borks type hint class name) (onr more problem)
2015-06-16 13:29:17 +03:00
Dmitry Stogov
ed84bff445
Complete fix for problems related to bug #69802
2015-06-16 11:24:35 +03:00
Bob Weinand
9db81340ba
Fix bug #69832 (Assertion failure)
2015-06-15 17:43:09 +02:00
Aaron Piotrowski
77cf6d81b4
Fix some missed tests
2015-06-15 08:20:30 -05:00
Dmitry Stogov
33e71d5c20
Fixed bug #69802 (Reflection on Closure::__invoke borks type hint class name)
2015-06-15 15:44:44 +03:00