Mercurial > hg > CbC > CbC_gcc
comparison gcc/ada/gnatls.adb @ 131:84e7813d76e9
gcc-8.2
author | mir3636 |
---|---|
date | Thu, 25 Oct 2018 07:37:49 +0900 |
parents | 04ced10e8804 |
children | 1830386684a0 |
comparison
equal
deleted
inserted
replaced
111:04ced10e8804 | 131:84e7813d76e9 |
---|---|
4 -- -- | 4 -- -- |
5 -- G N A T L S -- | 5 -- G N A T L S -- |
6 -- -- | 6 -- -- |
7 -- B o d y -- | 7 -- B o d y -- |
8 -- -- | 8 -- -- |
9 -- Copyright (C) 1992-2017, Free Software Foundation, Inc. -- | 9 -- Copyright (C) 1992-2018, Free Software Foundation, Inc. -- |
10 -- -- | 10 -- -- |
11 -- GNAT is free software; you can redistribute it and/or modify it under -- | 11 -- GNAT is free software; you can redistribute it and/or modify it under -- |
12 -- terms of the GNU General Public License as published by the Free Soft- -- | 12 -- terms of the GNU General Public License as published by the Free Soft- -- |
13 -- ware Foundation; either version 3, or (at your option) any later ver- -- | 13 -- ware Foundation; either version 3, or (at your option) any later ver- -- |
14 -- sion. GNAT is distributed in the hope that it will be useful, but WITH- -- | 14 -- sion. GNAT is distributed in the hope that it will be useful, but WITH- -- |
185 | 185 |
186 procedure Usage; | 186 procedure Usage; |
187 -- Print usage message | 187 -- Print usage message |
188 | 188 |
189 procedure Output_License_Information; | 189 procedure Output_License_Information; |
190 pragma No_Return (Output_License_Information); | |
190 -- Output license statement, and if not found, output reference to COPYING | 191 -- Output license statement, and if not found, output reference to COPYING |
191 | 192 |
192 function Image (Restriction : Restriction_Id) return String; | 193 function Image (Restriction : Restriction_Id) return String; |
193 -- Returns the capitalized image of Restriction | 194 -- Returns the capitalized image of Restriction |
194 | 195 |
692 -- Output_Token -- | 693 -- Output_Token -- |
693 ------------------ | 694 ------------------ |
694 | 695 |
695 procedure Output_Token (T : Token_Type) is | 696 procedure Output_Token (T : Token_Type) is |
696 begin | 697 begin |
697 if T in T_No_ALI .. T_Flags then | 698 case T is |
698 for J in 1 .. N_Indents loop | 699 when T_No_ALI .. T_Flags => |
699 Write_Str (" "); | 700 for J in 1 .. N_Indents loop |
700 end loop; | 701 Write_Str (" "); |
701 | 702 end loop; |
702 Write_Str (Image (T).all); | 703 |
703 | 704 Write_Str (Image (T).all); |
704 for J in Image (T)'Length .. 12 loop | 705 |
706 for J in Image (T)'Length .. 12 loop | |
707 Write_Char (' '); | |
708 end loop; | |
709 | |
710 Write_Str ("=>"); | |
711 | |
712 if T in T_No_ALI .. T_With then | |
713 Write_Eol; | |
714 elsif T in T_Source .. T_Name then | |
715 Write_Char (' '); | |
716 end if; | |
717 | |
718 when T_Preelaborated .. T_Body => | |
719 if T in T_Preelaborated .. T_Is_Generic then | |
720 if N_Flags = 0 then | |
721 Output_Token (T_Flags); | |
722 end if; | |
723 | |
724 N_Flags := N_Flags + 1; | |
725 end if; | |
726 | |
705 Write_Char (' '); | 727 Write_Char (' '); |
706 end loop; | 728 Write_Str (Image (T).all); |
707 | 729 end case; |
708 Write_Str ("=>"); | |
709 | |
710 if T in T_No_ALI .. T_With then | |
711 Write_Eol; | |
712 elsif T in T_Source .. T_Name then | |
713 Write_Char (' '); | |
714 end if; | |
715 | |
716 elsif T in T_Preelaborated .. T_Body then | |
717 if T in T_Preelaborated .. T_Is_Generic then | |
718 if N_Flags = 0 then | |
719 Output_Token (T_Flags); | |
720 end if; | |
721 | |
722 N_Flags := N_Flags + 1; | |
723 end if; | |
724 | |
725 Write_Char (' '); | |
726 Write_Str (Image (T).all); | |
727 | |
728 else | |
729 Write_Str (Image (T).all); | |
730 end if; | |
731 end Output_Token; | 730 end Output_Token; |
732 | 731 |
733 ----------------- | 732 ----------------- |
734 -- Output_Unit -- | 733 -- Output_Unit -- |
735 ----------------- | 734 ----------------- |