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.2 required=5.0 tests=BAYES_00,INVALID_MSGID, REPLYTO_WITHOUT_TO_CC autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,2e69f8b2b50371a6,start X-Google-Attributes: gid103376,public From: Fernando Tricas Subject: End_Of_Line, End_Of_File Date: 1996/11/30 Message-ID: #1/1 X-Deja-AN: 201553373 x-sender: ftricas@tsc1 content-type: TEXT/PLAIN; charset=US-ASCII organization: Universiad de Zaragoza - Spain mime-version: 1.0 reply-to: Fernando Tricas newsgroups: comp.lang.ada Date: 1996-11-30T00:00:00+00:00 List-Id: I'm trying to do a program similar to wc from Unix systems in Ada95 and I've found the following problem when dealing with a file such as: ** begin file a ** end file that is a file composed of two lines, the second (and last) one one empty. The problem is I do not know how to recognize when there is an End_Of_Line followed by an End_Of_File or when there is and End_Of_File alone. The problem seems to be that in Ada95 (I'm using gnat-3.01 compiler on a Unix workstation) when End_Of_File returns true, End_Of_Line also returns true and that need not be true. For example: ** begin file ** end file That is, an empty text file. Thank you and best regards, -- Fernando Tricas ftricas@posta.unizar.es