aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJason Merrill <jason@gcc.gnu.org>2014-03-14 11:20:28 -0400
committerJason Merrill <jason@gcc.gnu.org>2014-03-14 11:20:28 -0400
commit54ce77893d804574d1386311a2ca44c61d5112e5 (patch)
tree7862d2aa66598ff518f6172c97e17e65652cf405
parent25e57622a5cfa2ab4599b2cda93f7bd7a9acc5f2 (diff)
downloadgcc-54ce77893d804574d1386311a2ca44c61d5112e5.zip
gcc-54ce77893d804574d1386311a2ca44c61d5112e5.tar.gz
gcc-54ce77893d804574d1386311a2ca44c61d5112e5.tar.bz2
re PR c++/53711 (Wunused-function should warn for functions in the unnamed namespace)
PR c++/53711 * d++.dg/warn/anonymous-namespace-6.C: New test. From-SVN: r208569
-rw-r--r--gcc/testsuite/g++.dg/warn/anonymous-namespace-6.C8
1 files changed, 8 insertions, 0 deletions
diff --git a/gcc/testsuite/g++.dg/warn/anonymous-namespace-6.C b/gcc/testsuite/g++.dg/warn/anonymous-namespace-6.C
new file mode 100644
index 0000000..d238df3
--- /dev/null
+++ b/gcc/testsuite/g++.dg/warn/anonymous-namespace-6.C
@@ -0,0 +1,8 @@
+// PR c++/53711
+// { dg-options -Wall }
+
+namespace {
+ void f () // { dg-warning "not used" }
+ {
+ }
+}