Justin Lebar | a8f0254b | 2016-01-23 21:28:10 +0000 | [diff] [blame] | 1 | // RUN: %clang_cc1 -triple nvptx-unknown-cuda -fsyntax-only -fcuda-is-device -verify -DEXPECT_ERR %s |
2 | // RUN: %clang_cc1 -triple x86_64-unknown-linux-gnu -fsyntax-only -verify %s | ||||
3 | |||||
4 | // The alias attribute is not allowed in CUDA device code. | ||||
5 | void bar(); | ||||
6 | __attribute__((alias("bar"))) void foo(); | ||||
7 | #ifdef EXPECT_ERR | ||||
8 | // expected-error@-2 {{CUDA does not support aliases}} | ||||
9 | #else | ||||
10 | // expected-no-diagnostics | ||||
11 | #endif |