Greg Hurrell <[EMAIL PROTECTED]> writes: > El 28/03/2006, a las 20:43, Tony Lewis escribió: > >> Hrvoje Niksic wrote: >> >>> The cast to int looks like someone was trying to remove a warning and >>> botched operator precedence in the process. >> >> I can't see any good reason to use "," here. Why not write the line >> as: >> eta_hrs = eta / 3600; eta %= 3600; > > Because that's not equivalent.
Well, it should be, because the comma operator has lower precedence than the assignment operator (see http://tinyurl.com/evo5a, http://tinyurl.com/ff4pp and numerous other locations). I'd still like to know where Thomas got his version of progress.c because it seems that the change has introduced the bug.