From b834a7b73ce0dcf8fbf8d8b0d62f69e4b78059ad Mon Sep 17 00:00:00 2001 From: Daniel Dunbar Date: Wed, 22 Jul 2009 21:08:31 +0000 Subject: [PATCH] Define npos in a way that should make MSVC happier. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@76785 91177308-0d34-0410-b5e6-96231b3b80d8 --- include/llvm/ADT/StringRef.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/llvm/ADT/StringRef.h b/include/llvm/ADT/StringRef.h index 68d2deff959..1d7a9b6d56f 100644 --- a/include/llvm/ADT/StringRef.h +++ b/include/llvm/ADT/StringRef.h @@ -26,7 +26,7 @@ namespace llvm { class StringRef { public: typedef const char *iterator; - static const size_t npos = std::string::npos; + static const size_t npos = ~size_t(0); private: /// The start of the string, in an external buffer.