1
0
mirror of https://github.com/php/php-src.git synced 2026-03-29 03:32:20 +02:00
Commit Graph

15 Commits

Author SHA1 Message Date
Tim Düsterhus
f8b57ff1bf zend_execute: Suppress values in UnhandledMatchError for zend.exception_ignore_args=1 (#17619)
Fixes php/php-src#17618.
2025-01-31 10:19:49 +01:00
Máté Kocsis
c322da0606 Fix misleading pass by reference error message (#10639) 2023-07-18 15:02:38 +02:00
George Peter Banyard
3d4ff5ae22 RFC: Deprecate remains of string evaluated code assertions (#11671)
Link: https://wiki.php.net/rfc/assert-string-eval-cleanup
2023-07-13 15:45:32 +01:00
Ilija Tovilo
3a76f795f8 Fix incorrect match default branch optimization
Fixes GH-11134
Closes GH-11135
2023-04-26 15:19:20 +02:00
Dmitry Stogov
c3766c08f4 Fix SCDF cleanup of unused basic block, kept only because of FREE of a loop var
Fixes oss-fuzz #41516
2021-12-01 18:03:08 +03:00
Nikita Popov
64878757be Fix scdf loop var free check for phi vars
The variable may come from a phi node, in which case we should
take the defining block from it.

Fixes oss-fuzz #40453.
2021-11-01 11:03:17 +01:00
Nikita Popov
493c91c742 Start new block after loop free
In the attached test case we ended up not updating a leftover
MATCH jump in the unreachable_free block. There's different ways
this can be addressed, but in this case we can just make sure that
a new block is started after the loop free, which will allow it
to be dropped as unreachable. We only need to retain the free
itself for live-range reconstruction.

Fixes oss-fuzz #39516.
2021-10-04 16:59:46 +02:00
Nikita Popov
1e4a9a4999 Merge branch 'PHP-8.0' into PHP-8.1
* PHP-8.0:
  Fix block marking for two arm math
2021-09-28 10:38:22 +02:00
Nikita Popov
17d6efc729 Fix block marking for two arm math
This would end up taking the successors_count=2 case, even though
we need to treat SWITCH and MATCH differently. This incorrectly
marked a block as FOLLOW, resulting in incorrect block pass
optimization.

Fixes oss-fuzz #39380.
2021-09-28 10:37:54 +02:00
Joe Watkins
05ef6334cd Fix bug #81303 improve match errors 2021-08-02 17:31:26 +02:00
Máté Kocsis
9975986b7e Improve error messages mentioning parameters instead of arguments
Closes GH-5999
2020-09-09 10:47:43 +02:00
Levi Morrison
853eb8373f Default assert.exception to 1 2020-08-02 13:39:35 -06:00
Ilija Tovilo
1c967df5a0 Fix free of uninitialized memory in MATCH_ERROR
As suggested by Tyson Andre:
https://github.com/php/php-src/pull/5371#issuecomment-657081464

Also fix line number of unhandled match error

Closes GH-5841.
2020-07-12 13:33:36 +02:00
Ilija Tovilo
d5a0370828 [skip ci] Consistent match test closing tags 2020-07-11 16:50:51 +02:00
Ilija Tovilo
9fa1d13301 Implement match expression
RFC: https://wiki.php.net/rfc/match_expression_v2

Closes GH-5371.
2020-07-09 23:52:17 +02:00