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
CallableFactory checks for ReflectionType and then calls isBuiltin()/getName(). Those methods only exist on ReflectionNamedType, not ReflectionUnionType or ReflectionIntersectionType. A valid callable with a union/intersection parameter therefore triggers an engine Error instead of the factory's descriptive invalid-parameter exception.
Evidence / executed reproduction
Audited commit 67865fa35231c11e38c9facbfe775e0c5fbe2461. CallableFactory.php:83–97.
On PHP 8.4.26, invoking:
produces Error: Call to undefined method ReflectionUnionType::isBuiltin() before any container lookup. No remote operation performed.
Expected / acceptance criteria
The existing documented scope is named class/interface arguments; this task does not request union/intersection autowiring support. Guard with ReflectionNamedType before using named-type methods and reject unsupported composite types through the existing RuntimeException::forInvalidParameterType path. Add union, intersection and DNF regression cases, as well as the existing scalar/untyped checks.
Priority P3; confidence high, dynamically reproduced with unmodified source. Direct callers currently cannot handle this using the documented factory error convention; ServiceProviderContainer may wrap the engine error, but the diagnostic remains incorrect.
Dedupe: reviewed all current and historical issues/PRs (#5–#49). This is independent of extension composition #48/#49 and native constructor autowiring #17/#18. No code, merge, release or deployment changes were made.
Activity