Skip to content

Commit 4d5c2d3

Browse files
committed
Review
1 parent b362aca commit 4d5c2d3

2 files changed

Lines changed: 3 additions & 3 deletions

File tree

Zend/Optimizer/dfa_pass.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -479,7 +479,7 @@ static uint32_t zend_dfa_optimize_calls(zend_op_array *op_array, zend_ssa *ssa)
479479
if (send_opline->op1_type == IS_CONST) {
480480
zval *value = CT_CONSTANT_EX(op_array, send_opline->op1.constant);
481481
if (Z_TYPE_P(value) == IS_CONSTANT_AST) {
482-
/* Const exprs can evaluate to non-cont zvals (e.g. objects), and are not idempotent */
482+
/* Const exprs can evaluate to non-const zvals (e.g. objects), and are not idempotent */
483483
continue;
484484
}
485485
const_args |= (1 << i);

Zend/tests/partial_application/const_arg_opt.phpt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ $f(2);
5151
echo "# Constant pre-bound argument (inverted):\n";
5252
$f = f(?, 2);
5353
print_lexical_vars($f);
54-
$f(2);
54+
$f(1);
5555

5656
echo "# Inlined pre-bound argument:\n";
5757
$f = f(g(), ?);
@@ -106,7 +106,7 @@ array(2) {
106106
no lexical vars
107107
array(2) {
108108
[0]=>
109-
int(2)
109+
int(1)
110110
[1]=>
111111
int(2)
112112
}

0 commit comments

Comments
 (0)