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,8c07fb80fc02e8b0,start X-Google-Attributes: gid103376,public,usenet X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news1.google.com!news1.google.com!eweka.nl!lightspeed.eweka.nl!195.114.231.69.MISMATCH!feeder.news-service.com!multikabel.net!feed10.multikabel.net!feed.xsnews.nl!border-1.ams.xsnews.nl!fu-berlin.de!uni-berlin.de!individual.net!not-for-mail From: Sir Chewbury Gubbins Newsgroups: comp.lang.ada Subject: Newbie question Date: Fri, 23 Nov 2007 13:22:56 +0000 Message-ID: X-Trace: individual.net U+8FdcnXa79jPYBeiwv9ZACk3OvXYl+YLOAISRqTgNi8Ei0kmf X-Orig-Path: isis.home!news Cancel-Lock: sha1:cyGWbExJXhuijXO5PsJnygeLOeU= User-Agent: slrn/0.9.8.1pl1 (Debian) Xref: g2news1.google.com comp.lang.ada:18585 Date: 2007-11-23T13:22:56+00:00 List-Id: Good afternoon! I apologise if this is an eye-rolly question, but I'm having a bit of an issue using Gnat with the Lovelace tutorial. A trivial example - the "Compute" procedure on: http://www.adahome.com/Tutorials/Lovelace/s1sf.htm contains a sub procedure which does: loop Put(X); New_Line(X); Double(X); end loop; All fine - X is defined as an integer and initialised to 1. Now, if I comment out the loop and end loop, the program outputs one as expected. If I duplicate the three lines and run it again, I get a 1 and a 2 as expected. If I stick the infinite loop back in, I don't get the expected series of doublings, but just an infinite number of zeros. It *looks* as though X magically becomes out of scope within the loop, but I can't see why that would be the case. Anyone shed any light on this? Regards Choobs -- Sir Chewbury Gubbins ... Blog : http://www.nelefa.org /|\ Game Diary : http://www.chewbury.net / | \ Abu the Monkey was never naughty.