Re: RFC [Discussion]: Marking overridden methods (#[\Override])

From: Date: Sat, 27 May 2023 10:40:44 +0000
Subject: Re: RFC [Discussion]: Marking overridden methods (#[\Override])
References: 1 2 3 4 5  Groups: php.internals 
Request: Send a blank email to internals+get-120404@lists.php.net to get a copy of this message
On Mon, 22 May 2023 at 22:32, David Gebler <davidgebler@gmail.com> wrote: > > either you use static analysis tools as part of your PHP workflow, because > you care about that stuff, or you don't. I these words imply an unpleasant connotation; that people who don't use static analysis tools are bad people who don't care about their code. Just because someone doesn't use the same tools that 'good' programmers who care about their code use, doesn't mean that they 'deserve' to be punished for doing not having having setup those tools*. > I would argue means any new runtime check > warrants the utmost consideration of cost-benefit. The Override annotation is a small thing that we can add to PHP, that has a very low cost, and would benefit programmers who haven't had enough time/experience to setup static analysis tools. It appears to be a 'positive sum' proposal. Or as Ilija Tovilo wrote: > > The benefits seem worth the maintenance cost, even if small for the > average user. cheers Dan Ack * At least in this case, because having to deal with code that uses inheritance is already punishment enough.

« previous php.internals (#120404) next »