[flang] Fix clang build on MacOS

clang doesn't consider `std::strlen` of a constant to be a constexpr,
so just replace with the actual length.

Original-commit: flang-compiler/f18@738deab465
Reviewed-on: https://github.com/flang-compiler/f18/pull/761
This commit is contained in:
Tim Keith 2019-09-25 15:39:44 -07:00
parent 0e3b30489c
commit a3d2966637
1 changed files with 1 additions and 1 deletions

View File

@ -43,7 +43,7 @@ using namespace parser::literals;
struct ModHeader {
static constexpr const char *bom{"\xef\xbb\xbf"};
static constexpr const char *magic{"!mod$ v1 sum:"};
static constexpr int magicLen{std::strlen(magic)};
static constexpr int magicLen{13};
static constexpr int sumLen{16};
static constexpr char terminator{'\n'};
static constexpr int len{magicLen + 1 + sumLen};