[PATCH] D18649: [clang-tidy] cppcoreguidelines-interfaces-global-init

Clement Courbet via cfe-commits cfe-commits at lists.llvm.org
Fri Apr 8 01:32:41 PDT 2016


courbet added inline comments.

================
Comment at: test/clang-tidy/cppcoreguidelines-interfaces-global-init.cpp:7
@@ +6,3 @@
+
+extern int ExternGlobal;
+static int GlobalScopeBadInit1 = ExternGlobal;
----------------
alexfh wrote:
> What happens if you add:
> 
>   extern int ExternGlobal;
>   extern int ExternGlobal;
>   int ExternGlobal = 123;
> 
> ?
It does not trigger (as expected). I've added a test.


http://reviews.llvm.org/D18649





More information about the cfe-commits mailing list