New max() problem with integer promotion and narrow size_t

Alexandre Oliva
Tue Apr 8 12:03:00 GMT 2003

New problem that affects this target with narrower size_t than int.
Integer promotion causes max() to get two different data types, so it
can't match.  BTW, I'm not sure it wouldn't be appropriate to cast the
second argument to __size_type as well, since it is my understanding
that there's no guarantee that the string and the buf size_types are
going to be the same.  Anyway, I'm going ahead and checking this in as

-------------- next part --------------
A non-text attachment was scrubbed...
Name: lcxx-more-minmax-promotion.patch
Type: text/x-patch
Size: 1264 bytes
Desc: not available
URL: <>
-------------- next part --------------

Alexandre Oliva   Enjoy Guarana', see
Red Hat GCC Developer                 aoliva@{,}
CS PhD student at IC-Unicamp        oliva@{,}
Free Software Evangelist                Professional serial bug killer

More information about the Gcc-patches mailing list