blob: 39251ed10ecda05e4518f966467a7fa39fcf570d [file] [log] [blame]
Justin Lebara8f0254b2016-01-23 21:28:10 +00001// 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.
5void 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