Article View: comp.lang.modula2
Article #3378Re: structured types & procedures
From: J.Last
Date: Fri, 15 Mar 1996 14:49
Date: Fri, 15 Mar 1996 14:49
37 lines
2045 bytes
2045 bytes
seurer@nordruth.rchland.ibm.com (Bill Seurer) wrote:
>In article <DnrCDH.17u@lut.ac.uk>, "J.Last" <eljl3@dwalin.lut.ac.uk> writes:
>|> I use both the FTL Modula-2 compiler for CP/M and the Stony Brook compiler for
>|> the PC. In the FTL compiler, this statement was fine:
>|>
>|> TYPE Vector: ARRAY [0..10] OF REAL;
>
>Try
>
> TYPE Vector = ARRAY [0..10] OR REAL;
>
>The one with the : in it is invalid syntax.
>--
>
>- Bill Seurer ID Tools and Compiler Development IBM Rochester, MN
> Business: BillSeurer@vnet.ibm.com Home: BillSeurer@aol.com
Yeah, sorry for this posting. There's a mistake there....full marks you spotted
it. This posting only got half posted for some reason. What I meant to say was:
My FTL M-2 compiler allows me to return structured types like this:
PROCEDURE Thingy(Bob:REAL):StructuredType;
Whereas the StonyBrook DOS compiler won't let me. I have to do:
PROCEDURE Thingy(Bob:REAL;VAR Fred:StructuredType);
Is there a good reason for this?
--
_________ _______________________________ _________
< ""/_\"" \ / \ / ""/_\"" >
< (.o.) \/ Jake Last \/ (.o.) >
< v~v /\ eljl3@gimli.lut.ac.uk /\ v~v >
<_________/ \_______________________________/ \_________>
<http://www.geocities.com/SiliconValley/2915>
Technical Details
Message-ID:
<DoBD6w.6HI@lut.ac.uk>Path:
arc1-ca.pugleaf.net!lut.ac.uk!usenetReferences:
<DnrCDH.17u@lut.ac.uk> <4hmu5o$vje@locutus.rchland.ibm.com>Show Full Headers
Complete Article Headers
Newsgroups: comp.lang.modula2 Path: arc1-ca.pugleaf.net!lut.ac.uk!usenet From: "J.Last" <eljl3@dwalin.lut.ac.uk> Subject: Re: structured types & procedures Sender: usenet@lut.ac.uk (Usenet-News) Message-ID: <DoBD6w.6HI@lut.ac.uk> Date: Fri, 15 Mar 1996 14:49:44 GMT To: BillSeurer@aol.com X-Nntp-Posting-Host: elsun1.lut.ac.uk X-Url: news:4hmu5o$vje@locutus.rchland.ibm.com Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset=us-ascii References: <DnrCDH.17u@lut.ac.uk> <4hmu5o$vje@locutus.rchland.ibm.com> Mime-Version: 1.0 X-Mailer: Mozilla 1.1N (X11; I; SunOS 4.1.3_U1 sun4m) Organization: Loughborough University of Technology, UK