FileCheck: Add a flag to allow checking empty input
authorJustin Bogner <mail@justinbogner.com>
Thu, 7 Aug 2014 18:40:37 +0000 (18:40 +0000)
committerJustin Bogner <mail@justinbogner.com>
Thu, 7 Aug 2014 18:40:37 +0000 (18:40 +0000)
commitb7c9534f75970ba8a9e136ed52c66740fe787301
tree752502ac12890aed46cfbe32ad27adbc4cc53d5e
parent39637ed35e59d5e202f6d835710d5a4b9f8aeb6d
FileCheck: Add a flag to allow checking empty input

Currently FileCheck errors out on empty input. This is usually the
right thing to do, but makes testing things like "this command does
not emit some error message" hard to test. This usually leads to
people using "command 2>&1 | count 0" instead, and then the bots that
use guard malloc fail a few hours later.

By adding a flag to FileCheck that allows empty inputs, we can make
tests that consist entirely of "CHECK-NOT" lines feasible.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@215127 91177308-0d34-0410-b5e6-96231b3b80d8
test/FileCheck/check-empty.txt [new file with mode: 0644]
utils/FileCheck/FileCheck.cpp