mirror of
https://github.com/xomboverlord/ldc.git
synced 2026-04-19 02:09:03 +02:00
Workaround for --help output being truncated when redirecting to file.
This commit is contained in:
@@ -96,6 +96,11 @@ void printVersion() {
|
|||||||
if (CPU == "generic") CPU = "(unknown)";
|
if (CPU == "generic") CPU = "(unknown)";
|
||||||
printf(" Host CPU: %s\n", CPU.c_str());
|
printf(" Host CPU: %s\n", CPU.c_str());
|
||||||
printf("\n");
|
printf("\n");
|
||||||
|
|
||||||
|
// Without explicitly flushing here, only the target list is visible when
|
||||||
|
// redirecting stdout to a file.
|
||||||
|
fflush(stdout);
|
||||||
|
|
||||||
llvm::TargetRegistry::printRegisteredTargetsForVersion();
|
llvm::TargetRegistry::printRegisteredTargetsForVersion();
|
||||||
exit(EXIT_SUCCESS);
|
exit(EXIT_SUCCESS);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user