summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAlexandre Ganea <alexandre.ganea@ubisoft.com>2019-08-28 15:14:37 +0000
committerAlexandre Ganea <alexandre.ganea@ubisoft.com>2019-08-28 15:14:37 +0000
commit3c307370c8f865299a788bc8b26970e6d56b0571 (patch)
tree3ad0805e601510644763da4b1a64fbac1d80800f
parent92e09b2f56d635bf92c32089fdf81a819026d0bf (diff)
downloadbcm5719-llvm-3c307370c8f865299a788bc8b26970e6d56b0571.tar.gz
bcm5719-llvm-3c307370c8f865299a788bc8b26970e6d56b0571.zip
Try fixing CRLF issues in Git with [clang-scan-deps] Minimizer: Correctly handle multi-line content with CR+LF line endings
Differential Revision: https://reviews.llvm.org/D66556 llvm-svn: 370219
-rw-r--r--clang/.gitattributes3
-rw-r--r--clang/test/Lexer/minimize_source_to_dependency_directives_invalid_error.c16
2 files changed, 16 insertions, 3 deletions
diff --git a/clang/.gitattributes b/clang/.gitattributes
deleted file mode 100644
index b48a3e3911a..00000000000
--- a/clang/.gitattributes
+++ /dev/null
@@ -1,3 +0,0 @@
-# Windows line ending tests
-test/Lexer/minimize_source_to_dependency_directives_invalid_error.c text eol=crlf
-test/FixIt/fixit-newline-style.c text eol=crlf
diff --git a/clang/test/Lexer/minimize_source_to_dependency_directives_invalid_error.c b/clang/test/Lexer/minimize_source_to_dependency_directives_invalid_error.c
new file mode 100644
index 00000000000..c4a4cf3d975
--- /dev/null
+++ b/clang/test/Lexer/minimize_source_to_dependency_directives_invalid_error.c
@@ -0,0 +1,16 @@
+// Test CF+LF are properly handled along with quoted, multi-line #error
+// RUN: %clang_cc1 -DOTHER -print-dependency-directives-minimized-source %s 2>&1 | FileCheck %s
+
+#ifndef TEST
+#error "message \
+ more message \
+ even more"
+#endif
+
+#ifdef OTHER
+#include <string>
+#endif
+
+// CHECK: #ifdef OTHER
+// CHECK-NEXT: #include <string>
+// CHECK-NEXT: #endif
OpenPOWER on IntegriCloud