comp.lang.ada
 help / color / mirror / Atom feed
* Translate from C
@ 2005-04-09 19:30 Jean-Baptiste CAMPESATO
  2005-04-09 20:54 ` tmoran
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Jean-Baptiste CAMPESATO @ 2005-04-09 19:30 UTC (permalink / raw)


Hello,
I've this code in C : http://www.a2lf.org/util.c
and i want to translate it in Ada; 
A friend tried :
   procedure Copy
     (Source      : Address;
      Destination : Address;
      Bytes       : Natural)
   is
      S : String (1 .. Bytes);
      D : String (1 .. Bytes);
      for S'Address use Source;
      for D'Address use Destination;
   begin
      for I in S'Range loop
         D (I) := S (I);
      end loop;
   end Copy;

Do you think it's Ok ?

Thanks.



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

end of thread, other threads:[~2005-04-11 13:39 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2005-04-09 19:30 Translate from C Jean-Baptiste CAMPESATO
2005-04-09 20:54 ` tmoran
     [not found] ` <gkvg51de5t83scllh0sp7go8nmcfe3ede9@4ax.com>
2005-04-10  7:47   ` Jean-Baptiste CAMPESATO
2005-04-11 13:39 ` Steve

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