[Prev][Next][Index][Thread]
Re: Dynamic typing confuses me!
Andreas Bogk wrote:
>
> "Bertrand Augereau" <baugereau@ifrance.kom> writes:
>
> > Why does this code give a run-time error?
>
> It should give you a compile-time error here:
>
> > begin
> > main();
> > end;
>
> This is not Pascal, and begin..end is not valid. Just write
No, begin/end is definately a valid top-level form, per the DRM. In Functional Developer the editor also knows about begin/end top-level forms so it's actually preferable to put random top-level forms inside begin/end. Also, the project wizard produces code like this, which may be where the original poster got it.
References: