From e64103a31d1debeffece30779a2be459d8a500e9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Walenciak?= Date: Tue, 12 Sep 2017 21:52:27 +0200 Subject: [PATCH] removing c++14 stuff --- bigtiff/parse.cpp | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/bigtiff/parse.cpp b/bigtiff/parse.cpp index 4f6b8c1a..fb62b829 100644 --- a/bigtiff/parse.cpp +++ b/bigtiff/parse.cpp @@ -1,4 +1,5 @@ +#include #include #include #include @@ -103,7 +104,7 @@ bool is8ByteType(uint16_t type) || type == tiffIfd8; } -constexpr bool isBigEndianPlatform() +bool isBigEndianPlatform() { union { @@ -114,7 +115,7 @@ constexpr bool isBigEndianPlatform() return e.c[0]?true:false; } -constexpr bool isLittleEndianPlatform() { return !isBigEndianPlatform(); } +bool isLittleEndianPlatform() { return !isBigEndianPlatform(); } template struct TypeForSize {}; @@ -140,7 +141,7 @@ struct TypeForSize<64> template typename TypeForSize::Type byte_swap(const typename TypeForSize::Type& v) { - static_assert(size == 16 || size == 32 || size == 64, "unsupported data size"); + assert(size == 16 || size == 32 || size == 64); // supported sizes typename TypeForSize::Type result = 0; if (size == 16)