[PATCH] D24349: [clang-tidy] Extend readability-container-size-empty to arbitrary class with size() and empty()

Piotr Padlewski via cfe-commits cfe-commits at lists.llvm.org
Thu Sep 8 14:57:30 PDT 2016


Prazek added inline comments.

================
Comment at: clang-tidy/readability/ContainerSizeEmptyCheck.cpp:34
@@ +33,3 @@
+      has(functionDecl(
+          isPublic(), hasName("size"), returns(isInteger()),
+          unless(anyOf(returns(isAnyCharacter()), returns(booleanType()))))),
----------------
Would be nice to have 'isStrictlyInteger' matcher to do this thing.


Repository:
  rL LLVM

https://reviews.llvm.org/D24349





More information about the cfe-commits mailing list