1 //===-- Endian.h ------------------------------------------------*- C++ -*-===//
3 // The LLVM Compiler Infrastructure
5 // This file is distributed under the University of Illinois Open Source
6 // License. See LICENSE.TXT for details.
8 //===----------------------------------------------------------------------===//
10 #ifndef liblldb_host_endian_h_
11 #define liblldb_host_endian_h_
13 #include "lldb/lldb-enumerations.h"
19 static union EndianTest
22 uint8_t bytes[sizeof(uint32_t)];
23 } const endianTest = { (uint16_t)0x01020304 };
25 inline ByteOrder InlHostByteOrder() { return (ByteOrder)endianTest.bytes[0]; }
27 // ByteOrder const InlHostByteOrder = (ByteOrder)endianTest.bytes[0];
32 #endif // liblldb_host_endian_h_