Re: [CONCEPT][DISCUSSION] Allow objects to declareemptiness and by extension truthiness

From: Date: Tue, 14 Jul 2020 18:24:20 +0000
Subject: Re: [CONCEPT][DISCUSSION] Allow objects to declareemptiness and by extension truthiness
References: 1 2 3 4  Groups: php.internals 
Request: Send a blank email to internals+get-111004@lists.php.net to get a copy of this message
> On Jul 13, 2020, at 12:14 PM, Christoph M. Becker <cmbecker69@gmx.de> wrote: > > On 13.07.2020 at 17:18, Josh Bruce wrote: > >> Re the wiki: I can edit pages now, it doesn’t look like I can create them. There’s >> another thread I’ve been watching and I think I need more karma to make that a thing. I will >> continue working on this and if it generates enough pull then maybe I’ll be let in - I’ll also >> contribute where I can to start earning karma. > > You have RFC karma now. Christoph: Wow, okay. Thank you! All: I’ve decided to go ahead and do one more round using GitHub (big changes - kind of a synthesis of directions so far based on feedback). Then I’ll spend time transferring it to a draft (or discussion??) and making sure I understand the process more than I do at present. Nikita: Re falsiness: Switching back to being more about truthiness and falsiness. Thanks for the feedback. Re nullsafe: I agree that nullsafe handles the issue of null being returned and it’s a welcomed workaround, but it doesn’t address the problem of null being returned instead of a false (empty) object of the desired type that can be acted upon - even if limited. Brings up the new question again: Under what circumstances would PHP return null without a developer explicitly asking it to (somewhere in the call chain) or without PHP error? Cheers, Josh

« previous php.internals (#111004) next »