You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

22 lines
642 B
C

// This Source Code Form is subject to the terms of the Mozilla Public
// License, v. 2.0. If a copy of the MPL was not distributed with this
// file, You can obtain one at https://mozilla.org/MPL/2.0/.
#pragma once
#if !defined(__BYTE_ORDER__)
#error "__BYTE_ORDER__ not defined"
#elif !defined(__ORDER_BIG_ENDIAN__)
#error "__ORDER_BIG_ENDIAN__ not defined"
#elif !defined(__ORDER_LITTLE_ENDIAN__)
#error "__ORDER_LITTLE_ENDIAN__ not defined"
#endif
#if __BYTE_ORDER__ == __ORDER_BIG_ENDIAN__
#define TLSL_BIG_ENDIAN
#elif __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__
#define TLSL_LITTLE_ENDIAN
#else
#error "__BYTE_ORDER__ invalid"
#endif