Re: Class Extension

From: Date: Fri, 10 Jul 2026 12:14:38 +0000
Subject: Re: Class Extension
References: 1 2 3  Groups: php.internals 
Request: Send a blank email to internals+get-131854@lists.php.net to get a copy of this message
On 10 July 2026 12:53:39 BST, Holly Schilling <holly.a.schilling@outlook.com> wrote: > What I was referring to is that at compile-time from inside a function of the trait, it can > only call members known to the trait. There is no such check in PHP. Static Analysis tools may warn about it, but a trait will compile fine with code that refers to unknown members. The code will then succeed or fail at runtime just like any other object access: <https://3v4l.org/QIPsL> Regards, Rowan Tommins [IMSoP]

« previous php.internals (#131854) next »