ENH: remove warnings from try compiles
This commit is contained in:
parent
0c92cfb8c4
commit
6c5b67981e
|
@ -2,10 +2,15 @@
|
||||||
|
|
||||||
char CHECK_FUNCTION_EXISTS();
|
char CHECK_FUNCTION_EXISTS();
|
||||||
|
|
||||||
int main()
|
int main(int ac, char*av[])
|
||||||
{
|
{
|
||||||
|
int ret = 0;
|
||||||
CHECK_FUNCTION_EXISTS();
|
CHECK_FUNCTION_EXISTS();
|
||||||
return 0;
|
if(ac > 100)
|
||||||
|
{
|
||||||
|
ret = *av[0];
|
||||||
|
}
|
||||||
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
#else /* CHECK_FUNCTION_EXISTS */
|
#else /* CHECK_FUNCTION_EXISTS */
|
||||||
|
|
|
@ -1,4 +1,5 @@
|
||||||
int main () {
|
int main (int ac, char*av[]) {
|
||||||
|
int ret = 1;
|
||||||
/* Are we little or big endian? From Harbison&Steele. */
|
/* Are we little or big endian? From Harbison&Steele. */
|
||||||
union
|
union
|
||||||
{
|
{
|
||||||
|
@ -6,5 +7,9 @@ int main () {
|
||||||
char c[sizeof (long)];
|
char c[sizeof (long)];
|
||||||
} u;
|
} u;
|
||||||
u.l = 1;
|
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;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue