summaryrefslogtreecommitdiff
path: root/clang/test/CXX/basic/basic.start/basic.start.main/p2h.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'clang/test/CXX/basic/basic.start/basic.start.main/p2h.cpp')
-rw-r--r--clang/test/CXX/basic/basic.start/basic.start.main/p2h.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/clang/test/CXX/basic/basic.start/basic.start.main/p2h.cpp b/clang/test/CXX/basic/basic.start/basic.start.main/p2h.cpp
new file mode 100644
index 0000000..abf8faa
--- /dev/null
+++ b/clang/test/CXX/basic/basic.start/basic.start.main/p2h.cpp
@@ -0,0 +1,5 @@
+// RUN: %clang_cc1 -fsyntax-only -verify %s
+
+template<typename T>
+int main() { } // expected-error{{'main' cannot be a template}}
+