r207576 - Add test case for revision 207575 to verify that on Windows, clang doesn't

Andrea Di Biagio Andrea_DiBiagio at sn.scee.net
Tue Apr 29 13:19:14 PDT 2014


Author: adibiagio
Date: Tue Apr 29 15:19:13 2014
New Revision: 207576

URL: http://llvm.org/viewvc/llvm-project?rev=207576&view=rev
Log:
Add test case for revision 207575 to verify that on Windows, clang doesn't
crash with an assertion failure when 'nul' is passed in input.

Modified clang/test/lit.py to add feature 'system-windows' if
`platform.system()` returns 'Windows'.


Added:
    cfe/trunk/test/Frontend/windows-nul.c
Modified:
    cfe/trunk/test/lit.cfg

Added: cfe/trunk/test/Frontend/windows-nul.c
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/test/Frontend/windows-nul.c?rev=207576&view=auto
==============================================================================
--- cfe/trunk/test/Frontend/windows-nul.c (added)
+++ cfe/trunk/test/Frontend/windows-nul.c Tue Apr 29 15:19:13 2014
@@ -0,0 +1,8 @@
+// RUN: %clang_cc1 -dM -E nul -o /dev/null
+
+// REQUIRES: system-windows
+
+// Verify that cc1 doesn't crash with an assertion failure
+// in MemoryBuffer.cpp due to an invalid file size reported
+// when the Windows 'nul' device is passed in input.
+

Modified: cfe/trunk/test/lit.cfg
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/test/lit.cfg?rev=207576&r1=207575&r2=207576&view=diff
==============================================================================
--- cfe/trunk/test/lit.cfg (original)
+++ cfe/trunk/test/lit.cfg Tue Apr 29 15:19:13 2014
@@ -344,6 +344,9 @@ if not platform.system() in ['Windows']
 # This is used by debuginfo-tests/*block*.m and debuginfo-tests/foreach.m.
 if platform.system() in ['Darwin']:
     config.available_features.add('system-darwin')
+elif platform.system() in ['Windows']:
+    # For tests that require Windows to run.
+    config.available_features.add('system-windows')
 
 # ANSI escape sequences in non-dumb terminal
 if platform.system() not in ['Windows']:





More information about the cfe-commits mailing list