Op 19-12-2021 om 00:18 schreef Paul "LeoNerd" Evans: > I think if you were to present this if/else code to anyone not > intimately familiar with this three-value logic idea, and tell them > there is a value you can put in $foo which makes neither branch > execute, they would look at you strangely and consider you quite mad. > > There may be a Lewis Carroll quote applicable here... My thoughts exactly. But even worse, this will introduce bugs in existing code, unless you need a feature flag for this to happen, in which case code without the feature flag (for instance a library called from code that uses unknown) running against this situation probably should die. Silently skipping both branches of an if is insane if not guarded by a feature flag and only slightly less insane with. So what to do? Make such code die? But that reintroduces the original problem, then we have a new singleton value which avoids many calls to defined(), just to replace them with calls to is_unknown() (in other places, but still). I do think there must be a satisfactory answer to this question before we can proceed with implementation. It does not have to stand in the way of an RFC. HTH, M4Thread Previous | Thread Next