This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.
| Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
|---|---|---|
| Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |
| Other format: | [Raw text] | |
Tested on i686-linux, committed on mainline.
It is not possible to compute full external names if code is not being
generated since the necessary information is not available (for full
details, see comments added to exp_dbug.adb as part of this change).
The Get_External_Name_With_Suffix routine already had a guard so that
it did nothing if called when code was not being generated (e.g. in
ASIS mode). This patch applies the same guard to Get_Encoded_Name.
Also fix a bad generation of debug info.
Consider the following subprogram:
--
with TEXT_IO;
procedure TEST_GDB is
type T1 is range 1 .. 64;
C : constant T1 := 18;
type T2 (ART : T1 := T1'FIRST) is record
ADRESSE : STRING(1 .. 10) := (others => ' ');
case ART is
when C => ED : BOOLEAN := TRUE;
when others => null;
end case;
end record;
DUMMY : T2 (ART => C);
begin
DUMMY.ED := TRUE;
TEXT_IO.PUT_LINE(T1'IMAGE(DUMMY.ART));
TEXT_IO.PUT_LINE(BOOLEAN'IMAGE(DUMMY.ED));
end TEST_GDB;
--
When issuing the following commands in gdb:
b test_gdb.adb:26
r
p dummy
The output should be
$1 = (art => 18, adresse => " ", ed => true)
2005-06-14 Nicolas Setton <setton@adacore.com>
Ed Schonberg <schonberg@adacore.com>
* exp_dbug.ads, exp_dbug.adb (Get_Variant_Part): Fix the encoding of
the "simple_choice" member in a variant record, in accordance with the
description in the package spec: the information output for a constant
should be "S number", not "SS number".
(Get_Encoded_Name): Return at once if not generating code. Avoids name
overflow problem when compiling with -gnatct, for ASIS/gnatmetrics.
Attachment:
difs.23
Description: Text document
| Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
|---|---|---|
| Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |