Date : Wed, 29 May 1985 16:31:58 GMT
From : George Smith <gbs%voder.uucp@BRL.ARPA>
Subject: Re: BORLAND TURBO PASCAL - New release (CP/M Version)
> > 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