summaryrefslogtreecommitdiff
path: root/test/Lexer/cxx1z-trigraphs.cpp
diff options
context:
space:
mode:
authorRichard Smith <richard-llvm@metafoo.co.uk>2017-04-18 21:45:04 +0000
committerRichard Smith <richard-llvm@metafoo.co.uk>2017-04-18 21:45:04 +0000
commit961ed8002bce57c3ab6d138853983c629bf058e4 (patch)
tree2f6bf0a586a2a82bcba3cbc16fedc190d5b3d098 /test/Lexer/cxx1z-trigraphs.cpp
parent69c89b048e1a96066ddc9b4def3b1f27f988f44a (diff)
downloadclang-961ed8002bce57c3ab6d138853983c629bf058e4.tar.gz
Do not warn about whitespace between ??/ trigraph and newline in line comments if trigraphs are disabled in the current language.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@300609 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/Lexer/cxx1z-trigraphs.cpp')
-rw-r--r--test/Lexer/cxx1z-trigraphs.cpp7
1 files changed, 6 insertions, 1 deletions
diff --git a/test/Lexer/cxx1z-trigraphs.cpp b/test/Lexer/cxx1z-trigraphs.cpp
index 0ea2adbe1e..08c45e51f8 100644
--- a/test/Lexer/cxx1z-trigraphs.cpp
+++ b/test/Lexer/cxx1z-trigraphs.cpp
@@ -1,5 +1,5 @@
// RUN: %clang_cc1 -std=c++1z %s -verify
-// RUN: %clang_cc1 -std=c++1z %s -ftrigraphs -fsyntax-only
+// RUN: %clang_cc1 -std=c++1z %s -ftrigraphs -fsyntax-only 2>&1 | FileCheck --check-prefix=TRIGRAPHS %s
??= define foo ; // expected-error {{}} expected-warning {{trigraph ignored}}
@@ -7,3 +7,8 @@ static_assert("??="[0] == '#', ""); // expected-error {{failed}} expected-warnin
// ??/
error here; // expected-error {{}}
+
+// Note, there is intentionally trailing whitespace two lines below.
+// TRIGRAPHS: :[[@LINE+1]]:{{.*}} backslash and newline separated by space
+// ??/
+error here; // expected-error {{}}