From 99ca3c0a617337902c2b2006231acc64397d9df3 Mon Sep 17 00:00:00 2001 From: Eric Fiselier Date: Wed, 25 Jul 2018 22:21:47 +0000 Subject: [PATCH] Work around GCC bug in constexpr function llvm-svn: 337976 --- .../experimental/filesystem/convert_file_time.sh.cpp | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/libcxx/test/libcxx/experimental/filesystem/convert_file_time.sh.cpp b/libcxx/test/libcxx/experimental/filesystem/convert_file_time.sh.cpp index 4c18eedc67ea..9182366413b1 100644 --- a/libcxx/test/libcxx/experimental/filesystem/convert_file_time.sh.cpp +++ b/libcxx/test/libcxx/experimental/filesystem/convert_file_time.sh.cpp @@ -56,11 +56,12 @@ constexpr TestKind getFileTimeTestKind() { using Rep = typename FileTimeT::rep; if (std::is_floating_point::value) return TK_FloatingPoint; - if (sizeof(Rep) == 16) + else if (sizeof(Rep) == 16) return TK_128Bit; - if (sizeof(Rep) == 8) + else if (sizeof(Rep) == 8) return TK_64Bit; - assert(false && "test kind not supported"); + else + assert(false && "test kind not supported"); } template