From: Alp Toker Date: Sun, 17 Nov 2013 16:49:24 +0000 (+0000) Subject: Remove a bad string compare from r194968 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=675906eeb54dd2aa8a7cb3b326da07158c931758;p=clang Remove a bad string compare from r194968 lib/Tooling/CompilationDatabase.cpp:275:34: warning: result of comparison against a string literal is unspecified (use strncmp instead) [-Wstring-compare] This assert() should probably be fixed and added back at some point. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@194969 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/lib/Tooling/CompilationDatabase.cpp b/lib/Tooling/CompilationDatabase.cpp index 37e0027246..52452e7c6e 100644 --- a/lib/Tooling/CompilationDatabase.cpp +++ b/lib/Tooling/CompilationDatabase.cpp @@ -272,7 +272,6 @@ bool stripPositionalArgs(std::vector Args, End = std::remove_if(Args.begin(), End, MatchesAny(DiagClient.UnusedInputs)); // Remove the -c add above as well. It will be at the end right now. - assert(*(End - 1) == "-c"); --End; Result = std::vector(Args.begin() + 1, End);