summaryrefslogtreecommitdiff
path: root/test/SemaCUDA
diff options
context:
space:
mode:
Diffstat (limited to 'test/SemaCUDA')
-rw-r--r--test/SemaCUDA/gnu-inline.cu10
1 files changed, 10 insertions, 0 deletions
diff --git a/test/SemaCUDA/gnu-inline.cu b/test/SemaCUDA/gnu-inline.cu
new file mode 100644
index 0000000000..0ed543326b
--- /dev/null
+++ b/test/SemaCUDA/gnu-inline.cu
@@ -0,0 +1,10 @@
+// RUN: %clang_cc1 -fsyntax-only -verify %s
+
+#include "Inputs/cuda.h"
+
+// expected-no-diagnostics
+
+// Check that we can handle gnu_inline functions when compiling in CUDA mode.
+
+void foo();
+inline __attribute__((gnu_inline)) void bar() { foo(); }