gcc/testsuite/gdc.test/fail_compilation/fail96.d
raw| 1 | /* |
| 2 | TEST_OUTPUT: |
| 3 | --- |
| 4 | fail_compilation/fail96.d(21): Error: template instance `foo!long` `foo` is not a template declaration, it is a function alias |
| 5 | --- |
| 6 | */ |
| 7 | |
| 8 | // https://issues.dlang.org/show_bug.cgi?id=153 |
| 9 | |
| 10 | template bar(T) |
| 11 | { |
| 12 | void foo() {} |
| 13 | } |
| 14 | |
| 15 | alias bar!(long).foo foo; |
| 16 | alias bar!(char).foo foo; |
| 17 | |
| 18 | |
| 19 | void main() |
| 20 | { |
| 21 | foo!(long); |
| 22 | } |