NUXI(3spp) RISC/os Reference Manual NUXI(3spp)
NAME
nuxi - routines to convert between little and big-endian
byte order
SYNOPSIS
void nuxis(s);
short s;
void nuxil(l);
long l;
DESCRIPTION
Nuxi_s swaps bytes within a 16 bit short value and returns
the swapped result. If a and b are representable in 8 bits,
then:
nuxi_s((a<<8)|b) == (b<<8)|a
nuxi_l swaps bytes within a 32 bit long value and returns
the swapped result. If a, b, c, and d are representable in
8 bits, then:
nuxi_l((a<<24)|(b<<16)|(c<<8)|d) == (d<<24)|(c<<16)|(b<<8)|a
Printed 1/6/92 Page 1