Repository navigation
Bug sweep 4: crashes, named args and spread, typed properties, hooks, case-insensitive lookup (#263 #459 #460 #462–#469 #472–#474 #476–#480 #482) - #486
Merged
Conversation
… array; name the function in an emit failure
…takes the table path instead of a per-site inline chain
…ike a plain dynamic call
…atch keys to parameter names in spread expansion (#462)
…ot the per-name inline chain
…rampolines only, hint-aware element reads
…e scope for readonly Non-numeric string into a typed int/float property (static and dynamic-name stores) raises TypeError; $this inside Closure::bind literals is live; a readonly slot is initialised once; a scalar cell bound to a class-typed function param raises TypeError. Fixes #466 Fixes #472 Fixes #484 Refs #471 (re-init guard only covers non-ctor-assigned readonly props) Refs #475 (repro added, not fixed)
… slots from object views Fixes #467
# Conflicts: # src/Parser/Parser.php
…ynamic ctors; collect named args into __call arguments Spread expansion now reads names for any possibly-keyed array operand (cell/erased vec, assoc), not only the module-flagged folded shape; known-closure spread path binds by name with defaults for gaps; spreadAheadOfPack defers a string-keyed literal to the emitter; an undeclared method on a statically known __call class receives the argument list as written (named keys kept) instead of being packed against another class's variadic. Fixes #463 Fixes #464 Fixes #465 Fixes #469 Fixes #476 Fixes #477
…into a typed slot
|
@blacktrs You’re iterating insanely fast 🔥 |
Contributor
Author
|
@EduardoMateos thanks! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Five fix groups from the open-issue triage, merged on top of main (with the tolerant parser, #481).
Crashes
$obj[0]on a class without ArrayAccess throwsErrorinstead of SIGBUS.__operator/__compareat run time. Unary minus and++/--are not covered.Front end and lookup
function/constitems inside a groupuse.?>inside a // line comment does not end PHP mode #447, A line comment ends at the closing tag, so a trailing comment before it still closes PHP mode #431–readonlyis accepted as a function name #433: already fixed on main; regression case added.Named arguments and spread (one binding path, cherry-picked from the
laravelwork)__call.Typed properties
intproperty is accepted silently instead of throwing TypeError "Cannot assign string to property Tp::$x of type int" #466, A dynamic-name store of a non-numeric string into a typed int property throws "Argument must be of type int, string given" instead of "Cannot assign string to property Tp::$x of type int" #472 a non-numeric string stored into a typed int/float property throwsTypeError: Cannot assign string to property C::$p of type int, through static, dynamic-name,.=and erased-cell stores.Hooks and objects
(array)of an Exception answers php's wrong key set: public unmangled message/code and internal traceNames/traceLines instead of 7 mangled entries. #467Exception/Errordeclare protected/private properties like php;(array),get_object_vars, json and compare views hide the trace slots.$this->$kto the wrong object #468$this->$kin a rebindable closure dispatches on the runtime class.Not fixed (stay open)
__callthrough an erased receiver.Evidence
Targeted runs only, on a fresh
bin/buildof this branch: 25 new cases green;-kprop 206, closure 110, spread_ 41, named 16, hook 8, readonly 8, exception 14, overload 3 all pass;xfail.sh25 XFAIL, 0 XPASS.Gates owed
Full AOT suite,
tools/difftest.sh,tools/selfhost_fixpoint.sh, Linux gate.Fixes #263 Fixes #459 Fixes #460 Fixes #462 Fixes #463 Fixes #464 Fixes #465 Fixes #466 Fixes #467 Fixes #468 Fixes #469 Fixes #472 Fixes #473 Fixes #474 Fixes #476 Fixes #477 Fixes #478 Fixes #479 Fixes #480 Fixes #482
Refs #471 #475 #484