News for hackers. Stuff that matters.
Re:Google broke a conditional statement that verifies passwo... by dataflow on Friday July 23, 2021 @03:06AM (#27928022)
I would imagine has_value is checking to see if a pointer is NULL, and -> is dereferencing that same pointer. When the optimizer sees the two together it realizes the former is useless.
Re:Google broke a conditional statement that verifies passwo... by ddalex on Friday July 23, 2021 @06:43AM (#27929221)
by this logic the compiler would optimize any short-circuiting because it KNOWS the programmer WOULD NEVER deference an invalid pointer
Re:Google broke a conditional statement that verifies passwo... by jhasse on Friday July 23, 2021 @08:55AM (#27930116)
no, & is not short-circuiting