Frank Heckenbach wrote:
`Return' currently needs special syntactic handling, only because it's (optional) argument doesn't have to be enclosed in parentheses (like in C), such as `Return 42'.
The only Pascal dialect (AFAIK) that also supports `Return' is Mac Pascal. Does it work without parentheses there? If not, I suggest to change it in GPC, even if it means a few (trivial) changes in existing code.
According to the documentation, Compaq Pascal also supports the RETURN statement with the same syntax as used by CodeWarrior Pascal. In both, the expression doesn't have to be enclosed in parentheses.
Of the three common MacPascal dialect implementations, only the CodeWarrior Pascal implementation has the RETURN statement extension. IIRC, it was adopted as the result of a Compaq Pascal user's suggested improvement.
Gale Paeper gpaeper@empirenet.com