On 5/11/17 7:12 PM, deadalnix wrote:
On Thursday, 11 May 2017 at 12:26:11 UTC, Steven Schveighoffer wrote:
if(arr) -> same as if(arr.ptr)
Nope. It is:
if(arr) -> same as if(((cast(size_t) arr.ptr) | arr.length) != 0)
Should we conclude from the fact that absolutely nobody gets it right in
this very forum that nobody will get it right outside ? I'll let you judge.
But this still doesn't mean that *all* bool conversions are value based.
In at least the struct and class cases, more than just the bits are checked.
-Steve