add print-change diff modes that do not use colour
authorJamie Schmeiser <schmeise@ca.ibm.com>
Thu, 25 Mar 2021 14:32:13 +0000 (10:32 -0400)
committerJamie Schmeiser <schmeise@ca.ibm.com>
Thu, 25 Mar 2021 14:35:27 +0000 (10:35 -0400)
commit7f2ae3d55f19421a8bad4bc001e5fd7dfea0ddcb
tree3ac0cfc92196efa7aa6053d04df66125e8fe0859
parente21ab31f45a440e195f9c914083d57718e0de3b7
add print-change diff modes that do not use colour

Summary:
The colour characters currently added to the output of -print-changed=diff
and -print-changed=diff-quiet cause difficulties when capturing the output
and examining it in an editor. Change the function to not have the colour
characters and add 2 new choices (-print-changed=cdiff and
-print-changed=cdiff-quiet) to retain the existing functionality of adding
the colour characters.

Author: Jamie Schmeiser <schmeise@ca.ibm.com>
Reviewed By: aeubanks (Arthur Eubanks) yrouban (Yevgeny Rouban)
Differential Revision: https://reviews.llvm.org/D97398
llvm/include/llvm/Passes/StandardInstrumentations.h
llvm/lib/Passes/StandardInstrumentations.cpp
llvm/test/Other/ChangePrinters/print-changed-diff.ll