Liste des Groupes | Revenir à c arch |
Here we have the three variants:My 66000:
>
#include <limits.h>
>
extern long foo1(long);
extern long foo2(long);
>
long bar(long a, long b)
{
long c;
if (__builtin_sub_overflow(b,1,&c))
return foo1(a);
else
return foo2(a);
}
>
long bar2(long a, long b)
{
if (b < b-1)
return foo1(a);
else
return foo2(a);
}
>
long bar3(long a, long b)
{
if (b == LONG_MIN)
return foo1(a);
else
return foo2(a);
}
Les messages affichés proviennent d'usenet.