It is a function that is not really complex:

var ifelse(BOOL c,var a,var b) { if(c) return a; return b; }

And yes, unlike ?: all branches are executed. For not executing branches we're using the old fashioned if.