[WebAssembly] Relax constexpr for old standard libraries.

This will still be constexpr when the standard library supports it, but
doesn't force constexpr. Old libraries will get a global constructor,
which is not too bad.

llvm-svn: 326080
This commit is contained in:
Benjamin Kramer 2018-02-26 11:07:25 +00:00
parent 9d1b2acaaa
commit b84e158df7
1 changed files with 1 additions and 1 deletions

View File

@ -465,7 +465,7 @@ ManagedStatic<RuntimeLibcallSignatureTable> RuntimeLibcallSignatures;
struct StaticLibcallNameMap { struct StaticLibcallNameMap {
StringMap<RTLIB::Libcall> Map; StringMap<RTLIB::Libcall> Map;
StaticLibcallNameMap() { StaticLibcallNameMap() {
static constexpr std::pair<const char *, RTLIB::Libcall> NameLibcalls[] = { static const std::pair<const char *, RTLIB::Libcall> NameLibcalls[] = {
#define HANDLE_LIBCALL(code, name) {(const char *)name, RTLIB::code}, #define HANDLE_LIBCALL(code, name) {(const char *)name, RTLIB::code},
#include "llvm/CodeGen/RuntimeLibcalls.def" #include "llvm/CodeGen/RuntimeLibcalls.def"
#undef HANDLE_LIBCALL #undef HANDLE_LIBCALL