xref: /minix3/external/bsd/llvm/dist/clang/test/SemaCXX/unused-functions.cpp (revision f4a2713ac843a11c696ec80c0a5e3e5d80b4d338)
1*f4a2713aSLionel Sambuc // RUN: %clang_cc1 -std=c++11 -fsyntax-only -Wunused -verify %s
2*f4a2713aSLionel Sambuc // expected-no-diagnostics
3*f4a2713aSLionel Sambuc 
foo(int x)4*f4a2713aSLionel Sambuc static int foo(int x) { return x; }
5*f4a2713aSLionel Sambuc 
6*f4a2713aSLionel Sambuc template<typename T>
get_from_foo(T y)7*f4a2713aSLionel Sambuc T get_from_foo(T y) { return foo(y); }
8*f4a2713aSLionel Sambuc 
g(int z)9*f4a2713aSLionel Sambuc int g(int z) { return get_from_foo(z); }
10*f4a2713aSLionel Sambuc 
11*f4a2713aSLionel Sambuc namespace { void f() = delete; }
12