[PATCH] D16764: Move incorrect-roundings to upstream.
Haojian Wu via cfe-commits
cfe-commits at lists.llvm.org
Mon Feb 1 08:14:06 PST 2016
hokein marked 3 inline comments as done.
================
Comment at: clang-tidy/misc/IncorrectRoundings.cpp:39
@@ +38,3 @@
+namespace tidy {
+void IncorrectRoundings::registerMatchers(MatchFinder *MatchFinder) {
+ // Match a floating literal with value 0.5.
----------------
Done. The `ASTMatchers.h` file is not in clang-tidy repository, so I temporarily implement `isFloatingPoint` narrowing matcher here.
Will create a separated patch to clang repository.
================
Comment at: clang-tidy/misc/IncorrectRoundings.cpp:51
@@ +50,3 @@
+
+ // Match if either the LHS or RHS is a floating literal of 0.5 or a floating
+ // literal of 0.5 and the other is of type double or vice versa.
----------------
Just found out there is no need to bind here since `check` function doesn't use it. Have removed it.
http://reviews.llvm.org/D16764
More information about the cfe-commits
mailing list