This is an old revision of the document!
The TWENEX.ORG Pascal compiler was developed at Stanford LOTS based on the DECUS PASCAL compiler from Hamburg University.
The compiler can be invoked either with the standard compile/load/execute commands or directly with @PASCAL
. The standard extension for Pascal source files is .PAS
.
Additional information on the LOTS Pascal compiler can be found in @HELP PASCAL
. (The help file mentions another Pascal compiler, PASSGO, but it is not available on TWENEX.ORG.) Additional documentation is in the following files in directory NEO:<DOCUMENTATION>
(DOC:
):
To create and run a Hello, World! program in Pascal:
[KANKAN] PUBLIC:<~>@ create hello.pas
Your default text editor will start. Enter and save the following:
(* Hello program in Pascal *) program Hello(Output); begin writeln('Hello, World!'); end.
Return to EXEC then compile and run the program:
[KANKAN] PUBLIC:<~>@ execute hello PASCAL: HELLO LINK: Loading [LNKXCT HELLO execution] OUTPUT : Hello, World! [KANKAN] PUBLIC:<~>@
* Syntax of the EXECUTE command is EXECUTE filename[.extension]
. The file extension is optional if you used the standard source file extension (.PAS for Pascal) and there are no other program source files with the same name in your default directory.
* At the OUTPUT :
prompt, press Enter
to direct output to your terminal.
(The following reference documents are for the DEC TOPS-20 PASCAL compiler, which is not installed on TWENEX.ORG, not the LOTS compiler. Although the two compilers differ in some respects, the TOPS-20 compiler documents may provide some useful guidance.)