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.8 required=5.0 tests=BAYES_00,PLING_QUERY autolearn=no autolearn_force=no version=3.4.4 X-Google-Thread: 103376,b6d862eabdeb1fc4 X-Google-NewGroupId: yes X-Google-Attributes: gida07f3367d7,domainid0,public,usenet X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news2.google.com!news3.google.com!feeder.news-service.com!news.mixmin.net!newsfeed.straub-nv.de!noris.net!newsfeed.arcor.de!newsspool3.arcor-online.net!news.arcor.de.POSTED!not-for-mail Date: Mon, 07 Jun 2010 17:50:25 +0200 From: Georg Bauhaus User-Agent: Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10.5; en-US; rv:1.9.1.9) Gecko/20100317 Thunderbird/3.0.4 MIME-Version: 1.0 Newsgroups: comp.lang.ada Subject: Re: Ada noob here! Is Ada widely used? References: <2o8vq76hpv1m.vs7m2beo23nz.dlg@40tude.net> <1q5k4indthpli.1dn17o4ue4a15$.dlg@40tude.net> <4c0c1188$0$6887$9b4e6d93@newsspool2.arcor-online.net> <4c0cd44f$0$6766$9b4e6d93@newsspool3.arcor-online.net> <4c0cfe57$0$7660$9b4e6d93@newsspool1.arcor-online.net> <4c0d0978$0$7651$9b4e6d93@newsspool1.arcor-online.net> <1e1tfvcv6iqxl.5ofese1iqas.dlg@40tude.net> In-Reply-To: <1e1tfvcv6iqxl.5ofese1iqas.dlg@40tude.net> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Message-ID: <4c0d1542$0$7655$9b4e6d93@newsspool1.arcor-online.net> Organization: Arcor NNTP-Posting-Date: 07 Jun 2010 17:50:26 CEST NNTP-Posting-Host: 732e54b3.newsspool1.arcor-online.net X-Trace: DXC=UQiAbKlYORPFm0Y?OE@2^Xic==]BZ:af^4Fo<]lROoRQ<`=YMgDjhgRc1a@Zj3Rnc\616M64>ZLh>_cHTX3j]VdK@F499jNU X-Complaints-To: usenet-abuse@arcor.de Xref: g2news2.google.com comp.lang.ada:12408 Date: 2010-06-07T17:50:26+02:00 List-Id: On 07.06.10 17:09, Dmitry A. Kazakov wrote: > On Mon, 07 Jun 2010 17:00:07 +0200, Georg Bauhaus wrote: > >> On 07.06.10 16:51, Dmitry A. Kazakov wrote: >>> On Mon, 07 Jun 2010 16:12:38 +0200, Georg Bauhaus wrote: >>> >>>> On 07.06.10 14:22, Dmitry A. Kazakov wrote: >>> >>>>> This includes the exceptional ones. When bug >>>>> happens, the program is in no state. >>>> >>>> Erh, are you sure? >>> >>> Yes I am. Any program state is defined, it has some sematic interpretation >>> in the domain. Bug is when you have lost this synchronization. Meaningless >>> state is no state. >> >> Then what constitutes a bug? >> >> procedure add_to_account(Number: in out Account_ID; sum: Money) is >> client_account: Account := Find_Account(Number); >> begin >> -- FIXME: not ready, using dummy account >> client_account := Make_new_Account; >> end add_to_account; > > Where is a problem? The above program, if it enters production, has a bug, IMHO: if Passed_In > 0.0 then Lock.Seize; was := amount_in_account(123); add_to_account(123, sum => Passed_In); is := amount_in_account(123); Lock.Release; -- assume add_to_account is correct send(other_bank, is - was); Program state is meaningful, if buggy. Or are you defining a bug to be a state of the program to which you are unable to assign meaning?