[PHP-DEV] PHP7 Coalesce operator

2015-11-22 Thread shadda
Hey all. Been a while since I popped into this list. You may remember me from such emails as “Why god can’t we have namespaces”, or “so we’re still not fixing strpos, eh?” I had a question-suggestion based around the cool new operator we’re getting in PHP7, the ?? operator, which as I understan

Re: [PHP-DEV] PHP7 Coalesce operator

2015-11-23 Thread shadda
feature that was less concerned with a (defined|null) semantic and more in keeping with PHP’s overall handling of implicit type conversion in expressions. Does that make more sense? > On Nov 22, 2015, at 12:41 PM, Andrea Faulds wrote: > > Hi, > > shadda wrote: >> I had a ques

Re: [PHP-DEV] PHP7 Coalesce operator

2015-11-23 Thread shadda
Er, that should read, “anything non (null, false, undefined) is true” > On Nov 23, 2015, at 11:51 AM, shadda wrote: > > Hey, thanks for responding. > > However, I still think that misses the point, or at least the true utility of > what I’m proposing. > > In

Re: [PHP-DEV] PHP7 Coalesce operator

2015-11-23 Thread shadda
Oh, please, by no means take that as an endorsement for dropping error reporting levels. It was just an observation of how PHP actually derives a conditional in those situations. It’s not as if there’s a fatality in script execution when you make that kind of comparison, it’s just a really shitt

Re: [PHP-DEV] PHP7 Coalesce operator

2015-11-23 Thread shadda
/undefined exclusively. > On Nov 23, 2015, at 12:08 PM, Phil Sturgeon wrote: > > On Mon, Nov 23, 2015 at 9:52 AM, shadda wrote: >> Er, that should read, “anything non (null, false, undefined) is true” >> >>> On Nov 23, 2015, at 11:51 AM, shadda wrote: >&

Re: [PHP-DEV] PHP7 Coalesce operator

2015-11-23 Thread shadda
son in elvis to > "coalesce" to a default > $var = ($_GET['possible_value'] ?? $_COOKIE['secondary'] ?? false) ?: > DEFAULTS['var']; > > On Mon, Nov 23, 2015 at 1:16 PM, shadda <mailto:sha...@gmail.com>> wrote: > It’s not hate, I happen