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=-0.8 required=5.0 tests=BAYES_00, FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,REPLYTO_WITHOUT_TO_CC autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII X-Google-Thread: 103376,4ea0c01838520df4 X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2002-03-25 02:43:04 PST Path: archiver1.google.com!news1.google.com!newsfeed.stanford.edu!newsfeeds.belnet.be!news.belnet.be!deine.net!freenix!enst!enst.fr!not-for-mail From: Erik Sigra Newsgroups: comp.lang.ada Subject: Re: Read booleans from streams Date: Mon, 25 Mar 2002 11:46:53 +0100 Organization: ENST, France Sender: comp.lang.ada-admin@ada.eu.org Message-ID: References: <200203242318.g2ONIkc12876@a77.ib.student.liu.se> <3C9E85F6.8EDF3AAD@myob.com> Reply-To: comp.lang.ada@ada.eu.org NNTP-Posting-Host: marvin.enst.fr Mime-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 8bit X-Trace: avanie.enst.fr 1017052982 49800 137.194.161.2 (25 Mar 2002 10:43:02 GMT) X-Complaints-To: usenet@enst.fr NNTP-Posting-Date: Mon, 25 Mar 2002 10:43:02 +0000 (UTC) Return-Path: X-Mailer: KMail [version 1.3.2] In-Reply-To: <3C9E85F6.8EDF3AAD@myob.com> Errors-To: comp.lang.ada-admin@ada.eu.org X-BeenThere: comp.lang.ada@ada.eu.org X-Mailman-Version: 2.0.8 Precedence: bulk X-Reply-To: sigra@home.se List-Help: List-Post: List-Subscribe: , List-Id: comp.lang.ada mail<->news gateway List-Unsubscribe: , Errors-To: comp.lang.ada-admin@ada.eu.org X-BeenThere: comp.lang.ada@ada.eu.org Xref: archiver1.google.com comp.lang.ada:21636 Date: 2002-03-25T11:46:53+01:00 Thanks for your reply! m�ndagen den 25 mars 2002 03.05 skrev du: > >raised ADA.IO_EXCEPTIONS.END_ERROR : s-stratt.adb:170 > > Your loop doesn't do an EOF test. That was expected. It was the reading I wanted to investigate, so I didn't bother with an EOF test. > >data > >==== > >02027203 > > Which looks like > > 0000_0000,0000_0010,0000_0000,0000_0010, > ^ ^ ^ ^ > 0 0 0 0 > > 0000_0111,0000_0010,0000_0000,0000_0011 > ^ ^ ^ ^ > 1 0 0 1 > > > And your results look like > > 0 0 0 0 1 0 0 1 > > Interesting, I havn't checked it but how about > changing Actually it were the characters '0', '2' and '7' that were stored in the file, so it was rather 0001_1000,0001_1010,0001_1000,0001_1010, ^ ^ ^ ^ 0 0 0 0 0001_1111,0001_1010,0001_1000,0001_1011 ^ ^ ^ ^ 1 0 0 1 but that's essentially the same in this matter. > > "for Boolean_Aggregate'Component_Size use 1;" > > to > > "pragma Pack (Boolean_Aggregate);" and if > that doesn't work, try I already tried that. > > "for Boolean_Aggregate'Component_Size use 1;" > "for Boolean_Aggregate'Size use 8"; And I tried that too. I even used the test Put_Line ("Boolean_Aggregate'Size = " & Boolean_Aggregate'Size'Img); in the program and it showed "Boolean_Aggregate'Size = 8". I use gnat-3.13p. Any other suggestions?