From: Daniel Dunbar Date: Thu, 12 Nov 2009 18:40:12 +0000 (+0000) Subject: Spell empty StringRef correctly (0 is a null StringRef, which is not the same). X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=ad5757f798b08f24942f093c4ac8b9fc2b527d39;p=clang Spell empty StringRef correctly (0 is a null StringRef, which is not the same). git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@87011 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/include/clang/Sema/CodeCompleteConsumer.h b/include/clang/Sema/CodeCompleteConsumer.h index 9bbf11b162..c436b398f9 100644 --- a/include/clang/Sema/CodeCompleteConsumer.h +++ b/include/clang/Sema/CodeCompleteConsumer.h @@ -106,7 +106,7 @@ public: Chunk() : Kind(CK_Text), Text(0) { } - Chunk(ChunkKind Kind, llvm::StringRef Text = 0); + Chunk(ChunkKind Kind, llvm::StringRef Text = ""); /// \brief Create a new text chunk. static Chunk CreateText(const char *Text); diff --git a/lib/Sema/CodeCompleteConsumer.cpp b/lib/Sema/CodeCompleteConsumer.cpp index cb4e8ef826..f94989ee72 100644 --- a/lib/Sema/CodeCompleteConsumer.cpp +++ b/lib/Sema/CodeCompleteConsumer.cpp @@ -28,7 +28,7 @@ using namespace clang; // Code completion string implementation //===----------------------------------------------------------------------===// CodeCompletionString::Chunk::Chunk(ChunkKind Kind, llvm::StringRef Text) - : Kind(Kind), Text(0) + : Kind(Kind), Text("") { switch (Kind) { case CK_TypedText: