This is an archive of the discontinued LLVM Phabricator instance.

[clang-tidy][test] Allow specifying potentially unused suffixes
ClosedPublic

Authored by njames93 on Feb 23 2021, 11:59 AM.

Details

Summary

If a check-suffix is only required for a CHECK-FIXES or CHECK-MESSAGES. check_clang_tidy will pass the prefixes CHECK-FIXES<...> and CHECK-MESSAGES<...> to FileCheck.
This will result in a FileCheck failing because of an unused prefix.

This addresses the problem by not passing unused prefixes. Its also possible to fix this be passing --allow-unused-prefixes flag to FileCheck, but seeing as we have already done the legwork in the script to see its unused, this fix seems the better way to go.

Diff Detail

Event Timeline

njames93 created this revision.Feb 23 2021, 11:59 AM
njames93 requested review of this revision.Feb 23 2021, 11:59 AM
Herald added a project: Restricted Project. · View Herald TranscriptFeb 23 2021, 11:59 AM
Herald added a subscriber: cfe-commits. · View Herald Transcript
aaron.ballman accepted this revision.Feb 24 2021, 5:21 AM

LGTM, thanks!

This revision is now accepted and ready to land.Feb 24 2021, 5:21 AM