diff options
author | Don Hinton <hintonda@gmail.com> | 2017-08-03 16:13:13 +0000 |
---|---|---|
committer | Don Hinton <hintonda@gmail.com> | 2017-08-03 16:13:13 +0000 |
commit | baa7f4296b19e2948e411ffd4d5d5c6ba01e369e (patch) | |
tree | 1b1adc265ce37d25af6c5b3d5200faa149121c91 /test/Misc | |
parent | 71ca9f8a52ad545a71d72bbe82eb3edf86c29e1c (diff) |
[diagtool] Add ability to pass in the id and return the name for a
particular diagnostic.
Differential Revision: https://reviews.llvm.org/D36252
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@309955 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/Misc')
-rw-r--r-- | test/Misc/find-diagnostic-id.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/test/Misc/find-diagnostic-id.c b/test/Misc/find-diagnostic-id.c index bef66178f9..1cddde747f 100644 --- a/test/Misc/find-diagnostic-id.c +++ b/test/Misc/find-diagnostic-id.c @@ -1,5 +1,7 @@ -// RUN: diagtool find-diagnostic-id warn_unused_variable | FileCheck %s +// RUN: diagtool find-diagnostic-id warn_unused_variable > %t; FileCheck %s < %t +// RUN: cat %t | xargs diagtool find-diagnostic-id | FileCheck %s --check-prefix=INVERSE // RUN: not diagtool find-diagnostic-id warn_unused_vars 2>&1 | FileCheck --check-prefix=ERROR %s // CHECK: {{^[0-9]+$}} +// INVERSE: warn_unused_variable // ERROR: error: invalid diagnostic 'warn_unused_vars' |