[cfe-commits] r87011 - in /cfe/trunk: include/clang/Sema/CodeCompleteConsumer.h lib/Sema/CodeCompleteConsumer.cpp
Daniel Dunbar
daniel at zuster.org
Thu Nov 12 10:40:12 PST 2009
Author: ddunbar
Date: Thu Nov 12 12:40:12 2009
New Revision: 87011
URL: http://llvm.org/viewvc/llvm-project?rev=87011&view=rev
Log:
Spell empty StringRef correctly (0 is a null StringRef, which is not the same).
Modified:
cfe/trunk/include/clang/Sema/CodeCompleteConsumer.h
cfe/trunk/lib/Sema/CodeCompleteConsumer.cpp
Modified: cfe/trunk/include/clang/Sema/CodeCompleteConsumer.h
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/include/clang/Sema/CodeCompleteConsumer.h?rev=87011&r1=87010&r2=87011&view=diff
==============================================================================
--- cfe/trunk/include/clang/Sema/CodeCompleteConsumer.h (original)
+++ cfe/trunk/include/clang/Sema/CodeCompleteConsumer.h Thu Nov 12 12:40:12 2009
@@ -106,7 +106,7 @@
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);
Modified: cfe/trunk/lib/Sema/CodeCompleteConsumer.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Sema/CodeCompleteConsumer.cpp?rev=87011&r1=87010&r2=87011&view=diff
==============================================================================
--- cfe/trunk/lib/Sema/CodeCompleteConsumer.cpp (original)
+++ cfe/trunk/lib/Sema/CodeCompleteConsumer.cpp Thu Nov 12 12:40:12 2009
@@ -28,7 +28,7 @@
// Code completion string implementation
//===----------------------------------------------------------------------===//
CodeCompletionString::Chunk::Chunk(ChunkKind Kind, llvm::StringRef Text)
- : Kind(Kind), Text(0)
+ : Kind(Kind), Text("")
{
switch (Kind) {
case CK_TypedText:
More information about the cfe-commits
mailing list