This is an archive of the discontinued LLVM Phabricator instance.

Add a -D flag to FileCheck to define variables
ClosedPublic

Authored by arichardson on Nov 4 2017, 7:19 AM.

Details

Summary

This makes it very easy to test files that only differ in a constant
value somewhere in the test case.

Diff Detail

Repository
rL LLVM

Event Timeline

arichardson created this revision.Nov 4 2017, 7:19 AM
probinson added inline comments.
docs/CommandGuide/FileCheck.rst
89 ↗(On Diff #121590)

Is there an extra = here? I'm a little unclear on the details of how this markup works.

arichardson added inline comments.Nov 6 2017, 12:49 PM
docs/CommandGuide/FileCheck.rst
89 ↗(On Diff #121590)

Ah yes I think there is. Will fix before committing

probinson accepted this revision.Nov 6 2017, 12:57 PM

It does seem like this could be very useful in a sequence of RUN commands, where previously we'd have to add a bunch of run-specific checks.
LGTM.

This revision is now accepted and ready to land.Nov 6 2017, 12:57 PM
This revision was automatically updated to reflect the committed changes.