[PATCH] D39694: [VerifyDiagnosticConsumer] support -verify=PREFIX

Joel E. Denny via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Mon Nov 6 13:00:20 PST 2017


jdenny created this revision.

This mimic's FileCheck's --check-prefix option.

The default PREFIX is "expected".  That is, "-verify" is equivalent to
"-verify=expected".

The goal is to permit exercising a single test suite source file with
different compiler options producing different sets of diagnostics.
While cpp can be combined with the existing -verify to accomplish the
same goal, source is often easier to read when it's not cluttered with
preprocessor directives.  For those cases, this tiny extension seems
worthwhile.


https://reviews.llvm.org/D39694

Files:
  include/clang/Basic/DiagnosticOptions.h
  include/clang/Driver/CC1Options.td
  lib/Frontend/CompilerInvocation.cpp
  lib/Frontend/VerifyDiagnosticConsumer.cpp
  test/Frontend/verify-prefix.c

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D39694.121769.patch
Type: text/x-patch
Size: 5066 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20171106/60871c9a/attachment.bin>


More information about the cfe-commits mailing list