From: Douglas Gregor Date: Thu, 26 Aug 2010 02:54:05 +0000 (+0000) Subject: Fix thinko in sorting operation X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=86d00659f729473846f1681f6c003982e77e6fdd;p=clang Fix thinko in sorting operation git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@112154 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/tools/libclang/CIndexCodeCompletion.cpp b/tools/libclang/CIndexCodeCompletion.cpp index 825031bd4b..910ef06c7f 100644 --- a/tools/libclang/CIndexCodeCompletion.cpp +++ b/tools/libclang/CIndexCodeCompletion.cpp @@ -808,7 +808,7 @@ namespace { return false; result = llvm::StringRef(XText).compare(YText); - return result; + return result < 0; } }; } @@ -818,4 +818,4 @@ extern "C" { unsigned NumResults) { std::stable_sort(Results, Results + NumResults, OrderCompletionResults()); } -} \ No newline at end of file +}