From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00 autolearn=ham autolearn_force=no version=3.4.4 X-Google-Thread: 103376,580018a609f37d0f X-Google-Attributes: gid103376,public X-Google-Language: ENGLISH,ASCII Path: g2news1.google.com!news1.google.com!proxad.net!freenix!news.wanadoo.fr!news.wanadoo.fr!not-for-mail Date: Thu, 01 Sep 2005 20:23:37 +0200 From: Pascal Obry Organization: Home - http://www.obry.net User-Agent: Mozilla Thunderbird 1.0.6 (Windows/20050716) X-Accept-Language: fr, en MIME-Version: 1.0 Newsgroups: comp.lang.ada Subject: Re: equal and not equal References: <8_GRe.43146$F23.516228@twister2.libero.it> In-Reply-To: <8_GRe.43146$F23.516228@twister2.libero.it> Content-Type: text/plain; charset=ISO-8859-15 Content-Transfer-Encoding: 8bit Message-ID: <4317472c$0$1719$8fcfb975@news.wanadoo.fr> NNTP-Posting-Date: 01 Sep 2005 20:23:40 CEST NNTP-Posting-Host: 82.120.16.55 X-Trace: 1125599020 news.wanadoo.fr 1719 82.120.16.55:1061 X-Complaints-To: abuse@wanadoo.fr Xref: g2news1.google.com comp.lang.ada:4382 Date: 2005-09-01T20:23:40+02:00 List-Id: TC a �crit : > how translate = and /= for pointer use? > and := ? I bet you have a pointer to a data structure and want to use = or /= on the content (and not on the pointer itself). Use .all. type PA is access String; A, B : PA := new String'("azerty"); if A.all = B.all then ... Also to assign a value to the pointer : A.all := (others => ' '); -- All char of A.all are set to space Note that A.all := "qw"; Will raise Constraint_Error as A.all is 6 chars long not 2. You can omit the .all if using a slice : A (1 .. 2) := "qw"; Pascal. -- --|------------------------------------------------------ --| Pascal Obry Team-Ada Member --| 45, rue Gabriel Peri - 78114 Magny Les Hameaux FRANCE --|------------------------------------------------------ --| http://www.obry.net --| "The best way to travel is by means of imagination" --| --| gpg --keyserver wwwkeys.pgp.net --recv-key C1082595