News for hackers. Stuff that matters.
Re:The joy of max() by loeg on Friday March 30, 2018 @11:26PM (#16721519)
Does this coerce distinct type a and b, or just fail if they are different types? The C one will evaluate the comparison / trinary expression via the usual integer promotion rules.
Re:The joy of max() by gmueckl on Saturday March 31, 2018 @06:02AM (#16722637)
The C++ version does not promote types. The language is generally much stricter about implicit type conversions, so this is very much in line with the language design.