Douglas Gregor | b2809a0 | 2009-02-18 06:34:51 +0000 | [diff] [blame^] | 1 | // RUN: clang -fsyntax-only -verify %s |
2 | |||||
3 | int &foo(int); | ||||
4 | double &foo(double); | ||||
5 | void foo(...) __attribute__((__unavailable__)); // expected-note{{unavailable function is declared here}} | ||||
6 | |||||
7 | void test_foo(short* sp) { | ||||
8 | int &ir = foo(1); | ||||
9 | double &dr = foo(1.0); | ||||
10 | foo(sp); // expected-error{{call to function 'foo' that has been intentionally made unavailable}} | ||||
11 | } |