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'.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@207576
91177308-0d34-0410-b5e6-
96231b3b80d8
--- /dev/null
+// 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.
+
# 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']: