Re: Re: Alias for `int|float`

From: Date: Fri, 30 Sep 2022 09:04:46 +0000
Subject: Re: Re: Alias for `int|float`
References: 1 2  Groups: php.internals 
Request: Send a blank email to internals+get-118714@lists.php.net to get a copy of this message
2022-09-29 5:08 GMT+02:00, Hamza Ahmad <office.hamzaahmad@gmail.com>: > Hi Olle, > > I appreciate your idea of introducing a similar concept of typedef. > What if you write an RFC explaining that concept. I can join you > however in co-authoring this request. > > Seriously, I have had issues with writing such type again and again. > If you look at mixed type, it is indeed an alias of some union types. > Adding such an option to userland would lead to introduction of > various type hints. Plus, it will help devs write short hand aliases > for their intersection types. Note that my suggestion here is NOT about a project-global type alias, but an extension of the existing file-only alias, the use-statement. This can also explain the lack of reaction. :) Internal devs might already have consensus on the right way to proceed here, even if there's no RFC yet. Olle

« previous php.internals (#118714) next »