Re: [PHP-DEV] Warning for "confusable" types

This is only part of a thread. view whole thread
  107539
October 14, 2019 08:17 gertp93@gmail.com (Gert)
On that note, since traits aren't possible as a return type. Would it
be possible to determine that the given return type is a trait? In
that case a more specific error message could also be possible.
I don't know much of the internals, so i don't know if that is even
possible atm, but it would be a nice addition.

On Mon, 14 Oct 2019 at 09:53, Stanislav Malyshev <smalyshev@gmail.com> wrote:
> > Hi! > > > I was about to give my +1 on the more generic approach, but type hints > > could also be interfaces and "instance of the class X" is not a good fit. > > We could use "class or interface" if that's important. > > -- > Stas Malyshev > smalyshev@gmail.com > > -- > PHP Internals - PHP Runtime Development Mailing List > To unsubscribe, visit: http://www.php.net/unsub.php >