summaryrefslogtreecommitdiff
path: root/gcc/ada/gnatchop.adb
diff options
context:
space:
mode:
authorcharlet <charlet@138bc75d-0d04-0410-961f-82ee72b054a4>2003-11-21 10:46:37 +0000
committercharlet <charlet@138bc75d-0d04-0410-961f-82ee72b054a4>2003-11-21 10:46:37 +0000
commitbe4b2f7309eae165205b6127e2119f9d8e6ec0e0 (patch)
tree132085c540a6cf57220b0a3538e1675d09a58a83 /gcc/ada/gnatchop.adb
parent40e55fbbd58fe04a45af0335bc0b945cec36c9c9 (diff)
downloadgcc-be4b2f7309eae165205b6127e2119f9d8e6ec0e0.tar.gz
2003-11-20 Jerome Guitton <guitton@act-europe.fr>
* 5ztiitho.adb: Remove an unreferenced variable. 2003-11-20 Thomas Quinot <quinot@act-europe.fr> * adaint.c: For FreeBSD, use mkstemp. 2003-11-20 Arnaud Charlet <charlet@act-europe.fr> * gnatlbr.adb: Now reference Gnat_Static_Version_String. 2003-11-20 Robert Dewar <dewar@gnat.com> * bld.adb: Remove useless USE of gnatvsn * gnatchop.adb: Minor reformatting Clean up version handling to be more consistent * gnatxref.adb: Minor reformatting * gprcmd.adb: Minor reformatting Fix output of copyright to be more consistent with other tools 2003-11-20 Vincent Celier <celier@gnat.com> * make.adb (Scan_Make_Args): Do not transmit --RTS= to gnatlink 2003-11-20 Sergey Rybin <rybin@act-europe.fr> * atree.adb (Initialize): Add initializations for global variables used in New_Copy_Tree. * cstand.adb (Create_Standard): Add call to Initialize_Scanner (with Internal_Source_File as the actual). Put the set of statements creating Any_Character before the set of statements creating Any_Array to have Any_Character fully initialized when it is used in creating Any_Array. * scn.adb (Initialize_Scanner): Do not set Comes_From_Source ON and do not call Scan in case if the actual is Internal_Source_File Add 2003 to copyright note. * sinput.adb (Source_First, Source_Last, Source_Text): Add code for processing Internal_Source_File. * types.ads: Add the constant Internal_Source_File representing the source buffer for artificial source-code-like strings created within the compiler (the definition of Source_File_Index is changed). git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@73798 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/ada/gnatchop.adb')
-rw-r--r--gcc/ada/gnatchop.adb36
1 files changed, 22 insertions, 14 deletions
diff --git a/gcc/ada/gnatchop.adb b/gcc/ada/gnatchop.adb
index 8764a86578c..6855454c210 100644
--- a/gcc/ada/gnatchop.adb
+++ b/gcc/ada/gnatchop.adb
@@ -37,11 +37,6 @@ with Hostparm;
procedure Gnatchop is
- Cwrite : constant String :=
- "GNATCHOP " &
- Gnatvsn.Gnat_Version_String &
- " Copyright 1998-2000, Ada Core Technologies Inc.";
-
Terminate_Program : exception;
-- Used to terminate execution immediately
@@ -57,9 +52,13 @@ procedure Gnatchop is
Gnat_Cmd : String_Access;
-- Command to execute the GNAT compiler
- Gnat_Args : Argument_List_Access := new Argument_List'
- (new String'("-c"), new String'("-x"), new String'("ada"),
- new String'("-gnats"), new String'("-gnatu"));
+ Gnat_Args : Argument_List_Access :=
+ new Argument_List'
+ (new String'("-c"),
+ new String'("-x"),
+ new String'("ada"),
+ new String'("-gnats"),
+ new String'("-gnatu"));
-- Arguments used in Gnat_Cmd call
EOF : constant Character := Character'Val (26);
@@ -1110,6 +1109,7 @@ procedure Gnatchop is
else
Error_Msg ("-k# requires numeric parameter");
end if;
+
return False;
end if;
end loop;
@@ -1129,23 +1129,31 @@ procedure Gnatchop is
end;
when 'p' =>
- Preserve_Mode := True;
+ Preserve_Mode := True;
when 'q' =>
- Quiet_Mode := True;
+ Quiet_Mode := True;
when 'r' =>
Source_References := True;
when 'v' =>
- Verbose_Mode := True;
- Put_Line (Standard_Error, Cwrite);
+ Verbose_Mode := True;
+
+ -- Why is following written to standard error. Most other
+ -- tools write to standard output ???
+
+ Put (Standard_Error, "GNATCHOP ");
+ Put (Standard_Error, Gnatvsn.Gnat_Version_String);
+ Put_Line
+ (Standard_Error,
+ " Copyright 1998-2000, Ada Core Technologies Inc.");
when 'w' =>
- Overwrite_Files := True;
+ Overwrite_Files := True;
when 'x' =>
- Exit_On_Error := True;
+ Exit_On_Error := True;
when others =>
null;