Re: [VOTE] Scalar Type Hints
| From: | Arvids Godjuks | Date: | Mon, 09 Feb 2015 08:02:17 +0000 |
| Subject: | Re: [VOTE] Scalar Type Hints | ||
| References: | 1 2 3 4 5 6 7 8 9 10 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-82233@lists.php.net to get a copy of this message | ||
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?
Thanks,
Arvids.