Next: , Previous: , Up: Structs   [Contents][Index]


10.5.4 Field Endianness

By default fields are accessed in IO space using the current default endianness. However, it is possible to annotate integral fields with an explicit endianness, like in:

deftype Foo =
  struct
  {
    little int a;
    big int b;
    int c;
  };

In the example above, the field a will be stored using little-endian, the field b will be stored using big-endian, and the field c will be stored using whatever current endianness.