[gcc r15-3371] ada: Fix standard output stream for gnatcmd output
Marc Poulhi?s
dkm@gcc.gnu.org
Mon Sep 2 08:24:35 GMT 2024
https://gcc.gnu.org/g:2df253f35eec84a7dd7d4b0eaf4b1c052177044c
commit r15-3371-g2df253f35eec84a7dd7d4b0eaf4b1c052177044c
Author: Ronan Desplanques <desplanques@adacore.com>
Date: Wed Aug 21 15:10:38 2024 +0200
ada: Fix standard output stream for gnatcmd output
Before this patch, the gnat command sent to standard error pieces of
information that are a better match for standard output. This patch
makes this information go to standard output.
gcc/ada/
* gnatcmd.adb (GNATCmd): Fix standard output stream.
Diff:
---
gcc/ada/gnatcmd.adb | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/gcc/ada/gnatcmd.adb b/gcc/ada/gnatcmd.adb
index c1b817bd7864..ed37a348103a 100644
--- a/gcc/ada/gnatcmd.adb
+++ b/gcc/ada/gnatcmd.adb
@@ -278,7 +278,8 @@ procedure GNATCmd is
-- Start of processing for GNATCmd
begin
- -- All output from GNATCmd is debugging or error output: send to stderr
+ -- Almost all output from GNATCmd is debugging or error output: send to
+ -- stderr.
Set_Standard_Error;
@@ -349,6 +350,7 @@ begin
elsif Command_Arg <= Argument_Count
and then Argument (Command_Arg) = Ada_Help_Switch
then
+ Set_Standard_Output;
Usage;
Exit_Program (E_Success);
@@ -364,6 +366,7 @@ begin
-- Add the following so that output is consistent with or without the
-- --help flag.
+ Set_Standard_Output;
Write_Eol;
Write_Line ("Report bugs to report@adacore.com");
return;
More information about the Gcc-cvs
mailing list