STYLE: Nightly Version update
[cmake.git] / Modules / TestBigEndian.c
blobdb08ceb391fcb35d4c497097556d8d80783fd274
1 #ifdef __CLASSIC_C__
2 int main(){
3 int ac;
4 char*av[];
5 #else
6 int main(int ac, char*av[]){
7 #endif
8 /* Are we little or big endian? From Harbison&Steele. */
9 union
11 long l;
12 char c[sizeof (long)];
13 } u;
14 u.l = 1;
15 if(ac > 1000){return *av[0];}
16 return (u.c[sizeof (long) - 1] == 1)?1:0;