summaryrefslogtreecommitdiffstats
path: root/test
diff options
context:
space:
mode:
authorSeth Cantrell <seth.cantrell@gmail.com>2012-04-13 03:43:23 +0000
committerSeth Cantrell <seth.cantrell@gmail.com>2012-04-13 03:43:23 +0000
commit5e6c3f0397254e2a1a9ef85cf13232f89e653640 (patch)
tree26a8c3947b3c03ad9fbd94c14dba2779c0dfcec8 /test
parentb3440f5898f39b8f0a86edfa38538716ba4f06cd (diff)
Support -Wc++98-compat-pedantic as requested:
http://lists.cs.uiuc.edu/pipermail/cfe-commits/Week-of-Mon-20120409/056126.html git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@154655 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test')
-rw-r--r--test/Lexer/newline-eof-c++98-compat.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/test/Lexer/newline-eof-c++98-compat.cpp b/test/Lexer/newline-eof-c++98-compat.cpp
new file mode 100644
index 0000000000..7f7eebbad7
--- /dev/null
+++ b/test/Lexer/newline-eof-c++98-compat.cpp
@@ -0,0 +1,4 @@
+// RUN: %clang -cc1 -fsyntax-only -Wc++98-compat-pedantic -std=c++11 -verify %s
+
+// The following line isn't terminated, don't fix it.
+void foo() {} // expected-warning{{C++98 requires newline at end of file}} \ No newline at end of file