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.3 required=5.0 tests=BAYES_00,INVALID_MSGID autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,4ef9c02a78f0071f X-Google-Attributes: gid103376,public From: mheaney@ni.net (Matthew Heaney) Subject: Re: Multiple instantiation of Ada.Direct_IO Date: 1998/01/28 Message-ID: #1/1 X-Deja-AN: 320008327 Content-Transfer-Encoding: 8bit References: <886003669.3982.0.nnrp-02.9e98a25e@news.demon.co.uk> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Organization: Estormza Software Newsgroups: comp.lang.ada Date: 1998-01-28T00:00:00+00:00 List-Id: In article <886003669.3982.0.nnrp-02.9e98a25e@news.demon.co.uk>, "Blake Weston" wrote: >Hi there, > >I have a bit of a problem. Basically I am using Ada.Direct_IO to read / >write to a file. The problem being I wish to write records of differing >types to the file, without closing the file and re-opening it. > >Ada 95 will not even let me open the same file as two different file_type >variables as this creates a Use Exception error. > >Can anybody help? It sounds like you want to perform heterogeneous I/O. Direct_IO is for homogeneous I/O. Try Ada.Stream_I/O instead. -------------------------------------------------------------------- Matthew Heaney Software Development Consultant (818) 985-1271