-// RUN: diagtool show-enabled %s 2>&1 | FileCheck %s
+// RUN: diagtool show-enabled %s | FileCheck %s
//
// This shows warnings which are on by default.
// We just check a few to make sure it's doing something sensible.
// CHECK: warn_unterminated_string
-// RUN: diagtool show-enabled -Wno-everything %s 2>&1 | count 0
+// RUN: diagtool show-enabled -Wno-everything %s | count 0
-// RUN: diagtool show-enabled -Wno-everything -Wobjc-root-class %s 2>&1 | FileCheck -check-prefix CHECK-WARN %s
-// RUN: diagtool show-enabled -Wno-everything -Werror=objc-root-class %s 2>&1 | FileCheck -check-prefix CHECK-ERROR %s
-// RUN: diagtool show-enabled -Wno-everything -Wfatal-errors=objc-root-class %s 2>&1 | FileCheck -check-prefix CHECK-FATAL %s
+// RUN: diagtool show-enabled -Wno-everything -Wobjc-root-class %s | FileCheck -check-prefix CHECK-WARN %s
+// RUN: diagtool show-enabled -Wno-everything -Werror=objc-root-class %s | FileCheck -check-prefix CHECK-ERROR %s
+// RUN: diagtool show-enabled -Wno-everything -Wfatal-errors=objc-root-class %s | FileCheck -check-prefix CHECK-FATAL %s
//
// CHECK-WARN: W warn_objc_root_class_missing [-Wobjc-root-class]
// CHECK-ERROR: E warn_objc_root_class_missing [-Wobjc-root-class]
// CHECK-FATAL: F warn_objc_root_class_missing [-Wobjc-root-class]
-// RUN: diagtool show-enabled --no-levels -Wno-everything -Wobjc-root-class %s 2>&1 | FileCheck -check-prefix CHECK-NO-LEVELS %s
+// RUN: diagtool show-enabled --no-levels -Wno-everything -Wobjc-root-class %s | FileCheck -check-prefix CHECK-NO-LEVELS %s
//
// CHECK-NO-LEVELS-NOT: W
// CHECK-NO-LEVELS-NOT: E
int main(int argc, char *argv[]) {
if (argc > 1)
if (DiagTool *tool = diagTools->getTool(argv[1]))
- return tool->run(argc - 2, &argv[2], llvm::errs());
+ return tool->run(argc - 2, &argv[2], llvm::outs());
llvm::errs() << "usage: diagtool <command> [<args>]\n\n";
diagTools->printCommands(llvm::errs());