From cde28074a169212aa8f38fdac225ecbeac4e642d Mon Sep 17 00:00:00 2001 From: Johanna Amann Date: Mon, 7 Oct 2019 18:52:11 -0700 Subject: [PATCH] Fix compilation on OS-X. OS X complains about std::pair not having a constexpr constructor. Which seems to be the case for C++11. Hence, let's make it static const for the moment. This commit should be reverted when we move to C++17. --- src/Val.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Val.cc b/src/Val.cc index 075e5805bd..3ea10d706c 100644 --- a/src/Val.cc +++ b/src/Val.cc @@ -666,7 +666,7 @@ void IntervalVal::ValDescribe(ODesc* d) const { using unit_word = std::pair; - constexpr std::array units = { + static const std::array units = { unit_word{ Days, "day" }, unit_word{ Hours, "hr" }, unit_word{ Minutes, "min" },