if (a && b)
/* Do something */
Does the compiler always compile the code above to check for "a" first and then "b"? If "a" is already false does the compiler continue checking "b"? Is it different between compiler versions or debug vs optimize mode? Sometimes "b" is a function that needs to run any frames so I don't want it to be optimized out if "a" is false. Other times, "b" isn't important and may be very expensive so I want it to be ignored if "a" is already false.
What about "else if"? If the first "if" statement is already true does the compiler continue to check the "else if" condition?