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.4 required=5.0 tests=AC_FROM_MANY_DOTS,BAYES_00 autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,d875f8fc1f73cf09 X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2001-04-23 06:45:16 PST Path: newsfeed.google.com!newsfeed.stanford.edu!news-spur1.maxwell.syr.edu!news.maxwell.syr.edu!newsfeed.icl.net!isdnet!psinet-france!psiuk-f4!psiuk-p4!uknet!psiuk-n!news.pace.co.uk!nh.pace.co.uk!not-for-mail From: "Marin David Condic" Newsgroups: comp.lang.ada Subject: Re: Compiling AFLEX 1.4a with Dec Ada 83 3.5-20 on Open VMS 7.1 Date: Mon, 23 Apr 2001 09:33:44 -0400 Organization: Posted on a server owned by Pace Micro Technology plc Message-ID: <9c1avq$mr9$1@nh.pace.co.uk> References: <9bsm5c$khe$1@uranium.btinternet.com> NNTP-Posting-Host: 136.170.200.133 X-Trace: nh.pace.co.uk 988032826 23401 136.170.200.133 (23 Apr 2001 13:33:46 GMT) X-Complaints-To: newsmaster@pace.co.uk NNTP-Posting-Date: 23 Apr 2001 13:33:46 GMT X-Priority: 3 X-MSMail-Priority: Normal X-Newsreader: Microsoft Outlook Express 5.50.4522.1200 X-MIMEOLE: Produced By Microsoft MimeOLE V5.50.4522.1200 Xref: newsfeed.google.com comp.lang.ada:6855 Date: 2001-04-23T13:33:46+00:00 List-Id: Not really addressign your question directly, but.... There is an Ada95 implementation for Alpha/VMS. I have not checked in a while, but look at the GNAT FTP site and see if it is still there. I had it installed on an Alpha/VMS platforma couple of years ago and it worked very well, supporting all the DEC specific pragmas, etc. It would save you from having to hammer together patches to go backwards to Ada83... MDC -- Marin David Condic Senior Software Engineer Pace Micro Technology Americas www.pacemicro.com Enabling the digital revolution e-Mail: marin.condic@pacemicro.com Web: http://www.mcondic.com/ "singlespeeder" wrote in message news:9bsm5c$khe$1@uranium.btinternet.com... > I've got hold of the source for AFLEX 1.4a and want to compile it to run on > Open VMS 7.1 > > The compiler I have access to is DEC Ada 83 3.5-20. > > As far as I can tell there are two things in the code that require > modification. > > 1) AFLEX 1.4a assumes that the Ada 95 package Ada.Command_Line is available. > 2) AFLEX 1.4a assumes that the Ada 95 implementation of Text_IO is > available, and uses the file Standard_Error. It also generates a debug > scanner that uses Standard_Error. > > I've addressed the first issue by writing a package VAX_Command_Line that > wraps starlet, and I just used that in place of Ada.Command_Line - I only > had to change two packages, both of which were documented in the manual. > > I'm having more trouble with the second issue. In the lex specification for > the scanner I currently get around the scanner assuimg the presence of > Standard_Error by the following kludge in my lex specification. (Note that > AFLEX 1.4a only has two user defined sections, not 4 as in some manuals) > > -- definitions > %% > -- rules > %% > -- user defined section copied before yylex > package foo is > standard_error : text_io.file_type; > function yylex return token; > end foo; > package body foo is > ## > -- user defined section copied after yylex > begin > text_io.create (file => standard_error, > mode => out_file, > name => lexer_error.txt); > end foo; > > So my package foo declares it's own standard_error, which it creates when > the package is elaborated. It always does this even when I instruct AFLEX > not to generate a debug scanner - in which case I get an empty > lexer_error.txt file. > > Is there a better way of writing my lex specification so that I don't have > to have this kludge, or am I going to have to poke around in the source of > Aflex? I don't want to do this because I don't want to then have to generate > a set of tests for AFLEX to make sure I haven't screwed it up. > > Nick > >