[tree-ssa] Why are bools cast to int in conditionals?

Joseph S. Myers jsm@polyomino.org.uk
Thu Apr 22 17:49:00 GMT 2004


On Thu, 22 Apr 2004, Joe Buck wrote:

> This is a case where C and C++ differ.  The type of the != operator is
> bool in C++.

Fold must of course preserve the type of the result of !=.  That doesn't 
mean it can't narrow the operands.

-- 
Joseph S. Myers
jsm@polyomino.org.uk



More information about the Gcc mailing list