Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Posting-Version: version B 2.10.2 9/18/84; site voder.UUCP Path: utzoo!watmath!clyde!bonnie!akgua!whuxlm!harpo!decvax!decwrl!greipa!pesnta!pertec!scgvaxd!wlbr!voder!gbs From: gbs@voder.UUCP (George Smith) Newsgroups: net.micro.cpm,net.lang.pascal Subject: Re: BORLAND TURBO PASCAL - New release (CP/M Version) Message-ID: <778@voder.UUCP> Date: Wed, 29-May-85 12:31:58 EDT Article-I.D.: voder.778 Posted: Wed May 29 12:31:58 1985 Date-Received: Sat, 1-Jun-85 01:17:49 EDT References: <641@ptsfa.UUCP> <180@nicmad.UUCP> <519@utai.UUCP> <590@intelca.UUCP> Distribution: net Organization: National Semiconductor, Santa Clara Lines: 35 Xref: watmath net.micro.cpm:4187 net.lang.pascal:308 > > I would like to know if anyone has tried this new version (3.0) of > > Turbo Pascal in CP/M. An earlier version was flawed in that recursion was > > not properly implemented: a procedure that called itself using pass-by- > > reference (i.e. passing the parameters using var: name ) did not > > work properly ... > > > > Patrick Strauss > > Turbo Pascal V2.0 does indeed handle recursion correctly if you set the > appropriate compiler directive. The latest Tug Lines has a list of all > known bugs in the compiler and recursive use of Var parameters was not > one of them. V3.0 for CP/M does not buy you much more than a new manual. > New features are limited to SeekEOF, Exit, ... > > --Chuck I think there are two different points being addressed here. One refers to the CP/M-80 limitation that local variables may not be passed as VAR parameters in a recursive procedure. This is an implementation deficiency rather than a bug - it is documented on page 319 of the 3.0 manual. The second point refers to the fact that the default condition for the CP/M-80 version of Turbo generates non-recursive code. To turn on the generation of recursive code, you must use the A compiler directive. See page 318 of the 3.0 manual. However, even when recusive code generation is turned on, you may still NOT use local variables as VAR parameters in recursive calls. Also, I think that Version 3.0 is worth upgrading to. The addition of the EXIT statement alone is a boon for people porting code from the UCSD P-System environment. And, as pointed out in the V1#5 issue of TUG LINES, there were quite a few bugs fixed. -- George B. Smith National Semiconductor ...!{ihnp4!nsc | decvax!decwrl!nsc | ucbvax}!voder!gbs