[PATCH] D15710: [clang-tidy] Add non-inline function definition and variable definition check in header files.

Haojian Wu via cfe-commits cfe-commits at lists.llvm.org
Mon Jan 4 07:36:54 PST 2016


hokein marked an inline comment as done.

================
Comment at: docs/clang-tidy/checks/misc-definitions-in-headers.rst:19
@@ +18,3 @@
+   }
+
+   // error
----------------
About the internal linkage variable definition, how about only warning the variable in unnamed namespace?

The const/static variable definitions in header are used more widely (We also find there are a lot of such usages in Google code repo), and Google C++ code style doesn't explicitly give suggestions about such const/static usages.


http://reviews.llvm.org/D15710





More information about the cfe-commits mailing list