r240391 - Fix a warning. [-Wsign-compare]
NAKAMURA Takumi
geek4civic at gmail.com
Tue Jun 23 03:01:21 PDT 2015
Author: chapuni
Date: Tue Jun 23 05:01:20 2015
New Revision: 240391
URL: http://llvm.org/viewvc/llvm-project?rev=240391&view=rev
Log:
Fix a warning. [-Wsign-compare]
FIXME: Should "Level" be unsigned?
Modified:
cfe/trunk/lib/Sema/SemaOpenMP.cpp
Modified: cfe/trunk/lib/Sema/SemaOpenMP.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Sema/SemaOpenMP.cpp?rev=240391&r1=240390&r2=240391&view=diff
==============================================================================
--- cfe/trunk/lib/Sema/SemaOpenMP.cpp (original)
+++ cfe/trunk/lib/Sema/SemaOpenMP.cpp Tue Jun 23 05:01:20 2015
@@ -606,7 +606,7 @@ bool DSAStackTy::hasExplicitDSA(
D = D->getCanonicalDecl();
auto StartI = Stack.rbegin();
auto EndI = std::prev(Stack.rend());
- if (std::distance(StartI, EndI) <= Level)
+ if (std::distance(StartI, EndI) <= (int)Level)
return false;
std::advance(StartI, Level);
return (StartI->SharingMap.count(D) > 0) && StartI->SharingMap[D].RefExpr &&
More information about the cfe-commits
mailing list