ENH: remove warnings from try compiles

This commit is contained in:
Bill Hoffman 2004-04-14 15:56:39 -04:00
parent 0c92cfb8c4
commit 6c5b67981e
2 changed files with 14 additions and 4 deletions

View File

@ -2,10 +2,15 @@
char CHECK_FUNCTION_EXISTS();
int main()
int main(int ac, char*av[])
{
int ret = 0;
CHECK_FUNCTION_EXISTS();
return 0;
if(ac > 100)
{
ret = *av[0];
}
return ret;
}
#else /* CHECK_FUNCTION_EXISTS */

View File

@ -1,4 +1,5 @@
int main () {
int main (int ac, char*av[]) {
int ret = 1;
/* Are we little or big endian? From Harbison&Steele. */
union
{
@ -6,5 +7,9 @@ int main () {
char c[sizeof (long)];
} u;
u.l = 1;
return (u.c[sizeof (long) - 1] == 1)?1:0;
if(ac > 100)
{
ret = *av[0];
}
return (u.c[sizeof (long) - 1] == 1)?ret:0;
}