blob: d5501d3a7d746d59e8e4d3940013e5443bc9313c [file] [log] [blame]
unsigned long bad(int reg, unsigned long inWord)
{
union {
unsigned long word;
unsigned char byte[4];
} data;
data.word = inWord;
data.byte[reg] = 0;
return data.word;
}
main()
{
/* XXX This test could be generalized. */
if (sizeof (long) != 4)
exit (0);
if (bad (0, 0xdeadbeef) == 0xdeadbeef)
abort ();
exit (0);
}