Re: [VOTE] Scalar Type Hints

From: Date: Mon, 09 Feb 2015 08:04:09 +0000
Subject: Re: [VOTE] Scalar Type Hints
References: 1 2 3 4 5 6 7 8 9 10 11  Groups: php.internals 
Request: Send a blank email to internals+get-82234@lists.php.net to get a copy of this message
On Mon, Feb 9, 2015 at 3:02 PM, Arvids Godjuks <arvids.godjuks@gmail.com> wrote: > I actually have a question, that Ferenc touched on, but it never got any > discussion. > > How, actually, the declare will work with concatenated PHP files? It's > quite a common practice to put the files into packages, that require > minimal amounts of includes for performance reasons. > Declare is required to be a the top of a file as a first statement. So, if > I have like 10 packages from composer written in different styles, how > should I actually combine them? Stripping the declare from each file and > putting a single declare with the type hint level I want? What will happen > if a library is written for weak type hints ends up in strict type hint > mode? Or the other way around? Isn't it gonna be a mess? How do you do it for namespaces? This is the same issue. Cheers, -- Pierre @pierrejoye | http://www.libgd.org

« previous php.internals (#82234) next »