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,8982dc345b43855 X-Google-Attributes: gid103376,public X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news1.google.com!news3.google.com!news2.volia.net!zen.net.uk!dedekind.zen.co.uk!news-peer-lilac.gradwell.net!not-for-mail From: "Martin Dowie" Newsgroups: comp.lang.ada References: Subject: Re: Uninitialized variable and the effects they have Date: Thu, 24 Nov 2005 11:49:50 -0000 Organization: BAE SYSTEMS X-Priority: 3 X-MSMail-Priority: Normal X-Newsreader: Microsoft Outlook Express 6.00.2800.1506 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1506 Message-ID: <4385a6e7$1_1@glkas0286.greenlnk.net> X-Original-NNTP-Posting-Host: glkas0286.greenlnk.net NNTP-Posting-Date: 24 Nov 2005 11:51:09 GMT NNTP-Posting-Host: 20.133.0.1 X-Trace: 1132833069 news.gradwell.net 38044 dnews/20.133.0.1 X-Complaints-To: news-abuse@gradwell.net Xref: g2news1.google.com comp.lang.ada:6584 Date: 2005-11-24T11:51:09+00:00 List-Id: Maciej Sobczak wrote: [snip] > I : Integer; -- uninitialized It's likely that "I" will contain a valid value - you just don't know what it is! If it was a float it might be a different matter. > J : Integer := I + 2; The assignment may raise a Constraint_Error depending on what happened to be in I at the time. That's (yet another) reason to declare your own types and preferably ones that are not full range with respect to their base type. Combine that with "pragme Normalize_Scalars;" (see H.1) and you have a chance. In general, see 13.9.1. Cheers -- Martin