summaryrefslogtreecommitdiff
path: root/compilerplugins
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2017-07-17 17:17:27 +0200
committerStephan Bergmann <sbergman@redhat.com>2017-07-17 17:17:27 +0200
commite27f2a872095a589572030d9c923d66aaa4e3179 (patch)
tree9f2eb778f43ddfc27e7bca9f707602eeb87b98a0 /compilerplugins
parent9f08211d2461c3d46a5f448f6c399ac6b82e910d (diff)
Fix test for clang-cl
...whatever it is that causes clang-cl to not analyze the template code otherwise Change-Id: Id4da996714fe93c454abb3669a12d8afe27b918b
Diffstat (limited to 'compilerplugins')
-rw-r--r--compilerplugins/clang/test/oncevar.cxx1
1 files changed, 1 insertions, 0 deletions
diff --git a/compilerplugins/clang/test/oncevar.cxx b/compilerplugins/clang/test/oncevar.cxx
index 8c7b8d2a9e1d..5e01d1b98a21 100644
--- a/compilerplugins/clang/test/oncevar.cxx
+++ b/compilerplugins/clang/test/oncevar.cxx
@@ -22,6 +22,7 @@ template<typename T> void f() {
int i = sizeof (T) + 1; // expected-error {{var used only once, should be inlined or declared const [loplugin:oncevar]}}
call_value(i); // expected-note {{used here [loplugin:oncevar]}}
}
+template void f<int>(); // needed for clang-cl
int main() {
/* TODO