Because that scans as:
Variable x should be assigned if condition a true, otherwise b.
Variable x should be assigned if condition a true, otherwise b.
msg = if (status == 0) "done" else "error"msg = if status == 0 "done" else "error"
From a compiler perspective that's a bear to parse.