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,d1f23f0bd3971bec X-Google-Attributes: gid103376,public X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news1.google.com!news4.google.com!news.glorb.com!atl-c03.usenetserver.com!pc02.usenetserver.com!ALLTEL.NET!not-for-mail Date: Thu, 21 Apr 2005 14:40:41 -0500 From: "Marc A. Criley" User-Agent: Mozilla Thunderbird 1.0 (Windows/20041206) X-Accept-Language: en-us, en MIME-Version: 1.0 Newsgroups: comp.lang.ada Subject: Re: Timing Block of GNAT code in milliseconds References: <1114090119.383842.20950@l41g2000cwc.googlegroups.com> <1114109602.373794.96920@l41g2000cwc.googlegroups.com> In-Reply-To: <1114109602.373794.96920@l41g2000cwc.googlegroups.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Message-ID: <6e403$426801d3$49955b7$25683@ALLTEL.NET> X-Complaints-To: abuse@usenetserver.com Organization: UseNetServer.com X-Trace: 6e403426801d3a13cf01225683 Xref: g2news1.google.com comp.lang.ada:10632 Date: 2005-04-21T14:40:41-05:00 List-Id: markp wrote: > I tried this and got some errors. Hereis what my code looks like > > My_Time : Ada.Calendar.Time; > Result : Ada.Calendar.Time; Result should by declared to be of type Duration, just like the error message said. > > My_Time := Ada.Calendar.Clock; > Result := (Ada.Calendar.Clock - My_Time)/1000; > > The error I get is : > > Expected private type Ada.Calendar.Time > Expected type Standard Duration > > on the piece of code (Ada.Calendar.Clock - My_Time). > > Lastly, > > How would I print out Result? Put_Line(Duration'Image(Result)); Marc A. Criley www.mckae.com