aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--tools/opt/opt.cpp8
1 files changed, 1 insertions, 7 deletions
diff --git a/tools/opt/opt.cpp b/tools/opt/opt.cpp
index 3ca5d42272..949c9b1d5c 100644
--- a/tools/opt/opt.cpp
+++ b/tools/opt/opt.cpp
@@ -118,13 +118,7 @@ int main(int argc, char **argv) {
// If the output is set to be emitted to standard out, and standard out is a
// console, print out a warning message and refuse to do it. We don't impress
// anyone by spewing tons of binary goo to a terminal.
- if (Out == &std::cout && isStandardOutAConsole() && !Force && !NoOutput
- && !Quiet) {
- std::cerr << "WARNING: It looks like you're attempting to print out a "
- << "bytecode file. I'm\ngoing to pretend you didn't ask me to do"
- << " this (for your own good). If you\nREALLY want to taste LLVM"
- << " bytecode first-hand, you can force output with the\n`-f'"
- << " option.\n\n";
+ if (!Force && !NoOutput && !Quiet && CheckBytecodeOutputToConsole(Out)) {
NoOutput = true;
}