diff --git a/lib/Support/StringRef.cpp b/lib/Support/StringRef.cpp index a4c0e87c28e..deaa19efe99 100644 --- a/lib/Support/StringRef.cpp +++ b/lib/Support/StringRef.cpp @@ -10,7 +10,10 @@ #include "llvm/ADT/StringRef.h" using namespace llvm; +// MSVC emits references to this into the translation units which reference it. +#ifndef _MSC_VER const size_t StringRef::npos; +#endif //===----------------------------------------------------------------------===// // String Searching