You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Regression: nested string/scalar-return builtin in call argument evaluates to null (extends #9547, Zend/zend_execute.c) #10495
When a builtin that returns a string or other scalar (not only arrays) is used inline as an argument to another call, the nested expression evaluates to null instead of the return value. Assigning the same call to a variable first works.
Distinct from #9547 (array-return builtins such as array_keys() / stream_get_filters()). Same root cause class — nested FUNCCALL return slot not forwarded — but string/scalar returns are still broken.
Fix: When php-cfg hoists trailing literal ConstFetch between nested FuncCall nodes (var_export(get_debug_type(null), true)), wire inner FUNCCALL_EXEC_RETURN to outer TYPE_ARG_SEND via isNestedCallArgProducerSeparatedByConsumerLiteralPreludes() in lib/Compiler.php.
Fix:compileCallArgSends no longer skips findInlineExprCallArgProducerSlot when hasProducer is true for php-cfg dead nested-call arg temps (var_export(get_debug_type(null), true) pattern).
Activity
PurHur commentedon Jun 22, 2026
claim: cursor-agent-lane-c — starting this run
Fix nested scalar-return builtin call args evaluating to null (#10495)…
PurHur commentedon Jun 22, 2026
Merged via #10582.
Fix: When php-cfg hoists trailing literal
ConstFetchbetween nestedFuncCallnodes (var_export(get_debug_type(null), true)), wire innerFUNCCALL_EXEC_RETURNto outerTYPE_ARG_SENDviaisNestedCallArgProducerSeparatedByConsumerLiteralPreludes()inlib/Compiler.php.Verification:
```bash
./script/docker-exec.sh -- bash -lc 'source script/php-env.sh
php bin/vm.php -r "echo var_export(get_debug_type(null), true), "\n";"
./vendor/bin/phpunit --filter nested_string_builtin_arg test/compliance/
'
```
VM prints
'null'(wasNULL); compliancenested_string_builtin_arg.phptgreen.Fix arrow fn $this outside object context (#10558) (#10584)
PurHur commentedon Jun 22, 2026
claim: cursor-agent-lane-c — starting this run (continuation on agent/issue-10495-nested-string-builtin-arg)
PurHur commentedon Jun 22, 2026
Merged via #10586.
Fix:
compileCallArgSendsno longer skipsfindInlineExprCallArgProducerSlotwhenhasProduceris true for php-cfg dead nested-call arg temps (var_export(get_debug_type(null), true)pattern).Verification (Docker):
VM prints
'null','NULL','null','stdClass'; unit test green.Fix nested scalar-return builtin call args evaluating to null (#10495)…