comp.lang.ada
 help / color / mirror / Atom feed
From: "Y.Tomino" <demoonlit@panathenaia.halfmoon.jp>
Subject: Re: Ada.Containers.Indefinite_Ordered_Maps of gcc 4.0.1 has bug ?
Date: Sun, 07 Aug 2005 01:17:34 +0900
Date: 2005-08-07T01:17:34+09:00	[thread overview]
Message-ID: <dd2nqq$s4s$1@news522.nifty.com> (raw)
In-Reply-To: <uek97oz40.fsf@earthlink.net>

Thanks!
But I think it's not reflected to FSF...

Matthew Heaney wrote:
 >...
> This is an old bug, that was fixed a few months ago.  I'm surprised
> you're seeing it.  You can simply patch your copy like this:

I downloaded source of gcc 4.0.1 from one of mirrors:
http://mirrors.rcn.net/pub/sourceware/gcc/

 >...
 >I would submit a bug report either to the FSF or to AdaCore, to ensure
 >the fix wends its way to public GCC repositories.  This bug was found
 >and fixed in AdaCore's sources a while ago, so I don't understand why
 >you don't have the latest, corrected version.

Now, I downloaded the latest 4.1.0 snapshot from
http://mirrors.rcn.net/pub/sourceware/gcc/snapshots/4.1-20050730/
however, a-ciorse.abs's Copy_Node is

    function Copy_Node (Source : Node_Access) return Node_Access is
       Element : Element_Access := new Element_Type'(Source.Element.all);

    begin
       return new Node_Type'(Parent  => null,
                             Left    => null,
                             Right   => null,
                             Color   => Source.Color,
                             Element => Element);
    exception
       when others =>
          Free_Element (Element);
          raise;
    end Copy_Node;

It seems difference to your suggested code. There is not "Key".

 >  function Copy_Node (Source : Node_Access) return Node_Access is
 >      K : Key_Access := new Key_Type'(Source.Key.all);
 >      E : Element_Access;
 >   begin
 >      E := new Element_Type'(Source.Element.all);
 >
 >      return new Node_Type'(Parent  => null,
 >                            Left    => null,
 >                            Right   => null,
 >                            Color   => Source.Color,
 >                            Key     => K,
 >                            Element => E);
 >   exception
 >      when others =>
 >         Free_Key (K);
 >         Free_Element (E);
 >         raise;
 >   end Copy_Node;

YT



  reply	other threads:[~2005-08-06 16:17 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-08-06 11:57 Ada.Containers.Indefinite_Ordered_Maps of gcc 4.0.1 has bug ? Y.Tomino
2005-08-06 12:54 ` Matthew Heaney
2005-08-06 13:13   ` Y.Tomino
     [not found]   ` <42F4B753.2080004@panathenaia.halfmoon.jp>
2005-08-06 15:37     ` Matthew Heaney
2005-08-06 16:17       ` Y.Tomino [this message]
2005-08-06 16:33         ` Matthew Heaney
2005-08-06 16:49           ` Y.Tomino
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox