Hello Oliver,

Oliver Grätz wrote:

If I read Jessie correctly, the parser will throw an error now if the
usage is unclear with the ternary (a:b:c:d). So the real problem is when
namespace constants are not used but the parser thinks that he's reading
some:

$a = ($b)? c:d;

Are c and d constants or is this the constant d in the namespace c?
More problems arise if the thrid argument is made optional (wasn't this
raised with the ifsetor issue?). OK, I get the problem.

Jessie, what are you parsing from the thing up there? Will you eat this
as class constant or will this correctly be read as "constant a, else
constant b"?


This will be parsed as constant d in namespace c. This is valid code currently and I won't be surprised if it's used in many places, so I'm convinced now that forcing whitespace usage is no good.

Then again: I don't need namespace constants, but what about the
existing defined constants in globals namespace? Will they stay global
until they're all put into classes?

OLLi

I'll have to take them out for now. I just got an idea this morning that might solve this, but for now, they're scrapped.


Regards,

Jessie

--
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to