[cfe-commits] r162168 - /cfe/trunk/include/clang/ASTMatchers/ASTMatchers.h
Benjamin Kramer
benny.kra at googlemail.com
Sat Aug 18 03:33:09 PDT 2012
Author: d0k
Date: Sat Aug 18 05:33:09 2012
New Revision: 162168
URL: http://llvm.org/viewvc/llvm-project?rev=162168&view=rev
Log:
Silence a sign compare warning that only occurs on 32 bit platforms.
Modified:
cfe/trunk/include/clang/ASTMatchers/ASTMatchers.h
Modified: cfe/trunk/include/clang/ASTMatchers/ASTMatchers.h
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/include/clang/ASTMatchers/ASTMatchers.h?rev=162168&r1=162167&r2=162168&view=diff
==============================================================================
--- cfe/trunk/include/clang/ASTMatchers/ASTMatchers.h (original)
+++ cfe/trunk/include/clang/ASTMatchers/ASTMatchers.h Sat Aug 18 05:33:09 2012
@@ -1361,7 +1361,7 @@
/// declCountIs(2)
/// matches 'int a, b;' and 'int d = 2, e;', but not 'int c;'.
AST_MATCHER_P(DeclStmt, declCountIs, unsigned, N) {
- return std::distance(Node.decl_begin(), Node.decl_end()) == N;
+ return std::distance(Node.decl_begin(), Node.decl_end()) == (ptrdiff_t)N;
}
/// \brief Matches the n'th declaration of a declaration statement.
More information about the cfe-commits
mailing list