------- Comment #3 from tromey at gcc dot gnu dot org 2008-05-05 22:27 ------- fold_binary sees both MAX_EXPRs and reassociates. (I think this is why it works with intermediate variables.)
Then associate_trees creates a new MAX_EXPR, converting each argument to unsigned: return fold_build2 (code, type, fold_convert (type, t1), fold_convert (type, t2)); So, this is where the error enters. I'm not sure where this is best fixed though. -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=36137