comp.lang.ada
 help / color / mirror / Atom feed
* Some problems with string type
@ 2001-06-07  2:18 Valdes
  2001-06-06 16:34 ` Philip Anderson
  2001-06-06 17:49 ` tmoran
  0 siblings, 2 replies; 11+ messages in thread
From: Valdes @ 2001-06-07  2:18 UTC (permalink / raw)


I have my program writen in Ada that raise some exceptions:

raised CONSTRAINT_ERROR : gestindex.adb:5

... And at line 5...

 function createindex (S:string) return index is
      I:Index;
   begin
      i.nameindex:=s; -- Ligne cinq
      i.firstletter:=null;
      return i;
   end createindex;

... The index record is defined as follow...

  type index is record
      nameindex:String(1..20);
      firstletter:ptrletter;
   end record;

... The mistake seems to be trivial but I don't see it.

I have seen the same for this also:

    Ptrtemp.Letter:=Charat(M,Ni);

there is the same error but Charat return a character and letter is also
one. (ptrtemp is also type ptrlettre)

All my greetings if you have some ideas. And forgive me for my bad
english.

--
Le Vif Z�phyr Jubile Sur Les Kumquats Du Clown Gracieux.






^ permalink raw reply	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2001-06-07 13:20 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2001-06-07  2:18 Some problems with string type Valdes
2001-06-06 16:34 ` Philip Anderson
2001-06-06 20:29   ` Some problems with string type(Exact String?) McDoobie
2001-06-06 21:30     ` tmoran
2001-06-07  8:07       ` Jean-Pierre Rosen
2001-06-06 22:08     ` Marin David Condic
2001-06-07  6:48     ` Ada.Strings.Fixed procedure Move Petter Fryklund
2001-06-07  4:06   ` Some problems with string type Valdes
2001-06-07 13:20     ` Valdes Laurent
2001-06-06 17:49 ` tmoran
2001-06-07  4:07   ` Valdes

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