[PATCH] D53372: [clang-tidy] Resolve readability-else-after-return false positive for constexpr if.
Marek Kurdej via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Thu Oct 18 09:11:13 PDT 2018
curdeius updated this revision to Diff 170101.
curdeius added a comment.
Applied changes as per comments.
Repository:
rCTE Clang Tools Extra
https://reviews.llvm.org/D53372
Files:
test/clang-tidy/readability-else-after-return-if-constexpr.cpp
Index: test/clang-tidy/readability-else-after-return-if-constexpr.cpp
===================================================================
--- test/clang-tidy/readability-else-after-return-if-constexpr.cpp
+++ test/clang-tidy/readability-else-after-return-if-constexpr.cpp
@@ -6,7 +6,7 @@
return;
else
return;
- // CHECK-MESSAGES: [[@LINE-2]]:3: warning:
+ // CHECK-MESSAGES: [[@LINE-2]]:3: warning: do not use 'else' after 'return'
if constexpr (sizeof(int) > 4)
return;
@@ -20,4 +20,3 @@
else
return;
}
-// CHECK-NOT: warning:
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D53372.170101.patch
Type: text/x-patch
Size: 562 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20181018/46aec241/attachment.bin>
More information about the cfe-commits
mailing list