The two are not the same. The first will never evaluate Foo()
because the 1
short-circuits the ||
.
Why it’s done – probably someone wanted to force entry in the then
branch for debugging purposes and left it there. It could also be that this was written before source control, so they didn’t want the code to be lost, rather just bypassed for now.