Google
 

Trailing-Edge - PDP-10 Archives - decuslib20-03 - decus/20-0078/doc/simlh2.rnm
There is 1 other file named simlh2.rnm in the archive. Click here to see a list.
^^
.nojustify
.title DECsystem-10 SIMULA Language Handbook, part II
.spacing 1
.left margin 5
.paper size 65,65
.page
.number 2
.skip 1
.nofill
.left margin 0
Swedish National Defense Research Institute#####FOA 1 Report
Department of Planning and Operations Research##C8399-M3(E5)
S-10450 Stockholm 80############################December 1974
################################################Revised edition:
################################################Dec 1977
.skip 1
DECsystem-10 SIMULA Language Handbook Part II
.break
=============================================
.skip 1
.left margin 5
(Programmer's Guide)
.break
.skip 1
.fill
.indent -5
BY###Stefan Arnborg, Olof Bjorner, Lars Enderin, Elisabeth Engstrom,
Reidar Karlsson, Mats Ohlin, Jacob Palme, Ingrid Wennerstrom
and Claes Wihlborg.
.nofill
.skip 2
.indent -5
ABSTRACT:
.fill
.skip 1
The DECsystem-10 SIMULA Language Handbook contains the
information necessary for an applications programmer who intends to use
SIMULA on a DECsystem-10 computer.
.skip 1
Part I contains a description of the SIMULA programming language.
The contents of Part I are mostly machine-independent.
.skip
 Part II (this part)
contains special information for DECsystem-10.
Part II will tell you:
.break
.indent -2
>#How to run the compiler on a DECsystem-10,
.break
.indent -2
>#What might differ between SIMULA on the DEC 10 and other computers,
.break
.indent -2
>#How to write separately compiled classes in SIMULA and procedures
in SIMULA, MACRO 10 or FORTRAN,
.break
.indent -2
>#How to use the SIMULA Debugging
System (SIMDDT),
.break
.indent -2
>#How to produce efficient and portable programs,
.break
.indent -2
>#How to interpret error messages,
.skip
Part III will tell you about useful utility programs in SIMULA and/or
for SIMULA users.
.skip 1
.index ^^Release version of SIMULA
This document reflects the software as of version 4
of the DECsystem-10 SIMULA system.
.skip 1
Last update 1977-12-25.
.skip 2
.indent -5
NTIS NUMBER: PB-243 065.
.skip
.indent -5
SEARCH KEY
.skip 1
Computer, Programming, Programming Language, SIMULA, DECsystem-10,
Digital Equipment, Algol 60, Fortran, Separate compilation,
Part-compilation, Debugging, On-line debugging, DDT, Dynamic Debugging
Technique, Compiler, Compiling techniques, Data structures,
Diagnostic messages, Error messages, Program measurement,
Prettyprint, Program library.
.paper size 55,65
.page
.indent -5
CONDITIONS OF RELEASE
.index ^^Release of SIMULA, conditions of
.index ^^Responsibility for errors
.index ^^Copyright of the SIMULA system
.skip 1
The information in this document is subject to change without notice.
The  Swedish National Defense Research Institute assumes no
responsibility for any errors that may appear in this manual
(or in the SIMULA-10 system).
.skip 1
The software described in this document is furnished to the user for use on a
DECsystem-10
computer system and may be copied only for use on
 DECsystem-10 and DECsystem-20 systems, except as
may otherwise be provided in writing by the Swedish National Defense Research Institute.
.skip 1
Copyright 1974, 1975, 1976, 1977 by The Swedish National Defense Research Institute.
Copying is allowed.
.index ^^Copyright
.skip 3
.subtitle CHAPTER 0 CONTENTS
.page
.p -5,3,5
0####CONTENTS
.index ^^contents, table of
.break
========
.skip 3
###1##INTRODUCTION
.skip 1
###2##DEC SYSTEM-10 SIMULA SYSTEM
.skip 1
###3##OPERATING PROCEDURES
.skip 1
.left margin 11
3.1#INTRODUCTION
.break
3.2 THE R COMMAND
.break
3.3 COMPIL-CLASS COMMANDS
.break
3.4 BATCH
.break
3.5 SWITCHES
.skip 2
.indent -5
###4##IMPLEMENTATION DEFINED PARTS OF THE SIMULA LANGUAGE
.skip 1
4.1 SYSTEM PREFIXES
.break
4.2 VIRTUAL MATCHES
.break
4.3 EDITING AND DE-EDITING PROCEDURES
.break
4.4 MATHEMATICAL LIBRARY FUNCTIONS
.break
4.5 COLLATING SEQUENCE, LETTER
.break
4.6 INITIALIZATION OF CHARACTER VARIABLES
.break
4.7 SUBSCRIPT CHECKING
.break
4.8 RANDOM DRAWING
.break
4.9 QUALIFICATION CHECKING
.break
4.10 SIMULATION PROCEDURE TIME
.skip 2
.indent -5
###5##LANGUAGE EXTENSIONS
.skip 1
.indent -5
###6##RESTRICTIONS
.skip 1
6.1 CAPACITY RESTRICTIONS
.break
6.2 PARAMETER CORRESPONDENCE
.break
6.3 FOR STATEMENTS
.break
6.4 MISCELLANEOUS RESTRICTIONS
.break
6.5 RESTRICTIONS IN SIMULA WITH RESPECT TO ALGOL 60
.break
.left margin 5
.skip 2
###7##SEPARATE COMPILATION
.skip 1
.left margin 11
7.1 THE EXTERNAL DECLARATION
.break
7.2 THE EXTERNAL SWITCH
.break
7.3 RESTRICTIONS ON SEPARATE COMPILATION
.break
7.4 SIMDIR UTILITY PROGRAM
.page
.left margin 5
###8##OBJECT PROGRAM I/O
.skip 1
.left margin 11
8.1 INTRODUCTION
.break
8.2 HOW TO DEFINE A FILE
.break
8.3 RUN-TIME SWITCHES
.break
8.4 CLASS INFILE
.break
8.5 CLASS OUTFILE
.break
8.6 CLASS PRINTFILE
.break
8.7 CLASS DIRECTFILE
.break
8.8 CLASS BASICIO
.break
8.9 DEVICE CONTROL CHARACTERS
.left margin 5
.skip 2
###9##DEBUGGING SIMULA PROGRAMS WITH SIMDDT
.LEFT MARGIN 11
.SKIP 1
9.1 LOADING AND STARTING SIMDDT
.BREAK
9.2 SIMDDT INPUT AND OUTPUT
.BREAK
9.3 SIMDDT COMMANDS
.SKIP 2
.LEFT MARGIN 5
.skip 1
##10##PROGRAMMING CONSIDERATIONS
.left margin 11
.skip 1
10.1 WRITING EFFICIENT PROGRAMS
.break
10.2 WRITING PORTABLE PROGRAMS
.break
10.3 WRITING VERY LARGE PROGRAMS
.break
10.4 MISCELLANEOUS ADVICE
.left margin 5
.page
.skip 2
###APPENDICES
.skip 1
###A##HARDWARE REPRESENTATION
.skip 1
.left margin 11
A.1 SIMULA COMPILER INPUT
.break
A.2 SIMULA PROGRAMS ON CARDS
.break
A.3 STANDARD LINE SEQUENCE NUMBERS
.break
A.4 BASIC SYMBOLS
.break
A.5 IDENTIFIERS
.break
A.6 CONSTANTS
.break
A.7 COMMENTS
.break
A.8 USE OF SPACES AND LINE EDITING CHARACTERS
.skip 2
.left margin 5
###B##INTERNAL REPRESENTATION
.skip 1
.left margin 11
B.1 REPRESENTATION OF VARIABLES
.break
B.2 REPRESENTATION OF DYNAMIC ADDRESSES
.break
B.3 REPRESENTATION OF PARAMETERS
.break
B.4 DYNAMIC RECORDS
.skip 2
.left margin 5
###C##COMPILER DIAGNOSTICS
.skip 1
.left margin 11
C.1 COMMAND AND SWITCH MESSAGES
.break
C.2 SOURCE CODE DIAGNOSTICS
.skip 2
.indent -5
###D##RUN-TIME AND DEBUG DIAGNOSTICS
.skip 1
D.1 DIALOGUE MESSAGES
.break
D.2 RUN-TIME ERROR MESSAGES
.skip 2
.left margin 5
###E##HOW TO WRITE AN EXTERNAL MACRO OR 
.break
######FORTRAN PROCEDURE
.skip 1
.left margin 11
E.1 EXTERNAL FORTRAN PROCEDURES
.break
E.2 FORTRAN PROGRAMMING EXAMPLE
.break
E.3 EXTERNAL MACRO-10 PROCEDURES
.break
E.4 MACRO-10 CALLING STANDARD
.break
E.5 STANDARD MACROS
.break
E.6 MACRO-10 PROGRAMMING  EXAMPLES
.skip 2
.left margin 5
###F##RUN-TIME SYSTEM COMPONENTS
.skip 1
###G##RESERVED SIMULA WORDS AND STANDARD IDENTIFIERS
.skip 1
.page
###H##SAMPLE JOB LISTINGS
.LEFT MARGIN 11
.SKIP 1
H.1 THE R COMMAND
.BREAK
H.2 THE COMPILE COMMAND
.BREAK
H.3 THE LOAD COMMAND
.BREAK
H.4 THE EXECUTE COMMAND
.BREAK
H.5 THE DEBUG COMMAND
.BREAK
H.6 CONTROL CARDS IN BATCH
.BREAK
H.7 EXAMPLE OF CTL FILE IN BATCH
.BREAK
H.8 SOURCE CODE LISTING WITH ERRORS AND
.BREAK
####CROSS REFERENCE TABLE
.BREAK
H.9 SIMDDT EXAMPLES
.SKIP 2
.LEFT MARGIN 5
###I##ERROR REPORT
.skip 1
###J##PROGRAM MEASUREMENT SYSTEM
.skip 1
###K##TECO, SOS OR EDITS ON SIMULA PROGRAMS
.skip 1
.left margin 11
K.1 WHY LINE NUMBERED FILES?
.break
K.2 WHICH TEXT EDITOR SHOULD YOU USE?
.break
K.3 HOW TO USE SOS OR EDITS ON SIMULA SOURCE PROGRAMS
.break
K.4 HOW TO GIVE A FILE A NEW LINE NUMBER WITH TECO
.break
K.5 EDITING A LINE NUMBERED FILE WITH TECO
.left margin 5
.skip 2
###L##AUTOMATIC EDITING OF SIMULA PROGRAMS
.skip 1
###M##CONVERSION OF SIMULA PROGRAMS
.break
######BETWEEN DEC, IBM AND CDC COMPUTERS
.left margin 11
.skip 1
M.1 CONVERSION FROM IBM 360/370 SIMULA
.indent 4
TO DEC SYSTEM-10 SIMULA
.break
M.2 CONVERSION FROM DEC SYSTEM-10 SIMULA
.indent 4
TO IBM 360/370 SIMULA
.break
M.3 CONVERSION FROM CDC SIMULA
.indent 4
TO DEC SYSTEM-10 SIMULA
.skip 2
.left margin 5
###N##(Moved to part III of the handbook)
.skip 1
###O##DUMP OF CODE GENERATED BY THE SIMULA COMPILER
.skip 2
###P##CONVERSION FROM DEC 10 ALGOL TO DEC 10 SIMULA
.skip 1
.left margin 11
P.1 WHY TRANSLATE FROM ALGOL TO SIMULA?
.break
P.2 WHY IS SIMULA NOT COMPATIBLE WITH ALGOL?
.break
P.3 TEXT STRING HANDLING
.break
P.4 INPUT/OUTPUT
.break
P.5 MISCELLANEOUS
.left margin 5
^^
.spacing 1
.fill
.left margin 5
.nojustify
.subtitle Chapter 1 INTRODUCTION
.page
.skip 3
.indent -5
1####INTRODUCTION
.break
============
.skip 2
.index ^^Standardization of SIMULA
.index ^^Common base definition
.index ^^SIMULA Standards group
SIMULA is a general purpose language which contains
.index ^^defining documents
Algol 60 as a subset. Its defining documents are 
the Common Base Language [1] and the Revised Algol 60 Report [2].
In addition to the facilities offered by Algol, SIMULA is especially
suited for list processing, text handling and simulation,
through the class concept. The SIMULA language is
described in detail in the first part of the DECsystem-10 SIMULA Language Handbook [3].
.skip 1
The full SIMULA language, including recommended extensions,
is implemented as defined in Common Base Language.
In addition a powerful interactive debugging system called SIMDDT is provided.
Special care has been taken to make this SIMULA implementation
.index ^^IBM 360/370
compatible with IBM 360/370 SIMULA in as many respects
as possible. Conversion
programs exist which transform IBM 360/370 programs to
DECsystem-10 SIMULA and vice versa (see appendix M).
Compatibility with other SIMULA systems is also high and
a conversion program from CDC SIMULA to DECsystem-10 SIMULA
is also available (see appendix M).
.skip 1
This part of the SIMULA Language Handbook contains information on
all implementation defined parts of the SIMULA language, such as
object program I/O and various restrictions.
It also contains descriptions of features unique to the DECsystem-10
implementation, e.g. commands and switches, SIMDDT debugging package
and utility programs.
.skip 1
The reader of this manual is supposed to be familiar with
the SIMULA language and the time-sharing environment of
DECsystem-10 [4].
.skip 1
The development of the SIMULA system was undertaken as a joint project between the
software house Engmans Elektronik AB (ENEA) and the Swedish National Defense Research
Institute (FOA). This document was compiled by Olof Bjorner, Elisabeth Engstrom,
Reidar Karlsson, Ingrid Wennerstrom and Claes Wihlborg from ENEA and by
Lars Enderin, Mats Ohlin, Jacob Palme and Stefan Arnborg from FOA.
.page
.skip 4
If you want a copy of the SIMULA system (not for the KA10 CPU),
.index ^^ordering SIMULA
.index ^^KI10 CPU
.index ^^KL10 CPU
.index ^^DECUS library
you should get it either
from the Swedish National Defence Research Institute or from the DECUS
library. In that way you will get the best and latest version.
Therefore do not privately redistribute the SIMULA system to
other installations.
.skip
Copies of DECsystem-10 SIMULA for the KA10 CPU can be obtained from
.index ^^KA10 CPU
the Computing Center at the University of Western Ontario, London,
Canada.
.test page 24
.skip
Reference documents:
.index ^^References
.index ^^Bibliograhpy
.index ^^Literature list
.skip 2
1.##Dahl, Myhrhaug and Nygaard:
.break
####Common Base Language
.break
####Norwegian Computing Center, October 1970.
.break
####Publication No S-22.
.skip 1
2.##Revised Report on the Algorithmic Language Algol 60
.break
####CACM Vol 6,  No 1 1963.
.skip 1
3.##DECsystem-10 SIMULA Language Handbook, part I
.break
####FOA P Report No C8398-M3(E5), October 1974.
.skip 1
4.##DECsystem-10 Users Handbook, 2nd Edition
.break
####Digital Equipment Corporation, 1972
.skip 1
5.##Birtwistle, Myhrhaug, Nygaard:
.break
####SIMULA begin
.break
####Studentlitteratur, Lund, Sweden 1973
.skip 1
6.##DECsystem-10 SIMULA Technical documentation.
^^
.fill
.nojustify
.spacing 1
.left margin 5
.subtitle Chapter 2 THE DECsystem-10 SIMULA SYSTEM
.page
.skip 3
.indent -5
2.###THE DECsystem-10 SIMULA SYSTEM
.break
==============================
.skip 2
The SIMULA system consists of the following subsystems:
.skip 1
*##a three pass compiler
.break
*##a run-time system
.break
*##an interactive debug system
.break
*##utility programs and help files.
.skip 1
.index ^^monitor
.index ^^DEC monitors
The SIMULA system will run under DEC monitors series 5 and 6 and can
be used in the same way as other language processors,
e.g FORTRAN or COBOL. The operating procedures are described in chapter 3.
.skip 1
The compiler takes as input a source module specified in the command string.
If there are references to external modules in the program the compiler
also reads attribute files for these modules (for further
information about external modules see chapter 7).
The source program is translated into an equivalent object program. This
object program together with control information
to the run-time system and symbol tables are output to a REL file.
If compile-time errors or warning conditions were detected, diagnostic
messages are output to the terminal.
If the compiled module was itself an external class
or procedure definition, an attribute file with extension ATR is
output as well. The compiler also produces a program listing
with an optional cross reference table if requested.
.skip 1
The object program, i.e. the REL file produced from the main program
and all REL files for external modules referred to by it, are loaded into
.index ^^SIMLIB
core by LINK-10. LINK-10 also searches the SIMULA library SIMLIB and fetches subroutines
.index ^^LINK-10 Linking loader
referred to by the object programs. The output from LINK-10
is an executable SIMULA program in core which can be saved on disk
with the SAVE command.
.skip 1
Before the execution starts, the user may request the interactive debug package SIMDDT
by issuing the command REENTER instead of START.
.index ^^REENTER monitor command
This loads the self-relocating debug system into core.
Otherwise the debug system is automatically loaded
after execution start when needed.
.skip 1
.page
When the SIMULA program starts, a reentrant high segment
(usually called operating system, object-time system or run-time system(1))
.footnote 7
.skip 1
-----------------
.skip 1
(1)  The routines in SIMLIB and SIMRTS are called run-time system
(RTS) throughout this manual.
.index ^^High segment
.index ^^Run-time system
.index ^^Object time system
.index ^^Reentrant high segment
!
containing additional support routines is fetched from the 
system area. The execution of the SIMULA program then proceeds.
The high segment is called SIMRTS. For reasons of storage economy, SIMRTS
is usually split into two separate segments of which one is loaded
initially and is replaced with the other once initialization is ready.
The initial high segment may be needed by some programs when creating and
opening new files in the course of execution, but the other
high segment is the one normally active.
.skip 1
.index ^^SIMDDT, automatic loading of
If an illegal condition is detected during execution, SIMDDT
is loaded and an appropriate diagnostic message is printed on
the user's TTY. SIMDDT then waits
for commands issued by the user to find out the cause of the error,
but program execution can usually not be continued.
.skip 1
The debug package, SIMDDT, is similar in capacity to DDT but is
entirely source language oriented. The user may specify breakpoints
and conditions to stop at defined statements. SIMDDT is described in chapter 9.
.skip 1
.index ^^SIMULA program conversion
.index ^^source code conversion
.index ^^conversion of source code
.index ^^conversion of SIMULA programs
.index ^^utility programs
Utility programs exist for conversion of SIMULA source programs
between CDC SIMULA, IBM 360/370 SIMULA and DECsystem-10 SIMULA and for measuring
program efficiency. These utility programs are
described in appendix M.
.index ^^SIMDIR program
A special program, SIMDIR, can be used to obtain information
from the directory about the files compiled with the SIMULA compiler.
The SIMDIR program is described in chapter 7.
.skip 1
The ability of TOPS-10 to share reentrant code in high segments has been
utilized in the compiler and SIMRTS.
The compiler generates code in the low segment.
This code is also reentrant as long as no breakpoints are set.
.index ^^Reentrant code, generation of
.index ^^Sharable reentrant code, generation of
Library routines in SIMLIB are also
kept in low segment and are not reentrant.
.skip 1
.index ^^compilation core requirements
.index ^^run-time core requirements
.index ^^core requirements
The compiler will run in a minimum of 23K words for very
small programs and in 30K words for large programs.
The reentrant parts of RTS will occupy either 4.5K or 5.5K words
of core.
.skip 1
.index ^^help files
The following help files exist:
.skip 1
.index ^^SIMULA.HLP
SIMULA.HLP
.break
contains information about the SIMULA system and references to other help files and
documentation files.
.skip 1
.index ^^SIMCOM.HLP
SIMCOM.HLP
.break
contains information about command string format and compile-time
switches. This file is also printed as a result of the compiler switch HELP.
.skip 1
.index ^^SIMRTS.HLP
SIMRTS.HLP
.break
contains information about run-time switches and file definitions
in a specification file. This file is also printed
as a result of the run-time switch HELP.
.skip 1
.index ^^SIMDDT.HLP
SIMDDT.HLP
.break
contains information about available SIMDDT commands. An abbreviated version
of this file is printed on the user's TTY as a result of the
SIMDDT command HELP.
^^
.VR COMHLP,h,m
.IF COMHLP
.npa;.rm 72;.nst
.EI COMHLP
.nj;.lm 5;.spacing 1
.IN COMHLP
.subtitle Chapter 3 OPERATING PROCEDURES
.pg;.i -5;3.###OPERATING PROCEDURES
.br;====================
.subtitle Chapter 3.1##INTRODUCTION
.p -5,3,10
3.1##INTRODUCTION
.s;The DECsystem-10 monitor supports both time-sharing and multiprogramming
batch mode of operation. The SIMULA programmer can use either or both of
these operating environments to develop his applications.
In the time-sharing environment he can
run the SIMULA compiler either directly using
the R command or indirectly using the commands COMPILE,
LOAD, DEBUG and EXECUTE.
In a batch environment he can also use a special
batch card $SIMULA.
.subtitle Chapter 3.2 OPERATING PROCEDURES, THE R COMMAND
.pg;.index ^^R command
.p -5,3,10
3.2##THE R COMMAND
.s;This command can be used if your installation has not yet implemented
SIMULA into the COMPIL cusp, which interprets commands like COMPILE and EXECUTE.
.s;The compiler is invoked with the following command:
.s;R SIMULA
.s;The compiler outputs an asterisk (*) on the terminal and is now
ready to accept the first command. A command should have
the following format:
.EI COMHLP
.IF COMHLP
SIMULA command strings and switches
.s 2;Command string format:
.EI COMHLP
.s;.index ^^relfile
.index ^^lstfile
.index ^^listfile
relfil,lstfil=source1,source2,...
.s;.index ^^syntax of commands
.index ^^compiler commands
Syntax:
.s;.index ^^file descriptor format
1.	Each file descriptor has the format:
.s;dev:filename.ext[path]/switch/switch...
.s;.index ^^source device
.index ^^device, source
Default for device (dev) is DSK.
If no path (directory) is given, your own default path, which may be
different from your logged-in ppn (UFD), is used. The default path can
be changed by the SETSRC program. See the SETSRC program in the Monitor
Commands manual and the PATH_. UUO in the Monitor Calls manual for further
information about default paths. Subfile directories may be used.
.s;2.	relfil receives the object code generated by the compiler.
If a file specification for relfil is given explicitly or by default, it is
normally created unless severe errors were detected during compilation.
Exception: No rel file is produced when compiling the procedure heading for
a procedure with OPTIONS /E:CODE, QUICK, FORTRAN or F40.
See chapter 7 and app_. E.
Default filename is the name of the first source.
Default extension (ext) is REL.
.s;3.	lstfil receives the program listing generated by the compiler
and is produced if one of the switches L or C is set (see below).
.index ^^filename, listfile
.index ^^lstfile, default filename
.index ^^listfile, default extension
Default filename is the name of the last source file.
.index ^^listfile extension
.index ^^lstfile extension
.index ^^extension, listfile
Default extension (ext) is LST.
.s;4.	source1, source2, ... are the source files which, combined,
make up one SIMULA source 
program. Default extension is SIM.
If no extension is given with the source file specification, .SIM is tried
first, then the null extension. (x.SIM, then x.). Device
must be disk or a logical name assigned to a disk device
with the monitor command ASSIGN.
.s;.index ^^equal sign
.index ^^left arrow
.index ^^Underline
5.	Underline (left arrow) (__) may be used instead of equal sign (=).
.s;6.	If only one source file is used as input and default names of
rel and lst files are desired the equal sign or underline (left arrow)
may be omitted.
.br;Example:
.br;##.R SIMULA
.br;##*DSKD:X.SIM[123,456]
.br;is equivalent to
.br;##.R SIMULA
.br;##*DSK:X.REL,DSK:X.LST=DSKD:X.SIM[123,456]
.s;.IN COMHLP
.index ^^compiler switches
.index ^^switches, compiler
.index ^^LIST switch
7. A number of switches may follow any of the file descriptors.
A switch applies from the beginning of the preceding
source file until the switch is changed. Note however that
certain switches must appear before the start of the program,
i.e. must follow the first source specification. Switches following relfil
or lstfil apply to the first source.
The switches are described in section 3.5.
.s;.index ^^leading tabs in commands
.index ^^spaces in commands
.index ^^leading spaces in command
.index ^^tabs in commands
8. Leading and trailing spaces or tabs are ignored in a file descriptor.
.index ^^delimiters in file descriptor
.index ^^file descriptor delimiters
The following characters delimit a file descriptor:
.index ^^carriage return
.index ^^<CR>
.br;carriage return (<CR>)
.index ^^comma
.br;comma (,)
.index ^^equal sign
.br;equal sign (=)
.br;.index ^^left arrow
left arrow (__)
.br;All other delimiting characters will be treated as illegal and cause an
error message to appear on the terminal.
.s;.index ^^legal characters in command
9. Legal characters in a device name, file name or extension are
letters (lower case are converted to upper case), digits (0-9), dollar ($)
and percent (%).
.s;10. A project or programmer number must not exceed 6 digits
.index ^^square brackets
and must contain only octal digits (i e not 8 or 9).
Alternatively, the project or programmer number, or both, may be empty,
normally implying that the missing number(s)
should be taken from the UFD (logged-in ppn).
Specifically, [,] means your own ppn.
If the device has an implied ppn (SYS, HLP, NEW, LIB etc), that ppn
is used as default instead of the UFD, however.
The default path, which is assumed when no path is given, can also be
designated by [-].
The path definition must be surrounded by square brackets.
Sub-file directories are allowed.
.test page 6
.s;When the program is compiled without errors the following text is printed on the terminal:
.s;NO ERRORS DETECTED
.s;.test page 6
If errors were detected during the compilation the typed text consists of the diagnostic
messages together with the relevant source lines and the message:
.s;ERRORS DETECTED:
.s;###ww TYPE W
.br;###ee TYPE E
.s;where ww is number of warnings and ee is number of errors.
.s;Then a new
asterisk is output and a new command may be entered. The compilation is
.index ^^Control-C
terminated with control-C.
.skip
.subtitle Chapter 3.3 OPERATING PROCEDURES, COMPIL-CLASS COMMANDS
.page
.skip 3
.index ^^COMPIL-class commands
.index ^^commands (COMPIL)
.indent -5
3.3##COMPIL-CLASS COMMANDS
.skip 2
.index ^^COMPILE
.index ^^LOAD monitor command
.index ^^EXECUTE
.index ^^DEBUG monitor command
Any of the commands COMPILE, LOAD, EXECUTE and DEBUG
.index ^^COMPIL CUSP
may be used with all the standard features of the COMPIL CUSP
.index ^^concatenation of source files
such as concatenation with +, processor switches in parentheses etc.
.index ^^CREF (in COMPIL)
The switch SIMULA and the extension SIM are recognized by the
COMPIL class commands. The file will be compiled with the SIMULA
.index ^^/SIMULA
.index ^^.SIM extension
compiler if the source file extension is SIM or if the SIMULA
switch is used in the command and the source file extension
is not found or not recognized as belonging to another language processor.
The COMPIL switch CREF will give a listfile with extension
.index ^^LIST (in COMPIL)
LST and the LIST switch will give a spooled LPT file.
.br;If an external class or procedure is missing in a LOAD command
the LINK-10 program will give the message:
.index ^^LOAD commands, errors caused by
.index ^^LINK-10 error messages, explanation
.index ^^LNKUGS error message, explanation of
.br;_?LNKUGS undefined global symbols
.br;###name###location
.br;where the second character in the name is _%.
.br;This name is unique and created by the SIMULA compiler
to force an automatic check at load time
that the external module has not been changed since
the main program was compiled. You can use the SIMDIR program
to find out the names of all the external classes and procedures that are required by the main  program.
.test page 5
.s;.index ^^command examples
Examples:
.s;#.COMPILE SIMPRO(-WR),SIMPR5/LIST
.br;#SIMULA:##SIMPRO
.br;#SIMULA:##SIMPR5
.s;#EXIT
.skip  1
The line NO ERRORS DETECTED is suppressed.
.test page 5
.s;#.LOAD SIMPR1+SIMPR2
.br;#SIMULA:##SIMPR1
.br;#LINK:##Loading
.s;#EXIT
.test page 5
.s;#.EXECUTE SIMPRO
.br;#SIMULA:##SIMPRO
.br;#LINK:##Loading
.br;#[LNKXCT#SIMPRO Execution]
.test page 5
.s;#.DEBUG SIMPRO
.br;#SIMULA:##SIMPRO
.br;#Link:##Loading
.br;#[LNKXCT#SIMPRO Execution]
.br;#SIMDDT STARTED
.br;#*
.s;Chapter 9 describes how to use SIMDDT. More elaborate examples are found
in Appendix H.
.skip
INSTALLATIONS WITHOUT SIMULA MODIFICATIONS TO COMPIL AND LINK
.s;If your installation has not implemented the special
SIMULA modifications to the COMPIL and LINK cusps, then SIMULA source
programs must be compiled using the "R SIMULA" command (chapter 3.2).
They may then be loaded by the following command:
.s;_.LOAD/REL xxxx,SYS:SIMLIB/SEARCH
.index ^^LOAD monitor command without SIMULA-modified COMPIL
.skip
where "xxxx" is the name of the SIMULA program to
be loaded. (To execute write "EXECUTE" instead of "LOAD" in the
above command string.)
.skip
AVOIDING LINK-10 ERROR MESSAGES
.skip
.index ^^LINK-10 error messages
.index ^^error messages from LINK-10
When a SIMULA program is loaded, you will sometimes get
error messages from LINK-10. The following description may help you to
interpret those messages.
.skip
The most common error message is
.break
.index ^^?LNKUGS undefined global symbols
.index ^^LNKUGS undefined global symbols
.index ^^Undefined global symbols, LINK-10 error message
?LNKUGS undefined global symbols
.skip
Here are some possible causes of this error message:
.skip
.indent -2
> You have changed the attributes of a separately compiled
SIMULA class, but not recompiled dependent modules. Recompile
them with the ".COMP/COMP" command.
.skip
.indent -2
> If the undefined global symbols are ".SIMVL" and ".SIMLV" then
you have probably forgotten the switch /SEARCH on SIMLIB in
your LOAD command.
These symbols are defined by programs using SIMSET and/or SIMULATION.
.left margin 10
.p -7,1,6
> [For release 1B or 1C of DECsystem-10 SIMULA]:
.break
You have actually forgotten to list some separately compiled modules
which your program needs.
.indent -5
[From release 2 of DECsystem-10 SIMULA]:
.break
Separately compiled module names need no longer be listed in the LOAD
command from release 2. Instead, there must be .REL files corresponding
to each .ATR file for separately compiled modules. If the .ATR files
are combined in a library, then the .REL files must be combined in a
corresponding library. Corresponding
_.ATR and .REL files should have the same filename before
the extension and should be stored in the same directory path.
.s;.lm 5
You can find out which separately compiled modules are used by locating
the EXTERNAL declarations in the main program. Alternatively, you can use the
SIMDIR utility program. Write:
.br;#.R SIMDIR
.br;#DIRECTORY [1,4]
.br;#SEARCH mainp USING
.br;where "mainp" should be the name of the main SIMULA program.
.subtitle Chapter 3.4 OPERATING PROCEDURES, BATCH
.page
.skip 3
.index ^^Batch
.indent -5
3.4##BATCH
.breaK
.skip 1
.fill
.left margin 5
.index ^^$SIMULA card
The $SIMULA card is defined as a language card in SPRINT (Spooling
PRocessor for INpuT). The $SIMULA card precedes a SIMULA source
program and causes SPRINT to copy the program onto disk and to
insert a COMPILE monitor command into the control file. The source
program is ended by any SPRINT control card other than $MODE.
.skip 1
When the job is run, the specified program is compiled and
temporary relocatable binary and listing files are created.
The listing file is printed as part of the job's output.
.skip 1
The $SIMULA card does not cause execution of the program.
Execution is initiated by an EXECUTE monitor command
or by a $DATA or a $EXECUTE card.
.skip 1
.index ^^Spooled CDR data file
If execution is initiated by the $DATA card and no file name is 
specified on this card, then a "funny named" spooled card reader file
containing the data following the $DATA card is created.
This file can be read by a SIMULA program if a logical file name
is assigned to CDR. The assignment can be done either with the ASSIGN
monitor command or with a file specification in the SIMULA program.
.break
E.g.   ...NEW infile ("INFILE  CDR:");
.skip 1
Processor switches can be passed to the SIMULA compiler by 
including them in the command string. Refer to Paragraph 3.5
for a description of the SIMULA processor switches.
.skip 1
If the processor switch (C) is given on the $SIMULA card a spooled LPT
file containing program listing and cross reference listing will be
created since the $SIMULA card generates a COMPILE command with
/LIST as default.
.skip 2
Card format:
.skip 1
$SIMULA dev:name.ext [directory] (SS...)/S1/S2.../Sn
.skip 1
.tab stops 19,21
.left margin 21
.indent -16
dev:	=	a file structure name. If omitted, DSK is assumed.
.skip 1
.indent -16
name.ext	=	the name of the file to be created on disk.
If omitted, SPRINT assigns the filename LN???? (where ? represents
a character arbitrarily chosen by SPRINT to produce a unique filename)
with the extension .SIM. However, when the user specifies only a filename
(with no extension), SPRINT will not append any extension.
The source and relocatable binary files will be explicitly deleted at the end
of the job if no filename was specified. However, if an attribute file
was created during the compilation it will not be explicitly deleted.
Where the user has specified a filename, the disposition of the files
depends on the protection the user has given to them.
.skip 1
.indent -16
[directory]	=	a directory path other than that specified on the
$JOB card. If omitted, the project-programmer number on the
$JOB card is used.
.skip 1
.indent -16
(SS...)	=	processor switches to be passed to the SIMULA
compiler. They must be enclosed in parentheses without any commas or slashes.
However, a minus sign may precede any switch.
.skip 1
.indent -16
/S1/S2.../Sn	=	the switches that control the mode of input
interpretation and the listing of the compiled program.
.skip 1
.indent -14
Switch		Meaning
.skip 1
.indent -16
.tab stops 21
.index ^^Switches for the $SIMULA card
/ASCII	The input is read in ASCII mode. If no other card format switch
is specified, then the default is the mode indicated on the /HOLLERITH
switch on the $JOB card.
.skip 1
.indent -16
/NOLIST	No listing file of the program is created. If this switch is not
specified, a listing file will be created.
.skip 1
.indent -16
/NOSUPPRESS	Trailing blanks are not suppressed. The default is no
suppression.
.skip 1
.indent -16
/SUPPRESS	Trailing blanks are suppressed. The default is no suppression.
.skip 1
.indent -16
/WIDTH:nn	Columns 1 through nn (inclusive) are read. Any remaining
columns are treated as if they contained blanks. If this switch is not specified
or if no argument is specified, then SPRINT will assume a value of 80.
.skip 1
.indent -16
/026	The card deck is read in 026 card code. If no other card format switch
is specified, then the default is the mode indicated on the /HOLLERITH
switch on the $JOB card. This switch applies only to card-reader input.
Input from other devices must be read in ASCII code; otherwise, an error
message is written in the log file and the job is terminated.
.skip 2
.left margin 5
.tab stops
.index ^^SPRINT control cards
.index ^^Control cards to SPRINT
For a description of other SPRINT control cards that can be used in 
batch mode refer to DECsystem 10 OPERATING SYSTEM COMMANDS Chapter 3
Batch System Commands.
.skip 1
An example of a SIMULA batch is given in Appendix H.6 CONTROL CARDS IN BATCH.
.subtitle Chapter 3.5 OPERATING PROCEDURES, SWITCHES
.page
.skip 3
.index ^^switches, compiler
.indent -5
3.5##SWITCHES
.breaK
.skip 1
The compiler switches are passed to the compiler in three ways:
.skip 1
i) via a COMPIL-class command or a $SIMULA card in batch.
In this case only the short one letter forms of the switches
are accepted, possibly preceded by a minus sign or an unsigned decimal number e.g. 20P.
The switches must be placed inside parentheses without
slashes. Note that
the switches  LIST,  NOLIST and  CREF exist as switches directly in the command.
If used this way, however, these switches cause an LPT-file to
be produced instead of an LST-file.
.skip 1
ii) via the R SIMULA command. A switch may be placed after any file descriptor.
Each switch begins with a unique letter, which means that the
switch may be denoted with one or more letters. Each switch must be preceded by a slash.
.skip 1
iii) in the OPTIONS statement in the SIMULA source code.
See below for format of the OPTIONS statement.
.skip 1
.EI COMHLP
.IF COMHLP
.skip 3
Switches:
.skip 1
Switches may be placed after any file descriptor. Each switch starts
with a unique letter. Each switch is thus defined by one or more characters
and must be preceded by a slash or enclosed in parentheses ().
.EI COMHLP
The meaning of a switch is reversed if it is preceded by a minus sign.
.IN COMHLP
The lower case letters can always be used instead of the 
corresponding upper case letter.
.subtitle Chapter 3.5.1 SWITCHES IN COMPILER COMMAND STRING
.skip 1
.indent -5
3.5.1 SWITCHES IN COMPILER COMMAND STRING
.EI COMHLP
.skip 1
.tab stops 16,24
.nofill
Name	Format	Default/Meaning
.skip 1
.index ^^ARRAY switch
ARRAY	/A	/A
.left margin 24

.fill
Generate code to check array boundaries.
.left margin 5
.nofill
.skip 1
.index ^^CREF switch
CREF	/C	/-C
.left margin 24

.fill
.index ^^cross reference listing
Generate a cross reference listing on	
the list file. This switch also sets the L-switch.
.left margin 5
.nofill
.skip 1
.index ^^DEBUGS switch
DEBUGS	/D	/D
.left margin 24

.fill
.index ^^SIMDDT
.index ^^symbol table for SIMDDT
Generate a symbol table for SIMDDT.		
.left margin 5
.nofill
.skip 1
.index ^^EXTERNAL switch
EXTERNAL	/nE	/-E
.left margin 24

.fill
.index ^^external class
Treat the source program as an external class	
or procedure. n is a decimal unsigned number
.index ^^block level
specifying the block level at which the
.index ^^external program
external program will be compiled. Default
.index ^^main program
for n is 1. /-E indicates main program.
See below for format in OPTIONS statement.
.left margin 5
.nofill
.skip 1
.index ^^HELP switch
.test page 6
HELP	/H	/-H
.left margin 24
.fill
Type this information at the user terminal.
HELP can be placed anywhere before the second
source file descriptor.
HELP is only valid in connection with the R command.
.left margin 5
.nofill
.skip 1
.index ^^IDENTIFICATION switch
IDENTIFICATION /I	/I
.left margin 24
.fill
.index ^^line number table
Generate a line number table to be used for	
debugging with SIMDDT and for run-time diagnostic messages.
.left margin 5
.nofill
.skip 1
.index ^^LIST switch
LIST	/L	/-L
.left margin 24
.fill
Generate a listing of the source program.	
If this switch is present before the
first source file specification then all
source files are listed. If it is present after
say, the second source specification, then
the first will not be listed.
.lm 5;.nf;.s;.index ^^NOERR switch
NOERR	/N	/-N
.lm 24;.f;.index ^^error messages
Suppress output of error messages on the	
user's terminal.
.lm 5;.nf;.s;.index ^^PAGE switch
PAGE	/nP	/55P
.lm 24;.f;Specify the number (n) of lines per page	
in the source file listing.
If n > 55 then the default vale 55 is used.
See below for extended format.
.lm 5;.nf;.s;.index ^^QUALIFICATION switch
QUALIFICATION /Q	/Q
.lm 24;.f;.index ^^class instance
Generate code to check that a class instance	
has a certain qualification.
.lm 5;.nf;.s;.index ^^RUNSWITCHES switch
RUNSWITCHES /R	/-R
.lm 24;.f;.index ^^file specification in /RUNSWITCHES
File specifications will be read from TTY at	
.index ^^object program execution
the start of the object program execution.
See below for extended format.
.lm 5;.nf;.s;.index ^^SEARCH switch
SEARCH	/S	/S
.lm 24;.f;.index ^^external library specification
.index ^^automatic library search
.index ^^library search at compile-time
Enables automatic search of ATR libraries. Libraries on the default search list
(see below) are searched if an ATR file corresponding to an external
procedure or class cannot be found.
See below for extended format.
.lm 5;.nf;.s;.index ^^WARNING switch
WARNING	/W	/W
.lm 24;.f;.index ^^warning message
Warning messages are listed on the source	
listing (if any) and on the user's TTY.
.lm 5;.nf;.s;.index ^^Y switch
Y	/Y	/-Y
.test page 4
.lm 24;.f;.index ^^line number table
Write the line number table after the source listing. The IDENTIFICATION
and the LIST switches must be set.
.s;.lm 5;.IN COMHLP
.f;If the default setting (except for the LIST switch) is used
throughout the compilation the message DEFAULT SWITCHES USED
is printed after the source code on the listfile. If any of the
switches A, D, E, I, Q, R, S or W has been changed the message
SWITCHES CHANGED FROM DEFAULT: followed by a list of
changed switches is printed.
.subtitle Chapter 3.5.2 SWITCHES IN THE OPTIONS STATEMENT
.s;.i -5;3.5.2 SWITCHES IN THE OPTIONS STATEMENT
.s;All switches except HELP may occur in an OPTIONS statement.

.br;The OPTIONS statement is part of the source program
and may be placed everywhere a comment is allowed.
The format of the switch is the same as for case ii) above.
.s;Format:
.s;OPTIONS(/switch/switch...);
.index ^^OPTIONS statement
.index ^^Source program listing
.index ^^Program listing
.s;If the LIST switch is used in the OPTIONS statement then all
lines including the OPTIONS statement itself are listed on the list file.
If -LIST is used then all following lines starting with the
first line after the OPTIONS statement are suppressed up to the next LIST
switch (if any).
.subtitle Chapter 3.5.2.1 Extended formats for switches E, P, R and S
.s;.i -5;3.5.2.1 Extended formats for switches E, P, R and S
.EI COMHLP
.s;Note that extended formats for switches E, P, R and S are available.
The extended format for the E switch can only be used in the OPTIONS
statement, whereas the longer forms of the P, R and S switches can also
be used with the R SIMULA command (explicit execution of the compiler).
.s;.IN COMHLP
.subtitle Chapter 3.5.2.1.1 E switch
.index ^^EXTERNAL switch
.i -5;3.5.2.1.1 E switch
.s;.index ^^CODE 
.index ^^QUICK
.index ^^CHECK
.EI COMHLP
.IF COMHLP
.i -5;E switch
.s;.EI COMHLP
/nE:<codeword>,[<checkoption>,]entryname

.br;.index ^^FORTRAN
/nE:FORTRAN,entryname

.br;.index ^^F40
/nE:F40,entryname
.s;.index ^^assembly procedure
.index ^^CODE
.index ^^QUICK
<codeword> is CODE or QUICK and specifies an external assembly procedure.
FORTRAN specifies an external FORTRAN-10 (new FORTRAN) procedure
and F40 an external FORTRAN-IV (old FORTRAN) procedure.
.index ^^parameter checking
.skip 1
<checkoption> is CHECK or NOCHECK (-CHECK).
.index ^^CHECK
.index ^^NOCHECK
CHECK implies parameter checking and NOCHECK suppression of
parameter checking. If <checkoption> is omitted parameter checking is assumed.
.index ^^entry name in external procedure
NOCHECK and -CHECK are equivalent.
.skip 1
Entryname is the entry name of the
external procedure.
.skip 1
.IF COMHLP
See SIMULA Language Handbook Appendix E for further details.
.ELSE COMHLP
See Appendix E for further details.
.EI COMHLP
.skip 1
.IN COMHLP
.subtitle Chapter 3.5.2.1.2 P SWITCH
.index ^^PAGE switch
.indent -5
3.5.2.1.2 P SWITCH
.skip 1
.EI COMHLP
.IF COMHLP
.indent -5
P switch
.skip 1
.EI COMHLP
/P:"text"
.break
The text enclosed in quotes will be placed in the list file
.index ^^page heading, list file
.index ^^lstfile, page heading
.index ^^listfile, page heading
page heading.
The first line after the OPTIONS statement is printed on
a new page.
This is also done for /P without argument.
.skip 1
.IN COMHLP
.subtitle Chapter 3.5.2.1.3 R SWITCH
.index ^^RUNSWITCHES switch
.indent -5
3.5.2.1.3 R SWITCH
.EI COMHLP
.IF COMHLP
.indent -5
R switch
.EI COMHLP
.skip 1
/R:"file spec"
.break
The file specification
has the same syntax as file specifications in a command.
.index ^^File specifications in /RUNSWITCHES
File specifications will be
read from that file at run time.
.IF COMHLP
(See Chapter 8 in the handbook).
.ELSE COMHLP
(See Chapter 8).
.EI COMHLP
.test page 5
.skip 1
.index ^^File specifications in /RUNSWITCHES
Examples:
.skip 1
/R:"SYSIN"
.break
/R:"TTY:"########(equivalent to /R)
.break
/R:"DSKC:FILES.SPC[130,131]"
.fill
.skip 1
.index ^^SEARCH switch
.subtitle Chapter 3.5.2.1.4 S SWITCH
.nofill
.indent -5
.IN COMHLP
3.5.2.1.4 S SWITCH
.EI COMHLP
.IF COMHLP
.skip
S switch
.skip 1
/S:"file spec"	!add to search list;
/S		!enable standard search list;
/-S:"file spec"	!disable search for this file;
/-S		!disable library search for all files;
.skip 1
.fill
.index ^^search list for ATR files
The file specification is of the same form as file specifications in a command.
The file extension should be ATR if given, otherwise ATR is assumed.
The file specification will be placed on a search list to be used when
an ATR file is not found corresponding to an external declaration.
If S is preceded by a minus sign, the file will #n#o#t# be part of the search
list. An S switch without a file name enables search of the default libraries.
-S without a file name
turns off library search for all files. Selected files can then be put on the
search list by further SEARCH switches.
.IF COMHLP
For a declaration EXTERNAL CLASS A the standard search list is
DSK:A.ATR, DSK:LIBSIM.ATR, SYS:LIBSIM.ATR.
This means that LIBSIM.ATR will be searched if A.ATR is not found in your
default path, and SYS:LIBSIM.ATR will be used if DSK:LIBSIM.ATR does not exist
or does not contain the ATR module wanted.
.break
Important! Always make sure that each ATR file has a corresponding REL file,
where ATR has been replaced by REL, while the rest of the file specification
is identical. The compiler tells LINK-10 to expect this. A library such as
LIBSIM.ATR #m#u#s#t# have an index (X switch to FUDGE2).
.EI COMHLP
.IN COMHLP
.fill
See 7.1.1.
.subtitle Chapter 3.5.3 CHANGING SWITCHES DURING COMPILATION
.skip 2
.indent -5
3.5.3 CHANGING SWITCHES DURING COMPILATION
.skip 1
At start of compilation the switches are set to their default
values which may be changed via switches passed in the invoking
commands. The switches retain their values until
they are changed in an OPTIONS statement. All switches
can be set (change value) or reset by the OPTIONS statement
(except HELP). This can for example be used to list only parts
of the source program:
.break
 OPTIONS (/LIST);.... OPTIONS(/-LIST);
.subtitle Chapter 3.5.3.1 SWITCHES THAT MAY BE CHANGED ANYWHERE
.skip 1
.indent -5
3.5.3.1 SWITCHES THAT MAY BE CHANGED ANYWHERE IN THE SOURCE FILE
.skip 1
The switches A, L, N, P, Q, S and W can be set and reset in OPTIONS statements
placed troughout the SIMULA program.
The effect of several S switches, however, is dependent only on the order
in which they are listed, not on the location in the program.
Thus all S switches may be gathered together at the start of the program with
the same effect, as long as the order is the same.
Note that the libraries mentioned last will be searched first!
.subtitle Chapter 3.5.3.2 SWITCHES THAT MUST BE DEFINED AT THE START
.skip 1
.indent -5
3.5.3.2 SWITCHES THAT MUST BE DEFINED AT THE START OF THE SOURCE FILE
.skip 1
The switches C, D, E, I, R and Y must either be passed to the compiler
in the invoking command and/or they must appear in OPTIONS statements
which are placed before the proper start of the SIMULA program
(main program, class or procedure).
.EI COMHLP
.IF COMHLP
.skip 2
.center
[END OF SIMCOM.HLP]
.EI COMHLP
.LEFT MARGIN 5
^^
.NOJUSTIFY
.SPACING 1
.SUBTITLE Chapter 4 IMPLEMENTATION DEFINED PARTS OF THE SIMULA LANGUAGE
.page
.INDENT -5
4.###IMPLEMENTATION DEFINED PARTS OF THE SIMULA LANGUAGE.
.BREAK
===================================================
.SKIP 1
This chapter covers those parts of the language which are implementation
defined, which means that a program using them may execute differently
on different systems. A programmer should normally avoid using implementation
defined parts of SIMULA, but the information in this chapter should be
helpful when programs are moved between different SIMULA systems and
when unexpected diagnostics or results have been obtained. This
chapter does not cover input/output (chapter 8), language extensions
(chapter 5), capacity restrictions (chapter 6) or separate compilation
(chapter 7).
.SUBTITLE Chapter 4.1 IMPLEMENTATION DEFINED PARTS OF THE SIMULA LANGUAGE
.test page 10
.skip 2
.INDENT -5
4.1##SYSTEM PREFIXES.
.SKIP 1
The use of system classes as prefixes is restricted. For efficiency reasons
no subclass of FILE may be used as block or class prefix.
.SKIP 1
Since the body of LINKAGE contains a local object, the prefix chain of
a prefixed block may not contain this class or its subclasses LINK,
HEAD and PROCESS.
The definition of MAIN PROGRAM in SIMULATION implies that SIMULATION must
not occur as a prefix in a class instance, and the same restriction has
been enforced for SIMSET. It is however permitted to define subclasses of
SIMSET and SIMULATION as long as these subclasses do not occur in
object generators (i.e. after NEW).
.SKIP 1
According to the SIMULA definition, a class can be used as a prefix only at
the block level at which it is declared. The system classes SIMSET and SIMULATION
should be considered to be declared at the level where one of them first
occurs, and their attribute classes at a level one greater. There may be several
occurrences of the prefixes SIMULATION and/or SIMSET at this level (even
concurrently active) although
this would normally not be considered good programming practice.
.INDEX ^^System prefixes, restrictions
.INDEX ^^System prefixes, level of declaration
.INDEX ^^SIMULATION, concurrent instances of
.SUBTITLE Chapter 4.2 IMPLEMENTATION DEFINED PARTS OF THE SIMULA LANGUAGE
.test page 10
.skip 2
.INDENT -5
4.2##VIRTUAL MATCHES.
.SKIP 1
DEC-10 SIMULA only accepts the virtual matches listed in the Common Base [1]
(LABEL, SWITCH, PROCEDURE and <type> PROCEDURE),
which is a restriction compared to IBM 360/370 SIMULA. When a match is
detected, it is compared with the previous match or, if it is the first
match, with the virtual specification. The kinds (LABEL, SWITCH or PROCEDURE)
must be equal. If the types are not equal, it must either be a function
procedure matched to a pure (no type) procedure, or it must be two REF
type function procedures where the new match is qualified by a subclass of
the qualification of the old match.
If a no type specification has been matched by a function procedure
the result of the function is accessible only where the match can be
seen at compile time.
.INDEX ^^Virtual matches, restrictions and rules
.SUBTITLE Chapter 4.3 IMPLEMENTATION DEFINED PARTS OF THE SIMULA LANGUAGE
.test page 10
.skip 2
.INDENT -5
4.3##EDITING AND DE-EDITING PROCEDURES.
.SKIP 1
The character used to represent the power-of-ten symbol
in input data is initially E, as in FORTRAN. It may be changed to any other printable character except
a digit, ., +, -, TAB or blank by a call to the procedure LOWTEN.
.SKIP 1
The exponent created by PUTREAL and OUTREAL has two digits (possibly
both 0) and is preceded by + or -.
.skip 1
INFRAC and GETFRAC read a sequence of digits where two consecutive digits
may be separated by a blank or a decimal point. There can only be one decimal
point in one number.
.SKIP 1
An edit overflow causes the text field to be filled with asterisks
and a message to be typed after program completion.
.INDEX ^^power of ten symbol
.INDEX ^^exponent part of PUTREAL and OUTREAL
.INDEX ^^Fraction format, input
.INDEX ^^Edit overflow
.SUBTITLE Chapter 4.4 IMPLEMENTATION DEFINED PARTS OF THE SIMULA LANGUAGE
.test page 10
.skip 2
.INDENT -5
4.4##MATHEMATICAL SYSTEM FUNCTIONS.
.SKIP 1
If a mathematical function exists in both single and double
precision, the double precision routine is chosen if the argument
type is LONG REAL, otherwise both argument and function value
are considered to be REAL. Since the Algol Report [2] does not require
a particular set of mathematical functions, the functions available
in DEC-10 SIMULA are listed in table 4.1. An asterisk (*) marks
functions recommended in [2]. Argument types are:
I-INTEGER, R-REAL, L-LONG REAL.
.skip
In addition to the functions listed below, further functions
are available in the DECsystem-10 SIMULA Program Library.
See LIBSIM.HLP for a listing of these, and the DECsystem-10
SIMULA Language Handbook part III for a full description.
.test page 25
.SKIP 2
.NOFILL
RECOMM. NAME    ARG     2ND ARG EXPLANATION
.skip 1
*       ABS     R/L             modulus
        ARCCOS  R               inverse cosine
        ARCSIN  R               inverse sine
*       ARCTAN  R/L             inverse tangent
*       COS     R/L             cosine
        COSH    R               hyperbolic cosine
*       EXP     R/L             exponential
*       LN      R/L             natural logarithm
*       SIN     R/L             sine
        SINH    R               hyperbolic sine
*       SQRT    R/L             square root
        TAN     R               tangent
        TANH    R               hyperbolic tangent
*       ENTIER  R/L             integer part
        MOD     I       I       remainder of first arg
                                divided by second
*       SIGN    I/R/L           Euler sign function

.SKIP 2
Table 4.1: Mathematical functions.

.FILL
.INDEX ^^Mathematical functions, argument and result type
.INDEX ^^Mathematical functions available
.INDEX ^^ABS, system function
.INDEX ^^ARCCOS, system function
.INDEX ^^ARCSIN, system function
.INDEX ^^ARCTAN, system function
.INDEX ^^COS, system function
.INDEX ^^COSH, system function
.INDEX ^^EXP, system function
.INDEX ^^LN, system function
.INDEX ^^SIN, system function
.INDEX ^^SINH, system function
.INDEX ^^SQRT, system function
.INDEX ^^TAN, system function
.INDEX ^^TANH, system function
.INDEX ^^ENTIER, system function
.INDEX ^^MOD, system function
.INDEX ^^SIGN, system function
.SUBTITLE Chapter 4.5 IMPLEMENTATION DEFINED PARTS OF THE SIMULA LANGUAGE
.test page 10
.skip 2
.INDENT -5
4.5##COLLATING SEQUENCE, LETTER.
.SKIP 1
The internal representation of CHARACTER variables is the 7 bit
ASCII representation which defines the collating sequence and
the type conversion functions RANK and CHAR. The range of the former
and the domain of the latter is thus the integers from 0 to 127,
inclusive. In the collating sequence, digits 0-9 are first, then upper case
letters (A-Z) and lower case letters (a-z) (for details concerning
special and national characters see appendix A).
A portable program should not use lower case letters or assume
that digits precede letters, nor that letters are consecutive (letters
A-Z can however safely be assumed to rank in alphabetic sequence).
.SKIP 1
The Boolean function LETTER is TRUE for upper and lower case
letters A-Z, but is FALSE for national letters _$, _# and _@.
.INDEX ^^Collating sequence
.INDEX ^^Character representation
.INDEX ^^RANK, system function
.INDEX ^^CHAR, system function
.INDEX ^^Lower case letters, use in portable program
.SUBTITLE Chapter 4.6 IMPLEMENTATION DEFINED PARTS OF THE SIMULA LANGUAGE
.test page 10
.skip 2
.INDENT -5
4.6##INITIALIZATION OF CHARACTER VARIABLES.
.SKIP 1
A character variable in DEC-10 SIMULA is initialized to the
null character with rank zero. It will usually not be visible
on the output medium when output. In other SIMULA systems the initial
value may often be output as a space (blank).
.INDEX ^^Character representation, initialization
.INDEX ^^Null character
.SUBTITLE Chapter 4.7 IMPLEMENTATION DEFINED PARTS OF THE SIMULA LANGUAGE
.test page 10
.skip 2
.INDENT -5
4.7##SUBSCRIPT CHECKING.
.SKIP 1
If subscript checking is enabled (switch /A is set),
each subscript of a subscripted variable is checked individually. This is not
done on all other systems.
.SUBTITLE Chapter 4.8 IMPLEMENTATION DEFINED PARTS OF THE SIMULA LANGUAGE
.test page 10
.skip 2
.INDENT -5
4.8##RANDOM DRAWING.
.SKIP 1
The random drawing procedures in DEC-10 SIMULA are based on Lehmers
congruence method for pseudo random number generation.
The generator G is 5**15 and the modulus P is 2**35:
.NOFILL
.SKIP 2
                U  = G U    (mod P)
                 i      i-1
.SKIP 2
                X  = U /P
                 i    i
.SKIP 2
.FILL
If the initial value of a
sequence of pseudo random numbers is negated, the antithetic variables are
obtained. The procedures always make the variables odd, so no
initialization is necessary. However, if initialization is omitted
in a program it may loop indefinitely on other systems.
.SKIP 1
Where the definition of a random drawing procedure assumes a parameter
array to be monotonic, this is not checked for efficiency reasons.
However, no matter what the array contains, a reference outside the
array will never occur.
.INDEX ^^Random drawing, generator
.INDEX ^^Pseudo random number generator
.INDEX ^^Random number generator
.INDEX ^^Antithetic variables
.INDEX ^^Initialization of random number streams
.SUBTITLE Chapter 4.9 IMPLEMENTATION DEFINED PARTS OF THE SIMULA LANGUAGE
.test page 10
.skip 2
.INDENT -5
4.9##QUALIFICATION CHECKING.
.SKIP 1
If a class has become accessible by means of an INSPECT statement the
qualification of the connected class is considered identical to that of
the original class. However, a connected class can not be used as
block or class prefix.
.subtitle Chapter 4.10 IMPLEMENTATION DEFINED PARTS OF THE SIMULA LANGUAGE
.test page 10
.skip 2
.indent -5
4.10#SIMULATION PROCEDURE TIME
.skip 2
.index ^^TIME procedure
Unlike some other systems the SIMULATION real procedure TIME
returns the current simulation time in single precision.
This may possibly imply that a simulation program
will behave differently on DECsystem-10 SIMULA than on other systems.
^^
.NOJUSTIFY
.SPACING 1
.SUBTITLE Chapter 5 LANGUAGE EXTENSIONS
.PAGE
.INDENT -5
5.###LANGUAGE EXTENSIONS.
.BREAK
===================
.SKIP 1
.index ^^Comment conventions
.indent -5
Comments
.skip 1
Extensions in the source language representation are that ! (exclamation
mark) is equivalent to the keyword COMMENT, and that comments may occur anywhere between two basic symbols.
.skip 1
.index ^^Octal constants
.index ^^Binary constants
.index ^^Hexadecimal constants
.index ^^National characters
.indent -5
Constants in other radices than 10
.skip 1
Integer constants can
be given in the radix representation bRa where b is the radix (in decimal)
and a is the radix b representation of the number. This is allowed for
radices 2, 4, 8 and 16.
As an example, 31 can be written 16R1F.
.SKIP 1
.indent -5
National characters
.skip 1
National characters _$, _# and _@ can be used as letters in identifiers.
.skip 1

.indent -5
WHILE statement
.skip 1
The WHILE statement permits a programmer to write
.SKIP 1
        WHILE b DO s1
.SKIP 1
which is equivalent to
.SKIP 1
L:IF b THEN BEGIN s1; GOTO L END
.SKIP 1
Here b is a Boolean
expression and s1 is a statement (even a compound statement, a block or
a prefixed block). L is a label not occurring elsewhere in the program.
It is allowed to jump into s1 if it is a compound statement.
.p -5,1,5
TEXT value constants in conditional expressions
.skip 1
.index ^^TEXT value constant
.index ^^TEXT constant
Text value constants may occure in conditional text expressions.
However, such expressions must not be used as actual parameter when
the corresponding formal parameter is called by NAME.
TEXT constants are allowed in conditional expressions in the following
four cases:
.skip
a) As right-hand-side in a TEXT-VALUE-RELATION:
.break
###Example:#t:= IF bool THEN "yes" ELSE "no";
.skip
b) As actual parameter in a procedure called by VALUE:
.break
###Example:#PROCEDURE p(t); TEXT t; VALUE t; ...
.break
############p(IF bool THEN "yes" ELSE "no");
.skip
c) As actual parameter to certain system procedures,
.break
###OUTTEXT, COPY and NEW ... FILE.
.break
###Example: t:= COPY(IF bool THEN "yes" ELSE "no");
.skip
d) In a TEXT-value-relation:
.break
###Example: IF x = (IF uc THEN "C" else "c") THEN
.p -5,1,5
Precision
.skip 1
The additional types LONG REAL and SHORT INTEGER are allowed in DEC 10
SIMULA. LONG REAL is used for double precision floating point numbers,
but SHORT INTEGER is equivalent to INTEGER and has been introduced
only to get better compatibility with IBM 360/370 SIMULA.
All arithmetic types can be mixed in any way in expressions
except as stated in chapter 6.2.
.skip 1
.indent -5
CALL system procedure
.skip 1
The system procedure CALL has the following effect:
.index ^^CALL system procedure
.break
The execution of CALL(Y) resumes execution of the detached
instance Y at its reactivation point. Further operations are as
if an object generator (NEW) had been used, i.e. if Y detaches
or terminates control returns to after the CALL statement. Y
must be detached and not operating when CALL(Y) is executed.
.SKIP 1
.indent -5
PREV system function
.skip 1
The new system function PREV which is an attribute of LINKAGE gives as result
the same value as LAST for a HEAD of a non-empty list, the same as PRED for a LINK which is not first in a list and
the HEAD for the first LINK in a list (Common Base 17.2).
.SKIP 1
.index ^^BREAKOUTIMAGE
.indent -5
BREAKOUTIMAGE system procedure
.skip 1
The new system procedure BREAKOUTIMAGE is an attribute of OUTFILE.
It is identical in effect to OUTIMAGE except that the trailing <CR><LF>
of the image is not output (used mainly when writing to a terminal).
.skip 1
.indent -5
OPTIONS statement
.skip 1
The OPTIONS statement is not a language extension but a communication
channel to the programming system, see Chapter 3.
OPTIONS is however made a reserved word in DEC-10 SIMULA.
.skip 1
.indent -5
EXTERNAL procedures and classes
.skip 1
Language extensions related to separate module compilation
are described in Chapter 7 of this handbook and in chapter
4 of part I of the DECsystem-10 SIMULA Language Handbook.
.INDEX ^^PREV, system function
.INDEX ^^comment
.INDEX ^^radix representation
.INDEX ^^integer constants
.INDEX ^^WHILE statement
.INDEX ^^LONG REAL
.INDEX ^^SHORT INTEGER
.INDEX ^^extensions
.INDEX ^^language extensions
.INDEX ^^double precision
.p -5,1,5
HIDDEN specification
.skip
The HIDDEN and PROTECTED specifications described in
the DECsystem-10 Simula Language Handbook part I chapter 2.5.7
are accepted by the system.
.index ^^HIDDEN specification
.index ^^PROTECTED specification
.LEFT MARGIN 5
.NOJUSTIFY
.SPACING 1
.SUBTITLE Chapter 6 RESTRICTIONS
.PAGE
.INDENT -5
6.###RESTRICTIONS.
.BREAK
=============
.SKIP 1
.SKIP 1
.INDENT -5
6.1##CAPACITY RESTRICTIONS.
.SKIP 1
.index ^^Restrictions on the compiler
.INDEX ^^Capacity restrictions
Capacity restrictions are a consequence of the internal design of DEC-10 SIMULA,
such as the number of bits used internally to hold a particular quantity. The significance
of such restrictions at source language level is often difficult to explain,
and the normal course of action taken by a programmer should be to rewrite a program
when a violation has been diagnosed. Some of the capacity limits are so
high that a violation is very unlikely to occur whereas others are not.
The limitations are also dependent on the amount of core and disk space
available.
The following limits must not be exceeded:
.SKIP 1
.NOFILL

LIMIT   QUANTITY
.SKIP 1
128K    largest low segment area(object code+data)
10      number of subscripts in array
64      block level
255     formal parameters to procedure or
.BREAK
        (concatenated) class
255     virtual quantities in (concatenated) class
511     BLOCK STATE NUMBER
65535   maximum line number in source module
3072    number of differently spelled identifiers
.BREAK
        in source module
32      DISPLAY LEVEL
20      CONCURRENT single precision intermediate
.BREAK
        quantities
4096    FIXUPS
200     SUBEXPRESSIONS IN A SIMPLE STATEMENT
1023    words in BLOCK INSTANCE RECORD
.SKIP 2
.FILL
The meaning of some of these quantities can only be explained by reference to
the syntax tree for a program as defined in the Algol Report [2] and the
Common Base [1].
.SKIP 1
[The maximum BLOCK STATE NUMBER is the size of the
maximal set of <unlabelled block>:s
 in the syntax tree which is not cut by
an instance of <prefixed block>, <class body>, <procedure body>,
<connection> or <for statement>, except an instance of <prefixed block> or <procedure body> which is the root
of the minimal subtree containing all the subblocks in the set.
In this definition a prefixed block or a procedure or class body should
not be regarded as an unlabelled block.]
.SKIP 1
The maximum DISPLAY LEVEL is computed for a hypothetical program
obtained by replacing all external declarations by their defining
declarations. In this program take the number
of instances of <prefixed block>, <class declaration>, <procedure
declaration>, <for statement>, <connection> and <actual
parameter> corresponding to a formal parameter which is not known
not to be by name in a path of the syntax tree. Also add all occurrences along the path of <unlabelled block> which are
separated from the enclosing scope by an instance of <for statement>, <connection> or
<class body>.
The maximum DISPLAY LEVEL is the maximal such value plus one or, if
the outermost scope is a <prefixed block>, two.
.SKIP 1
The number of FIXUPS is obtained by adding weights of syntax entities in a single
module:
.NOFILL
.SKIP 1
2       <conditional statement>
4       <connection>
1       <label definition>
2       <unlabelled block>
4       <procedure declaration>
6       <class declaration>
5       <prefixed block>
2       <while statement>
.FILL
.SKIP 1
The number of CONCURRENT INTERMEDIATE QUANTITIES is minimized by reordering operands to
commuting operators like +, *, :=, etc.
As an example, the expression 
.SKIP 1
        A:=A+(A+(A+(A+A)))
.SKIP 1
has 6 INTERMEDIATE QUANTITIES if A is a formal parameter called by name, but
only one if A is a declared REAL variable.
.SKIP 1
The number of SUBEXPRESSIONS IN A SIMPLE STATEMENT is well approximated by the
number of basic symbols in it, with the following corrections:
.SKIP 1
.nofill
-1      <conditional expression>
-1      parenthesis delimiting subexpression
-1      left parenthesis delimiting parameters, switch
        index or array subscripts
+1      long real constant
+1      implicit arithmetic conversion or qualification
        check
+1      actual parameter to class, prefixed block or
        declared procedure
.SKIP 1
.FILL
The size of a BLOCK INSTANCE RECORD is two plus the size of all its parameters and variables.
All name parameters require two words. Otherwise, an ARRAY requires one word regardless of type.
LABEL and PROCEDURE parameters called by reference require two words, SWITCH by reference one word.
Simple quantities require two words if their type is LONG REAL or TEXT, otherwise one word.
In addition, the value of a function requires one or two words depending on
the type.
.test page 10
.skip 2
.INDENT -5
6.2##PARAMETER CORRESPONDENCE.
.index ^^Procedure parameter transmission
.index ^^Parameter transmission to procedures
.SKIP 1
.INDENT -5
6.2.1 Call by value.
.SKIP 1
.FILL
For an arithmetic array passed by value the actual type must be
identical to the formal type.
.NOFILL
.SKIP 1

.INDENT -5
6.2.2 Call by reference.
.SKIP 1

.FILL
A string is not a legal actual parameter for a text parameter called by reference.
This is a restriction compared to IBM 360/370 SIMULA.
An actual array parameter of type REF must have the same qualification
as the formal array.
.NOFILL

.SKIP 1
.INDENT -5
6.2.3 Parameters to system procedures and functions.
.SKIP 1

.FILL
Where an array is passed to a system procedure or function
(DISCRETE, HISTD, LINEAR, HISTO) the type of the array must be
REAL. The last parameter to random drawing functions must be an
INTEGER (declared, subscripted or remote) variable or an INTEGER
parameter which was passed by value. The first three parameters
to ACCUM must be REAL (declared, subscripted or remote) variables or REAL value parameters.
.index ^^DISCRETE, parameters
.index ^^HISTD, parameters
.index ^^LINEAR, parameters
.index ^^ACCUM, parameters
.index ^^Random drawing procedures, parameters
.test page 10
.skip 2
.INDENT -5
6.3##FOR STATEMENTS.
.SKIP 1
The controlling variable of a for statement must not be of type TEXT.
Neither may it be a subscripted or remote variable, a name parameter or
a function identifier.
.SKIP 1
These restrictions to Algol 60 are recommended in SIMULA, but they have
not been enforced in all implementations.
.INDEX ^^FOR statement, controlled variable, restrictions
.INDEX ^^Controlled variable, restrictions
.test page 10
.skip 2
.INDENT -5
6.4 ##MISCELLANEOUS RESTRICTIONS.
.SKIP 1
A subclass must be declared after its prefix class.
.SKIP 1
A switch which is an attribute of a terminated class instance can not
be accessed.
.INDEX ^^Subclass, order of declarations
.INDEX ^^SWITCH, attribute of terminated class instance
.test page 10
.skip 2
.INDENT -5
6.5##RESTRICTIONS IN SIMULA WITH RESPECT TO ALGOL 60.
.SKIP 1
In this section we list all differences between SIMULA and pure Algol 60
which may cause a pure Algol 60 program to behave differently when
running as a SIMULA program.
All subsections are preceded by the number of a paragraph in the Algol Report
[2] which is not valid for SIMULA.
.SKIP 1
(2.6) The entities <proper string>, <open string> and <string> do not
exist in SIMULA. They are replaced by TEXT variables and constants.
.SKIP 1
(3.2) A <parameter delimiter> in SIMULA is a comma (,). Parameter comments ("fat comma") are not permitted.
Ordinary comments may be used instead.
.SKIP 1
(3.5.1) Integer labels are not permitted.
.SKIP 1
(4.3.5) A transfer to a switch designator whose value is undefined is
equivalent to a dummy statement except that side effects caused during the
evaluation will remain.
.SKIP 1
(4.6.1) FOR statements, see also 6.3.
The increment of a STEP-UNTIL element is evaluated once after the initial
assignment to the control variable, once for every new repetition and once
after the last repetition. This may cause different behaviour if the increment
is an expression which causes side effects or is dependent on the value
of the control variable.
.SKIP 1
(4.7.3.1), (4.7.3.2) The default parameter transmission mode for simple parameters is by value, not by name.
.SKIP 1
(4.7.5.5) All formal parameters must be completely specified with respect to type and kind.
A standard (system) procedure or function can not be passed as an actual parameter
to a formal parameter specified PROCEDURE or <type> PROCEDURE.
For actual to formal parameter correspondence, see also 6.2.1.
.skip 1
(5.1) OWN variables are not permitted in SIMULA.
.index ^^OWN
.INDEX ^^string
.INDEX ^^Labels, unsigned integer
.INDEX ^^unsigned integer labels
.INDEX ^^parameter delimiter
.INDEX ^^switch designator, side effects
.INDEX ^^Transmission mode for parameters, default
.INDEX ^^Formal parameter, specifications
.VR DIRHLP,C,Z
.IF DIRHLP
.npa;.nst;.rm 72
.EI DIRHLP
^^
.nj;.spacing 1
.IN DIRHLP
.lm 5;.rm 65;.ps 55,65
.subtitle CHAPTER 7  SEPARATE COMPILATION
.lm 5;.PG
.figure 3
.i -5;7.###SEPARATE COMPILATION
.index ^^external modules
.index ^^Separate compilation
.index ^^Part-compilation
.index ^^segmentation into separately compiled parts
.br;====================
.s 2;A user-oriented description of separate compilation in SIMULA
is given in chapter 4 of the DECsystem-10 SIMULA Language Handbook Part 1.
If you are not thoroughly familiar with the principles of separate
compilation in SIMULA, you should read that chapter before continuing with this text.
.s 1;To implement the error checking during compile time,
the compiler, when compiling an external module,
generates an attribute file (extension ATR) which
describes all accessible attributes of the object.
.s 1;When compiling a program which uses a previously compiled
external module, the compiler must be told where to find the
ATR-file of the used module. This can be done in the EXTERNAL declaration
or by using the SEARCH switch in the OPTIONS statement.
.subtitle CHAPTER 7.1  SEPARATE COMPILATION. THE EXTERNAL DECLARATION.
.p -5,2,6
7.1##THE EXTERNAL DECLARATION
.index ^^EXTERNAL declaration
.s 2;The syntax of the <external declaration> is (! stands for choice):
.nf
.s;###<octal digit>::=0!1!2!3!4!5!6!7
.s;###<octal number>::=<octal digit>!
####################<octal number><octal digit>
.s;###<ppn>::=!<octal number>,<octal number>!
############<octal number>,!,<octal number>
.s;###<sfd list>::=<identifier>!<sfd list>,<identifier>
.s;###<path>::=![<ppn>]![-]![<ppn>,<sfd list>]
.s;###<device>::=!<identifier>:
.s;###<external identifier>::=<device><identifier><path>
.s;###<external item>::=<external identifier>!
#####################<identifier>=<external identifier>
.s;###<external list>::=<external item>!
#####################<external list>,<external item>
.s;###<external declaration>::=
#############EXTERNAL PROCEDURE <external list>!
#############EXTERNAL <type> PROCEDURE <external list>!
#############EXTERNAL CLASS <external list>
.s;###<separately compiled procedure>::=<procedure declaration>
######!<external declaration><separately compiled procedure>
.s;###<separately compiled class>::=<class declaration>!
#######<external declaration><separately compiled class>
.s;###<separately compiled main program>::=<program>
.s;###<singly compiled main program>::=<program>
.f;.s 2;The difference between <separately compiled main program> and
<singly compiled main program> is that <separately compiled main program>
contains at least one <external declaration> and
<singly compiled main program> contains no <external declaration>.
.s 2;The external identifier is a file specification which may be used to retrieve
the attribute file (after completing the specification by the extension ATR).
DSK: is used for <device> if omitted. The user's default path is used if <path> is omitted.
If project or programmer number is omitted, the user's logged-in ppn (his UFD)
is used to supply the missing information. The specification [-] is an alternative
way of specifying the default path (same as missing <path>).
.s;<device> must be a disk-like device.
.p 0,2,11
A separately compiled class or procedure may only refer to
the following entities in the local environment of
the external statement:
.s;- Formal parameters of the separately compiled
class or procedure.
.s;- Other separately compiled classes with their
externally accessible attributes.
.s;- Other separately compiled procedures.
.s 2;These other separately compiled classes and procedures
are declared by external declarations in the source
program of the separately compiled module.
Their declarations precede the proper start of the source code of the
separately compiled class or procedure.
.p 0,2,10
Example of full source text of a separately compiled
class using these conventions:
.s;.nf
##OPTIONS(/E);
##EXTERNAL PROCEDURE a;
##EXTERNAL CLASS b,c,d;
##b CLASS e(f);REF (c) f;
####BEGIN REF (d) g;
######g :- NEW d;
######a(g);
####END
.f;.s 2;External declarations preceding the beginning of a separately compiled
class or procedure do not cause any copying of the declared
external modules into the combined program.
.br;They simply inform the compiler that these
external declarations will occur in the environment
of an external statement introducing the module into another program,
class or procedure.
.br;Thus, a, b, c and d in the example must be
declared by external declarations in the environment of an external statement
referring to e.
.s;According to SIMULA rules, separately compiled prefix classes must
be copied into a program in the same
block as their subclasses.
.p 0,1,10
Example; "- - - -" indicates separate compilation:
.nf
.s;CLASS a; BEGIN ... END
- - - -
EXTERNAL CLASS a; a CLASS b; BEGIN ... END
- - - -
BEGIN COMMENT main program;
##EXTERNAL CLASS a,b;
##...
END
.f;.p -5,2,15
7.1.1 TELLING THE COMPILER WHERE TO FIND EXTERNAL MODULES
.s;When an external module is compiled, two output
files are usually produced, one with extension ATR and one
with extension REL. (If the actual code is in another language,
another compiler produces the REL file, see appendix E.)
For example, the separately compiled module X.SIM
will yield the two output files X.ATR and X.REL.
.s;The ATR file is read by the compiler each time a module which uses X
is compiled. The REL file is used by the loader (LINK-10) to produce
an executable program from several separately compiled modules.
.p -5,1,10
7.1.1.1 SEARCH LIST
.skip.s;When the compiler has encountered an external declaration, e.g.
.indent 5
EXTERNAL CLASS X;
.br;and does not find the file <external#identifier>.ATR (X.ATR in this case)
in the user DSK area,
it scans an (implied) SEARCH LIST consisting of file
.index ^^search list for ATR files
definitions (device name, file name, path).
The search list is also used when a class or procedure is compiled separately,
to find a possible matching ATR module which is compared to the attribute
information of the module being compiled. If no attributes have changed, no
new information need be created, but if the matching module was found in a
library, a copy of the module is output as a separate ATR file matching the
REL file being produced, if any.
In this way the ATR and REL files will nearly always be found on the same
disk area (possibly in matching libraries).
.p -5,1,10
7.1.1.1.1 DEFAULT SEARCH LIST
.s;If no
SEARCH switch is given in the source file or via the R or COMPILE command,
the default search list contains DSK:LIBSIM[user#default path] and SYS:LIBSIM.
The extension ATR is assumed throughout.
.index ^^libraries of attribute files
.index ^^ATR libraries
.s;LIBSIM and any other file on the search list must be recognized as a library.
In the library, the SIMULA name of the external module is used as a search
key to find the corresponding ATR module.
FUDGE2 or MAKLIB can be used to create an ATR library. See 7.1.1.5.
.s;The SEARCH switch can be used to modify the search list by adding or deleting
files. If an explicit file definition (see 7.1.1.2)
is given in the external declaration,
the search list is not used.
.p -5,2,10
7.1.1.2 EXPLICIT SPECIFICATION OF THE ATR FILE
.s;In the EXTERNAL declaration, you can write e.g.
.i 5;EXTERNAL CLASS x=x1[100,200];
.br;This tells the compiler that the CLASS x is described
in the ATR file x1.ATR on the disk area for ppn [100,200]. The compiler will not
look for other ATR files if you give the file name in this way.
If x1.ATR is not found, an error message will be given.
If x1.ATR is a library (see 7.1.1.5), the name x will be looked up,
otherwise x1.ATR will be used directly.
When compiling a class or procedure separately, the corresponding effect is
achieved by having a name on the REL file which is different from the SIMULA
name of the class or procedure (first 6 letters) and/or by specifying a
path different from the default path for the REL file.
Note that the REL file specification is used also for the ATR file, with the
extension changed to ATR.
.p -5,2,10
7.1.1.3 THE SEARCH SWITCH
.s;The SEARCH switch can be used to modify
the library search which is performed when X.ATR is not found. You
can tell the compiler to search other libraries than LIBSIM and on
directories (paths) other than your own default path or the SYS default path.
The possible variants are:
.s;a) /S with no argument. This means that the default search list (see 7.1.1.1.1) is (re)established.
Any additional libraries are left on the list in their original places.
.s;b) /S:"file spec", puts the library mentioned on the search
list. The same library will only appear once on the search list.
.s;c) /-S with no argument. No libraries will be searched. /S will
reestablish the standard search list, leaving other libraries off
the list.
.s;d) /-S:"file spec" removes the specified library from the search list.
.s;Example: OPTIONS(/-S/S:"LIBSIM[101,101]") removes LIBSIM.ATR and
SYS:LIBSIM.ATR from the search list, leaving only LIBSIM.ATR[101,101].
OPTIONS(/S), if given later, reestablishes the standard list, but
LIBSIM.ATR[101,101] will still be searched before LIBSIM.ATR[-].
[-] means the default path for DSK.
Note that the SEARCH switch can also be given via R SIMULA in the command
string!
Note also that ALL search switches apply to ALL external declarations in
the currently compiled module, since action is taken after scanning the
whole module.
.p -5,1,8
7.1.1.4 LOADING AND EXECUTING PROGRAMS WITH EXTERNAL MODULES
.index ^^Loading and executing programs with external modules
.s;Loading and execution commands are greatly simplified if the REL file
corresponding to a given ATR file is found by simply substituting the
extension REL for the extension ATR. If the ATR file is X.ATR, the REL file
should be X.REL, and if the attributes of X are found in the library L.ATR, the
code of X should be found in the library L.REL.
To simplify the load command, the compiler will tell LINK-10 to look for
object code in REL files corresponding to the ATR files used.
.s;A program can thus be (compiled and loaded and) executed simply by the
command
.i 5;EXECUTE mainprogramname
.br;providing the external modules have been compiled in advance.
.s;Note that since the REL files are loaded in library search mode,
explicit inclusion of files in the command string may be used to bypass
the search for certain entry points.
.index ^^external libraries for ATR and REL files
.index ^^FUDGE2 program for handling libraries
.index ^^MAKLIB program for handling libraries
.p -5,2,8
7.1.1.5 Producing ATR and REL file libraries
.s;Libraries of ATR or REL files can be produced by
copying together several ATR or REL files using the FUDGE2 or MAKLIB
program, which are described in the DECsystem-10 monitor commands handbook.
.s;IMPORTANT!!! The /X (/INDEX) switch must be used to produce an index, otherwise
the SIMULA compiler cannot find the ATR modules. Be careful to mention
the extension ATR, since REL is assumed if no extension is given!
.s;Example: Add proc to LIBSIM.ATR and LIBSIM.REL -
.br;.nf
##.R FUDGE2
##*LIBSIM.REL=LIBSIM.REL,proc.REL/A$
##*LIBSIM.ATR=LIBSIM.ATR,proc.ATR/A$
##*LIBSIM.REL=LIBSIM.REL/X$
##*LIBSIM.ATR=LIBSIM.ATR/X$
.s;$ stands for <ALTMODE> (octal 33).
.f
.subtitle CHAPTER 7.2  SEPARATE COMPILATION.  THE EXTERNAL SWITCH.
.p -5,4,6
7.2##THE EXTERNAL SWITCH
.index ^^External switch in options statement
.index ^^Options statement, external switch
.s 2;.nf
Short form: nE:<list>
Long form:##nEXTERNAL:<list>
Default:####-E
.s 2;.f
Treat the source program as an EXTERNAL CLASS or PROCEDURE.
-E indicates main program.
When /E or /-E appears in an OPTIONS statement
it has no effect unless
it appears before the proper start of the SIMULA program.
.s;n is an unsigned decimal number specifying the block level at which the external
.index ^^Block level for external module
.index ^^External module, block level of
.index ^^Separately compiled module, block level of
module is going to be declared in the main program.
n is optional and has the default value 1 (the outermost block).
.s;:<list> can only be used in an OPTIONS statement placed
at the start of the SIMULA specification program
for an external procedure written in MACRO-10 or
FORTRAN (detailed explanation in appendix E).
.subtitle CHAPTER 7.3  SEPARATE COMPILATION.  RESTRICTIONS.
.p -5,4,5
7.3##RESTRICTIONS ON SEPARATE COMPILATION
.s 2;A separately compiled class or procedure must not be declared
as attribute to another class.
.s;A separately compiled class or procedure must not be copied indirectly,
i.e.#in a separately compiled class or procedure 
all external declarations must precede the proper start
of the class or procedure declaration.
.s;In an EXECUTE, LOAD or DEBUG monitor command, source files
should be listed in compilation order, with the main program last. The compilation order must be such
that attribute files are available when referred to.
.index ^^LOAD monitor command
.index ^^EXECUTE monitor command
.index ^^DEBUG monitor command
.s;Error messages from LINK-10 because of missing REL files are
explained at the end of section 3.3 in this handbook.
.s;.subtitle CHAPTER 7.4  SEPARATE COMPILATION.  SIMDIR UTILITY PROGRAM.
7.4##SIMDIR UTILITY PROGRAM
.p -5,4,5
.EI DIRHLP
.tab stops 8,16,24,32,48
With the SIMDIR program you can easily find out:
.br;>#Which separately compiled modules are required by one or several
main programs.
.br;>#Which program modules require a certain separately compiled
procedure or class.
.br;To start
the program type:
.br; .R SIMDIR
.br;SIMDIR responds with a "*" , signalling that it
is ready for a command.
.s;In the simplest case, you can now write:
.s;###SEARCH /ALL REQUIRED BY main
.s;This will list all modules on your PPN which
are used by the module main. main is usually a SIMULA main program, but can be a separately compiled module.
.s;###SEARCH /ALL USING proc
.s;This will list all modules on your PPN which
use the separately compiled module proc.
.s;You can precede the SEARCH command with a DIRECTORY command
to tell the system to include other PPN:s in the search.
For example, you can write:
.s;###DIRECTORY [*,*]
.br;###SEARCH /ALL USING proc
.s;This will give a listing of all SIMULA programs on all PPN:s which require
your separately compiled procedure proc.
.s;As input SIMDIR requires ATR-files from separately compiled
classes and procedures and REL-files from main programs. This means
that SIMDIR only works when such ATR and REL files are present for the programs
to be listed.
.s;The syntax of SIMDIR commands follows:
.left margin 8
.s;.nf
.i -3
<SEARCH-command>::= SEARCH <pattern> [<relation>[<pattern>]]
<relation>::= USING ! REQUIRED BY
<pattern>::= [<device>][<filename>][<ppn>][<switches>]
<ppn>::= <left bracket><ppn1><right bracket>
<ppn1>::= SELF ! OTHERS ! <pnr>,<pnr>
<pnr>::= ! * ! <octal number>
<switches>::= <switch> ! <switches><switch>
<switch>::= /<switchname>
<switchname>::= ALL ! MAIN ! CLASSES ! PROCEDURES !
	FPROCEDURES ! SPROCEDURES ! MPROCEDURES !
	FAST ! TTY
<device>::= <name>:
<filename>::= <name>
.s;.f
SEARCH <pattern> means that all modules matching the
pattern will be searched for and listed.
.s;SEARCH <pattern> <relation> means that all modules matching
the pattern will be searched for and listed together with
the modules which have the given relation to the modules.
.s;SEARCH <pattern> <relation> <pattern> means that all modules
matching the first pattern and having the given relation
to any module matching the second pattern are listed.
.s;A module matches a pattern when it matches all components
of that pattern. If any component is missing in a pattern,
then all modules match that component.
The pattern may not be empty, however.
.s;There are two special PPN:s that you may use in a pattern:
[SELF] is the LOGIN PPN.
[OTHERS] stands for all PPN's except [SELF] which have been given in
DIRECTORY commands.
.s;Explanation of switches:
.nofill
	ALL		All modules match
	MAIN		Main programs match
	CLASSES		Classes match
	PROCEDURES	Procedures match
	FPROCEDURES	FORTRAN procedures match
	MPROCEDURES	MACRO-10 procedures match
	SPROCEDURES	SIMULA procedures match
	FAST		Do not output PPN
	TTY		Change output device
			temporarily to TTY.
.p -3,2,10
<DIRECTORY-command>::= DIRECTORY <directories>
<directories>::= <directory> ! <directory>,<directories>
<directory>::= [<switch>] <ppn> [<switch>]
<switch>   ::= /MAIN ! /-MAIN
.s;.fill
Include the given directories when searching.
.br;/MAIN means that all modules are fetched from this
directory, /-MAIN that only external classes and
procedures are fetched. Default is /-MAIN.
.s 2;.i -3;<LIST-command>::= LIST <file specification>
.s;Program output - as generated by subsequent search commands - is written on the specified file.
Default is DSK:SIMDIR.LST
.p -3,2,5
<CLOSE-command>::= CLOSE
.s;The current list file is closed.
.p -3,2,5
<EXIT-command>::= EXIT
.s;Close current list file (if any) and return to monitor.
.p -3,2,5
<HELP-command>::= HELP [ /TTY ]
.s;Output help-text.
.lm 5
.s 2;All "reserved words" (upper case letters above) can be abbreviated arbitrarily.
Any conflicts are resolved as follows :
.br;	/M means /MAIN
.br;	/F means /FAST
.s 2;When SIMDIR is started a *D[S]/M command is automatically performed.
.s 2;EXAMPLES:
.s;List all SIMULA modules on your own PPN
.nofill
 .R SIMDIR
 *S/ALL
	.
	.
	.
.fill
.s;List those of your own modules which are used by others in
the same project.
.nofill
 .R SIMDIR
 *DIR [,*]/M
 *SEARCH [SELF] REQ BY [OTHERS]
	.
	.
	.
.fill
.tab stops
.IF DIRHLP
.s 2;.c;[END OF SIMDIR.HLP]
.EI DIRHLP
^^
.nojustify
.spacing 1
.VR RTSHLP,h,m
.IF RTSHLP
.npa;.nst;.rm 72
.nofill
Switch summary
.SKIP
ACCESS:APPEND   Create file in append mode
ACCESS:RONLY	Directfile may only be read, not modified
BUFFERS:n       Define no of buffers
FILES:n         Define max no of files
IMAGESIZE:n     Define directfile imagesize
LIMIT:n         Define max no of blocks for an outfile
NUMBERED	Outfile: set linenumber bit in buffer images
SIZE:n          Define total no of blocks for an outfile
WORDALIGNED	Put images on word boundaries in buffer
.SKIP 2
File definitions
.SKIP
File definitions can be given in three different ways:
.fill
.br;1) In the text argument which is a parameter when the SIMULA program generates
a new file object.
.br;2) In a special file of run-time switches.
.br;3) At run-time via a user-RTS dialogue.
.s;File definition formats:
.nofill
.s;1.  logical-filename file-descriptor/switch/switch...
2.  /switch/switch...
3.  /switch/switch... logical-filename file-descriptor/switch/switch...
4.  @file-descriptor
.fill
.S;Run-time switches are passed to the object program in a specification
file. This file is defined at compile-time with the R-option. The
specification file contains one or more file definitions, each having
one of the formats above.
.s;The first empty line or end of file terminates the reading of the
specification file. Format 4 defines an indirect specification file.
It is possible to have more than one indirect specification file but they
must not be nested. A specification file can be read from TTY or disk.
SYSIN can be specified to contain the file definitions, which then must be
the first lines of SYSIN and must be terminated with an empty line.
Specification files cannot be kept in sub-file directories.
.SKIP
The logical name is one to six alphanumeric characters.
If it is omitted the filename is used as logical name, or, if the
filename is omitted, the devicename.
.SKIP
A file descriptor has the following format:
.S;device:filename.extension[prjno,prgno,sfd,...]_<protection code_>
.br;###or
.br;str:_<directory_>filename.type;protection  (TOPS-20)
.s;Default for device (str) is DSK.
Default for 'prjno,prgno' is the logged-in directory (UFD), unless the
device has an implied ppn (SYS, LIB etc), which is then used.
Default for the TOPS-20 directory is the connected directory.
No part of the file descriptor is mandatory. The file definition
is linked to the file object through the logical name when the file
object is created.
.SKIP
The text argument when generating a new file object in a SIMULA program
has one of the following formats:
.SKIP
1.  "logical-filename file-descriptor/switch/switch..."
.break
2.  "/switch/switch... logical-filename file-descriptor/switch/switch..."
.SKIP
Information in the specification file overrides the file object argument.
.SKIP
The file descriptor may contain an asterisk in any of the fields except
protection. The user is then conversationally asked for additional
information when the file object is created and he may enter missing
fields or override already defined fields. This applies both to the
specification file and to the file object argument.
.s 2;Switches
.SKIP
.ELSE RTSHLP
.SUBTITLE CHAPTER 8 OBJECT PROGRAM I/O
.LEFT MARGIN 5
.RIGHT MARGIN 65
.PAGE
.SKIP 3
.INDENT -5
.index ^^I/O in SIMULA programs
.index ^^input/output in SIMULA
.index ^^object program I/O
.index ^^run-time I/O
8####OBJECT PROGRAM INPUT-OUTPUT
.BREAK
.indent -5
#####===========================
.SKIP 2
.indent -5
8.1##INTRODUCTION
.SKIP 2
The SIMULA run-time system (RTS) supports input from and output to files on
auxiliary memory like disk storage, DECtape and magnetic tape and standard
peripherals like line printer, card reader and punch, paper tape
reader and punch. These peripherals will normally be spooled in a time-sharing environment
.index ^^unspooled devices
.index ^^spooled devices
but RTS will not distinguish between spooled and unspooled devices.
.skip 1
.index ^^ASCII mode I/O
.index ^^ISO-7
.index ^^binary mode I/O
Only ASCII (=ISO-7) mode input and output is supported. Binary I/O can be performed only with
external assembly procedures (see chapter 7 and appendix E).
.skip 1
.index ^^random access
Files can be accessed sequentially using class INFILE.
Class DIRECTFILE allows random access in addition to sequential access.
Class DIRECTFILE can only be used with files on disk, however.
.skip 1
.index ^^RTS I/O
The I/O subsystem of RTS works interactively with the user as described
in later sections. When an error condition occurs the user is consulted for corrective
action if recovery is possible, otherwise a run-time error occurs.
.skip 1
To escape from the dialogue the user can use altmode as answer.
SIMDDT is then entered and the user can later resume the dialogue with the PROCEED
command (refer to chapter 9).
.index ^^escape from run-time dialogue
.index ^^run-time dialoque, escape from
Note however, that it is not possible to
use SIMDDT when the escape facility is used in dialogue before start of
the SIMULA program execution, i.e. when the specification file is read.
.skip 1
The various dialogue messages are described in appendix D. The rest of this chapter
is concerned with how to define files, run-time switches and various
aspects of the different input-output classes of SIMULA.
.subtitle Chapter 8.2 OBJECT PROGRAM I/O, HOW TO DEFINE A FILE
.p -5,6,19
.index ^^file specification at run time
.index ^^file definitions
8.2# HOW TO DEFINE A FILE
.skip 2
.index ^^NEW
.index ^^file object
A new file is created with the object generator NEW.
File objects can be of four different classes:
.s;infile
.br;outfile
.br;printfile
.br;directfile
.s;Printfile is a subclass of outfile.
The argument to these file classes should be a text variable or a text
constant containing a file definition.
The file definition binds the file object to a device and a physical file.
.br;File definition format:
.s;logicalname  file-descriptor
.index ^^logical name
.index ^^percent, in logical name
.index ^^dollar in logical name
.s;The logical name must consist of one to six alphanumeric characters. The characters
.index ^^% in logical name
.index  ^^$  in logical name
percent (%) and dollar ($) will also be accepted.
The logical name is used in all run-time error messages concerning I/O.
The following text will precede all such errors:
.break
ERROR FOR FILE: logicalname
.break
.index ^^unique logical name
The logical name need not be unique, but the user is advised to
have unique names for ease of identification.
The logical name is also used to link file
class arguments to file definitions from the specification file as described below.
.s;Examples:
.s;FILE1:-NEW infile ("FILE1 MYFILE.DAT");
.br;x:-NEW outfile("FILE2 RESULT.LST<077>");
.br;INSPECT NEW directfile ("dir random") DO ...
.s;The logical name may be omitted from the file definition. In this case the file name will be used 
as logical name or if the file name is missing, the device name is used.
.s;Examples:
.s;.tab stops 45
Y:-NEW outfile("LPT:");	Logical name is LPT
Z:-NEW infile("TEXT.ASC");	Logical name is TEXT
W:-NEW infile("W");	Logical name is W
.s;The logical name must be delimited by at least one space or tab.
.s;.test page 5
.index ^^file descriptor
The complete format of a file descriptor is:
.s;device:filename.extension[path]<protection>/switch/switch ...
.br;###or
.br;str:<directory>filename.type;protection/switch/switch ... (TOPS-20)
.s;.index ^^device, in run-time file descriptor
Default for device or str is DSK. Device may be any physical device name or logical device
.index ^^ASSIGN command
name (structure name) previously defined (via the ASSIGN command or equivalent).
.index ^^file name, in run-time file descriptor
.index ^^extension, in run-time file descriptor
Default for file name is logical name.
No default for extension (type).
.index ^^percent, in file name at run-time
.index ^^%, in file name at run time
.index ^^$, in file name at run time
may contain letters (lower case are converted to upper case), digits, percent
.index ^^dollar, in file name at run-time
and dollar sign.
.br;Part or all of the filename can also be specified in octal code.
.index ^^Number sign, in file name at run-time
.index ^^Funny file name at run-time
.index ^^Special characters in file name at run-time
.index ^^# in file name at run-time
.index ^^Octal digits in file name at run-time
.index ^^UFD file access at run-time
The character "_#" (number sign) starts a string of octal digits 
(values 0-7). Two octal digits represent one character in sixbit (DEC-10
64 character subset). An odd number of digits is augmented by a final zero.
The string is converted to 6-bit bytes and inserted in the file name
(left justified) at the position of the number sign. The string of digits
is finished when a non-octal character is encountered.
Example: "DSKD:_#000123000456.UFD[1,1]" is the specification of the UFD
(user file directory) of path [123,456] on structure DSKD.
.skip 1
.index ^^ppn, in run-time file descriptor
.index ^^sub-file directories in run-time file descriptor
.index ^^SFD in run-time file descriptor
Default for path is user's default path. The format is:
.skip 1
[projectnumber,programmernumber,sfd1,sfd2,...]
.skip 1
.index ^^protection, in run-time file descriptor
The path must always end with a right square bracket.
Default TOPS-20 directory is the connected directory.
Default for protection is the installation defined standard protection.
Switches are covered in section 8.3. Trailing or leading spaces and tabs are
ignored in the file descriptor.
.skip 1
.index ^^asterisk (*) in run-time file descriptor
.index ^^* (asterisk) in run-time file descriptor
.index ^^star (*) in run-time file descriptor
A file descriptor may contain an asterisk in any of the
fields except protection. This will cause a dialogue at run-time.
The following message is typed on the terminal:
.skip 1
%PLEASE SPECIFY ADDITIONAL INFORMATION FOR FILE: logicalname
.break
*
.skip 1
The user can now enter missing parts of the file descriptor and also
override previously defined parts.
.skip 1
Example:
.skip 1
###... NEW infile ("FILE1 *");
.skip 1
RTS types:
.skip 1
%PLEASE SPECIFY ADDITIONAL INFORMATION FOR FILE: FILE1
.break
*INFIL.DAT
.skip 1
The system will repeat this request until all fields containing asterisks are defined.
.skip 1
The source contains: ... NEW infile("file2 *:*");
.skip 1
.test page 7
The following dialoque might take place:
.skip 1
%PLEASE SPECIFY ADDITIONAL INFORMATION FOR FILE: file2
.break
*INFIL.DAT
.break
%PLEASE SPECIFY ADDITIONAL INFORMATION FOR FILE: file2
.break
*DSK:
.skip 1
This is one way in which the user can defer the binding between file and file object
until run-time.
.skip
A similar dialogue is entered when an error occurs such that
the file specification given by the program cannot be opened.
In such a case, you can transfer to SIMDDT from this dialogue
by pushing the ALTMODE (ESCAPE) button on your terminal.
.skip 1
Another way is to let the SIMULA program use data from the TTY or a file
on any other device to create parameter strings to NEW file creations.
.skip 1
.index ^^specification file
A third way to achieve this is the specification file facility.
This gives the user the ability to specify all his file definitions
in a special file that is read by RTS before start of execution.
.index ^^run-time switches
.index ^^RUNSWITCHES switch
This file may also contain run-time switches. The compile switch RUNSWITCHES must
be used at compilation. This switch defines the specification file which can be TTY or a DSK file. 
/R without argument denotes TTY. In that case the RTS will type
ENTER FILE DEFINITIONS before execution start and the user may supply
file definitions and switches. The  TTY input is terminated with a carriage return.
.skip 1
Example:
.skip 1
#.EXECUTE SIMPRO(R)
.break
#SIMULA:##SIMPRO
.break
#LINK: Loading
.break
#[LNKXCT# SIMPRO Execution]
.break
#ENTER FILE DEFINITIONS:
.break
#*FILE1 INFILE.DAT[130,133]
.break
#*FILE2 OUTFIL.DAT
.break
#*SCRATCH DUMMY
.break
#*
.break
#EXECUTION STARTED
.skip 1
The file definitions have the same format as in the argument to the 
.index ^^unique logical name
file classes. The logical name must be unique, since RTS uses
this name to link the file definitions in the specification file to
the file class arguments. RTS will build a table from the
specification file. When a new file object is created this table
is searched to see if the file was defined prior to execution. Information in the
specification file overrides the information in the file class argument.
.skip 1
.index ^^SYSIN, used as specification file
The file definitions may also be a part of SYSIN. This is accomplished with /R:"SYSIN"
in the OPTIONS statement in the source code. If SYSIN is read from TTY
the dialogue described above will take place. If SYSIN is a disk file, the
file definitions are read from SYSIN. They must then be terminated with an
empty line to separate them from the rest of the SYSIN input to be read by
the program.
.skip 1
.test page 7
.index ^^indirect specification file
.index ^^indirect delimiter
.index ^^@ delimiter
It is also possible to use indirect specification files. 
This is denoted with the normal indirect delimiter:
.skip 1
@file-descriptor
.skip 1
Indirect files can only be read from disk and must not contain any definitions
of indirect files. They must not be stored in
sub-file directories.
.skip 1
.test page 11
Example:
.skip 1
#.EXECUTE SIMPRO(R)
.break
#SIMULA:##SIMPRO
.break
#LINK:##Loading
.break
#[LNKXCT##SIMPRO Execution]
.break
#ENTER FILE DEFINITIONS:
.break
#*@FILES.SPC
.break
#*
.break
#EXECUTION STARTED
.skip 1
Specification files on disk need not be terminated with an empty line. It is possible to have more than one
indirect specification file, but they can not be nested.
SYSIN may also be used as an indirect specification file.
.subtitle Chapter 8.3 OBJECT PROGRAM I/O, RUN-TIME SWITCHES
.p 0,4,19
.skip 3
.indent -5
.index ^^file specification at run time
.index ^^run-time switches
8.3##RUN-TIME SWITCHES
.skip 2
.EI RTSHLP
Switches that appear before the file definition or, in a specification file, alone on a line
.index ^^global run-time switches
are called GLOBAL switches. Other switches
.index ^^local run-time switches
 are termed LOCAL. The same switch may be either local or global as defined
below. All switches can be designated with their first letter or with as
many letters as desired. The full names are given below.
.skip 1
.index ^^ACCESS switch
ACCESS:APPEND
.break
This switch can only be local and is applicable to outfiles and printfiles
.index ^^append mode
only. It means that the file will be written in append mode, i.e. the
output will be appended to the file if it already exists.
.skip 1
.index ^^RONLY
.index ^^read only file
ACCESS:RONLY
.break
This local switch is applicable to directfiles only.
It means that the directfile can only be read, not modified.
.skip 1
.index ^^BUFFER switch
BUFFER:n
.skip 1
.tab stops  14,22
.nofill
type	n	meaning
.skip 1
global	=<32	
.break
.fill
.left margin 22
.index ^^buffer ring
n is the number of buffers in the buffer ring for all
subsequent files, unless they have a local BUFFER switch
or a new global BUFFER switch appears
.break
.nofill
.left margin 5
global	>32	
.break
.fill
.left margin 22
.index ^^buffer area
n defines the area in words to be allocated for buffers
(necessary space for all files defined in the specification
file will however always be allocated regardless of this value)
.break
.nofill
.left margin 5
local	=<32	
.break
.fill
.left margin 22
n is the number of buffers in the buffer ring for this file
.break
.nofill
.left margin 5
local	>32	
.break
.fill
.left margin 22
n defines the size of one buffer in a two-buffer ring
.index ^^magnetic tape
(applicable to mag-tape only)
.fill
.left margin 5
.skip 1
.index ^^FILES switch
FILES:n
.break
This switch defines the number of files to be handled simultaneously
during execution and helps the run-time system to allocate an appropriate
.index ^^garbage collection
buffer area before start of execution. Since garbage collection will be
invoked when the buffer area overflows, FILES can be used to avoid this.
FILES is a global switch only. Default for n is 0.
.test page 6
.skip 1
.index ^^IMAGESIZE switch
IMAGESIZE:n
.break
.index ^^record size in directfile
A local switch applicable to directfiles only. It defines the record
size which will be n+2 to allow for carriage return and line feed.
If this switch is not given, the image size specified via the parameter
to OPEN will be used to define n.
.IN RTSHLP
.skip 1
.index ^^HELP switch at run-time
HELP
.break
.index ^^SIMRTS.HLP
Prints the contents of the help file SIMRTS.HLP
on the user's terminal.
.EI RTSHLP
.skip 1
.index ^^LIMIT switch
LIMIT:n
.break
LIMIT specifies the number of blocks that may be written on an outfile
or printfile. Default is no limit. A run-time error occurs if this
limit is exceeded. LIMIT may only be used as a local switch.
.skip 1
.index ^^NUMBERED switch
NUMBERED
.break
.index ^^Creating line numbered files in SIMULA
.index ^^Line numbering of files
This switch can be applied only as a local switch in the specification
of an outfile, printfile or directfile.
On a call to outimage, the last bit of the first word of the image is set
to 1.
.IN RTSHLP
The actual line number must be supplied by the SIMULA program in the
five first characters of the image.
.break
NOTE!! The image must start on a word boundary!
.break
If the image is a main text or starts a main text, this is always the case.
According to DEC standard, the sixth character should be a tab (char(9)).
.EI RTSHLP
NUMBERED implies WORDALIGNED. See below.
.skip 1
.index ^^SIZE switch
SIZE:n
.break
This switch defines the initial number of blocks (n) to be allocated to an 
outfile or directfile. Default for n is 5. 
At least n blocks will always be allocated but the file can
however become larger than this size. The switch will improve
the efficiency when the file is large.
SIZE may only be used
as a local switch.
.skip 1
.index ^^switch value
A numeric switch value must be given in the form of a decimal integer
optionally followed immediately by the letter K or P, signifying multiplication with 1024 and 512 respectively.
.skip 1
.index ^^WORDALIGNED switch
WORDALIGNED
.break
This switch is local and applies to outfiles and printfiles.
Directfiles are always word-aligned. The WORDALIGNED switch
forces each image in the buffer to start on a word boundary.
If in addition the internal image is word-aligned, the
image can be copied more efficiently to the buffer.
Main texts are always word-aligned.
.skip 1
All switches except  FILES and HELP may appear in the text argument
to a file object.
.skip 1
Example:
.skip 1
INSPECT NEW outfile("RES.DAT/A:APPEND/LIMIT:100") DO ...
.IF RTSHLP
.skip 2
.center
[END OF SIMRTS.HLP]
.ELSE RTSHLP
.subtitle Chapter 8.4 OBJECT PROGRAM I/O, CLASS INFILE
.p 0,4,19
.skip 3
.indent -5
.index ^^infile
.index ^^class infile
8.4##CLASS INFILE
.skip 2
.index ^^sequential access
An infile is always read sequentially. Each inimage will return the next
record in the image defined for the file, which is the text variable
specified in the OPEN call. A record is terminated with either of
.index ^^line feed, object I/O
.index ^^carriage return, object time I/O
.index ^^form feed, object I/O
.index ^^altmode, object time I/O
.index ^^vertical tab, object I/O
line feed, altmode, form feed or vertical tab. Carriage returns and nulls
are ignored on input. Form feed, altmode and vertical tab
are transferred to the image, while the line feed is not moved.
This means that if a file which contains, say, form feeds, is copied
with a very simple SIMULA program, the new copy of the file will have an extra
carriage return+line feed sequence appended after each form feed, since
.index ^^OUTIMAGE, for infile
OUTIMAGE appends these two characters after each image.
(Unless the copying SIMULA program explicitly
checks for form feeds in the copied text).
.skip 1
If the external image is longer than the image size then a run-time
error occurs. If the external length is shorter than the image size, the rest of the image
is padded with blanks.
.skip 1
.index ^^ENDFILE, for infile
The procedure ENDFILE will return TRUE when the end of file has been passed. The image will
.index ^^end of file record
contain a special end of file record consisting of the two characters /* followed
.index ^^INIMAGE, for infile
by spaces when INIMAGE is called and end of file is encountered.
.skip 1
The following scheme may be used to process an infile:
.skip 1
.tab stops 13,21,28
.nofill
	REF(INFILE)F;
.break
	F:-NEW infile("...");
.break
	F.OPEN(...);
.break
	.
.break
	.
.break
	.
.break
	F.INIMAGE;
.break
	WHILE NOT F.ENDFILE DO
.break
	BEGIN
.break
		process one record;...;
.break
		F.INIMAGE
.break
	END;
.break
	.
.break
	.
.break
	F.CLOSE;
.fill
.skip 1
If ENDFILE returns TRUE when INIMAGE is called a run-time error occurs.
.skip 1
.index ^^devices for infile
The following devices can be used for infile:
.break
TTY, disk, DECtape, magnetic tape, card reader and paper tape reader.
.subtitle Chapter 8.5 OBJECT PROGRAM I/O, CLASS OUTFILE
.p 0,4,19
.skip 3
.indent -5
.index ^^class outfile
.index ^^outfile
8.5##CLASS OUTFILE
.skip 2
.index ^^sequential access
.index ^^file allocation
Outfiles are written sequentially. The user may allocate as many
.index ^^SIZE switch
blocks as appropriate with the SIZE switch. If SIZE is omitted at least 5 blocks will be allocated.
If the initial allocation is used up, the operating system will automatically allocate
as much as needed.
.skip 1
.index ^^LIMIT switch
The LIMIT switch may be used to stop unintentional endless loops
with output. The argument to LIMIT defines how many blocks will be
written on a file. A run-time error is invoked if this limit is exceeded.
.skip 1
.index ^^OUTIMAGE, for outfile
On OUTIMAGE, IMAGE.STRIP is output with carriage return and line feed appended.
.index ^^BREAKOUTIMAGE
A special procedure BREAKOUTIMAGE exists to allow output on TTY
without carriage return and line feed. This procedure can be
used on any device.
BREAKOUTIMAGE strips away only spaces after POS before outputting the line.
.skip 1
.index ^^ACCESS switch
.index ^^append mode
Outfiles can also be written in append mode with the switch ACCESS:APPEND.
If the file already exists, the new output is appended to
the existing file. The minimum allocation of (usually) 5 blocks does not apply
to files written in append mode. All unused space will be released at CLOSE.
.skip 1
.index ^^devices for outfile
Outfiles can be written on the following devices:
.break
TTY, disk, DECtape, magnetic tape, line printer, card and paper tape punch.
.subtitle Chapter 8.6 OBJECT PROGRAM I/O, CLASS PRINTFILE
.p 0,4,19
.skip 3
.indent -5
.index ^^class printfile
.index ^^printfile
8.6##CLASS PRINTFILE
.skip 2
This file class is a subclass of outfile. The following differences
exist compared to outfile:
.skip 1
.index ^^SIZE switch
- SIZE does not apply to printfile, i.e. the user can not allocate a 
specific amount of blocks, all unused space will be released when the file
is closed.
.skip 1
.index ^^form feed, in printfile
- a form feed is output when the file is opened on a device other than TTY.
.skip 1
- a form feed is output after n lines, where n is the current value of the internal
variable linesperpage (set by the user with the procedure
.index ^^LINESPERPAGE
LINESPERPAGE or defaulted to 60).
.skip 1
- the following special procedures exist for printfile to control the layout of
the printed file:
.break
.index ^^SPACING
.index ^^EJECT
SPACING, LINESPERPAGE, EJECT.
These procedures are described in the SIMULA Language Handbook Part I.
.skip 1
It is often inconvenient to get a form feed on TTY after n lines of output,
especially in conversational applications. This can be circumvented
with the following statement: SYSOUT.LINESPERPAGE(-1)
which will set n to 2**18-1, which will be the same as  no form feeds
in most practical cases.
.skip 1
.index ^^devices for printfile
Printfiles can be written on the same devices as outfiles.
.subtitle Chapter 8.7 OBJECT PROGRAM I/O, CLASS DIRECTFILE
.p 0,4,19
.skip 3
.indent -5
.index ^^class directfile
.index ^^directfile
8.7##CLASS DIRECTFILE
.skip 2
.index ^^random access
A SIMULA directfile is a file that can be accessed randomly by specifying
.index ^^relative record number
the desired record's relative number in the file. This is done with the
LOCATE procedure. The records are numbered sequentially from 1 upwards.
.skip 1
The operating system permits the user to create directfiles randomly. It is
e.g. possible to start from scratch and write, say, record 100. The
operating system will then write blocks 1 to 99 and fill them with nulls and
then write block 100. The file can then be expanded randomly, the
operating system will allocate needed space and fill unwritten blocks with nulls.
.skip 1
Definitions:
.skip 1
.index ^^image size in directfile
Image size is the length of the text variable used at OPEN.
.skip 1
.index ^^record size in directfile
Record size is the length of each external record in the file, this
length is fixed for directfile.
.skip 1
.index ^^actual record size in directfile
Actual record size is the number of characters preceding
line feed, not counting carriage return, or number of characters
preceding and including vertical tab, altmode or form feed.
.skip 1
.index ^^physical record size in directfile
Physical record size is the number of words needed to store
one record in the file; all records start on a word boundary.
.skip 1
.index ^^disk block
A disk block consists of 128 words, 640 characters,  which gives an
image size of 638 characters not counting carriage return
and line feed. The record size for a directfile is fixed and is defined
.index ^^IMAGESIZE switch
with the IMAGESIZE switch or, if the switch is not given, by the length
of the text variable given on the first call of OPEN for the file.
For each following inimage or outimage call, the current image of the file
#m#u#s#t# have the size used at open.
.skip 1
.index ^^external image
A directfile record, the external image, is thus n+2 characters long, where n
is the value of the IMAGESIZE switch argument. The record size may
.index ^^physical block size
be smaller, greater than or equal to the physical block size. RTS will compute
the relative block number from the record number and the physical record size.
.skip 1
On output, CR-LF is appended after the end of the image in the buffer.
Both on input and output, the #w#h#o#l#e# image is always transferred
to or from the buffer, regardless of any special characters.
It is thus possible to embed control characters, e.g. line feed,
carriage return, form feed, in the image.
.skip 1
.index ^^ENDFILE, for directfile
.index ^^LOCATION
The ENDFILE procedure returns TRUE when both of the following two
conditions are true:
.skip 1
a_) LOCATION identifies a record outside the file range, i.#e.#LOCATION _< 1
or LOCATION _> limit, where limit is an internal variable containing the highest record number in the file.
This variable is computed from record size and file length at OPEN and is
updated by OUTIMAGE when the file is expanded.
.skip 1
b_) INIMAGE has been called at least once, and the last call was made after the
last call for OUTIMAGE, and the last call for INIMAGE was made with a location
identifying a record outside the file range as defined above.
.skip 1
ENDFILE also returns TRUE when the file is not open.
.skip 1
.index ^^unwritten record in directfile
If LOCATE identifies a not yet written record, a subsequent call on ENDFILE
.index ^^end of file record
will return FALSE. INIMAGE will return the end of file record
(see section 8.4) when an unwritten record is read.
.skip 1
Example:
.skip 1
###D:-NEW directfile(...);
.break
###.
.break
###.
.break
###.
.break
###D.LOCATE(I);
.break
###D.INIMAGE;
.break
###IF D.ENDFILE THEN action for end of file;
.break
###IF D.IMAGE.STRIP="/*" THEN action for not written record;
.break
###.
.break
###.
.skip 1
This will also work for empty files.
.skip 1
.index ^^devices for directfile
Directfiles can only be stored on disk.
.skip 2
If you intend to read a directfile sequentially from start to end,
you can save about 30_% of the CPU time by declaring it as an
INFILE in your SIMULA program.
.subtitle Chapter 8.8 OBJECT PROGRAM I/O, BASICIO
.p 0,4,19
.skip 3
.indent -5
.index ^^class BASICIO
.index ^^BASICIO
8.8##CLASS BASICIO
.skip 2
This class contains actions to generate a standard infile called
.index ^^SYSIN
.index ^^SYSOUT
SYSIN and a standard printfile called SYSOUT. These files are generated and
opened at start of execution. They will be automatically closed at end of execution,
but the user may close and reopen them as he wishes. SYSIN and SYSOUT
will normally be assigned to TTY by RTS, but the user may prevent this
through definitions in the specification file, e.g.:
.skip 1
SYSIN INDAT.DAT
.break
SYSOUT RESULT.LST/ACCESS:APPEND
.skip 1
The user can also use the ASSIGN command before the execution
and assign SYSIN and SYSOUT to, say, DSK. SYSIN will then be read
from a file called SYSIN without extension and SYSOUT will be written
on a file called SYSOUT also without extension.
.skip 1
.index ^^image size of SYSIN
.index ^^image size of SYSOUT
If TTY is used as device for SYSIN or SYSOUT, the image size
will initially be set to the carriage width of that terminal.
In other cases the image size of SYSIN will be 80 characters
and the image size of SYSOUT will be 132 characters.
.tab stops 1
.subtitle Chapter 8.9 DEVICE CONTROL CHARACTERS
.p -5,3,15
8.9##DEVICE CONTROL CHARACTERS
.skip
.index ^^ASCII device control characters
.index ^^ISO device control characters
.index ^^characters, device control, in ASCII-ISO
.index ^^device control characters in ASCII-ISO
Most ASCII(ISO) device control characters are illegal in SIMULA source
.index ^^TEXT constants, allowed characters in
.index ^^CHARACTER constants, allowed characters in
program TEXT and CHARACTER constants.
They can however be entered into TEXT and CHARACTER variables by using
.index ^^CHAR built-in function
the built-in function CHAR.
.index ^^character conversion during I/O
.skip
For outfiles and printfiles all 128 ASCII(ISO)
characters are output just as they appear
in the image of the outfile.
However, outimage will skip trailing blanks and breakoutimage
will skip trailing blanks after pos.
.skip
For directfiles, all 128 ASCII(ISO) characters are
input and output unchanged. Trailing blanks are not skipped.
.skip
On input for infiles, the following special handling of certain device
control characters will occur:
.tab stops 12 20 33
.left margin 33
.p -27,1,27
Octal	Decimal	Name	Action
.indent -27
.skip
000	 0	Null	Ignored in input.
.index ^^NULL character
.index ^^LINE FEED character
.index ^^VERTICAL TAB character
.index ^^FORM FEED character
.index ^^CARRIAGE RETURN character
.index ^^Control-Z character
.index ^^ESCAPE character
.index ^^ALTMODE character
.indent -27
011	10	Line Feed	The character is not input, but will
finish a line, so that the next INIMAGE will continue with the
character following the line feed.
.indent -27
013	11	Vertical Tab	The character will be input as the
last character of a line, and the next INIMAGE will continue with the
following character.
.indent -27
014	12	Form Feed	Same as vertical tab.
.indent -27
015	13	Carr.#Return	Ignored in input.
.indent -27
032	26	Control-Z	Signifies end-of-file in input from a terminal.
				Otherwise copied directly.
.indent -27
033	27	Escape	Same as vertical tab.
.tab stops 1
.EI RTSHLP
^^
.nj;.ts 1;.sp 1
.VR DDTHLP,D,W
.IN DDTHLP
.lm 5;.rm 65;.ps 55,65
.subtitle CHAPTER 9 DEBUGGING SIMULA PROGRAMS WITH SIMDDT
.pg;.s 3
.IF DDTHLP
.npa;.nst;.rm 72;.lm 0
.EI DDTHLP
.IN DDTHLP
.I -5;9.###DEBUGGING SIMULA PROGRAMS WITH SIMDDT
.index ^^SIMDDT
.index ^^SIMULA debugging system
.index ^^Debugging system (SIMDDT)
.br;=====================================
.EI DDTHLP
.IF DDTHLP
.br;DEBUGGING SIMULA PROGRAMS WITH SIMDDT
.EI DDTHLP
.s 2;SIMDDT is an interactive program that is used to debug
SIMULA programs. SIMDDT allows the user to:
.s;a) set up to 20 breakpoints
.IN DDTHLP
(1)
##############[STOP] AT n...
.br;###in the program
.EI DDTHLP
.if ddthlp
in the program####[STOP] AT [module:] nn ...
.ei ddthlp
.IN DDTHLP
.index ^^[STOP] BREAKS
.index ^^breakpoint
.fn 7
.s;-----------------
.s;(1) At a breakpoint the normal program execution
is interrupted and the debugging program SIMDDT gets control. SIMDDT
will perform the tasks that were specified when the breakpoint was set.
!
.EI DDTHLP
.br;b) continue from a breakpoint#################PROCEED
.br;c) display the current breakpoint settings####[STOP] BREAKS
.br;d) remove a breakpoint setting################REMOVE [AT n]
.br;e) change the contents of a variable##########INPUT x:= ...
.br;f) display the contents of a variable#########OUTPUT x, ...
.br;
g) display all variables in the storage pool##VARIABLES 
.if ddthlp
[/switches]
.ei ddthlp
.br;
h) display the dynamic operating chain########CHAIN
.br;
i) display all scheduled processes############SCHEDULED
.br;
k) switch output to a disk file e.g. a.bug###USE a.bug
.br;l) display the source code####################DISPLAY 
.if ddthlp
[module:][m:n!m,n]
.ei ddthlp
.in ddthlp
m[:n]
.ei ddthlp
.br;m) move SIMDDT viewpoint : to object x#######INSPECT x
.br;######to SIMDDT interrupt point###############INSPECT/START
.br;######to CLASS or PROCEDURE generation point##INSPECT/RETURN
.br;######to viewpoint before last RETURN#########INSPECT/RESET
.br;######to statically enclosing block###########INSPECT/UP
.br;n) close open files###########################[STOP] CLOSE
.br;o) read SIMDDT control file e.g. x.cmd#######@x.cmd
.br;p) terminate execution########################EXIT
.IN DDTHLP
.p -5,4,19
.EI DDTHLP
.index ^^compiler switches DEBUGS and IDENTIFICATION
.IF DDTHLP
.s 3;1.##LOADING AND STARTING SIMDDT
.EI DDTHLP
.IN DDTHLP
9.1##LOADING AND STARTING SIMDDT
.EI DDTHLP
.s 2;The SIMDDT program is self-relocating and it is read from disk by a SIMRTS
routine when requested.
The SIMULA compiler switches I (IDENTIFICATION, produces a line number
table) and D (DEBUGS, produces a symbol table) must have been set during
compilation if the program is to be debugged with SIMDDT. The switches are
set by default but if they were set off, SIMDDT will give incomplete
information to the user.
.s;.lm 5;.i -5
.IN DDTHLP
9.1.1#DEBUG
.EI DDTHLP
.IF DDTHLP
1.1#DEBUG
.EI DDTHLP
.index ^^DEBUG monitor command
.s;.lm 5
	If the source file has extension SIM or the /SIMULA switch is used,
	the DEBUG monitor command will ensure that SIMDDT is read into low
	segment core and started before the SIMULA program execution starts.
.IN DDTHLP
	Note that this will not work if the first file
	in the DEBUG command is placed on another 
	directory path. You will get DDT instead of SIMDDT.
	In that case you can use
	LOAD followed by REENTER to get SIMDDT.
.EI DDTHLP
.br;Command example:
.s;_.DEBUG MYPROG.SIM
.p -5,2,5
.index ^^DDT when you wanted SIMDDT
.index ^^SIMDDT, loading of
.IN DDTHLP
9.1.2#LOAD, SAVE, GET, REENTER
.EI DDTHLP
.IF DDTHLP
1.2#LOAD, SAVE, GET, REENTER
.EI DDTHLP
.index ^^LOAD monitor command
.index ^^SAVE monitor command
.index ^^GET monitor command
.index ^^REENTER monitor command
.s;	The monitor commands LOAD plus SAVE will save the user program not
	including SIMDDT on disk.
	If issued directly after LOAD (+SAVE) or GET, the REENTER command will
	cause SIMDDT to be read into low segment core and started.
	The START monitor command will start user program execution directly.
.br;Command example:
.s;_.LOAD MYPROG.SIM
.br;	_.SAVE
.br;	_.REENTER
.p -5,2,5
.IN DDTHLP
9.1.3#_^C - REENTER
.EI DDTHLP
.IF DDTHLP
1.3#_^C - REENTER
.EI DDTHLP
.index ^^_^C monitor command
.s;	After the SIMULA program has started to execute without the debugging
	system it is usually possible to invoke SIMDDT. One or
	two _^C commands will stop execution and return the terminal to monitor
	mode. The REENTER monitor command will load and start SIMDDT,
	which will give
	the number of the source program line which corresponds to the statement
	which was interrupted by _^C. This is very useful when the program is 
	looping. _^C can also be used if SIMDDT is already loaded.
.IN DDTHLP
	If the user program was expecting input from the user terminal when
	the _^C was given (i.e. if one _^C is sufficient), then SIMDDT will not
	start until the input has been typed.
.break
Note that SIMDDT will be started when the execution has reached
the user source program level, i.e. an I/O operation
must be completed. In some cases it will not be possible to break the
execution and the user will be advised to try again.
.break
 
.test page 6
.EI DDTHLP
.break
Command example:
.skip 1
	_.EXECUTE MYPROG.SIM
.break
_^C
.break
_^C
.break
_.REENTER
.skip 2

.indent -5
.index ^^run time errors
.IN DDTHLP
9.1.4#Program errors
.EI DDTHLP
.IF DDTHLP
1.4#Program errors
.EI DDTHLP
.skip 1
.IN DDTHLP
After a run time error has been detected,
the SIMDDT program will be called to write the error message 
and the source program line number which holds the statement
that caused the error.
Appendix H contains an example on how to handle program errors in a batch run.
.EI DDTHLP
.IF DDTHLP
SIMDDT will be called to write the error message and information on
where the error occurred.
.EI DDTHLP
.skip 2
.indent -5
.IN DDTHLP
9.1.5#CONTINUE after program exit
.EI DDTHLP
.IF DDTHLP
1.5#CONTINUE after program exit
.EI DDTHLP
.index ^^CONTINUE command
.skip 1
The CONTINUE monitor command can be used to start SIMDDT after a normal program
exit. The variables  in the storage pool can be displayed with the
VARIABLES command.
.skip 2
.indent -5
.IN DDTHLP
9.1.6#REENTER after program exit
.EI DDTHLP
.IF DDTHLP
1.6#REENTER after program exit
.EI DDTHLP
.skip 1
	The REENTER command should be used to restart the program and SIMDDT
	after program exit. Note that all breakpoint settings will be lost,
	since the data area is reinitialized.
	If SIMDDT was not loaded at execution start, the START command will
	restart the program without invoking SIMDDT.
.IF DDTHLP
.skip 3
.ELSE DDTHLP
.p 0,4,19
.left margin 5
.skip 2
.indent -5

9.2##SIMDDT INPUT AND OUTPUT
.index ^^input to SIMDDT
.index ^^output from SIMDDT
.skip 2
The user TTY is normally used for input to SIMDDT. An "*" on the
terminal signals that SIMDDT is expecting a user command.
The _@ command will cause SIMDDT to read its
input from the indicated file.
.break
.skip 1
A maximum of 135 characters are allowed in the input 
command which is terminated by a break character (e.g. carriage
return, line feed).
.skip 2
At entry to SIMDDT one of the following messages will be given:
.break
.skip 1
SIMDDT STARTED
.break
*
.indent 9
SIMDDT and SIMRTS have been initialized but
.indent 9
user program execution has not started.
.indent 9
Breakpoints can be set before starting the
.indent 9
program with the PROCEED command.

.skip 2
.break
AT <LINE> .....
.indent 9
Breakpoint instruction executed, no STOP specified.
.skip 2
.break
STOP AT <LINE> .....
.break
*
.indent 9
Breakpoint instruction executed and STOP specified.
.skip 2
.break
SIMDDT ENTERED , PROGRAM INTERRUPTED AT <LINE>
.break
*
.indent 9
Program was probably interrupted via _^C and
.indent 9
REENTERed or the CONTINUE command was issued after
.indent 9
 program exit.

.skip 2
?ERROR IN JOB <N> AT <LINE>
.break
ZYQnnn ......
.break
*
.indent 9
The error ZYQnnn was found. 
.skip 1
.skip 1
<LINE> is a reference to a line number in the source program
or an octal address, see below.
.p 0,4,19
.break
.skip 1
	The user TTY is used for output from SIMDDT when it is in debug
	mode and no USE command has been given.
.skip 1
	Both the user TTY and the SYSOUT file are used for output from
	SIMDDT when it is in error mode and continuation after the error is not possible. The output from the ALL 
	command is only written to SYSOUT but all other output is
	written on both files.
.break
	If an output file is specified with the USE command it
	replaces the SYSOUT file.
.skip 1
.break
The _^O monitor command can be used to suppress output from SIMDDT.
.index ^^_^O monitor command in SIMDDT
.break
The _^C and REENTER monitor commands can be used to end processing of
the current command.
.break
.index ^^_^C - REENTER in SIMDDT
The output will be resumed when a new command is expected and SIMDDT 
outputs the "*".
.skip 1
The format of the output from SIMDDT is briefly described in
the command descriptions below. Appendix H contains examples of
SIMDDT output.
.break
Every address that points into the generated code for statements 
is output in the line number format <MODULE>:<NNNNN>, see below 9.3.1. The line chosen
by SIMDDT is the last line on which a statement starts with an address less than or 
equal to the referenced address. If no line number table was generated during
compilation (-I switch set) or if the address references an external FORTRAN
procedure the format of the line identification is <MODULE>:O <oooooo> , where
o is an octal digit. When the address can not be linked to any line number
table the address is output in octal format O <oooooo> . This is
the case for all addresses pointing to the dynamic area, into an external
Macro 10 procedure, into the simulation routines and into the high segment.
.p 0,4,19
.skip 2
.indent -5

.EI DDTHLP
.IF DDTHLP
.left margin 0
2##SIMDDT COMMANDS
.EI DDTHLP
.IN DDTHLP
9.3##SIMDDT COMMANDS
.EI DDTHLP
.index ^^debug mode (SIMDDT)
.index ^^error mode (SIMDDT)
.skip 2
SIMDDT operates in two modes, debug and error mode. SIMDDT is in error mode
when  entered after a program error, otherwise it is in debug mode.
.skip 2
.IF DDTHLP
2.1 Command syntax
.left margin 5
.EI DDTHLP
.IN DDTHLP
.indent -5
9.3.1 Command syntax
.EI DDTHLP
.index ^^command syntax (SIMDDT)
.skip 2
	SIMDDT will translate all lower case letters to upper case.
	The reserved words in the commands can be  truncated to any number of 
	characters as long as they are unique. 
	The keywords INPUT and STOP have also been given short forms namely I and ST.
	A command may not occupy more than one line.
.skip 1
	A line starting with the character _; will be treated as a comment and ignored.
.skip 1
.IN DDTHLP
	One or more blank and/or TAB characters must be used as
	separator between adjacent identifiers or keywords.
.skip 1
	Meta symbols used in the syntax description below are:
.break
.skip 1
!#####(logical or sign) separates alternative options
.break
[]####(square brackets) enclose a group of options of which
.br;######one or none may be selected
.br;_...###denotes an arbitrary repetition of the group enclosed
.br;######by the preceding braces or square brackets.
.s;	See also the ALGOL report [2] for an explanation of the 
	meta language.
.s
.EI DDTHLP
.s;	The user identifies a breakpoint with a source program line
	number. In the command descriptions below the notation
	<LINE> is used.  <LINE> has the form [<MODULE>:] <NNNNN>.
.index ^^<LINE> in SIMDDT
.index ^^<MODULE> in SIMDDT
.s;
	<MODULE> is MAIN or the SIMULA name of a separately
	compiled procedure or class. MAIN indicates the main program.
	If <MODULE>: is omitted, the current module is used by SIMDDT, that is
	MAIN at program start and later the module in which the current 
	breakpoint is placed.
.s;	<NNNNN> is a line number in the source program. The line should
.index ^^<NNNNN> in SIMDDT
.index ^^line number in SIMDDT
	contain the beginning of an executable statement. If not found the first
	higher numbered line on which a statement starts will be chosen.
.IN DDTHLP
.p 0,4,19
.s
.index ^^<IDENTIFICATION> in SIMDDT
.index ^^<IDENTIFICATION2> in SIMDDT
.index ^^<SUBSCRIPT LIST> in SIMDDT
.EI DDTHLP
.s;	In the commands the user references a source variable with the 
	notation <IDENTIFICATION> or <IDENTIFICATION2>.
.s;	<IDENTIFICATION> ::= <IDENTIFICATION1> 
.br;	#####################[QUA <CLASS IDENTIFIER>] !
.br;	#####################<IDENTIFICATION>.<IDENTIFICATION1>
.s;	<IDENTIFICATION1> ::= <IDENTIFIER> ! 
.br;	######################THIS <CLASS IDENTIFIER>!
.br;	##################### <ARRAY IDENTIFIER>(<SUBSCRIPT LIST>)
.s;	<SUBSCRIPT LIST> ::= [-] <INTEGER> !
.br;	#################### [-] <INTEGER>,<SUBSCRIPT LIST>

.s;	<IDENTIFICATION2> ::= <IDENTIFICATION> !
.br;	#####################[<IDENTIFICATION>.]<ARRAY IDENTIFIER> !
.br;	#####################[<IDENTIFICATION>.]*
.s;	The <IDENTIFIER> must be a simple variable of type INTEGER, REAL,
	LONG REAL, BOOLEAN or CHARACTER or a simple object reference or
	TEXT type variable. When the <IDENTIFIER> is a formal parameter
	called by name it is not handled by SIMDDT. A formal
	parameter with transmission mode by value or by reference will
	be treated like a declared variable.
	The standard procedures SYSIN, SYSOUT, FIRST, LAST, SUC, PRED,
	PREV, EVTIME, MAIN, TIME and CURRENT are accepted by SIMDDT.
	A type procedure identifier is handled by SIMDDT if the current block is the procedure 
	block. The identifier can however not be used in connection with the IFCHANGED
	and the IF features in a breakpoint command or on the right hand side in an INPUT
	command.
.s;	The brackets ( ) around the <SUBSCRIPT LIST> can be replaced
	by a pair of square brackets, e.g. A[1,2].
.s;	In the commands below the notation <STRING> is used.
.index ^^<STRING> in SIMDDT
	<STRING> is a string of characters enclosed in " . The first
	5 characters in the string are part of the message that SIMDDT
	outputs at the breakpoint.
.IN DDTHLP
.SUBTITLE CHAPTER 9 DEBUGGING SIMULA PROGRAMS , SIMDDT COMMANDS

.p 0,4,19
.EI DDTHLP
.p -5,2,5
.index ^^SIMDDT commands
.index ^^AT, SIMDDT command
.index ^^STOP AT, SIMDDT command
.index ^^breakpoint in SIMDDT
.index ^^IFCHANGED, SIMDDT command keyword
.index ^^SIMDDT commands
.indent -5
.IF DDTHLP
2.2 Commands
.EI DDTHLP
.IN DDTHLP
9.3.2 Commands
.EI DDTHLP
.s 2;	[STOP] AT <LINE> [,<N>] [<STRING>]
.s;	SIMDDT ACTION: Identifies a breakpoint and outputs a message
	every n:th time the referenced statement is executed.
	If STOP is given  execution is halted and  new SIMDDT commands 
	are accepted. <N>, the loop counter, is an integer number.
.s 2;	[STOP] AT <LINE> [<STRING>] [IFCHANGED] <IDENTIFICATION2> [,
	<IDENTIFICATION2> ]...
.s;	SIMDDT ACTION: Identifies a breakpoint. If IFCHANGED is specified
	SIMDDT will output only changed variable values, otherwise
	the values are always given.
	If IFCHANGED is specified the first time the breakpoint is
		reached, the value is compared to 0, FALSE, NOTEXT, NONE or CHAR(0), depending on its type.
	* the complete block indicator and <ARRAY IDENTIFIER> are
	not allowed when IFCHANGED used.
.s;	[STOP] AT <LINE> [<STRING>] IF <IDENTIFICATION> 
.br;<RELATION OPERATOR> <VALUE>
.index ^^<RELATION OPERATOR>
.s;	SIMDDT ACTION:  Identifies a breakpoint. SIMDDT will output the 
	variable value if the relation is TRUE.
.br;	The <RELATION OPERATOR> can be one of  > >= < <= = _\= == =/= 
	GT GE LT LE EQ NE EQV IS IN.
	The <VALUE>  can be an <IDENTIFICATION>, TRUE, FALSE, NOTEXT, NONE, 
	arithmetic constant, character constant, text value constant or
	CLASS identifier.
.IN DDTHLP
.br;	The character " can never be part of an input text value constant. 
	Some special control characters can not be part of a character or text
	value constant, see 9.2.
.br;	The arithmetic constant must be in the form of an <INTEGER ITEM>
	when the variable is integer and in the form of a <REAL ITEM>
	when it is a real or long real variable. The de-editing 
	procedures GETINT and GETREAL in the RTS system are used to get the value.
.EI DDTHLP
.p 0,2,6
.index ^^REMOVE, SIMDDT command
	REMOVE [ AT <LINE> ]
.s 1;	SIMDDT ACTION: Remove all breakpoint commands for a 
	specific line or remove all breakpoints.
.s 2;
.index ^^BREAKS, SIMDDT command
	[STOP] BREAKS
.s 1;	SIMDDT ACTION: List all breakpoint commands. The input order is not
	kept. If STOP is specified, SIMDDT will halt after each breakpoint command
	and allow the user to remove it. When all breakpoint
	commands for a line are removed the breakpoint is removed.
.IN DDTHLP
	The BREAKS command can be used to check if it was possible
	to set a breakpoint at the line given in the user command since SIMDDT
	will change the line number if necessary.
.s 1;	USER ACTION: Type REMOVE to remove the last command listed or 
	type an empty line (RETURN key) to keep the command.
.EI DDTHLP
.s 2
.index ^^OUTPUT, SIMDDT command
.index ^^<IDENTIFICATION2> used in OUTPUT SIMDDT command
	OUTPUT <IDENTIFICATION2> [/-TEXT][/-ARRAY]
.br;	[,<IDENTIFICATION2>]...
.s 1;	SIMDDT ACTION: Output the values of the variables.
	See VARIABLES for explanation of the switches.
.s 1
.IN DDTHLP
	For an <ARRAY IDENTIFIER> the following will be output:
.br;	The name and the array bounds
.br;	<SUBSCRIPT LIST> = value of element  ( if not initial value)
.s 1;	If [<IDENTIFICATION>.]* is used then all the variables in the
	referenced block are output.
.br;	The editing procedure PUTINT is used to output an integer
	variable and the PUTREAL procedure is used for real and long real
	variables. A real variable will be given with 8 and a long real
	variable with 16 significant digits.
.s 1;.br;	For a text variable the following will be output:
.br;	Octal address of the dynamic area allocated to the text variable
.break	
	SUBTEXT STARTS AT POSITION= <N>  ### (only if subtext)
.br;	LENGTH= <N>
.br;	POS= <N>
.br;	" plus all characters in the stripped text
.br;	"  ##### (only if the last character in text is not a blank)
.br;	A character with RANK(character)#_<#32 will be replaced by _^ followed
	by a capital letter 
	(octal 100 is added to the internal representation of the character).
.s 1;.br;	For a REF variable the following will be given:
.br;	QUALIFICATION ERROR ####(if error)
.br;	Name of class referenced by variable
.br;	Octal address of dynamic area referenced by variable
.br;	TERMINATED or DETACHED <LINE> or <LINE> (if active class)
	where <LINE> is the reactivation point of the invoking block.
.s 1;	For a character variable the character enclosed in quotes
	will be output if RANK(character) is >= 32,
	otherwise the output will be CHAR <N>,
	where <N> is RANK(character), RANK(' ')=32.
.p 0,4,19
.EI DDTHLP
.s 2
.index ^^INPUT, SIMDDT command
	INPUT <IDENTIFICATION> <ASSIGNMENT OPERATOR> <VALUE>
.s 1;	SIMDDT ACTION: Changes the value of the referenced variable to the
	value given in the command. The operators are := and :-.
	See above for explanation of <VALUE>.
.index ^^DISPLAY, SIMDDT command
.s 2;	DISPLAY [<MODULE>:][<RANGE>]
.p 8,1,5
		<RANGE> ::= <NNNNN> ! [<NNNNN>]:<NNNNN> ! [<NNNNN>],<NN>
.s 1;	SIMDDT ACTION: Output the indicated source program lines.
.IN DDTHLP
	If no range is given, 10 lines are displayed starting with the
	next line to be displayed. The next line can be denoted by a dot (.).
	The value of "." is 0 when no lines have been displayed. The next
	existing line number is substituted for a non-existent line.
	The first line can also be denoted by an up-arrow (_^).
	A colon (:) is used to separate the end-points of the range.
	A dash (-) can also be used.
	Alternatively, the number of lines to be displayed can be given
	following a comma (,). <NN> is the number of lines.
	The upper end of the range can be given by an asterisk (*),
	which is interpreted as +infinity.
	If the first line of the range is not given, "." is assumed.
	If the source program file is not found the user must enter
	the correct file specification via the I/O dialogue.
	The display file is closed at exit from SIMDDT.
	If <MODULE>: is not given in the command and it is the first
	DISPLAY command since SIMDDT was entered, the current module
	is assumed otherwise the already opened source program file is read again.
.EI DDTHLP
.p 0,2,7
.index ^^INSPECT, SIMDDT command
	INSPECT <IDENTIFICATION> ! /START ! /RETURN ! /RESET ! /UP
.s 1;	SIMDDT ACTION: The point in the program, from which SIMDDT sees the variables, is moved.
	This makes it possible to input and output variables, which are not visible from
	the block in which the program execution was interrupted.
.p 0,1,3
	INSPECT <IDENTIFICATION>
.br;	SIMDDT will now see inside the CLASS object, to which the variable refers.
	It must be an object reference (not NONE).
.p 0,1,3
	INSPECT /START
.br;	SIMDDT will again see from the place, where program execution
	was originally interrupted and SIMDDT entered.
	If SIMDDT was entered via an error or via _^C-REENTER, the
	initial SIMDDT message is repeated, giving the reason for
	entering SIMDDT. Useful with display terminals.
.p 0,1,5
	INSPECT /RETURN
.br;	SIMDDT should be looking inside a procedure or an active CLASS.
	/RETURN will make SIMDDT see from the point where the procedure was
called
	or where the class was generated or called.
.p 0,1,4
	INSPECT /RESET
.br;	Go back to where SIMDDT was looking before the last INSPECT /RETURN command.
.IN DDTHLP
	/RESET is equal to /START if no INSPECT /RETURN command has been given
	since SIMDDT was entered.
.EI DDTHLP
.p 0,1,3
	INSPECT /UP
.br;	Look directly at the statically enclosing block.
.IN DDTHLP
Not valid when SIMDDT
	is looking at a terminated class instance.
.p 0,4,19
.EI DDTHLP
.if ddthlp
.s 2
.ei ddthlp
.index ^^PROCEED, SIMDDT command
	PROCEED
.s 1;	SIMDDT ACTION: SIMDDT will either start program execution or
	continue processing at the point where it was interrupted.
	PROCEED is not valid after an error from which it is not 
	possible to continue or after a NOPROCEED command.

.s 2;
.index ^^USE, SIMDDT command
	USE <FILE SPECIFICATION>
.s 1;	SIMDDT ACTION: SIMDDT output will be written on the file specified in
	the command. All output that signals a user action is also output on 
	TTY e.g. the message "STOP AT MAIN:17 " will be output both at
	the TTY and the file at the breakpoint stop.
	The file is not closed until a new USE command is given or at the 
	end of execution. The format of the <FILE SPECIFICATION> is the same 
	as the one used for the other user files, see chapter 8.2.
	USE TTY: will reset SIMDDT output to the terminal.

.s 2;
.index ^^CHAIN, SIMDDT command
	CHAIN
.s 1;	SIMDDT ACTION: Writes the dynamic operating chain starting with
	the current block. Only procedures, class instances and
	inspected class instances are given.
	The name of the block and its activation line are listed.
.IN DDTHLP
	Note that no operating chain is given when the interruption address was not located in any
	line number table.
.EI DDTHLP
.s 2;
.index ^^VARIABLES, SIMDDT command
	VARIABLES [/-ARRAY][/-TEXT][/-GC][/START:[-]<oooooo>

.s 1;	SIMDDT ACTION: The complete storage pool is scanned and all variables
	that are of a type treated by SIMDDT are listed together with the name
	of the dynamic block in which the variables are declared. 
	Unless /-GC was specified or garbage collection is not safe,
	the garbage collector routine (G.C.) will
	be called  before the storage pool is scanned.
	When /-ARRAY is specified all array elements are skipped in the output.
	When /-TEXT is specified all text characters are skipped in the output.
	The /START switch can be used to output only the top of the pool.
.IN DDTHLP
Only blocks at addresses greater than the (octal)
value of the /START switch will be output. A negative value is added
to the top of pool address to give a starting address.
	G.C. scans the pool and removes all dynamic blocks
	that are unreferenced and inactive.
.EI DDTHLP
	To reduce output only variables which do not have their initial values
	are given. The amount of data is often very large, and the USE command 
	can be used to direct the output to a disk or LPT file.
.br
.IN DDTHLP
.test page 7
For each dynamic block instance the following will be output:
.br;The name of the dynamic block, that is the procedure or class
name, MAIN if main program, PREFIXED BLOCK plus name of prefix class
or BLOCK if unreduced block
.br;Octal address of the dynamic area
.br;TERMINATED or DETACHED <LINE> or <LINE> (if active)
.s 1;The value of a type procedure will also be output.
.s;The format of the variables is found in the description of the
OUTPUT command above. For each array identifier the name and the
array bounds are always given even if all elements have their
initial values.
.EI DDTHLP
.s 2;
.index ^^SCHEDULED, SIMDDT command

	SCHEDULED
.s 1;	SIMDDT ACTION: For each scheduled process the following will be output:
.br;	EVTIME= scheduled time
.br;	Class name
.br;	Octal address of dynamic area
	DETACHED <LINE>
.s 2;
.index ^^ALL, SIMDDT command
	ALL [/-ARRAY] [/-TEXT] [/-GC] [/START:[-]<oooooo>]
.s 1;	SIMDDT ACTION: Produces the same information as if the commands
	CHAIN, VARIABLES and SCHEDULED had been given. 
	The switches apply to the implied VARIABLES command, q.v.
.s 2;
.index ^^CLOSE, SIMDDT command
	[STOP] CLOSE
.s 1;	SIMDDT ACTION: Lists and closes all open files except SYSIN and
	SYSOUT. If STOP is specified SIMDDT will halt and allow the user
	to close the file. Answer CLOSE or carriage return.
.s 2;
.index ^^NOPROCEED, SIMDDT command
	NOPROCEED
.s 1;	SIMDDT ACTION: Inhibits the use of the PROCEED command.
	After this command it will be possible to use a critical
	command such as USE or DISPLAY.
	Not necessary when stopping at preset breakpoints.
	
.s 2;
.index ^^@, SIMDDT command
	@ <FILE SPECIFICATION>
.s 1;	SIMDDT ACTION: SIMDDT input will be read from the file specified
	in the command. The command will be output on the TTY before it is
	processed. When end of file found SIMDDT will
	request input from the TTY.
.s 2;
.index ^^EXIT, SIMDDT command
	EXIT
.s 1;	SIMDDT ACTION: Returns control to SIMRTS which closes the SYSIN and SYSOUT files
	and then returns to the monitor. 
.test page 5
.s 2;
.index ^^HELP, SIMDDT command
	HELP
.s 1;	SIMDDT ACTION: Lists part of the SIMDDT.HLP file.
.s 2
.IN DDTHLP
.p 0,4,19
.s 2;
.indent -5
.index  ^^SIMDDT command examples
.index  ^^examples of SIMDDT commands
9.3.3 Command examples
.ELSE DDTHLP
2.3 Command examples
.EI DDTHLP
.s 2;
	STOP AT 55,3
.s 1;
	EXPLANATION: Set a breakpoint at first statement on line 55 and
	stop processing every third time the statement is executed so that
	the user can communicate with SIMDDT.
.s 1;	AT MAIN:30 "LIST" VINT[1,3], VREF.VBOOL
.s 1;	EXPLANATION: Output the  values of the variables
	VINT[1,3] and VREF.VBOOL each time the first statement on line 30 
	in the main program is to be executed. The message will contain the
	letters "LIST".
.s 1;	AT 10 IFCHANGED VREAL,VTEXT
.s 1;	EXPLANATION: Output the variable value if any of the variables were
	changed since the last time the statement at line 10 was to be
	executed.
.s 1;	STOP AT 80 IF VREAL>=1.5
.s 1;	EXPLANATION: Stop execution at the statement on line 80 if
	the variable VREAL>=1.5
.s 1;   STOP AT 80 IF BOOL EQV TRUE
.s 1;   EXPLANATION: SIMDDT does not understand "STOP AT 80 IF BOOL"
        but the above statement works and gives the desired effect.
        In the same way, write "BOOL EQV FALSE" to give the effect
        of "NOT BOOL".
.IN DDTHLP
.s 1;	OUTPUT VREF.VINTARRAY,VREALA[-1,7,7],VCHAR
.s 1;	EXPLANATION: Output all elements of the array VREF.VINTARRAY which
	are not zero, output the array element VREALA[-1,7,7] and the
	variable VCHAR.
.EI DDTHLP
.s 1;	INPUT VTEXT:="TEXT VALUE ASSIGNMENT"
.s 1;	EXPLANATION: Change the value of the text variable. Note that only the
	characters may be changed, but not the length.
.s 1;	USE DEBFIL.LPT
.s 1;	EXPLANATION: SIMDDT output will be written on file DEBFIL.LPT.
	Output in connection with a breakpoint stop will also
	appear on the user TTY.
.s 1;	DISPLAY 1:10
.s;	EXPLANATION: Output the source program lines 1 to 10.
.s;	DISPLAY ,5
.s;	EXPLANATION: Output the next 5 lines of the program.
.s;	DISPLAY
.s;	EXPLANATION: Output the next 10 lines (== DISPLAY .,10).
.s 2
.IN DDTHLP
Appendix H.9 contains additional SIMDDT examples.
.EI DDTHLP
.IF DDTHLP
.s 2;
.indent -5
2.4 SIMDDT input and output
.s 1;	The user TTY is normally used for input to SIMDDT . A "*"
	on the terminal signals that SIMDDT is expecting a
	user command.
	The @ command will cause SIMDDT to read its input from the
	indicated file.
.s 1;	The user TTY is used for output from SIMDDT when it is in debug
	mode and no USE command has been given.
.s 1;	Both the user TTY and the SYSOUT file are used for output from
	SIMDDT when it is in error mode.The output from the ALL 
	command is only written to SYSOUT but all other output is
	written on both files.
.br;	If an output file is specified with the USE command it
	replaces the SYSOUT file.
.EI DDTHLP
.IF DDTHLP
.s 2;.center
[END OF SIMDDT.HLP]
.EI DDTHLP
.subtitle ^^Chapter 10 PROGRAMMING CONSIDERATIONS
.nojustify
.spacing 1
.page
.left margin 5
.indent -5
10.##PROGRAMMING CONSIDERATIONS
.break
.indent -5
#####==========================
.skip 1
.indent -5
10.1#WRITING EFFICIENT PROGRAMS
.skip 2
.index ^^Efficient program writing
.index ^^Optimization of programs
This section contains some hints on how to write efficient programs in SIMULA.
.index ^^Structured programming
Unless very high efficiency is required, however, good structuring
and readability should always have the highest priority.
If the program is to be run at other installations, portability considerations
are also important. See 10.2.
.skip 1
A programmer who writes less well structured programs to gain
efficiency will often find that he did not gain the efficiency
he intended.
The initial version may be efficient, but due to the bad structure, later
changes and additions will be harder to make, and as a result the end
product may be less efficient and probably less reliable than if
the program had been well structured at the outset.
.skip 1
If you desire efficiency, your efforts towards this goal should
be guided by knowledge about which parts of your programs are
expensive. Use of performance measurements programs such as
that described in appendix J may be a good aid towards gaining
this knowledge. When you know which parts of
your programs consume the most cpu time, core or other
expensive resources, you will know where to apply
rewriting or MACRO 10 procedures to minimize use of these resources.
.skip 1
The following hints are not ordered by importance:
.skip 1
.test page 4
.index ^^Warning messages from the compiler
#-> Do not ignore warning messages issued by the compiler. Often, these
messages point to possibly inefficient or dangerous coding sequences or
features.
.skip 1
.test page 4
#-> Avoid unnecessary type conversions by declaring variables
with appropriate types, and by avoiding mixed type expressions.
Note that the precision of certain arithmetic functions is governed
by the precision of the argument, i.e.#LONG REAL arguments cause the LONG REAL
version to be called. This may be inefficient in some cases where the
greater precision is not necessary.
.skip 1
.test page 6
#-> In connection with the above, note also that the de-editing procedures
GETREAL and INREAL always give LONG REAL results.
Copy the result to a REAL variable before using it in a REAL expression,
if you want to avoid unnecessary conversions.
.skip 1
.index ^^Standard functions
.index ^^GETREAL precision
.index ^^INREAL precision
.index ^^FOR statements, efficiency considerations
.index ^^WHILE statements, efficiency considerations
.test page 4
#-> In FOR statements, the STEP and UNTIL elements should be
constants or simple variables. Usually you do not want re-evaluation of
these at every loop iteration.
Avoid function designators, formal parameters
by name, subscripted variables, variables of different type from the controlled
variable, and general expressions. The fastest loop is one
with step +1 or -1 and  a limit which is a simple constant or variable.
Use the WHILE statement where the full generality of the FOR statement
is not needed.
.skip 1
.test page 4
#-> In most cases, it is best to avoid
.index ^^Procedure parameter transmission efficiency
.index ^^Parameter transmission efficiency
transmitting parameters by name if value
or reference mode can be used.
One case where name parameters may be necessary is when the values
of some parameters are to be modified by a procedure.
In this case, it often pays
to copy the value on entry and copy the modified value back on return.
Access to simple variables corresponding to formal parameters by name
is optimized, but it is still slower than accessing a local or global
variable. In this respect, value and reference mode parameters count as local
variables in the procedure.
What is said above does not always apply for text parameters when
you have to choose between name and value mode. One reason for
this is that value transmission of text parameters destroys the
stack nature of the
top of the data area, which makes memory allocation
slower. Another reason is that copying of long texts should be avoided.
See below about "memory allocation for procedures".
.skip 1
.test page 4
#-> Avoid long linear searches through large sets. If possible, use
hash coding or binary tree representations to reduce the search times.
Note that CARDINAL performs a linear search through the whole set on each
.index ^^Cardinal function, efficiency of
call!
.skip 1
.test page 4
.index ^^Inspect statement, efficiency of
#-> If many attributes of a class are to be accessed, use inspection in order to
save some code space and execution time.
As a guideline, use INSPECT when you have more than 4 accesses to attributes
of the same class.
However, program readability may often motivate
deviations from this guideline.
.skip 1;.test page 4
#-> Do not repeat the same information in many blocks. Suppose for
example that you have a large number of instances of the same class,
and some data is repeated in many or all of these instances.
.s;Instead of copying this information in all the
block instances, you may put the information in a separate class
object, with a reference from the partly similar objects to
the single common object.
.skip 1
Example: Suppose that you have 1000 records of people with only
four different work addresses. Instead of including the work
address in each of the 1000 class instances, you can have
just four instances of a class "address", with references
from each of the 1000 records to one of the four "address" instances.
.skip 1
.test page 4
#-> Avoid creating unnecessary blocks. If a new temporary variable is
required, declare it in an existing block rather than converting a
compound statement into a block.
.skip 1
.test page 4
#-> Use EJECT and SPACING instead of outputting blank images on printfiles.
This is faster.
.skip 1
.test page 4
#-> Garbage collection time and the amount of core used is reduced
if care is taken to avoid maintaining
references to space-consuming data structures which are no longer needed.
.index ^^core usage, optimization of
.index ^^garbage collection, optimization of
.index ^^memory allocation, optimization of
.skip 1
Examples:
.skip 1
REF(HEAD) QUEUE; ....building a large queue...
QUEUE:- NONE; Comment when the set is no longer needed, this
may save a lot of core and garbage collection time;
.skip 1
TEXT MANUSCRIPT; ...building a long text string...
MANUSCRIPT:- NOTEXT; Comment saves space when the manuscript is no
longer needed;
.skip 1
BEGIN REAL ARRAY MATRIX[100,100];
.break
_...use of the MATRIX ...
.break
END; Comment saves space when the MATRIX is no longer needed;
.skip 1
.test page 4
#-> Memory allocation for procedures without VALUE-declared TEXT parameters
is especially efficient.
However, this efficiency is lost if the procedure
or any procedure called by it directly or indirectly 
creates new text objects (via COPY, BLANKS, INTEXT) or class instances (NEW)
or CALLs a detached CLASS instance.
.p 0,1,4;#-> Do not use INTEXT unnecessarily. It creates a new text
object (see above) and can usually be replaced by a suitable subtext
of Image, but be careful not to use Inimage directly or indirectly
before you have handled that subtext completely. You may e.g_. use
text assignment: T:=Sysin.Image.Sub(Sysin.Pos,10) might replace
T:- Intext(10) if T is preallocated e.g_. via Blanks(10).
T can be reused.
.p 0,1,4;#-> Use built-in system procedures and classes
where these suit your needs. They are often considerably faster than a
corresponding SIMULA procedure or even corresponding in-line code.
.skip 1
Example I: "WHILE mytext.more DO" is faster than
"n:= mytext.length; FOR i:= 1 STEP 1 UNTIL n DO".
.skip 1
Example II: The built-in procedures LETTER and DIGIT provide a faster way
of checking if a character is a letter or digit than using RANK and
checking the integer values yourself. Your program will also become less
machine-dependent if you use LETTER and DIGIT.
.skip 1
.test page 4
#-> If you use DIRECTFILE, try to organize your programs to minimize
the number of reads and writes. This can be done by using hash-coding,
keeping central tables in core, etc.
.skip 1;.test page 4
#-> If you have to choose from a number of alternatives, depending
on the value of a variable, then a series of IF ... THEN ...
ELSE statements is more efficient than a SWITCH, when the
number of alternatives is less than 50. When the number of alternatives
is larger than 50, a nested IF ... THEN BEGIN IF ... THEN ... ELSE ...
END ELSE structure is still more efficient, though less neat, than
use of a SWITCH.
.skip 1
.test page 4
#-> If a program has been carefully tested both by the programmer
and in production work, you may, if you dare,
consider to set off some of
the built-in debugging aids, to save core and cpu time.
The following switches can be used (should be given in the COMPILE (EXECUTE etc.) command):
.skip 1
-A##removes array bounds checking for arrays. May save cpu time.
.break
-Q##removes qualification checking of reference assignments.
May save cpu time.
.break
-I##removes the generation of line number tables for SIMDDT. Saves core.
.break
-D##removes the generation of symbol tables for SIMDDT. Saves core.
.skip 2
.indent -5
10.2#WRITING PORTABLE PROGRAMS
.skip 2
.index ^^Transportability of programs to other computers
.index ^^Compatibility of programs to other computers
.index ^^Portability of programs to other computers
 Even if you do not now plan
to move a program to another SIMULA system, such a need may arise in
the future.
If portability is desirable,
deviations from the Common Base language [1] should be kept at a minimum, or at
least be very clearly commented and set aside from the rest of the code.
If external assembly or FORTRAN procedures are used, a SIMULA version should
if possible be available for each of these in case of a move to a different
installation.
.skip 1
The following constructs of DECsystem-10 SIMULA should be avoided if you
want portable programs:
.skip 2
.test page 4
#-> Any input procedure which is dependent on the line length of the
input file. Especially avoid input procedures requiring input lines
longer than 72 or 80 characters.
.skip 1;.test page 4
#-> Changing the length of the image of a file after opening the
file, especially letting the image be == NOTEXT.
.skip 1
.test page 4
#-> Use of multi-line text constants.
.index ^^text constants, multi-line
.skip 1
.test page 4
#-> Any output procedure which writes disk files with lines longer
than 72 or 80 characters (132 characters for printfiles).
.skip 1
.test page 4
#-> Any use of the following Swedish characters in source program
identifiers:
$, _#, @, }, {, `. These characters may however occur in TEXT
and CHARACTER constants.
.skip 1
.test page 4
#-> Use of non-decimal constants.
.skip 1
.test page 4
#-> Use of lower case letters.
.skip 1
#-> Use of the characters whose decimal value is less than 32 and the characters:
.break
####!, [, ], _^, ~, | \.
.break
Use alternative representations as follows:
NE for _\=, NOT for _\, COMMENT for !, () for [], ** for _^.
.skip 1;.test page 3
->#Use of TEXT constants in IF-clauses, e.g.
"Outtext(IF#bool#THEN#"yes"#ELSE#"no");"
.skip;.test page 4
#-> With DIRECTFILE, use of the procedure ENDFILE, reading of
unwritten lines, writing past the end of the file.
.p 0,2,6
Most of the external library procedures in chapters 4 and 7 of the
DECsystem-10 Simula Language Handbook part III will give portability
problems.
.p 0,1,3
Some of the incompatibilities mentioned above will be removed
automatically from your source programs if you convert them to
IBM SIMULA using the SIMIBM program described in appendix M
of this handbook.
.left margin 5
.p -5,2,10
10.3 WRITING VERY LARGE PROGRAMS
.p 0,2,2
When you begin writing a program which may in the end be larger than
1000 or 2000 lines, you can save much trouble by planning the
program carefully before starting to program.
.p 0,1,5
To save compilation time when the program grows large, it is
advisable to divide the program into separately compiled modules.
This division must be planned BEFORE starting to write the program.
When a program already has grown large, it is often difficult
or impossible to find a workable such structuring.
.p 0,1,5
The best way to divide a program into separately compiled modules
is usually to divide it into a not too large number of rather
large (about 500 lines) separately compiled classes.
.p
Take advantage of the SIMULA feature that one class may extend the
concepts defined in a prefixing class, and that the main
program may combine the facilities of several such
separately compiled classes or class chains.
.p;.test page 7
Example: Your program may be divided into the following
modules:
.nofill;.break
1) Analyzing user input commands
2) Interpreting formulas input by the user
3) Handling help requests from the user
4) Processing of the data base
.p;.fill;.test page 10
If none of these four modules use data or procedures
from another module, you can write the four modules as
four independent separately compiled classes, all
accessible only from the main program:
.p;.nofill
Command    Formula           Help request    Data base
analysis   interpretation    handling        handling
     !            !            !               !
     --------------Main program-----------------
.p;.fill;.test page 18
If, however, the module "Formula interpretation uses
facilities defined in the module "Command analysis", the
following structure may be appropriate:
.p;.nofill
Command
analysis
   !
Formula            Help request     Data base
interpretation     handling         handling
   !                  !                !
   -------------Main program------------
.p;.fill
This has the disadvantage that changes in the data
definitions in "command analysis" may force recompilation
of "Formula interpretation", but the advantage that
"Formula interpretation" has access to the data
structures and operations defined in "Command analysis".
.p;.test page 19
Suppose now that "Data base handling" can be divided into
two modules, "Reading records" and "Handling records".
Both these modules require access to the data structure
definitions used to represent "records" in core.
.p
One solution is then to make one of these two a subclass
to the other:
.p;.nofill
                                    Defining
                                    records
                                       !
Command                             Reading
analysis                            records
   !                                   !
Formula            Help request     Handling
interpretation     handling         records
   !                  !                !
   -------------Main program------------
.p;.fill;.test page 18
Another solution is to make "reading records" and
"handling records" two parallel subclasses to "Defining
records":
.p;.nofill
Command                              Defining
analysis                             records
   !                                 !     !
Formula          Help request   Reading   Handling
interpretation   handling       records   records
   !                   !          !         !
   --------------------Main program----------
.p;.fill
The latter solution has the advantage that no changes in
"reading records" can cause recompilation of "handling
records", but the disadvantage that "defining records"
becomes more limited. It works best if "defining records"
is a class with no internal class definitions in it.
.p
In some cases, the only solution for you is to structure your
program as a long chain of separately compiled classes,
each a subclass to the previous one. This is the only
solution for code which has to be inside "SIMSET" or
"SIMULATION". The disadvantage with this solution is
that a change in the data definitions in the outermost
class may force recompilation of the whole chain.
.p -5,2,13
10.4#MISCELLANEOUS ADVICE
.skip 2
.test page 4
#-> Use BREAKOUTIMAGE when communicating with a conversational
display terminal.
This permits the prompting question and the answer
to be written on the same line.
Example: outtext("Enter t:"); breakoutimage; lastitem;
t:-copy(sysin.image.sub(sysin.pos,...)); sysin.setpos(0).
.index ^^Display terminals, how to avoid automatic eject
.skip 1
.test page 4
#-> If the output from a program is directed to a conversational terminal
(e.g.#the user's tty),
it may be inconvenient, especially with display terminals, to get the automatic
new page after every 60
lines. This can be circumvented by using an outfile instead of a printfile, or
by coding LINESPERPAGE(-1)  in your program. LINESPERPAGE(-1) effectively
sets the page size to infinity.
.skip 1
.subtitle APPENDIX A   HARDWARE REPRESENTATION
.paper size 55,65
.page
.left margin 5
.indent -5
.index ^^Hardware representation
.index ^^Representation in hardware
.index ^^Compiler input
.index ^^Input to the compiler
APPENDIX A###HARDWARE REPRESENTATION
.break
.indent -5
====================================
.break
.skip 2
.indent -5
A.1##SIMULA COMPILER INPUT.
.index ^^Program, source, input to the compiler
.index ^^Program input to the compiler
.index ^^Input to the compiler
.index ^^Source program input to the compiler
.break
.skip 1
A DECsystem-10 SIMULA program is a sequence of symbols from the
DECsystem-10 character set (ASCII 7 bit code) placed on a disk file
(i.e. an ordered set of data on a disk like device). The data on the
file is separated into lines. A line is delimited by a vertical
tab (VT), line feed (LF) or form feed (FF) character. The maximum length
of a line is 135 characters.
.skip 1
A SIMULA program consists of a sequence of basic symbols, identifiers,
constants, comments and line editing characters. The rules for
these are given below.
.skip 3
.indent -5
.index ^^Programs on cards
.index ^^Card input to the compiler
A.2##SIMULA PROGRAMS ON CARDS.
.skip 1
Existing SIMULA programs with card characteristics, 80 characters per card
with columns 73-80 for identification or sequence numbers can easily be processed
by using either (i) the batch switch WIDTH or (ii) the PIP command switch
E or (iii) the IBMSIM or CDCSIM program described in appendix M to remove
columns 73-80. The IBMSIM and CDCSIM program will also convert the character
representation from IBM SIMULA or CDC SIMULA to DECsystem 10 SIMULA.
.skip 3
.indent -5
.index ^^Line numbers in input files
A.3##STANDARD LINE SEQUENCE NUMBERS.
.index ^^Numbered lines in source programs
.skip 1
The rules for standard sequence numbers are specified in the LINED reference
manual paragraph 7.0. Those characters that belong to the sequence number
(i.e. padding NULL characters, the number itself and a trailing tab
character) are not considered part of the input SIMULA program. However they
will appear in the program listing and they are put in the line
number table so that SIMDDT can use them. If no line numbers appear in
the source code the SIMULA compiler will supply its own line numbers.
The handling of programs with partly numerical, partly blank
line numbers is described in appendix K.
.page
.nofill
.left margin 0
.tab stops 11,26,41,55
.index ^^Special character representation
.index ^^Character representation of special characters
.index ^^Representation of special characters
.index ^^Character representation
Reference	DEC 10 SIMULA	Alternative	ASCII 7 bit	Comments
language	representation	representation	octal code
-----------------------------------------------------------------
.left margin 3
.tab stops 15,30,41,49
+	+		053
-	-		055
x	*		052
/	/		057
.indent -3
"int. div."	//		057 057
_^	_^	**	136
>	>	GT	076
.indent -3
"> or ="	>=	GE	076 075
<	<	LT	074
.indent -3
"< or ="	<=	LE	074 075
=	=	EQ	075
.indent -3
"not ="	NE	_\=	(134 075)
==	==		075 075
=/=	=/=		075 057 075
_.	.		056
,	,		054
:	:		072
;	;		073
.indent -3
"lowered ten"	_&	_&_&	046	Lowered ten symbol
				_& in real
				constants
				_&_& in long real
(	(		050
)	)		051
[	[	(	133
]	]	)	135
:=	:=		072 075
:-	:-		072 055
'	'		047	Character quote
"	"		042	Text quote
.indent -3
"not"	NOT	_\	(134)
.indent -3
"space"	<space>		040
.indent -3
"log. OR "	OR
.indent -3
"log. AND"	AND
.indent -3
"log. IMP"	IMP
.indent -3
"log. EQV"	EQV
.indent -3
COMMENT	COMMENT	!	041	! is comment
				symbol in
				DEC 10 ALGOL
				and FORTRAN but
				not in standard
				SIMULA

.indent -3
-----------------------------------------------------------------
.skip 1
Table A.1###Special character representation in DEC 10 SIMULA.
.break
	Non-printable reference language symbols
	are enclosed in double quotes.
.tab stops 1
.page

.fill
.left margin 5
.indent -5
.index ^^Basic symbols
A.4##BASIC SYMBOLS.
.index ^^Operator words
.index ^^Keywords
.skip 1
A basic symbol is represented as a keyword, a special character or a
sequence of special characters. The keywords are the standard SIMULA words
plus GO, LONG, OPTIONS, SHORT, TO and the words listed in the
table A.1 above (See Appendix G.).
A lower case letter can always be used instead of the corresponding upper
case letter.
.skip 3
.indent -5
.index ^^Identifier representation
.index ^^Representation of identifiers
.index ^^Lower case letters
A.5##IDENTIFIERS.
.skip 1
The first character in an identifier must be a letter. The following
characters must be letters, digits or underline characters. A lower case letter can always be used instead
of the corresponding upper case letter. The first 12 characters in an 
identifier are significant.
An identifier must not be a keyword (See Appendix G). The character
<underline> or <left arrow> (octal code 137) is accepted in identifiers
but not as the first caracter. Embedded blanks are not accepted.
.skip 3
.indent -5
.index ^^Constants in source programs
A.6##CONSTANTS.
.skip 1
.indent -5
.index ^^Arithmetic constants in source programs
A.6.1##Arithmetic constants.
.skip 1
.index ^^Integer constants
Integer constants consist of a number of decimal digits.
If an integer constant is out of integer range it is regarded as a
real constant. The integer range is 1 - 2_^35 to 2_^35 - 1.
.break
( 2_^35 = 34 359 738 368 ).
.break
.index ^^Radix constants
An integer constant can be written in a different radix as follows:
.break
nRd
.break
where n is 2, 4, 8 or 16 and d represents a string of
digits acceptable in the corresponding radix. E.g. octal number 7711
is written 8R7711 and binary 10 is written 2R10.
.skip 1
.index ^^Real constants
.index ^^Lowered ten symbol
Real constants consist of a decimal number (containing either an integral
part or a fractional part or both) followed by an optional exponent.
The fractional part has a range in magnitude of 1/2 to (1 - 2_^-27) with
a precision of approximately 8 decimal digits.
The exponent consists of the lowered ten symbol _& followed by an optionally signed
integer. The exponent range is -128 to 127 inclusive.
E.g. 0.000000000123 could be written 1.23_&-10.
Assuming positive numbers,
the smallest real number distinct from zero is 0.146#936#793#852#785#939_&_&-38,
and the greatest number is 0.170#141#183#460#469#231_&_&+39.
Since the sign is treated separately, these limits are valid for negative
numbers if the sign is changed.
.skip 1
.index ^^Long real constants
Long real constants must contain the exponent part with the lowered ten symbol 
_&_&. The exponent range is the same as for real constants.
The fractional part has a range in magnitude of 1/2 to (1 - 2_^-62)
with a precision of approximately 19 decimal digits. 
Long real constants should be used only if a precision greater than
8 decimal digits is needed. E.g. 3.1415926535898 is written 
3.1415926535898_&_&0 to be represented in double precision.
.skip 3
.indent -5
.index ^^Boolean constants
A.6.2##Boolean constants.
.skip 1
Boolean constants are the SIMULA words TRUE and FALSE.
.skip 3
.indent -5
.index ^^Character constants
A.6.3##Character constants.
.skip 1
A character constant is any single printable character from the ASCII set,
octal code 040-176, enclosed by the symbol ' (octal code 047).
Other ASCII character values can be entered with the CHAR
procedure, e.g. CHAR(9) for <TAB>.
.skip 3
.indent -5
.index ^^Text constants
A.6.4##Text constants.
.skip 1
A text constant is represented by one or more sequences of printable
ASCII characters, octal code 040-176, enclosed in double quote symbols " (octal code 042). The sequences may be separated by any number of blanks, tabs
or line control characters (VT, CR, LF, FF). Together, the sequences
form one text constant which is the concatenated contents of the
character sequences. The double
quote symbol in a text constant is written as two consecutive 
double quote symbols. The line delimiting characters VT, CR, LF
and FF are accepted but not treated as part of the text constant.
Other ASCII character values can be entered with a combination of the
PUTCHAR and CHAR procedures.
.skip 3
.indent -5
.index ^^Comment in source programs
A.7##COMMENTS.
.skip 1
A comment consists of the basic symbol COMMENT followed by a nonalphameric
character and the successive characters up to and including the next semicolon.
The symbol COMMENT may be replaced by the character ! (octal code 041).
All printable characters plus the line editing characters are allowed in 
comments.
.skip 1
.index ^^END comments in source programs
An END comment is the string of characters following the 
basic symbol END up to but not including the next semicolon, END, ELSE, WHEN or OTHERWISE.
.skip 1
Comments and END comments are printed in the program listing, but they
are not further processed by the compiler.
.skip 1
.index ^^END comment warnings
A warning message is issued if an END comment contains the basic symbols
":=" , ":-" , "(" or "GOTO".
.skip 3
.indent -5
.index ^^Spaces in source programs
.index ^^Line editing characters in source programs
.index ^^Editing characters in source programs
A.8##USE OF SPACES AND LINE EDITING CHARACTERS.
.skip 1
A basic symbol, identifier or constant must not contain line editing characters
or non-significant spaces.
.break
Exceptions are:
.break
1)#GOTO can be written with or without spaces and
.break
###line editing characters between GO and TO.
.break
2)#Arithmetic constants may contain spaces.
.break
.skip 1
Adjacent identifiers or basic symbols represented by keywords must
be separated by one or more spaces and/or line editing characters.
The same rule applies to a keyword followed or preceded by a number
constant. Any basic symbol, identifier or constant must be
contained in one line. A text constant may, however,
continue over several lines. This is best achieved by splitting the constant into several parts, e g
.break
####t:-copy("first part of text "
.break
############"second part of text");
.tab stops 5,13,21,29,37,45,53,61
.subtitle APPENDIX B###INTERNAL REPRESENTATION
.page
.indent -5
.index ^^Internal representation
APPENDIX B###INTERNAL REPRESENTATION
.indent -5
====================================
.skip 3
The DECsystem-10 SIMULA Technical Documentation [6] should be
consulted when the information in this appendix is insufficient.
.skip 3
.indent -5
B.1##REPRESENTATION OF VARIABLES
.skip 2
.index ^^Integer variables, internal representation
INTEGER
.break
-------
.skip 1
One word. Twos complement fixed point hardware format.
.skip 2
.index ^^Short integer variables, internal representation
SHORT INTEGER
.break
-------------
.skip 1
Treated as INTEGER.
.skip 2
.index ^^Real variables, internal representation
REAL
.break
----
.skip 1
One word. Single precision floating point hardware format.
.skip 2
.index ^^Long real variables, internal representation
LONG REAL
.break
---------
.skip 1
Two words. Double precision floating point hardware format.
.skip 2
.index ^^Character variables, internal representation
CHARACTER
.break
---------
.skip 1
One word. The rightmost 7 bits contain the character. The rest
of the word is zero.
.skip 2
.index ^^Boolean variables, internal representation
BOOLEAN
.break
-------
.skip 1
One word. TRUE is represented by -1.
Any other non-zero value will also be interpreted as TRUE.
FALSE is represented by 0.
.skip 2
.index ^^Reference variables, internal representation
.index ^^NONE, internal representation
REF
.break
---
.skip 1
One word. Left halfword is zero. Right halfword points at an object or is NONE.
NONE is represented by octal  676000 (223K).
.skip 2
.index ^^Text variables, internal representation
TEXT
.break
----
.skip 1
.nofill
Two words.		---------------------
		0	[   SP    I   ZTE   ]
			----------+----------
		1	[   LNG   I   CP    ]
			---------------------
.fill
.skip 1
.left margin 21
.indent -16
SP###0<0:17>	The number of characters before this (sub)text within
the text object.
.indent -16
ZTE##0<18:35>	Pointer to the text record.
.indent -16
LNG##1<0:17>	Length of TEXT.
.indent -16
CP###1<18:35>	Current position in text (= POS-1)
.skip 1
.indent -16
.index ^^Text record, internal representation
Text record:
.nofill
	---------------------
0	[     Overhead      ]
	----------+----------
1	[   CLN   I   LEN   ]
	----------+----------
2	[    Characters     ]
	.    of text        .
	[		    ]
	---------------------
.skip 1
.fill
.indent -16
Overhead	One word with information and workspace for
the garbage collector.
.indent -16
CLN##1<0:17>	Number of characters in text as given in parameter
to BLANKS or COPY.
.indent -16
LEN##1<18:35>	The length of the record in words
.left margin 5
.page
.index ^^Array variables, internal representation
ARRAY
.break
-----
.skip 1
One word. Left halfword is zero. Right halfword
points to an array record.
.skip 1
.index ^^Array record, internal representation
Array record:
.nofill
.left margin 21
	---------------------------------
0	[	    Overhead		]
	----------------+----------------
1	[		I      LEN	]
	----------------+----------------
2	[	       BAD		]
	--------+-------+----------------
3	[  TYP  I  SUB  I      ZPR	]
	--------+-------+----------------
4	[	      LOW(1)		]
	---------------------------------
5	[	      UPP(1)		]
	.				.
2n+2	[	      LOW(n)		]
	---------------------------------
2n+3	[	      UPP(n)		]
	---------------------------------
2n+4	[	      DOP(2)		]
	.				.
3n+2	[	      DOP(n)		]
	---------------------------------
3n+3	[				]
	.	Array  elements		.
	[				]
	---------------------------------
.skip 1
.fill
.indent -16
Overhead	One word with information and workspace for
the garbage collector.
.indent -16
LEN##1<18:35>	Total length of array record.
.indent -16
BAD##2<0:35>	Address of the (possibly fictive) array
element with all subscripts zero.
.indent -16
TYP##3<0:8>	Type of the elements in the array.
.indent -16
SUB##3<9:17>	Number of subscripts.
.indent -16
ZPR##3<18:35>	Qualification prototype pointer if REF array.
.indent -16
LOW[1:SUB]	Lower subscript bounds.
.indent -16
UPP[1:SUB]	Upper subscript bounds.
.indent -16
DOP[2:SUB]	Dope vector.
.left margin 5
.page
.index ^^Dynamic addresses, internal representation
.indent -5
B.2	REPRESENTATION OF DYNAMIC ADDRESSES
.skip 2
DYNAMIC ADDRESS OF VALUE TYPE VARIABLE
.skip 1
.nofill
.left margin 21
	----------------+----------------
	[      OFS	I      ZBI	]
	----------------+----------------
.skip 1
.indent -8
OFS	Offset of variable in block instance.
.indent -8
ZBI	Block instance address.
.skip 2
.indent -16
DYNAMIC ADDRESS OF SWITCH
.skip 1
	----------------+----------------
	[      ZSR	I      ZBI	]
	----------------+----------------
.skip 1
.indent -8
ZSR	Switch record address.
.indent -8
ZBI	Block instance address (static environment).
.skip 2
.indent -16
DYNAMIC ADDRESS OF LABEL
.skip 1
	----------------+----------------
	[      CAD	I      ZBI	]
	----------------+----------------
	[      EBL	I      BNM	]
	----------------+----------------
.skip 1
.indent -8
CAD	Code address.
.indent -8
ZBI	Block instance address.
.indent -8
EBL	Effective block level.
.indent -8
BNM	State (block number).
.skip 2
.indent -16
DYNAMIC ADDRESS OF ARRAY
.skip
	---------------------------------
	[	       ZAR		]
	---------------------------------
.skip
.indent -8
ZAR	Address of array record.
.page
.indent -16
DYNAMIC ADDRESS OF REF ARRAY
.skip 
	---------------------------------
	[	       ZAR		]
	---------------------------------
	[	       ZPR		]
	---------------------------------
.skip
.indent -8
ZAR	Address of array record.
.indent -8
ZPR	Qualification prototype address.
.skip 2
.indent -16
DYNAMIC ADDRESS OF REF VARIABLE
.skip
	----------------+----------------
	[      OFS	I      ZBI	]
	----------------+----------------
	[	       ZPR		]
	---------------------------------
.skip
.indent -8
OFS	Offset in block instance.
.indent -8
ZBI	Block instance
.indent -8
ZPR	Qualification prototype address.
.skip 2
.indent -16
DYNAMIC ADDRESS OF PROCEDURE
.skip
	----------------+----------------
	[      ZPR	I      ZBI	]
	----------------+----------------
	[		I      EBI	]
	----------------+----------------
.skip
.indent -8
ZPR	Procedure prototype address.
.indent -8
ZBI	Enclosing "complete" block (with display).
.indent -8
EBI	Innermost enclosing block.
.left margin 5
.fill
.page
.index ^^Parameters, internal representation
.indent -5
B.3	REPRESENTATION OF PARAMETERS
.skip 2
VALUE TYPE (integer, (long)real, boolean or character) CALLED BY VALUE.
.break
OBJECT REF CALLED BY REFERENCE.
.break
TEXT OR ANY TYPE OF ARRAY CALLED BY VALUE OR REFERENCE.
.skip
They have the same representation as the corresponding variables.
.skip 2
LABEL,SWITCH AND PROCEDURE CALLED BY REFERENCE
.skip
They are represented by their dynamic addresses.
.skip 2
ALL PARAMETERS CALLED BY NAME
.skip
Parameters called by name are represented by a
double-word descriptor with the following fields:
.skip
.left margin 21
.indent -16
NTH##0<0>	This field is =1 if no thunk exists, i.e. if
all information about the actual parameter is contained in the descriptor.
.indent -16
ATP##0<1:5>	Type code for actual parameter.
.indent -16
DTP##0<6:8>	Type of descriptor and thunk.
.break
VALUE	EXPLANATION
.left margin 25
.indent -4
0###Actual parameter is a simple variable. Its address is obtained by adding
ZBI and ADR.
.indent -4
1###Not used.
.indent -4
2###Not used.
.indent -4
3###The thunk will yield a dynamic address.
.indent -4
4###ADR is the address of a constant actual parameter.
.indent -4
5###Not used.
.indent -4
6###Not used.
.indent -4
7###The thunk yields the value of an expression.
.left margin 21
.indent -16
AKD##0<9:11>	Gives the kind of the actual parameter.
.indent -16
CNV##0<13>	Set to 1 if parameter conversion is necessary. i.e.
the type of the formal parameter and the actual parameter are not the same.
.indent -16
FTP##0<14;17>	Type code for formal parameter.
.page
.indent -16
ZBI##0<18:35>	Address of block instance where actual parameter exists or
address of nearest block instance (with display) to be used when
evaluating the thunk.
.indent -16
ZQU##1<0:17>	Qualifying prototype for actual parameter of type REF.
.indent -16
ADR##1<18:35>	If NTH is zero this is the address of the thunk.
Otherwise the interpretation of this field depends on the value of DTP as follows:
.break
DTP=0	Offset of variable in its block.
.break
DTP=4	Address of a constant.
.break
.left margin 5
.skip 4
.index ^^Dynamic records, internal representation
.indent -5
B.4	DYNAMIC RECORDS
.left margin 21
.skip 2
.indent -16
.index ^^Display record, internal representation
DISPLAY RECORD
.skip
.nofill
	---------------------------------
	[	    Overhead		]
	----------------+----------------
-n-2	[      ZAC	I      LEN	]
	---------------------------------
-n-1	[	     ZPB(n)		]
	.				.
-2	[	     ZPB(1)		]
	----------------+----------------
-1	[      ZBI	I      ARE	]
	----------------+----------------
.fill
.skip
.indent -8
Overhead One word with information and workspace
for the garbage collector.
.indent -8
ZAC	Pointer to an accumulator stack record if present.
.indent -8
LEN	Length of the display record.
.indent -8
ZPB[1:n] Display vector
.indent -8
ZBI	Normally the block instance which was active when
this display record was created.
.indent -8
ARE	Reactivation address of the block to which this display belongs.
.page
.indent -16
.index ^^Block instance, internal representation
BLOCK INSTANCE HEADER
.skip
.nofill
	---------------------------------
0	[	    Overhead		]
	----------------+----------------
1	[      BNM	I      ZPR	]
	----------------+----------------
.skip
.fill
.indent -8
Overhead One word with information and workspace for the garbage collector.
.indent -8
BNM	State of block instance (i.e. the
number of the subblock currently active).
.indent -8
ZPR	Prototype address
.skip 2
.indent -16
.index ^^Unreduced subblock, internal representation
UNREDUCED SUBBLOCK RECORD
.skip
.nofill
	---------------------------------
0	[				]
	.     block instance header	.
1	[				]
	---------------------------------
2	[				]
	.     variables in subblock	.
	[				]
	---------------------------------
.indent -16
.index ^^Procedure instance, internal representation
PROCEDURE INSTANCE
.skip
	---------------------------------
	[				]
	.	display record		.
-1	[				]
	---------------------------------
0	[				]
	.     block instance header	.
1	[				]
	---------------------------------
2	[				]
	.      formal parameters	.
	[				]
	---------------------------------
	[				]
	.    variables of procedure	.
	[				]
	---------------------------------
.page
.indent -16
.index ^^Function designator instance, internal representation
FUNCTION DESIGNATOR INSTANCE
.skip
	---------------------------------
	[				]
	.	 display record		.
-1	[				]
	---------------------------------
0	[				]
	.     block instance header	.
1	[				]
	---------------------------------
2	[	value of function	]
	.				.
	[       formal parameters	]
	---------------------------------
	[				]
	.     variables of function	.
	[				]
	---------------------------------
.skip 2
.indent -16
.index ^^Class instance, internal representation
CLASS INSTANCE
.skip
	---------------------------------
	[				]
	.	  display record	.
-1	[				]
	---------------------------------
0	[				]
	.     block instance header	.
1	[				]
	---------------------------------
2	[				]
	.	formal parameters	.
	[				]
	---------------------------------
	[				]
	.	   attributes		.
	[				]
	---------------------------------
.page
.indent -16
.index ^^Subclass instance, internal representation
SUBCLASS INSTANCE
.skip
	---------------------------------
	[				]
	.     prefix class instance	.
	[				]
	---------------------------------
	[				]
	.	formal parameters	.
	[				]
	---------------------------------
	[				]
	.	    attributes		.
	[				]
	---------------------------------
.skip 2
.indent -16
.index ^^Prefix block instance, internal representation
PREFIX BLOCK INSTANCE
.skip
	---------------------------------
	[				]
	.     prefix class instance	.
	[				]
	---------------------------------
	[				]
	.      variables of block	.
	[				]
	---------------------------------
.fill
.left margin 5
.skip 3
.left margin 21
.indent -16
.index ^^Eventnotice record, internal representation
EVENTNOTICE RECORD
.skip
.nofill
	---------------------------------
0	[	    Overhead		]
	----------------+----------------
1	[		I	LEN	]
	----------------+----------------
2	[	ZEV	I	ZER	]
	----------------+----------------
	[				]
	.	Eventnotices		.
	[				]
	---------------------------------
.fill
.skip
.indent -8
Overhead One word with information and workspace
for the garbage collector.
.indent -8
LEN	Length of the eventnotice rcord.
.indent -8
ZEV	Eventnotice free chain start.
.indent -8
ZER	Chain of eventnotice records.
.skip 3
.indent -16
.index ^^Eventnotice, internal representation
EVENTNOTICE
.nofill
.skip
	----------------+----------------
0	[	ZBL	I	ZPS	]
	----------------+----------------
1	[	ZLL	I	ZRL	]
	----------------+----------------
2	[	ZER	I	ZCH	]
	----------------+----------------
3	[	       TIM		]
	---------------------------------
.skip
.fill
.indent -8
ZBL	Backward link.
.indent -8
ZPS	Process pointer.
.indent -8
ZLL	Left link.
.indent -8
ZRL	Right link.
.indent -8
ZER	Base pointer (enclosing eventnotice record).
.indent	-8
ZCH	Free list pointer.
.indent -8
TIM	Scheduled time.
.skip 3
.indent -16
.nofill
.index ^^Simulation block, internal representation
SIMULATION BLOCK
.skip
	---------------------------------
0	[				]
	.	block instance header	.
1	[				]
	----------------+----------------
2	[	FT	I	LT	]
	----------------+----------------
3	[	LNK	I	ZER	]
	----------------+----------------
4	[	       ZPS		]
	---------------------------------
.skip
.fill
.indent -8
FT	First eventnotice in SQS.
.indent -8
LT	Last eventnotice in SQS and root of binary tree.
.indent -8
LNK	Chain of simulation blocks. Used by garbage collector.
.indent -8
ZER	Chain of eventnotice records.
.indent -8
ZPS	Ref(PROCESS) main program.
.page
.nofill
.indent -16
.index ^^Linkage class, internal representation
LINKAGE
.skip
	---------------------------------
0	[				]
	.	block instance header	.
1	[				]
	----------------+----------------
2	[	SUC	I	PRE	]
	----------------+----------------
.skip
.fill
.indent -8
SUC	SUC link.
.indent -8
PRE	PRED link.
.skip 3
.nofill
.index ^^Process class, internal representation
.indent -16
PROCESS
.skip
	---------------------------------
0	[				]
	.	     linkage		.
2	[				]
	---------------------------------
3	[	       ZEV		]
	---------------------------------
.skip
.fill
.indent -8
ZEV	Eventnotice pointer.
.skip 3
.left margin 5
.index ^^Parameters, internal order
ORDER OF PARAMETERS
.skip
The parameters will appear in the same order as they
are named in the source program.
.skip 2
.index ^^Variables, internal order
.index ^^Attributes, internal order
ORDER OF ATTRIBUTES AND VARIABLES
.skip
The attributes and variables are divided into three groups.
In the first group are all which do not belong to another group.
In the second group are all of type TEXT and kind simple.
In the third group are all of type REF or kind ARRAY.
Within each group the attributes and variables have
the same order as they are declared in the source program.
.tab stops 1
^^
.vr DUMMY,d,e
.IF DUMMY
**The DUMMY switch should not be set when running RUNOFF. Used to enclose
**information required by the SUTERR program, but not to be printed.
.EI DUMMY
.spacing 1
.nojustify
.subtitle APPENDIX C COMPILER DIAGNOSTICS
.lm 5;.rm 65
.page
.p -5,5,10;APPENDIX C##COMPILER DIAGNOSTICS
.p -5,0,01;================================
.s 3;This appendix is divided into two sections. The first section
covers the diagnostic messages associated with commands and switches.
These messages are unnumbered.
.s;The second section contains all source code messages produced by
the compiler.
.p -5,4,6
C.1##COMMAND AND SWITCH MESSAGES
.p -5,4,6
?= OR __ MISSING IN COMMAND
.s
EXPLANATION:##Equal sign or left arrow (=underline) is mandatory in all commands
unless the command consists of only one source file descriptor.
.p -5,2,6
?CAN'T OPEN DISK
.s
EXPLANATION:##OPEN failure when trying to open a disk device.
.s
COMPILER ACTION:##The compiler prints an asterisk and waits for next command.
.p -5,2,6
?COMMAND LINE EXCEEDS 135 CHARACTERS
.s
EXPLANATION:##Overflow in the internal command line buffer.
.s
COMPILER ACTION:##The input buffer is cleared, i.e. all type ahead input
is deleted. The compiler prints an asterisk and waits for next command.
.p -5,2,6
COLON AFTER -E OR nE NOT ALLOWED. LIST IGNORED
.s
COMPILER ACTION:##Switch is processed as /-E or /nE.
.p -5,2,6
COLON AFTER SWITCH switch NOT SUCCEEDED BY QUOTE. COLON IGNORED.
.s
COMPILER ACTION:##The switch is processed as if no colon was present.
.p -5,2,6
?COMMA MISSING IN PPN
.s
USER ACTION:##Retype the command.
.p -5,2,6
EXTERNAL SWITCH ALREADY SPECIFIED. IGNORED
.s
EXPLANATION:##EXTERNAL switch can only be specified once for each compilation.
.p -5,2,6
FINAL QUOTE IN TEXT CONSTANT MISSING. QUOTE ASSUMED
.s
EXPLANATION:##Text constant after colon must be enclosed in quotes.
.p -5,2,6
?HELP FILE NOT FOUND
.s
COMPILER ACTION:##HELP switch ignored.
.p -5,2,6
?ILLEGAL DELIMITER "byte" IN COMMAND
.s
EXPLANATION:##Legal file specification delimiters are comma, equal sign,
left arrow, space, tab and carriage return.
.s
USER ACTION:##Retype command.
.p -5,2,6
INCOMPLETE EXTERNAL LIST
.s
EXPLANATION:##Not valid EXTERNAL list format. See Chapter 3.5.
.p -5,2,6
?INVALID DEVICE. ONLY DSK ALLOWED
.s
EXPLANATION:##Device in command can only be disk or a logical name
assigned to disk.
.s
USER ACTION:##Retype command.
.p -5,2,6
KEYWORD (NO)CHECK EXPECTED AFTER CODE IN EXTERNAL LIST. LIST IGNORED
.s
EXPLANATION:##CHECK, NOCHECK or -CHECK is expected after CODE in
EXTERNAL list.
.s
COMPILER ACTION:##Switch is processed as /E.
.p -5,2,6
KEYWORD FORTRAN, F40 OR CODE EXPECTED AFTER : IN EXTERNAL LIST. LIST IGNORED
.s
COMPILER ACTION:##Switch is processed as /E.
.p -5,2,6
?LOOKUP ERROR ON COMMAND FILE
.s
EXPLANATION:##Command file from COMPILE not found.
.s
COMPILER ACTION:##The compiler prints an asterisk and waits for next command.
.p -5,2,6
MINUS NOT VALID BEFORE switch. MINUS IGNORED
.s
EXPLANATION:##Minus is not excepted before HELP and PAGE.
.p -5,2,6
MISSPELLED SWITCH: switch. FIRST LETTER USED
.s
EXPLANATION:##First letter of switch matches existing switch name but not rest of switch.
.s
COMPILER ACTION:##The misspelling is ignored and the switch is processed
according to the first letter.
.test page 6
.skip 2
.i -5
?MORE THAN 6 DIGITS IN PPN
.s
USER ACTION:##Retype the command.
.p -5,2,6
UNRECOGNIZABLE SWITCH: switch. SWITCH IGNORED
.s
EXPLANATION:##First letter of switch name does not match any legal switch.
.p -5,2,6
NUMBER BEFORE switch NOT VALID. NUMBER IGNORED
.s
EXPLANATION:##Decimal number may only precede EXTERNAL AND PAGE.
.p -5,2,6
NUMBER NOT VALID WITH MINUS IN switch. NUMBER IGNORED
.s
EXPLANATION:##Number is not valid after minus sign in any switch.
.p -5,2,6
?READ ERROR ON COMMAND FILE
.s
EXPLANATION:##Read error occurred when reading the command file from COMPIL.
.s
COMPILER ACTION:##The compiler types an asterisk and waits for next command from the user (see chapter 3.2).
.p -5,2,6
READ ERROR ON HELP FILE
.s
COMPILER ACTION:##The rest of the help message is lost. The compiler continues
command processing.
.p -5,2,6
?RIGHT PARENTHESIS MISSING AFTER SWITCH(ES)
.s
EXPLANATION:##Switches from the COMPIL CUSP must be enclosed in parentheses.
.s
USER ACTION:##Retype the command.
.p -5,2,6
?RIGHT SQUARE BRACKET MISSING IN PPN
.s
USER ACTION:##Retype the command.
.p -5,2,6
SWITCH switch NOT VALID AFTER PROGRAM START. SWITCH IGNORED
.s
EXPLANATION:##See chapter 3.5.
.p -5,2,6
?SWITCH WITHOUT FILE SPEC. SWITCH IGNORED.
.s
EXPLANATION:##All switches except HELP must be preceded by a file specification.
.s
USER ACTION:##Type a new command.
.p -5,2,6
TEXT CONSTANT AFTER -R NOT ALLOWED. TEXT CONSTANT IGNORED.
.s
COMPILER ACTION:##Switch processed as /-R.
.p -5,2,6
WARNING: NO SWITCH NAME
.s
EXPLANATION:##Slash is not followed by a switch name.
.s
COMPILER ACTION:##Slash ignored.
.ps 55,65
.nj;.spacing 1
.lm 0;.fill
.subtitle APPENDIX C.2 COMPILER SOURCE CODE DIAGNOSTICS
.index ^^Error messages from the compiler
.index ^^COMPILER SOURCE CODE DIAGNOSTICS
.index ^^Messages, error, from the compiler
.index ^^Diagnostic messages from the compiler
.skip 3
C.2##COMPILER SOURCE CODE DIAGNOSTICS
.break
.skip 2
All compiler messages are numbered SIMnnn X, where nnn is an identification
number and X indicates type of error:
.skip 1
E##indicates error, generated code may or may not be executable
.break
W##indicates warning, generated code is executable
.break
T##indicates termination error, no relfil is generated
.skip 1
If a terminating error occurs, the list file may not be generated.
.skip 2
The message is printed on the user's TTY and in the source listing
after the faulty line. If the faulty statement covers more than
one line, the message is written after the last line. The line
number given in the message points at the start of the faulty
statement.
.skip 2

COMPILER SOURCE CODE DIAGNOSTICS:
.skip 2
.left margin 9
.test page 5
.indent -9
SIM001 W MINUS NOT VALID IN AAAA , MINUS IGNORED
.skip 1
.index ^^minus, error message
	EXPLANATION: AAAA is a switch name. Minus may not precede PAGE or HELP.
.p -9,2,5
SIM002 W COLON AFTER AAAA NOT SUCCEEDED BY QUOTE, TEXT CONSTANT IGNORED
.skip 1
.index ^^colon, error message
	EXPLANATION: AAAA is a switch name. A text constant after colon must be
	enclosed in quotes.
.p -9,2,5
SIM003 W END QUOTE MISSING IN TEXT CONSTANT, QUOTE ASSUMED
.skip 1
.index ^^TEXT constant, error message
	EXPLANATION: A text constant argument to a switch must
	be enclosed in quotes.
.p -9,2,5
SIM004 W COLON AFTER AAAA NOT ALLOWED IN COMMAND, CONSTANT IGNORED
.skip 1
	EXPLANATION: AAAA is a switch name. Colon indicates a switch argument
	and is only allowed for EXTERNAL, PAGE and RUNSWITCHES.

.p -9,2,5
SIM005 W HELP NOT VALID IN OPTIONS STATEMENT, IGNORED
.skip 1
.index ^^OPTIONS statement, error messages
	EXPLANATION: HELP switch is always ignored in OPTIONS.
.p -9,2,5
SIM006 W NUMBER IN AAAA NOT VALID, NUMBER IGNORED
.skip 1
	EXPLANATION: AAAA is a switch name. Number is allowed only before
	EXTERNAL and PAGE.
.p -9,2,5
SIM007 W NOT RECOGNIZABLE SWITCH AAAA , SWITCH IGNORED
.skip 1
.index ^^SWITCHes, error messages
	EXPLANATION: AAAA is a switch name. First letter of switch
	did not match the beginning of any legal switch.
.p -9,2,5
SIM010 W SWITCH: AAAA MISSPELLED.
.skip 1
	EXPLANATION: AAAA is a switch name.
.skip 1
	COMPILER ACTION: Switch is processed according to first letter.
.p -9,2,5
SIM011 W SWITCH AAAA NOT VALID AFTER PROGRAM START, SWITCH IGNORED
.skip 1
	EXPLANATION: AAAA is a switch name. See chapter 3.5.
.p -9,2,5
SIM012 W NUMBER NOT VALID WITH MINUS IN AAAA , NUMBER IGNORED
.skip 1
	EXPLANATION: AAAA is a switch name.
.p -9,2,5
SIM013 W EXTERNAL SWITCH ALREADY SPECIFIED, IGNORED
.skip 1
	EXPLANATION: EXTERNAL can only be specified once in each compilation.
.p -9,2,5
SIM014 W CHECK EXPECTED AFTER AAAA IN EXTERNAL LIST, LIST IGNORED
.skip 1
	EXPLANATION: AAAA is a keyword, CODE or FORTRAN.
.skip 1
	COMPILER ACTION: Switch is processed as /E.
.p -9,2,5
SIM015 W EXTERNAL LIST INCOMPLETE
.skip 1
	EXPLANATION: Illegal EXTERNAL list format. See chapter 3.5.
.p -9,2,5
SIM016 W FORTRAN, F40 OR CODE EXPECTED AFTER : IN EXTERNAL, LIST IGNORED
.skip 1
	COMPILER ACTION: Switch is processed as /E.
.skip 2
.index ^^EXTERNAL FORTRAN or MACRO, error message
.index ^^FORTRAN, error message
.test page 5
.indent -9
SIM017 W COLON AFTER -E NOT ALLOWED, LIST IGNORED
.skip 1
	COMPILER ACTION: Switch is processed as /-E or /nE.
.p -9,2,5
SIM020 W TEXT CONSTANT AFTER -R NOT ALLOWED, TEXT CONSTANT IGNORED
.skip 1
	COMPILER ACTION: Switch is processed as /-R.
.p -9,2,5
SIM021 W INVALID DEVICE IN R-SWITCH, ONLY DSK ALLOWED
.skip 1
	EXPLANATION: File specification in R-switch must have a DSK device.
.skip 1
	COMPILER ACTION: Switch ignored.
.skip 1
	USER ACTION: Change device to DSK, or, if a logical name is used, assign this name to DSK.
.p -9,2,5
SIM022 W COMMA MISSING IN R-SWITCH
.skip 1
	EXPLANATION: PPN in file specification in R-switch must contain comma.
.skip 1
	COMPILER ACTION: Switch ignored.
.skip 1
	USER ACTION: Correct PPN and re-compile.
.p -9,2,5
SIM023 W RIGHT SQUARE BRACKET MISSING IN R-SWITCH
.skip 1
	EXPLANATION: PPN in file specification must always be terminated with
	right square bracket ].
.skip 1
	USER ACTION: Correct PPN and re-compile.
.p -9,2,5
SIM024 W MORE THAN SIX DIGITS IN PPN
.skip 1
	EXPLANATION: PPN in file specification in R-switch contains more than 6 digits.
.skip 1
	COMPILER ACTION: Switch ignored.
.skip 1
	USER ACTION: Correct PPN and re-compile.
.p -9,2,5
SIM031 W COMPILER HAS RENUMBERED LINE AAAA
.skip 1
.index ^^Line number, error message
	EXPLANATION: AAAA = line number.
.skip 1
	COMPILER ACTION: The line number is replaced by previous line number + 1
	in the source code listing.
.skip 1
	USER ACTION: Resequence the line numbers in the source file.
	If you are using the SOS text editor, use the NP command
	to get consecutive line numbers throughout the file.
	See also appendix K.2 (for SOS or EDITS) or K.3 (for TECO).
.p -9,2,5
SIM032 W LINE NUMBER EXCEEDS 65534
.skip 1
	EXPLANATION: Line numbers exceeding 65534 will not affect the
	compilation, but later run-time errors will not indicate the
	correct line. These line numbers cannot be used for debugging with SIMDDT.
.skip 1
	USER ACTION: Alternative 1: 
	Resequence the source file with smaller line number
	increment. See appendix K.2 or K.3.
.break
	Alternative 2: Divide large SIMULA source program file into
	separately compiled modules. See chapter 4 of part I of
	the DECsystem-10 SIMULA Language Handbook.
.p -9,2,5
SIM034 W OVERFLOW, INTEGER CONVERTED TO REAL
.skip 1
.index ^^Overflow, error message
	EXPLANATION: Integer constant larger than 2_^35-1.
.p -9,2,5
SIM035 W YOU MAY HAVE FORGOTTEN ; AFTER END
.skip 1
	EXPLANATION: One of the basic symbols:
.break
	#### := :- ( GOTO
.break
	has been found in an end comment. The comment is terminated by:
.break
	#####;  END ELSE WHEN or OTHERWISE
.skip 1
	USER ACTION: If error, correct it, if not, insert COMMENT after END.
.p -9,2,5
.index ^^TEXT constant, error message
SIM036 W END OF LINE IN TEXT CONSTANT
.skip 1
	EXPLANATION: One of the characters LF CR FF or VT has
	been found in a text constant.
.skip 1
	COMPILER ACTION: The character is 
	skipped and not moved to the generated program.
.p -9,2,5
SIM037 W PAGE STRING MISSING AFTER : IN OPTIONS
.skip 1
	COMPILER ACTION: The input is skipped until / or ; is found.
.p -9,2,5
SIM040 W PAGE STRING LONGER THAN 60 CHARACTERS
.skip 1
	EXPLANATION: The maximum number of characters in a page switch string
	is 60.
.skip 1
	COMPILER ACTION: The input is skipped until the next " or 
	until a new line is found.
.p -9,2,5
SIM041 W INVALID CHARACTER, AAAA EXPECTED IN OPTIONS
.skip 1
	EXPLANATION: The invalid character and the character
	which is expected are edited into the message. One of
	the characters ( / ) ; is expected.
.skip 1
	COMPILER ACTION: The input is skipped until the next /
	( ) or ; is found.
.p -9,2,5
SIM042 W SWITCH MISSING IN OPTIONS STATEMENT
.skip 1
	EXPLANATION: No switch was found in an 
	OPTIONS statement.
.p -9,2,5
SIM043 W END OF FILE IN OPTIONS STATEMENT
.skip 1
.p -9,2,5
SIM044 W CHARACTER AFTER TEST NOT VALID
.skip 1
	EXPLANATION: This message should not occur.
	The test version of the compiler accepts _^_^ as a control character	
	which directs debug output. The characters after _^_^ are not valid 
	and 0 is assumed.
.p -9,2,5
SIM051 W ILLEGAL END OF PROGRAM
.skip 1
	EXPLANATION: Program continues after last end.
.skip 1
	USER ACTION: Check block structure.
.p -9,2,5
SIM052 W ILLEGAL SWITCH SETTING
.skip 1
.p -9,2,5
SIM053 W SHORT NOT FOLLOWED BY INTEGER
.skip 1
	COMPILER ACTION: Treated as INTEGER.
.p -9,2,5
SIM054 W LONG NOT FOLLOWED BY REAL
.skip 1
	COMPILER ACTION: Treated as REAL.
.p -9,2,5
SIM055 W LEFT BRACKET IN EXPRESSION
.skip 1
.p -9,2,5
SIM056 W % AT START OF LINE, LINE IGNORED
.s
	EXPLANATION:	Line starting with % may contain compiler
	directives in other SIMULA systems.	
.s;COMPILER ACTION: Line is treated as a comment.
.s;USER ACTION:	Delete the line or translate to OPTIONS statement.
.p -9,2,5
SIM061 E TOO LONG LINE
.skip 1
	EXPLANATION: A source code line must not exceed 135 characters
	including possible nulls.
.skip 1
	COMPILER ACTION: The line is truncated to 135 characters and compiled as if
	it were terminated with carriage return and line feed.
.p -9,2,5
SIM063 E = MUST FOLLOW =/
.skip 1
	COMPILER ACTION: =/= assumed.
.p -9,2,5
SIM064 E NONPRINTABLE CHARACTER
.skip 1
	COMPILER ACTION: The character is ignored.
.skip 1
	USER ACTION: Check the source input program. 
.p -9,2,5
SIM065 E ILLEGAL CHARACTER AAAA
.skip 1
	EXPLANATION: AAAA is the illegal character.
.skip
	COMPILER ACTION: The character is treated as a blank.
.p -9,2,5
SIM066 E GO NOT FOLLOWED BY TO
.skip 1
	COMPILER ACTION: The single GO is treated as GO TO.
.p -9,2,5
SIM067 E GO MISSING BEFORE TO
.skip 1
	COMPILER ACTION: The TO is ignored.
.p -9,2,5
SIM070 E EOF IN COMMENT
.skip 1
	EXPLANATION: The ; which closes the comment is not found
	before the end of the input file is found.
.p -9,2,5
SIM071 E EOF IN TEXT CONSTANT
.skip 1
	EXPLANATION: The " which closes the text constant is not found
	before the end of the input file is found.
.skip 1
	COMPILER ACTION: Valid program parts are taken as part of the
	text constant if the " was forgotten.
.p -9,2,5
SIM072 E CHARACTER QUOTE MISSING
.skip 1
	COMPILER ACTION: The  incomplete character constant is
	treated as a valid one.
.p -9,2,5
SIM073 E CONTROL CHARACTER IN CHARACTER CONSTANT
.skip 1
	EXPLANATION: The TAB character (HT) and the line control characters
	LF, FF, VT and CR are not accepted as character constants.
	Non-printable characters, e.g_. altmode, are not accepted either,
	see SIM064.
.skip
	COMPILER ACTION: The character is treated as a blank.
.skip 1
	USER ACTION: Use the built-in procedure CHAR.
.p -9,2,5
SIM074 E TAB IN TEXT CONSTANT
.skip 1
.index ^^Character set, error message
	EXPLANATION: The horisontal tab character
	is not accepted in a text constant.
.skip 1
	COMPILER ACTION: The tab is treated as a blank character.
.skip 1
	USER ACTION: Use PUTCHAR(CHAR(9));.
.p -9,2,5
SIM075 E TEXT CONSTANT LONGER THAN 2**15
.skip 1
.skip 2
.index ^^TEXT constant, length of, error message
.test page 5
.indent -9
SIM076 E MORE THAN ONE DECIMAL POINT
.skip 1
	COMPILER ACTION: Extra decimal points in the real constant
	are ignored.
.p -9,2,5
SIM077 E DIGIT MISSING AFTER DECIMAL POINT
.skip 1
	COMPILER ACTION: A zero is assumed to follow the decimal point
	in the real constant.
.p -9,2,5
SIM100 E NO DIGITS IN EXPONENT
.skip 1
	COMPILER ACTION: The exponent is ignored.
.skip 2
.test page 5
.indent -9
SIM101 E FLOATING OVERFLOW
.skip 1
	COMPILER ACTION: The maximal real constant, approximately 1.7_&38,
	see A.6.1, is used instead.
.skip 2
.index ^^Overflow, error message
.test page 5
.indent -9
SIM102 E FLOATING UNDERFLOW
.skip 1
	COMPILER ACTION: The real constant 0 is used.
.p -9,2,5
SIM103 E INTEGER OVERFLOW IN RADIX CONSTANT
.skip 1
	COMPILER ACTION: The integer constant 8R377777777777 is used.
.p -9,2,5
SIM104 E DIGITS MISSING IN RADIX NUMBER
.skip 1
	EXPLANATION: There are no digits (0-9 or A-F) after R in
	a radix constant.
.skip 1
	COMPILER ACTION: The base is used as integer constant.
.p -9,2,5
SIM105 E DIGIT AAAA NOT LESS THAN RADIX BASE
.skip 1
	EXPLANATION: AAAA is the digit (0-9 or A-F) which is greater than the radix base.
.skip 1
	COMPILER ACTION: The rest of the number is ignored.
.p -9,2,5
SIM110 E ILLEGAL START OF PROGRAM
.skip 1
	COMPILER ACTION: Scan until program start is found.
.p -9,2,5
SIM111 E XXXX IS MISPLACED
.skip 1
	EXPLANATION: XXXX = misplaced entity.
.skip 1
	COMPILER ACTION: Skip rest of statement or declaration.
.p -9,2,5
SIM112 E DECLARATION MUST BE FOLLOWED BY ;
.skip 1
	COMPILER ACTION: ; assumed.
.p -9,2,5
SIM113 E MISSING END
.skip 1
	COMPILER ACTION: An extra END is assumed.
.p -9,2,5
SIM114 E XXXX IS ILLEGAL CLASS PREFIX
.skip 1
	EXPLANATION: XXXX = prefix.
.skip
	COMPILER ACTION: The class is treated as unprefixed.
.p -9,2,5
SIM115 E XXXX SPECIFICATION MUST PRECEDE TYPE SPECIFICATION
.skip 1
	EXPLANATION: XXXX = value or name.
.skip 1
	COMPILER ACTION: Specification ignored.
.skip
	USER ACTION: Reorder specifications.
.left margin 9
.p -9,2,5
SIM116 E ILLEGAL CLASS SPECIFICATION
.skip 1
.p -9,2,5
SIM117 E VIRTUAL MUST BE FOLLOWED BY :
.skip 1
	COMPILER ACTION: : is assumed.
.skip 2
.index ^^VIRTUAL, error message
.test page 5
.indent -9
SIM120 E ILLEGAL VIRTUAL SPECIFICATION
.skip 1
	COMPILER ACTION: Specification ignored.
.p -9,2,5
SIM121 E MISSING ; AFTER INNER
.skip 1
	COMPILER ACTION: ; is assumed.
.p -9,2,5
SIM122 E XXXX IS ILLEGAL CLASS/PROCEDURE NAME
.skip 1
	EXPLANATION: XXXX = CLASS/PROCEDURE name.
.skip
	USER ACTION: Check that name is not a reserved word. (See appendix G).
.p -9,2,5
SIM123 E ILLEGAL VIRTUAL TYPE
.skip 1
	COMPILER ACTION: Specification ignored.
.p -9,2,5
SIM124 E MISSING IDENTIFIER LIST
.skip 1
	EXPLANATION: No identifier follows <type>.
.p -9,2,5
SIM125 E ERRONEOUS SWITCH DECLARATION
.skip 1
	COMPILER ACTION: Declaration ignored.
.p -9,2,5
SIM126 E ILLEGAL REFERENCE TYPE
.skip 1
	EXPLANATION: Syntax should be: REF(<CLASS-identifier>).
.skip
	COMPILER ACTION: Declaration or specification ignored.
.p -9,2,5
SIM127 E MORE THAN 10 DIMENSIONS
.skip 1
.index ^^Dimensions, number of, error message
.index ^^ARRAY dimensions, number of, error message
.p -9,2,5
SIM130 E MISSING XXXX
.skip 1
	EXPLANATION: XXXX = right parenthesis/bracket.
.skip
	COMPILER ACTION: Missing symbol is assumed.
.p -9,2,5
SIM131 E HOMELESS XXXX PART
.skip 1
	EXPLANATION: XXXX = ELSE/WHEN/OTHERWISE.
.skip
	COMPILER ACTION: Statement ignored.
.p -9,2,5
SIM132 E STATEMENT BEFORE BEGIN NOT TERMINATED
.skip 1
	COMPILER ACTION: ; assumed before BEGIN.
.p -9,2,5
SIM133 E CANNOT FIND THEN IN IF-STATEMENT
.skip 1
	COMPILER ACTION: statement skipped.
.p -9,2,5
SIM134 E IF-STATEMENT CANNOT BE PLACED DIRECTLY AFTER THEN
.skip 1
.index ^^IF-statement, error messages
	COMPILER ACTION: Enclose statement by BEGIN-END.
.skip
	USER ACTION: Do the same.
.p -9,2,5
SIM135 E FOR-, INSPECT- or WHILE-STATEMENT CANNOT BE PLACED BETWEEN THEN AND ELSE
.skip 1
	COMPILER ACTION: Enclose statement by BEGIN-END.
.skip
	USER ACTION: Do the same.
.p -9,2,5
SIM136 E INNER ILLEGALLY PLACED
.skip 1
	EXPLANATION: 1) INNER is not placed at the outermost block level
	in a class body.
.br
	2) Several INNER statements occur in the same class body.
.br
	3) INNER is preceded by something different from BEGIN or
	semicolon (;). According to the syntax ([1] Sect 2.1, [3] Sect 5.5),
	these are the only symbols which can directly precede INNER (except for
	comments).
.skip
	COMPILER ACTION: This INNER is skipped.
.p -9,2,5
SIM137 E DECLARATION FOUND WHERE STATEMENT WAS EXPECTED
.skip 1
	USER ACTION: Check that this is not caused by an error
	in a previous declaration.
	This error may also be caused by a missing END earlier in the
	program. (Use SIMED - see App. L - to check the BEGIN-END
	nesting).
.p -9,2,5
SIM140 E MISSING FOR-LIST
.skip 1
.p -9,2,5
SIM141 E MISSING DO IN FOR-STATEMENT
.skip 1
	COMPILER ACTION: Statement ignored.
.skip 2
.test page 10
.indent -9
SIM142 E ILLEGAL CONTROLLING VARIABLE
.skip 1
	EXPLANATION: The controlling variable may not be of type TEXT,
	a remote or subscripted variable, or a function identifier.
.skip 1
	COMPILER ACTION: Statement ignored.
.p -9,2,5
SIM143 E MISSING CONNECTION BLOCK
.skip 1
	COMPILER ACTION: Statement ignored.
.p -9,2,5
SIM144 E ILLEGAL WHEN-CLAUSE
.skip 1
	EXPLANATION: The syntax is: WHEN <CLASS-identifier> DO
.skip
	COMPILER ACTION: Clause is ignored.
.p -9,2,5
SIM145 E MISSING DO IN WHILE-STATEMENT
.skip 1
	COMPILER ACTION: Statement ignored.
.p -9,2,5
SIM146 E CANNOT FIND UNTIL
.skip 1
	COMPILER ACTION: FOR list element skipped.
.p -9,2,5
SIM147 E XXXX MISSING IN CONDITIONAL EXPRESSION
.skip
	EXPLANATION: XXXX = THEN/ELSE.
.p -9,2,5
SIM150 E NOCHECK PROCEDURES MUST NOT HAVE ANY EXPLICIT FORMAL PARAMETERS
.skip 1
.p -9,2,5
SIM151 E MISSING IDENTIFIER AFTER XXXX
.skip
	EXPLANATION: XXXX = NEW/THIS/#.#/QUA.
.p -9,2,5
SIM152 E CONDITIONAL EXPRESSION IS NOT ENCLOSED BY PARENTHESES
.skip 1
	COMPILER ACTION: Parentheses assumed.
.p -9,2,5
SIM153 E MISSING OPERAND
.skip 1
.p -9,2,5
SIM154 E MISSING BINARY OPERATOR
.skip 1
	COMPILER ACTION: Skip second operand.
.skip
	EXPLANATION: Could be missing ;.
.p -9,2,5
SIM155 E ILLEGAL EXTERNAL ITEM
.skip 1
	EXPLANATION: Only CLASSes or PROCEDUREs may be external.
.p -9,2,5
SIM156 E ERROR IN EXTERNAL ITEM
.skip 1
.p -9,2,5
SIM157 E BLOCK STACK OVERFLOW
.skip 1
	EXPLANATION: Too deep nesting of blocks, PROCEDUREs, CLASSes and connections.
.skip
	USER ACTION: Restructure program, for example by using recursive procedures instead of blocks within blocks.
.p -9,2,5
SIM160 E XXXX PREVIOUSLY SPECIFIED
.skip 1
	EXPLANATION: XXXX = identifier.

.skip
	COMPILER ACTION: Specification ignored.
.p -9,2,5
SIM161 E XXXX SPECIFIED BUT IS NOT FORMAL PARAMETER
.skip 1
	EXPLANATION: XXXX = identifier.
.p -9,2,5
SIM162 E FORMAL PARAMETER XXXX NOT SPECIFIED
.skip 1
	EXPLANATION: XXXX = identifier.
.skip
	COMPILER ACTION: Mode of formal is set to default.
.p -9,2,5
SIM163 E FORMAL PARAMETER XXXX ILLEGALLY SPECIFIED
.skip 1
	EXPLANATION: XXXX = identifier.
.p -9,2,5
SIM164 E XXXX HAS MORE THAN 255 FORMAL PARAMETERS
.skip 1
	EXPLANATION: XXXX = identifier.
.p -9,2,5
SIM165 E XXXX HAS MORE THAN 255 VIRTUALS
.skip 1
	EXPLANATION: XXXX = identifier.
.p -9,2,5
SIM166 E TOO LARGE BLOCK LENGTH
.skip 1
	EXPLANATION: See Chapter 6.1
.p -9,2,5
SIM167 E TOO MANY REDUCED SUBBLOCKS
.skip 1
	EXPLANATION: See Chapter 6.1
.skip 1
	USER ACTION: Divide large block at program, CLASS or PROCEDURE block level.
.p -9,2,5
SIM170 E EXTERNAL MUST BE COPIED INTO MAIN
.skip 1
	EXPLANATION: External declarations must not precede a main program.
.p -9,2,5
SIM171 E EXTERNAL MUST NOT BE COPIED INDIRECTLY
.skip 1
	EXPLANATION: This external declaration must precede the start of an external CLASS
	or PROCEDURE.
.p -9,2,5
SIM172 E EXTERNAL MUST NOT BE ATTRIBUTE
.skip 1
.p -9,2,5
SIM173 E XXXX HAS ILLEGAL FORTRAN SPECIFICATION
.skip 1
.p -9,2,5
SIM174 E PPN IN EXTERNAL IDENTIFIER NOT OCTAL DIGIT
.skip 1
.p -9,2,5
SIM175 E PPN IN EXTERNAL IDENTIFIER MORE THAN SIX DIGITS
.skip 1
.skip 2
.test page 9
.indent -9
SIM176 E CONFLICT BETWEEN SPECIFICATIONS
.skip
	EXPLANATION: In the protection part there exists specification both
	with and without NOT.
.skip
	USER ACTION: Change the specifications so that they have the
	same form.
.skip
	COMPILER ACTION: The last specification is skipped.
.skip 2
.test page 7
.indent -9
SIM177 E ENTRY NAME CONFLICT BETWEEN EXTERNALS XXXX AND XXXX
.skip 1
	EXPLANATION: The externals have unfortunately been assigned the same entry point name by the compiler.
.skip
	USER ACTION: Re-compile one of the externals after deleting the corresponding ATR-file.
.p -9,2,5
SIM200 E EXTERNAL XXXX DECLARED TWICE
.skip
	EXPLANATION: Externals must only be copied once into a main program.
.p -9,2,5
SIM201 E DISPLAY SIZE OVERFLOW, TOO MANY BLOCK LEVELS
.skip
	EXPLANATION: More than 30 block levels including FOR loops
	and inspection blocks.
.skip 2
.test page 3
.indent -9
SIM202 E ATTRBUTE XXXX IN PROTECTION LIST NOT FOUND
.skip
.p -9,2,5
SIM240 T ?INVALID DEVICE, ONLY DSK IS ALLOWED
.skip 1
	EXPLANATION: See corresponding message in Appendix C.1.
.p -9,2,5
SIM241 T ?COMMA MISSING IN PPN
.skip 1
	EXPLANATION: See corresponding message in Appendix C.1.
.p -9,2,5
SIM242 T ?RIGHT SQUARE BRACKET MISSING IN PPN
.skip 1
	EXPLANATION: See corresponding message in Appendix C.1.
.p -9,2,5
SIM243 T ?MORE THAN 6 DIGITS IN PPN
.skip 1
	EXPLANATION: See corresponding message in Appendix C.1.
.p -9,2,5
SIM244 T ?= OR _ MISSING IN COMMAND
.skip 1
	EXPLANATION: See corresponding message in Appendix C.1.
.p -9,2,5
SIM245 T ?RIGHT PARENTHESIS MISSING IN SWITCH EXPRESSION
.s
	EXPLANATION: See corresponding message in Appendix C.1.
.p -9,2,5
SIM246 T ?LOOKUP ERROR IN COMMAND FILE
.s
	EXPLANATION: See corresponding message in Appendix C.1.
.p -9,2,5
SIM247 T ?CANNOT OPEN DISK
.s
	EXPLANATION: See corresponding message in Appendix C.1.
.p -9,2,5
SIM251 T ?SWITCH WITHOUT FILE SPECIFICATION, SWITCH IGNORED
.s
	EXPLANATION: See corresponding message in Appendix C.1.
.p -9,2,5
SIM252 T ?TOO MANY SOURCE FILES
.s
	EXPLANATION: This error may occur if the user tries to concatenate
	more than six small source files, the sum of which does
	not exceed 135 characters.
.s
	COMPILER ACTION: The compilation is terminated after the fifth file.
.p -9,2,8
SIM255 T ?IMPROPER ATR LIBRARY FORMAT - FILE AAAA
.s
	EXPLANATION: The first (possibly a following) block of the file is not
	an index block.
.s
	USER ACTION: Make an index to the file with FUDGE2 or MAKLIB, or
	substitute another ATR library.
.p -9,2,8
SIM256 T ?FILE NOT FOUND OR DUPLICATE DECLARATION - AAAA
.s
	EXPLANATION: Source or attribute file not found.
        This error message is also issued when the same EXTERNAL
        declaration is repeated more than once, so that the external
        module is multiply declared.
.s
	COMPILER ACTION: This is a terminating error.
	No rel file is generated  and the list file
	is only generated when a source file has 
	been found.
.s
        USER ACTION: Search for duplicate EXTERNAL declarations
        in your source program.
.p -9,2,5
SIM260 T ?CANNOT ENTER FILE *.TMP
.s
.p -9,2,5
SIM261 T ?INTERNAL I/O ERROR
.s
	EXPLANATION: Probable reasons are that another job on the same ppn
	has deleted or protected the compiler TMP files,
	or that no space is available on DSK:.
	It could also be a system software or hardware error.
.p -9,2,5
SIM264 T ?MORE THAN 3072 IDENTIFIERS
.s
	USER ACTION: Redeclare quantities where possible or split
	the program into separately compiled modules.
.skip 2
.index ^^Identifiers, number of, error message
.index ^^Capacity limitations, error message
.test page 5
.indent -9
SIM265 T ?NO PROGRAM FOUND
.s
	EXPLANATION: Source file is not a SIMULA program.
.p -9,2,5
SIM266 T ?NOT ENOUGH CORE PASS 1
.s
	EXPLANATION: Too many declarations found.
.s
	USER ACTION: Split into separetely compiled modules.
.p -9,2,5
SIM267 T ?TYPE AND/OR KIND OF EXTERNAL XXXX DOES NOT MATCH
.s
	USER ACTION: Check if the correct ATR-file is used,
	and that the external declaration is correct.
.p -9,2,5
SIM270 T ?NAME OF EXTERNAL XXXX DOES NOT MATCH
.skip
	USER ACTION: Check if the correct ATR-file is used.
.p -9,2,5
SIM271 T ?EXTERNAL XXXX COMPILED AT WRONG LEVEL, LEVEL SHOULD BE NNNN
.s
	USER ACTION: Re-compile EXTERNAL with value of /E switch as given in error
	message, or move declaration to another block level.
.p -9,2,7
SIM272 T ?EXTERNAL XXXX NOT FOUND IN ATR LIBRARY XXXX
.s
	USER ACTION: Make sure the library is correct.
.p -9,2,7
SIM274 T ?FIXUP TABLE OVERFLOW
.skip
	EXPLANATION: Not more than 4096 fixups can be allocated in a module.
.skip
	USER ACTION: Split the module into several separately compiled modules.
.p -9,2,5
SIM301 W INTERMEDIATE QUANTITIES SAVED IN SLOW MEMORY, EXPRESSION SHOULD BE SIMPLIFIED
.s
.p -9,2,5
SIM303 W IMPLICIT ARITHMETIC CONVERSION
.s
	EXPLANATION: A conversion between types INTEGER and LONG REAL is performed by a
	relatively slow subroutine in order not to lose precision.
.p -9,2,5
SIM304 W INTEGER BASE CONVERTED TO REAL BEFORE EXPONENTIATION
.s
	EXPLANATION: This conversion is made to avoid run-time overflow when the
	result is larger than 2_^35. Integer precision may be lost if the base is
	larger than 134 258 569.
.s
	USER ACTION: If you want to retain full integer precision then convert
	the base to LONG REAL before exponentiation.
.p -9,2,5
SIM305 W IMPLICIT QUALIFICATION CHECK
.s
	EXPLANATION: Extra code has been emitted to check the qualification in a reference
	denotes statement or a parameter transmission.
.IF DUMMY !Not yet implemented
.p -9,2,5
SIM306 W IDENTIFIER XXXX REDECLARED BY INSPECTION
.s
	EXPLANATION: By inspecting a class instance, the identifier XXXX now
	refers to an
	attribute of the inspected class instead of the quantity it refers to
	outside the inspection. This may be unintentional and cause trouble.
.s
	USER ACTION: Change name on one of the quantities.
	The names of class attributes
	should not be too short or too common, like I, J, X.
.EI DUMMY
.p -9,2,5
SIM307 W EXPRESSION OR CONVERSION AFTER UNTIL
.skip 1
	EXPLANATION: The quantity after UNTIL must be evaluated once for each repetition.
.p -9,2,5
SIM310 W STANDARD FUNCTION XXXX HAS ONLY SINGLE PRECISION
.skip
	EXPLANATION: XXXX = function identifier.
.p -9,2,5
SIM311 W CONNECTED LABEL OR SWITCH XXXX
.skip 1
	EXPLANATION: The transfer to a connected label may cause unexpected effects.
.p -9,2,5
SIM331 E QUALIFICATION XXXX IS NOT A CLASS
.skip 1
	EXPLANATION: XXXX = identifier.
.p -9,2,5
SIM332 E INVALID 2ND OPERAND KIND OF OPERATOR XXXX
.skip 1
	EXPLANATION: XXXX = operator.
.p -9,2,5
SIM333 E PREFIX XXXX IS NOT A CLASS
.skip 1
	EXPLANATION: XXXX = identifier.
.p -9,2,5
SIM334 E PREFIX XXXX IS NOT ON THIS BLOCK LEVEL
.skip 1
	EXPLANATION: XXXX = identifier.
.p -9,2,5
SIM335 E VIRTUAL MATCH TO XXXX HAS WRONG KIND
.skip 1
	EXPLANATION: XXXX = identifier.
.p -9,2,5
SIM336 E VIRTUAL MATCH TO XXXX HAS WRONG TYPE OR QUALIFICATION
.skip 1
	EXPLANATION: XXXX = identifier.
.p -9,2,5
SIM337 E INCORRECT NUMBER OF PARAMETERS TO XXXX
.skip 1
	EXPLANATION: XXXX = identifier.
.p -9,2,5
SIM340 E DOUBLE DECLARATION OF XXXX
.skip 1
	EXPLANATION: XXXX = identifier.
.p -9,2,5
SIM341 E INCORRECT NUMBER OF SUBSCRIPTS TO XXXX
.skip 1
	EXPLANATION: XXXX = identifier.
.p -9,2,5
SIM342 E IDENTIFIER AFTER XXXX IS NOT A CLASS
.skip 1
	EXPLANATION: XXXX = operator.
.p -9,2,5
SIM343 E OPERAND OF ACTIVATE OR REACTIVATE IS NOT PROCESS
.skip 1
.p -9,2,5
SIM344 E CONTROLLED VARIABLE OF TYPE TEXT IS NOT PERMITTED
.skip 1
.p -9,2,5
SIM345 E INVALID LEFT HAND SIDE EXPRESSION TO OPERATOR XXXX
.skip 1
	EXPLANATION: XXXX = :- or :=.
.p -9,2,5
SIM346 E CONTROLLED VARIABLE XXXX IS OF NAME MODE
.skip 1
	EXPLANATION: XXXX = identifier.
.p -9,2,5;.comment [210]
SIM347 E STANDARD (OR "QUICK") FUNCTION OR PROCEDURE XXXX CANNOT BE PASSED AS AN ACTUAL PARAMETER
.skip 1
	EXPLANATION: XXXX = procedure name.
.p -9,2,5
SIM350 E NON-ARITHMETIC SUBSCRIPT TO ARRAY XXXX
.skip 1
	EXPLANATION: XXXX = ARRAY identifier.
.p -9,2,5
SIM351 E PARAMETERS OR SUBSCRIPTS TO XXXX OMITTED
.skip 1
	EXPLANATION: XXXX = identifier.
.p -9,2,5
SIM352 E THIS XXXX IS NOT A VALID LOCAL OBJECT, CLASS HAS BEEN USED AS BLOCK PREFIX
.skip 1
	EXPLANATION: XXXX = identifier.
.p -9,2,5
SIM353 E THIS XXXX IS NOT A VALID LOCAL OBJECT, NO ENCLOSING INSTANCE
.skip 1
	EXPLANATION: XXXX = identifier.
.p -9,2,5
SIM354 E BRACKETS AFTER XXXX SHOULD BE PARENTHESES
.skip 1
	EXPLANATION: The identifier XXXX is a function or PROCEDURE, not a SWITCH or an ARRAY.
.p -9,2,5
SIM355 E SIMPLE QUANTITY XXXX IS USED AS ARRAY, FUNCTION OR SWITCH
.skip 1
	EXPLANATION: XXXX = identifier.
.p -9,2,5
SIM356 E RESULT OVERFLOW OR DIVISION BY ZERO IN CONSTANT EXPRESSION
.skip 1
.p -9,2,5
SIM357 E INCOMPATIBLE OPERAND TYPES OF OPERATOR XXXX
.skip 1
	EXPLANATION: XXXX = operator.
.p -9,2,5
SIM360 E INVALID OPERAND TYPE OF OPERATOR XXXX
.skip 1
	EXPLANATION: XXXX = operator.
.p -9,2,5
SIM361 E INVALID REMOTE ACCESS, CLASS XXXX HAS LOCAL CLASS ATTRIBUTES
.skip 1
	EXPLANATION: XXXX = identifier.
.p -9,2,5
SIM362 E IDENTIFIER XXXX IS NOT DECLARED
.skip 1
	EXPLANATION: XXXX = identifier.
.p -9,2,5
SIM363 E INCOMPATIBLE QUALIFICATIONS XXXX AND XXXX TO OPERATOR XXXX
.skip 1
	EXPLANATION: XXXX = identifier,identifier and operator, respectively.
.p -9,2,5
SIM364 E OPERAND OF UNTIL IS NOT SIMPLE
.skip 1
.p -9,2,5
SIM365 E INVALID OPERAND KIND OF OPERATOR XXXX
.skip 1
	EXPLANATION: XXXX = operator.
.p -9,2,5
SIM366 E TEXT CONSTANT IS NOT A VALID ACTUAL PARAMETER FOR REFERENCE MODE FORMAL XXXX OF XXXX
.skip 1
	EXPLANATION: XXXX = identifier,identifier.
.skip 1
	USER ACTION: Declare the formal parameter as NAME (if only used a few times)
	or VALUE (if used many times).
.p -9,2,5
SIM367 E INVALID ACTUAL PARAMETER  KIND CORRESPONDING TO FORMAL PARAMETER XXXX OF XXXX
.skip 1
	EXPLANATION: XXXX = identifier.
.p -9,2,5
SIM370 E INVALID ACTUAL PARAMETER TYPE CORRESPONDING TO FORMAL PARAMETER XXXX OF XXXX
.skip 1
	EXPLANATION: XXXX = identifier,identifier.
.skip 1
.test page 5
.indent -9
SIM371 E EXPRESSION IS NOT A VALID STATEMENT
.skip 1
	EXPLANATION: The expression is not a procedure call or an object generator, which
	are the only expressions allowed at statement level.
.p -9,2,5
SIM372 E BLOCK TOO LARGE
.skip 1
.p -9,2,5
SIM373 E EXPRESSION TOO COMPLICATED
.skip 1
.p -9,2,5
SIM374 E CANNOT SAVE INTERMEDIATE QUANTITIES, EXPRESSION TOO COMPLICATED
.skip 1
.p -9,2,5
SIM375 E DETACH NOT ON OUTERMOST LEVEL IN CLASS
.skip 1
.p -9,2,5
SIM376 E OPERAND SUCCEEDING BEFORE/AFTER NOT QUALIFIED AS PROCESS
.skip 1
.p -9,2,5
SIM377 E CHAR PARAMETER ERROR
.skip 1
	EXPLANATION: The parameter is a constant outside the range [0,127].
.p -9,2,5
SIM400 E PREFIX XXXX TO XXXX IS NOT PREVIOUSLY DECLARED OR IS REDEFINED LATER
.skip 1
	EXPLANATION: A prefix CLASS must be declared before its subclass.
.p -9,2,5
SIM401 E INVALID REMOTE ACCESS, XXXX IS NOT AN ATTRIBUTE OF XXXX
.skip 1
	EXPLANATION: The attribute XXXX does not exist in the CLASS qualifying the expression before the dot.
.p -9,2,5
SIM402 E INCOMPATIBLE QUALIFICATION OF PARAMETER CORRESPONDING TO FORMAL XXXX OF XXXX
.skip 1
	EXPLANATION: XXXX = identifier,identifier.
.p -9,2,5
SIM403 E INVALID ACTUAL PARAMETER MODE CORRESPONDING TO FORMAL PARAMETER XXXX OF XXXX
.skip 1
	EXPLANATION: A name mode parameter must not be passed to random drawing
	procedures or ACCUM as a parameter on which side effects may occur.
.p -9,2,5
SIM404 E  ILLEGAL EXPRESSION AS ACTUAL PARAMETER CORRESPONDING TO FORMAL PARAMETER XXXX OF XXXX
.skip 1
	EXPLANATION: XXXX = identifier,identifier.
.p -9,2,5
SIM405 E  PREFIX CLASS HAS LOCAL OBJECT
.skip 1
	EXPLANATION: A class, say CLASS C, which contains a reference like
	"THIS C" (=local object) cannot be used as a prefix, since the prefixed
	block is NOT a C object, implying that "THIS C" would be an error.
	To avoid the necessity of run-time checks for this, using the class
	as prefix to a block is disallowed.
.p -9,2,5
SIM406 E CONSTANT BEFORE DOT
.skip 1
.p -9,2,5
SIM407 E INVALID ACCESS OF EXTERNAL XXXX FROM XXXX
.skip 1
	EXPLANATION: Either the first EXTERNAL is invisible, not
	declared or mixed with another EXTERNAL with the same name,
	or the second EXTERNAL needs re-compilation.
.skip 1
        EXAMPLE: An EXTERNAL can become invisible, if it is
        superseded by a local identifier in your program with
        the same identifier. This local identifier can also
        be in another separately compiled module which you are
        also using.
.p -9,2,5
SIM410 E CONNECTED PREFIX
.skip 1
	EXPLANATION: A class which has become visible via inspection cannot be
	used as prefix. Use block prefixing (C BEGIN ...) instead of INSPECT ..,
	if possible.
.p -9,2,5
SIM411 E CONNECTED QUANTITY HAS NO QUALIFICATION
.skip 1
.p -9,2,5
SIM412 E DISPLAY SIZE OVERFLOW, TOO MANY LEVELS OR PARAMETER NESTINGS
.skip 1
	EXPLANATION: More than 30 block levels including FOR loops,
	inspection blocks and thunk save areas used for certain parameters
	passed by name.
.skip 2
.index ^^Capacity limitations, error message
.test page 5
.indent -9
SIM413 E TEXT STRING AFTER DENOTES
.skip 1
.p -9,2,5
SIM414 E LOCAL QUANTITY IN ARRAY DECLARATION
.skip 1
.p -9,2,5
SIM415 E PROGRAM TOO LARGE, CAPACITY LIMIT EXCEEDED
.skip 1
	EXPLANATION: At least one of the five code streams generated
	in PASS 2 exceeds 32767 words.
.skip 1
	USER ACTION: Try separate compilation!
.p -9,2,5
SIM416 E TOO MANY ACCUMULATORS NNNN NEEDED FOR PARAMETERS
.skip 1
	EXPLANATION: A "QUICK" MACRO-10 procedure requires its parameters in
	consecutive accumulators. Only 10 accumulators are available for this
	purpose.
.skip 1
	USER ACTION: Do not use name mode unnecessarily. Two ac's are required
	for each name mode parameter. Place more information in some parameters.
.p -9,2,5
SIM417 E TOO COMPLICATED ACTUAL PARAMETER CORRESPONDING TO FORMAL PARAMETER XXXX OF "QUICK" PROCEDURE XXXX
.skip 1
	EXPLANATION: The actual parameter corresponding to a name mode formal
	parameter of a "QUICK" procedure may not have a thunk, which means that
	expressions, procedures, labels and switches are disallowed. Note that
	this only applies to name mode.
.skip 1
	USER ACTION: Compute the expression, if possible, to a variable
	and pass this instead. Otherwise change the specifications
	of the procedure. Note that "CODE" (not "QUICK") procedures permit
	any valid parameters according to the SIMULA definition, at the
	expense of the overhead incurred with a general procedure call.
.p -9,2,5
SIM420 E ACTUAL/FORMAL TYPE MISMATCH FOR PARAMETER XXXX OF "QUICK" PROCEDURE XXXX
.skip 1
	EXPLANATION: In name mode, the type of an actual parameter to a "QUICK" procedure must
	be identical to the formal type.
.skip 1
	USER ACTION: Copy the actual parameter to a variable with the correct
	type and use the variable as parameter. If side effects are wanted, copy
	back the value after the call.
.skip 2
.test page 1
.indent -9
SIM421 E ATTRIBUTE XXXX HIDDEN BUT NOT PROTECTED
.skip
.skip 2
.test page 1
.indent -9
SIM422 E NO ATTRIBUTE XXXX VISIBLE
.skip
.p -9,2,5
SIM423 E NEW XXXX IS AN ILLEGAL OBJECT GENERATOR
.skip 1
	EXPLANATION: See this handbook section 4.1. SIMSET, SIMULATION and their
	subclasses cannot occur after NEW, only as prefix.
.p -9,2,5
SIM424 E ILLEGAL VIRTUAL SPECIFICATION OF XXXX
.skip 1
	EXPLANATION: Either there are two virtual specifications of
	the same identifier visible simultaneously or a formal
	parameter is specified virtual.
.p -9,2,5
SIM425 E VIRTUAL MATCH XXXX MUST NOT BE PROTECTED
.skip 1
	EXPLANATION: The virtual match inherits the protection
	mode of the virtual specification.
.skip 1
	USER ACTION: Remove the illegal protection.
.p -9,2,5
SIM426 E ILLEGAL USE OF TEXT VALUE CONSTANT
.skip 1
.p -9,2,5
SIM461 T ?STACK OVERFLOW, STATEMENT TOO COMPLICATED
.skip 1
.p -9,2,5
SIM462 T ?CORE FAILURE, PROGRAM HAS TOO MANY DECLARATIONS AND INSPECTIONS FOR THE AVAILABLE MEMORY
.skip 1
	USER ACTION: Split the program into separately compiled modules.
.p -9,2,5
.IF dummy; [271]
.EI dummy
SIM463 T TOO COMPLICATED PROGRAM STRUCTURE
.skip 1
EXPLANATION:	The compiler ran out of "fixups".
Probably too many branches in a conditional expression (or statement).
.skip 1
USER ACTION:	Try splitting conditional expression into several conditional
statements.
.p -9,2,5
SIM467 T ?STACK UNDERFLOW
.skip 1
.p -9,2,5
SIM530 E INTERNAL ERROR: NON-EXISTENT ERROR NUMBER
.skip 1
	EXPLANATION: Error should never occur.
	The wrong version of SIMDDT may be in use, or SIMDDT needs updating.
.skip 1
	USER ACTION: Call a systems programmer.
.p -9,2,5
SIM560 T ?NOT ENOUGH CORE PASS 3
.skip 1
	EXPLANATION: Not enough core to create line number table for listing,
	cross reference listing or attribute file.
.p -9,2,5
SIM561 T ?UNRECOVERABLE ERRORS
.skip 1
	EXPLANATION: Too many severe errors of type termination have occurred.
.skip 1
	USER ACTION: Contact a systems programmer.
.p -9,2,5
SIM566 T ?INTERNAL ERROR: STACK UNDERFLOW PASS AAAA
.skip 1
	EXPLANATION: Same number in all three passes. This message should never occur. AAAA is pass number.
.skip 1
	USER ACTION: Contact a systems programmer.
.p -9,2,5
SIM567 T ? STACK OVERFLOW PASS AAAA
.skip 1
	EXPLANATION: AAAA is pass number. A capacity restriction has been violated.
	Stack overflow pass 3 is often caused by too many BEGINs 
	placed after each other without any closing ENDs.
	The error may also be an internal error.
.skip 1
	USER ACTION: See SIM157.
.p -9,2,5
SIM570 T ?OPEN ERROR ON FILE AAAA
.skip 1
	EXPLANATION: This may occur if the file is protected.
	AAAA is the name of the file.
	This error may have occurred in any of the three passes.
	The error may also be an internal compiler or system failure.
.skip 1
	USER ACTION: Check protection and recompile program.
.p -9,2,5
SIM571 T ?LOOKUP ERROR ON FILE AAAA
.skip 1
	EXPLANATION: This may occur if the file is protected.
	AAAA is the name of the file.
	This error may have occurred in any of the three passes.
	The error may also be an internal compiler or system failure.
.skip 1
	USER ACTION: Check protection and recompile program.
.skip 2
.indent -9
SIM572 T ?ENTER ERROR ON FILE AAAA
.skip 1
	EXPLANATION: This may occur if the file is protected.
	AAAA is the name of the file.
	This error may have occurred in any of the three passes.
        Another explanation may be that no space is available 
        because you are exceeding your disk quota.
	The error may also be an internal compiler or system failure.
.skip 1
	USER ACTION: Check protection and recompile program.
.skip 2
.test page 8
.indent -9
SIM573 T ?INPUT ERROR ON FILE AAAA
.skip 1
	EXPLANATION: This may occur if the file is protected.
	AAAA is the name of the file.
	This error may have occurred in any of the three passes.
	The error may also be an internal compiler or system failure.
.skip 1
	USER ACTION: Check protection and recompile program.
.skip 2
.indent -9
SIM574 T ?OUTPUT ERROR ON FILE AAAA
.skip 1
	EXPLANATION: This may occur if the file is protected.
	AAAA is the name of the file.
	This error may have occurred in any of the three passes.
	The error may also be an internal compiler or system failure.
.skip 1
	USER ACTION: Check protection and recompile program.
.skip 2
.test page 8
.indent -9
SIM575 T ?CLOSE ERROR ON FILE AAAA
.skip 1
	EXPLANATION: This may occur if the file is protected.
	AAAA is the name of the file.
	This error may have occurred in any of the three passes.
	The error may also be an internal compiler or system failure.
.skip 1
	USER ACTION: Check protection and recompile program.
.IF DUMMY
.skip 2
.indent -9
SIM576 T ?RENAME ERROR ON AAAA ERROR ON FILE
.skip 1
	EXPLANATION: This may occur if the file is protected.
	AAAA is the name of the file.
	This error may have occurred in any of the three passes.
	The error may also be an internal compiler or system failure.
.skip 1
	USER ACTION: Check protection and recompile program.
.break
.EI DUMMY
.IF DUMMY
.skip 3
END OF COMPILER SOURCE CODE DIAGNOSTICS
.EI DUMMY
.tab stops 1
.variable dummy2,f,g
.IF dummy2
** The dummy2 switch should not be set **
.EI dummy2
.subtitle APPENDIX D RUN-TIME AND DEBUG DIAGNOSTICS
.f;.nj;.sp 1;.lm 5;.ps 55,65
.pg;.p -5,2,0
APPENDIX D RUN-TIME AND DEBUG DIAGNOSTICS
.i -5
=========================================
.p -5,2,10
D.1##DIALOGUE MESSAGES
.s 2;These messages are printed by the I/O subsystem of the RTS.
Some of them start a dialogue with the user and some are
only warnings. A few messages also terminate execution.
The messages are unnumbered.
.s;You can transfer from the i/o error dialogue to SIMDDT by
pushing the ALTMODE (ESCAPE) button on your terminal.
.p -5,2,7
?APPEND OR RONLY EXPECTED AFTER ACCESS
.s
EXPLANATION: ACCESS switch must be followed by :APPEND or :RONLY
.s
RTS ACTION: The user is asked in dialoque to enter a new file definition.
.p -5,2,7
?CANNOT OPEN: device
.s
EXPLANATION: Device specified for SYSIN or SYSOUT not defined.
.s
USER ACTION: Retype correct device.
.p -5,2,7
?CANNOT OPEN DSK
.s
EXPLANATION: OPEN failed for a disk-like device.
.s
RTS ACTION: EXIT to monitor.
.p -5,2,7
CANNOT DO INPUT FROM DEVICE: devicename
.p -5,0,0
CANNOT DO OUTPUT TO DEVICE: devicename
.s
EXPLANATION: Illegal file class type - device type combination.
.s
USER ACTION: Retype correct device.
.p -5,2,7
CANNOT SWITCH DEVICE AT THIS STAGE
.s
EXPLANATION: This message is printed if the user tries to change a directory device
(i.e. DECtape or disk) after a LOOKUP or ENTER error. It is only
possible to switch between disk devices, e.g. from
DSKB to DSKD, or between DECtapes.
.s
USER ACTION: Retype correct device.
.p -5,2,7
?CLOSE ERROR ON: filename
.s
EXPLANATION: CLOSE error on specification file.
.s
RTS ACTION: EXIT to monitor.
.p -5,2,7
CLOSE ERROR ON SIMRTS.HLP
.s
RTS ACTION: HELP switch ignored.
.p -5,2,7
?CORE NOT AVAILABLE
.s
EXPLANATION: RTS tried to allocate core according to the file definitions
and switches in the specification file, but this core request
could not be met by the monitor.
.s
RTS ACTION: EXIT to monitor.
.p -5,2,7
?DEVICE devicename ILLEGAL
.s
EXPLANATION: Devicename does not exist.
.s
USER ACTION: Retype correct device name.
.p -5,2,7
?FILE filename NOT FOUND
.s
EXPLANATION:  LOOKUP failure on specification file.
.s
RTS ACTION: RTS reads new file descriptor from TTY.
.s
USER ACTION:  Retype file descriptor.
.p -5,2,7
HELP SWITCH MISPLACED. IGNORED
.s
EXPLANATION: The HELP switch is relevant only when file definitions are
read from TTY. HELP is also ignored in file parameters.
.p -5,2,7
I SWITCH IGNORED. FILE: logicalname IS NOT DIRECTFILE
.s
EXPLANATION: This is a warning message. IMAGESIZE is relevant for directfiles only.
.p -5,2,7
ILL DELIM AFTER LAST SWITCH
.s
EXPLANATION: Valid delimiter after a run-time switch is either 
space or carriage return.
.s
RTS ACTION: This is just a warning message.
.p -5,2,7
?ILL DELIM AFTER LOGICAL NAME
.s
EXPLANATION: Delimiter after logical name must be space, tab or carriage return.
.s
USER ACTION: Retype file definition.
.p -5,2,7
?ILLEGAL DELIMITER: "byte" IN FILE DESCRIPTOR
.s
EXPLANATION: Valid delimiters after a file descriptor are carriage return,
space, tab or slash.
.s
USER ACTION:  Retype file definition.
.p -5,2,7
?ILLEGAL PPN
.s
EXPLANATION: Right square bracket missing or ppn contains a digit > 7.
.s
USER ACTION: Retype correct ppn.
.p -5,2,7
?ILLEGAL PROTECTION CODE
.skip1
EXPLANATION: Right angle bracket missing or protection code contains a digit > 7.
.s
USER ACTION: Retype correct protection code.
.p -5,2,7
?ILL FILE DESC. ENTER NEW FILE DESC
.s
EXPLANATION: Illegal file descriptor was typed after LOOKUP or ENTER error.
.s
USER ACTION: Retype correct file descriptor.
.p -5,2,7
?ILL FILE DESCRIPTOR IN FILE PARAMETER
.s
EXPLANATION: The file descriptor in the parameter to NEW ...FILE("...") is illegal. This message
is normally preceded by one or more messages specifying the error(s).
.s;USER ACTION: Retype file class argument including logical name.
.p -5,2,7
IND SPEC FILE NOT FOUND
.s
EXPLANATION: LOOKUP error on indirect specification file.
.s
USER ACTION: Retype file descriptor for indirect specification file.
.p -5,2,7
L SWITCH IGNORED. FILE: logical name IS NOT AN OUTFILE OR PRINTFILE
.s
EXPLANATION:  LIMIT is not relevant for infile and directfile.
.p -5,2,7
LOCAL SWITCH: switch USED AS GLOBAL. IGNORED
.p -5,2,7
LOGICAL NAME: logical name ALREADY DEFINED
.s
EXPLANATION: This message is printed in connection with the SIMDDT USE command.
A USE file may not exist when the USE command is given.
.s
RTS ACTION: Retype the USE command.
.p -5,2,7
LOGICAL NAME: logical name ALREADY DEFINED. IGNORED
.s
EXPLANATION: Logical names must be unique in the specification file.
.s
RTS ACTION: The file definition is ignored.
.p -5,2,7
LOOKUP FAILURE ON SIMRTS.HLP
.s
RTS ACTION: HELP switch ignored.
.p -5,2,7
?LOOKUP OR ENTER ERROR (nnn) ON FILE: file specification
.s
EXPLANATION:  The code nnn indicates the type of error. The following codes are used:
.break
000##File not found
.break
010##User file directory does not exist on current file
.break
#####structure, usually incorrect ppn.
.break
020##Protection failure or directory full on DECtape
.break
003##File being modified
.break
014##Disk quota exceeded
.break
015##Write-lock error
.break
016##Not enough table space in monitor
.break
017##Partial allocation only. The requested space allocation
.break
#####could not be met.
.break
021##Cannot supersede an existing directory
.break
023##Sub-directory not found.
.s
Other error codes usually indicate internal RTS error.
.s
The file specification contains the information which is currently known
about the file. Empty fields indicate standard value.
.s
USER ACTION: Retype file descriptor (no logical name!)
.p -5,2,7
NESTED IND FILES NOT ALLOWED. IGNORED
.s
EXPLANATION: An indirect specification file contains a specification
file definition.
.p -5,2,7
?NULL ARG AFTER SWITCH: switch
.s
EXPLANATION: Argument after colon is either 0 or missing.
.s
USER ACTION: Retype the entire file definition.
.p -5,2,7
ONLY DSK ALLOWED
.s
EXPLANATION: Device can only be disk after retyping the definition
of a specification file.
.s
RTS ACTION: DSK assumed.
.p -5,2,7
?PROJ NO NOT FOLLOWED BY COMMA
.s
USER ACTION: Retype file definition.
.p -5,2,7
?PROT CODE EXCEEDS THREE DIGITS
.s
USER ACTION: Retype file definition.
.p -5,2,7
?READ ERROR ON: filename
.s
EXPLANATION: Read error occurred on a specification file.
.s
RTS ACTION: EXIT to monitor.
.p -5,2,7
?READ ERROR ON SIMRTS.HLP
.s
RTS ACTION: HELP switch ignored.
.p -5,2,7
SPEC FILE STILL OPEN AS SYSIN. LINE IGNORED
.s
EXPLANATION: When SYSIN is used as indirect specification file, no more indirect
files are allowed.
.p -5,2,7
SWITCH: switch MISSPELLED
.s
RTS ACTION: Switch processed according to first letter.
.p -5,2,7
SWITCH: switch NOT FOLLOWED BY COLON
.s
EXPLANATION:##All run-time switches except HELP must be
followed by colon and an argument.
.s
USER ACTION:##Retype file definition.
.p -5,2,7
SWITCH: switch NOT FOLLOWED BY DECIMAL NUMBER
.s
USER ACTION:##Retype file definition.
.p -5,2,7
SWITCH: switch NOT RECOGNIZED
.s
EXPLANATION:##First letter of the switch not a legal switch name.
.s
USER ACTION:##Retype file definition.
.p -5,2,7
SYSIN ALREADY READ. LINE IGNORED
.s
EXPLANATION:##File definitions can be read from SYSIN only once.
.p -5,2,7
?TOO DEEP SFD NESTING
.s
EXPLANATION:##The maximum number of sub-file directories (an installation
defined parameter) is exceeded.
.s
USER ACTION:##Retype the file definition.
.p -5,2,10
?TTY END OF FILE OR TTY INPUT ERROR
.s
EXPLANATION: The user has typed a _^Z or an input
error was detected.
.s
RTS ACTION: EXIT to monitor, i.e. _^Z works as _^C.
A CONTINUE command, if given, will cause a final EXIT from the program,
i#e# execution cannot then be continued any more.
.s
USER ACTION: Use _^C instead of _^Z. It is then possible
to resume execution with the CONTINUE command.
.p -5,2,7
WARNING: APPEND MODE IGNORED FOR DIRECTFILE
.p -5,0,0
WARNING: APPEND MODE IGNORED FOR INFILE
.p -5,0,0
WARNING: APPEND MODE IGNORED FOR NON-DISK DEVICES
.s
EXPLANATION:##Append mode is valid only for printfiles and outfiles on disk.
.p -5,2,7
WARNING: DEVICE NOT DSK FOR DIRECTFILE. DSK ASSUMED.
.s
EXPLANATION:## Device can only be disk for directfile.
.p -5,2,7
WARNING: DEVICE NOT DSK FOR SPECIFICATION FILE. DSK ASSUMED.
.s
EXPLANATION:##Specification files can only be read from disk or TTY.
.s
RTS ACTION:##RTS tries to lookup the file on DSK.
.p -5,2,7
WARNING: FILES MUST BE A GLOBAL SWITCH. FILES IGNORED
.p -5,2,7
WARNING: NO SWITCH NAME FOUND. IGNORED
.s
EXPLANATION:##Slash is followed by slash, space, tab or carriage return.
.p -5,2,7
WARNING: PROJ OR PROG NUMBER TRUNCATED
.s
EXPLANATION:##Project or programmer number exceeds 6 digits.
.s
RTS ACTION:##Only the first 6 digits are used.
.p -5,2,7
WARNING: SFD IGNORED
.s
EXPLANATION:##Sub-file directories cannot be used for specification files.
.p -5,2,7
WARNING: SWITCHES IGNORED
.s
EXPLANATION:## Switches do not apply to definitions of a specification file.
.p -5,2,7
WARNING: TOO MANY BUFFERS FOR FILE: logical name. 2 STANDARD BUFFERS ASSUMED
.s
EXPLANATION:##A value greater than 32 of the BUFFER switch argument is
applicable to magnetic tape only.
^^
.paper size 55,65
.nojustify
.spacing 1
.fill
.left margin 0
.subtitle APPENDIX D.2 RUN-TIME AND DEBUG DIAGNOSTICS
.page
.index ^^Error messages, at run time
.index ^^Messages, error, at run time
.index ^^Diagnostic messages at run time
.index ^^Run time error messages
.index ^^Object time error messages
.index ^^Execution time error messages
.s 2
D.2 RUN-TIME AND DEBUG DIAGNOSTICS:
.skip 2
.left margin 9
.IF dummy2
EXPLANATION:
.EI dummy2
.break
	The messages starting with ZYQ apply to the run time system (RTS),
	except for SIMDDT, which has its own messages starting with ZYD. A few
	of the ZYQ messages may be issued by SIMDDT, with ZYQ changed to ZYD.
	The RTS action on any of the ZYQ errors is to invoke SIMDDT in error
	mode. SIMDDT prints the error message and indicates where the error
	occurred. Commands can be entered to SIMDDT to find out more information
	about variables, state of execution etc. By the EXIT command to
	SIMDDT, files are closed and the SIMULA program is terminated.
	If you do not want to close files, exit via _^C.

.skip 2
For some of the ZYQ messages it is possible to continue execution of the SIMULA program
with the SIMDDT command "PROCEED". Note that SIMDDT may be used to
investigate the cause of the error before the execution
is continued.
.skip 2
	In addition to the numbered messages, the following messages
	may appear on the TTY or the batch log:
.s
.indent -9
[ZYQCCS Current SIMDDT command suppressed]
.s
EXPLANATION:##REENTER was issued while SIMDDT was active. This is a way of suppressing
lengthy output resulting from a SIMDDT command and to return to SIMDDT
command level as quickly as possible. Preferred to using _^O, which only
suppresses the actual output, but does not stop the command execution.
.skip 2
.indent -9
[ZYQCSH Cannot stop here]
.s
EXPLANATION:##REENTER was attempted at a point where SIMDDT cannot be called
	because data may not be consistent.
.s
USER ACTION:##Try again to stop and reenter.
.skip 2
.indent -9
%ZYQCUF CORE UUO failed. Cannot load SIMDDT
.s
EXPLANATION:##The program is too big to allow for SIMDDT.
.skip 2
.indent -9
%ZYQEDO nn EDIT OVERFLOW(S)
.s
EXPLANATION:##In nn cases, the field width in an output editing operation, e g
	PUTREAL, was too small to hold the number. Asterisks were edited into
	the field.
.s
USER ACTION:##Examine output fields for asterisks. Correct the program.
.p -9,2,3
[ZYQEIR Error in routine: XXXXXX]
.s
EXPLANATION:##An error has occurred in a subroutine such as SQRT taken from the FORTRAN library.
	XXXXXX should be the name of the entry point of the routine.
.s
	A subsequent ZYQ message issued by SIMDDT gives more information.
	Some library routines have inline messages for errors. Such a message
	will be typed following the above message.
.p -9,2,3
%ZYQFLE <text>
.s
EXPLANATION:##An error has occurred in a subroutine such as SQRT taken from the FORTRAN library.
	<text> is a string provided by the subroutine. This
	message is preceded by a ZYQEIR message.
.p -9,2,3
%ZYQIUF IN UUO failed. Cannot load SIMDDT
.s
EXPLANATION:##Probably a DECsystem-10 error. Consult a systems programmer.
.p -9,2,3
%ZYQLUF LOOKUP UUO failed. Cannot load SIMDDT
.s
EXPLANATION:##SIMDDT.ABS is not available on the device (normally SYS), or a
	system error has occurred. Consult a systems programmer.
.p -9,2,3
?ZYQNCA No core available - can not proceed
.s
EXPLANATION: The program cannot run with too small core size.
.s
USER ACTION:##If possible, allocate more core (virtual and/or physical)
	 and try again.
.p -9,2,3
%ZYQNEC Not enough core. Cannot load SIMDDT
.s
EXPLANATION:##The program is too big to allow for SIMDDT.
.s
USER ACTION:##See ZYQNCA.
.s
RTS ACTION:###The program continues without SIMDDT.
.p -9,2,3
%ZYQNIO No free I/O channel. Cannot load SIMDDT
.s
EXPLANATION:##Probably a SIMULA system or user error.
	If an external MACRO-10 procedure is doing I/O, check it.
	Consult a systems programmer if the error cannot be located.
.p -9,2,3
[ZYQNYI RTS not yet initialised, continuing ...]
.s
EXPLANATION:##REENTER was used too early after program start. Try later.
.p -9,2,3
%ZYQOUF OPEN UUO failed. Cannot load SIMDDT
.s
EXPLANATION:##Probably a DECsystem-10 error. Consult a systems programmer.
.sk 2;.i -9
[ZYQPID Please input a line of data so SIMDDT can be entered]
.sk 1
EXPLANATION:##The program was interrupted by _^C while waiting for input from
	the terminal. SIMDDT cannot be entered until Inimage has returned with
	a line of data. The data given should be valid input to the program.
	Usually, hitting carriage return will do (a blank line).
.p -9,2,3
?ZYQREZ SIMULA RTS Error ZYQnnn
.s
EXPLANATION:##Since SIMDDT could not be loaded, the proper error message could
	not be issued. Look up the message ZYQnnn in this handbook.
.p -9,2,3
%ZYQSFS STOP statement executed or EXIT called in FORTRAN subprogram
.s
EXPLANATION:##An external FORTRAN subroutine attempted to stop execution
	by a STOP statement or CALL EXIT. Handled as if control had passed
	through the final END of the SIMULA main program.
.p -9,2,3
%ZYQUFL nn UNDERFLOW(S)
.s
EXPLANATION: In nn cases, an arithmetic operation has given a result too
	small to be normalized. Zero was substituted as result.
.p -9,2,10
The following messages are issued by SIMDDT:
.p -9,2,3
ZYQ001###Source program error
.s
.index ^^Erroneous programs, treatment of, error message
EXPLANATION:##An incorrect part of the source program has been compiled as an error UUO.
.s
SIMDDT ACTION:##The error message is followed by the text:
.break
.s
	TO CONTINUE TYPE PROCEED
.s
.break
	At exit from SIMDDT the user may give a PROCEED command
	to continue the execution of the SIMULA program.
.s
RTS ACTION:##The execution continues with the next compiled statement.
	The effect of continuing execution is unpredictable except in very
	simple cases.
.p -9,2,3
ZYQ002###Array index out of bounds
.index ^^ARRAY subscript, error message
.p -9,2,3
ZYQ003###QUA error
.s
EXPLANATION:##In an expression of the form "X QUA C", X does not refer to a
		C object or an object belonging to a subclass of C.
.p -9,2,3
ZYQ004###Illegal denotes or wrong parameter qualification
.s
EXPLANATION:##See explanation for ZYQ003. ZYQ004 results from an implicit QUA
              check generated for a denotes (:-) statement or when a REF(...)
              parameter is passed to a class or procedure.
.p -9,2,3
ZYQ005###No match for virtual quantity
.skip 1
EXPLANATION:##The quantity (procedure, switch or label) was specified virtual,
	but no matching declaration is available at any prefix level of the
	class object to which the quantity should belong, i e the current
	class, prefixed block, inspection block or the class object referred
	to by the quantity before the dot in case of remote access.
.p -9,2,5
ZYQ006###CHAR argument out of bounds
.skip 1
EXPLANATION:##Argument must be >= 0 and <=127.
.skip 2
SIMDDT ACTION: The error message is followed by the text:
.break
.skip 1
	TO CONTINUE TYPE PROCEED
.skip 1
.break
	At exit from SIMDDT the user may give a PROCEED command
	to continue the execution of the simula program.
	If PROCEED is given the following text is issued:
.break
.skip 1
	GIVE NEW INTEGER ARGUMENT
.skip 1
.break
	after which the user must enter an integer.
	The execution is then continued.
.p -9,2,3
ZYQ007###Wrong number of subscripts
.skip 1
EXPLANATION:##A formal array was used with wrong number of subscripts.
.p -9,2,3
ZYQ010###OCERC###0,Too many files
.skip 1
EXPLANATION:##At most 14 files can be active at the same time.
.index ^^File handling at run time, error message
.skip 1
SIMDDT ACTION:##The error message is followed by the text:
.break
.skip 1
	TO CONTINUE TYPE PROCEED
.skip 1
.break
	At exit from SIMDDT the user may give a PROCEED command
	to continue the execution of the SIMULA program.
.skip 1
RTS ACTION:##When the execution is resumed RTS will again try
	to assign a free I/O channel.
.skip 1
USER ACTION:##The user must close one or more files with the
	SIMDDT command CLOSE before the PROCEED command is used.
.p -9,2,3
ZYQ011###OCERR###1,Pushdown list underflow
.skip 1
EXPLANATION:##Should not occur. Wild jumps may have been executed as
		a result of removing the checking of array subscripts
		(-A) or qualification (-Q), or an external MACRO-10 or
		FORTRAN procedure may have run wild.
.skip 1
USER ACTION:##If none of the above applies, report the error.
.p -9,2,3
ZYQ012###OCERC###12,SIMDDT entered after file spec error
.skip 1
EXPLANATION: This error occurs when the user escapes the dialogue with altmode.
.skip 1
SIMDDT ACTION:##The error message is followed by the text:
.break
.skip 1
	TO CONTINUE TYPE PROCEED
.skip 1
.break
	At exit from SIMDDT the user may give a PROCEED command
	to continue the execution of the SIMULA program.
.skip 1
RTS ACTION:##If the user types PROCEED the dialogue is restarted.
.p -9,2,3
ZYQ013###OCERR###3,OPEN failure
.index ^^Input-output at run time, error message
.index ^^I/O at run time, error message
.skip 1
EXPLANATION: Failure when trying to OPEN the channel for SYSIN or SYSOUT.
.p -9,2,3
ZYQ014###OCERR###4,FILE(S) OPEN AT EXIT. DO [STOP] CLOSE OR EXIT

.index ^^close files
.skip 1
EXPLANATION: At end of execution some files other than SYSIN and SYSOUT were open.
.skip 1
USER ACTION: Use the [STOP] CLOSE command in SIMDDT to close all or some of files.
.p -9,2,3
ZYQ015###OCERR###5,Object NONE
.skip 1
EXPLANATION:##An attempt was made to refer to an attribute of a non-existent
	class object (or to a not yet allocated array object).
.p -9,2,3
ZYQ016###OCERR###6,Illegal memory reference
.skip 1
EXPLANATION:##Probably a SIMULA system error or a user error in an external
MACRO-10 or FORTRAN procedure.
It may also be a user error in the SIMULA program or an
external SIMULA procedure or class,
if compile-time checking was partially turned off (-A or -Q switches).
If so, try running with those checks on. If the error persists,
check any external MACRO 10 or FORTRAN procedure for errors
before reporting the trouble.
.p -9,2,3
ZYQ017###OCERC###7,Integer overflow or division by zero
.skip 1
EXPLANATION:##An arithmetic operation has exceeded the valid number range,
              or attempted to divide by zero.
.skip 1
SIMDDT ACTION:##The error message is followed by the text:
.break
.skip 1
	TO CONTINUE TYPE PROCEED
.skip 1
.break
	At exit from SIMDDT the user may give a PROCEED command
	to continue the execution of the SIMULA program.
	The operation will return maxint = 2_^35-1.
.p -9,2,3
ZYQ020###OCERC###10,Floating point overflow or division by zero
.skip 1
EXPLANATION:##A floating point operation gives a result outside of the
              available number range, or division by zero is attempted.
.skip 1
SIMDDT ACTION:##The error message is followed by the text:
.break
.skip 1
	TO CONTINUE TYPE PROCEED
.skip 1
.break
	At exit from SIMDDT the user may give a PROCEED command
	to continue the execution of the SIMULA program.
	The operation will return maxreal = approx 1.7_&38.
.p -9,2,3
ZYQ021###CPERC###0,RESUME: object NONE
.index ^^Quasi-parallel processing, error message
.index ^^Coroutine handling, error message
.index ^^DETACH, error message
.index ^^RESUME, error message
.skip 1
SIMDDT ACTION:##The error message is followed by the text:
.break
.skip 1
	TO CONTINUE TYPE PROCEED
.skip 1
.break
	At exit from SIMDDT the user may give a PROCEED command
	to continue the execution of the SIMULA program.
.p -9,2,3
ZYQ022###CPERC###1,RESUME: terminated class instance
.skip 1
SIMDDT ACTION:##The error message is followed by the text:
.break
.skip 1
	TO CONTINUE TYPE PROCEED
.skip 1
.break
	At exit from SIMDDT the user may give a PROCEED command
	to continue the execution of the SIMULA program.
.p -9,2,3
ZYQ023###CPERC###2,RESUME: attached class instance
.skip 1
SIMDDT ACTION:##The error message is followed by the text:
.break
.skip 1
	TO CONTINUE TYPE PROCEED
.skip 1
.break
	At exit from SIMDDT the user may give a PROCEED command
	to continue the execution of the SIMULA program.
.p -9,2,3
ZYQ024###CPERR###3,RESUME: operating class instance
.p -9,2,3
ZYQ025###CPERC###4,CALL: object NONE
.skip 1
SIMDDT ACTION:##The error message is followed by the text:
.break
.skip 1
	TO CONTINUE TYPE PROCEED
.skip 1
.break
	At exit from SIMDDT the user may give a PROCEED command
	to continue the execution of the SIMULA program.
.p -9,2,3
ZYQ026###CPERC###5,CALL: terminated class instance
.skip 1
SIMDDT ACTION:##The error message is followed by the text:
.break
.skip 1
	TO CONTINUE TYPE PROCEED
.skip 1
.break
	At exit from SIMDDT the user may give a PROCEED command
	to continue the execution of the SIMULA program.
.p -9,2,3
ZYQ027###CPERC###6,CALL: attached class instance
.skip 1
SIMDDT ACTION:##The error message is followed by the text:
.break
.skip 1
	TO CONTINUE TYPE PROCEED
.skip 1
.break
	At exit from SIMDDT the user may give a PROCEED command
	to continue the execution of the SIMULA program.
.p -9,2,3
ZYQ030###CPERR###7,CALL: operating class instance
.p -9,2,3
ZYQ036###CSERR###1,Undefined GOTO
.skip 1
.index ^^GO TO, error message
.index ^^Jumps, error message
EXPLANATION:##The target of the GOTO statement is not operating.
.p -9,2,3
ZYQ037###CSERR###2,Illegal GOTO
.skip 1
EXPLANATION:##Attempt to leave a detached class instance by a GOTO.
.p -9,2,3
ZYQ040###CSERR###3,Too big array
.skip 1
EXPLANATION:##The size of the array would be > 2_^18 words.
.p -9,2,3
ZYQ041###CSERR###4,Upper bound of array < lower bound
.skip 1
.index ^^ARRAY size, error message
.index ^^Capacity limitations, error message
.p -9,2,3
ZYQ042###CSERR###5,Cannot use switch in terminated class
.skip 1
.index ^^SWITCHes, error messages
EXPLANATION:##Cannot use a switch in a terminated class instance.
.p -9,2,3
ZYQ043###CSERR###6,Procedure should have no parameters
.skip 1
EXPLANATION:##Attempt to call a parameterless formal or virtual procedure with an actual parameter list.
.p -9,2,3
ZYQ044###CSERR###7,Parameters missing
.skip 1
EXPLANATION:##Attempt to call a formal or virtual procedure with specified
parameters without supplying an actual parameter list.
.p -9,2,3
ZYQ051###IOERR###0,File not open
.skip 1
.index ^^File handling at run time, error message
.index ^^Input-output at run time, error message
.index ^^I/O at run time, error message
EXPLANATION: File not opened when (a) OUTIMAGE, OUTTEXT or another
output procedure was called.
(b) LOCATE was called.
.p -9,2,3
ZYQ052###IOERR###1,OPEN failure
.s
EXPLANATION:
.br;a) The requested device is in use and cannot be shared
.br
              b) The requested device does not exist
.br
              c) The device is restricted and has not been assigned via a
                MOUNT command.
.p -9,2,3
ZYQ053###IOERR###2,File already assigned to TTY
.s
EXPLANATION:##Only one file may be assigned to the output or the input side of the TTY.
.p -9,2,3
ZYQ054###IOERR###3,Transfer failure
.s
EXPLANATION:##A read or write operation failure.
.p -9,2,3
ZYQ055###IOERC###4,File already open
.s
SIMDDT ACTION:##The error message is followed by the text:
.s
	TO CONTINUE TYPE PROCEED
.s
	At exit from SIMDDT the user may give a PROCEED command
	to continue the execution of the SIMULA program.
.s
RTS ACTION:##The OPEN call is ignored after PROCEED.
.p -9,2,3
ZYQ056###IOERC###5,File already closed
.s
SIMDDT ACTION:##The error message is followed by the text:
.s
	TO CONTINUE TYPE PROCEED
.s
	At exit from SIMDDT the user may give a PROCEED command
	to continue the execution of the SIMULA program.
.s
RTS ACTION:##The CLOSE call is ignored after PROCEED.
.p -9,2,3
ZYQ057###IOERC###6,CLOSE failure
.s
EXPLANATION: Write operation failure in CLOSE procedure.
.s
SIMDDT ACTION:##The error message is followed by the text:
.s
	TO CONTINUE TYPE PROCEED
.s
	At exit from SIMDDT the user may give a PROCEED command
	to continue the execution of the SIMULA program.
.s
RTS ACTION:##The CLOSE call is ignored after PROCEED.
.p -9,2,3
ZYQ060###IOERR###7,EOF in INIMAGE
.s
EXPLANATION: ENDFILE procedure returned TRUE when INIMAGE was called.
.p -9,2,3
ZYQ061###IOERR###10,External image too long
.s
EXPLANATION:##The external image (string of characters finished by LF, FF,
              VT, or altmode) cannot fit into the image text.
.p -9,2,3
ZYQ062###IOERR###11,Image too large
.s
EXPLANATION:##The internal image is too long for imagesize of a directfile.
.p -9,2,3
ZYQ063###IOERC###12,EJECT: argument out of range
.s
EXPLANATION:##The argument to EJECT is <= 0.
.s
SIMDDT ACTION: The error message is followed by the text:
.s
	TO CONTINUE TYPE PROCEED
.s
	At exit from SIMDDT the user may give a PROCEED command
	to continue the execution of the simula program.
	If PROCEED is given the following text is issued:
.s
	GIVE NEW INTEGER ARGUMENT
.s
	after which the user must enter an integer.
	The execution is then continued.
.p -9,2,3
ZYQ064###IOERC###13,SPACING: argument out of range
.s
EXPLANATION:##The argument to SPACING is < 0 or > LINESPERPAGE.
.s 2
SIMDDT ACTION: The error message is followed by the text:
.s
	TO CONTINUE TYPE PROCEED
.s
	At exit from SIMDDT the user may give a PROCEED command
	to continue the execution of the simula program.
	If PROCEED is given the following text is issued:
.s
	GIVE NEW INTEGER ARGUMENT
.s
	after which the user must enter an integer.
	The execution is then continued.
.p -9,2,3
ZYQ065###IOERC###14,Output field width out of range
.s
EXPLANATION:##For an output editing procedure, the requested field width is
              negative or zero or does not fit into an output image.
.s
SIMDDT ACTION: The error message is followed by the text:
.s
	TO CONTINUE TYPE PROCEED
.s
	At exit from SIMDDT the user may give a PROCEED command
	to continue the execution of the simula program.
	If PROCEED is given the following text is issued:
.s
	GIVE NEW INTEGER ARGUMENT
.s
	after which the user must enter an integer.
	The execution is then continued.
.p -9,2,3
ZYQ066###IOERC###15,Output limit exceeded
.s
EXPLANATION:##The number of blocks written to an outfile (printfile) has reached
              the limit established with a LIMIT switch in the file specification.
.s
SIMDDT ACTION:##The error message is followed by the text:
.s
	TO CONTINUE TYPE PROCEED
.s
	At exit from SIMDDT the user may give a PROCEED command
	to continue the execution of the SIMULA program.
.s
RTS ACTION:##The limit is set to 0, i.e. no limit if the
	user continues execution.
.p -9,2,3
ZYQ067###IOERR###16,OUTIMAGE (DIRECTFILE): LOC <= 0
.s
SIMDDT ACTION: The error message is followed by the text:
.s
	TO CONTINUE TYPE PROCEED
.s
	At exit from SIMDDT the user may give a PROCEED command
	to continue the execution of the simula program.
	If PROCEED is given the following text is issued:
.s
	GIVE NEW INTEGER ARGUMENT
.s
	after which the user must enter an integer.
	The execution is then continued.
.p -9,2,3
ZYQ070###IOERR###17,OUTIMAGE (DIRECTFILE). File is read-only
.p -9,2,3
ZYQ071###IOERR###20,INCHAR: end of file
.p -9,2,3
ZYQ072###IOERR###21,ININT: INREAL: INFRAC: end of file
.p -9,2,3
ZYQ074###IOERR###23,INTEXT: end of file
.p -9,2,3
ZYQ075###IOERC###24,INTEXT: length out of range
.s
EXPLANATION:##The specified length must be >= 0 and < 2_^18
.s
SIMDDT ACTION: The error message is followed by the text:
.s
	TO CONTINUE TYPE PROCEED
.s
	At exit from SIMDDT the user may give a PROCEED command
	to continue the execution of the simula program.
	If PROCEED is given the following text is issued:
.s
	GIVE NEW INTEGER ARGUMENT
.s
	after which the user must enter an integer.
	The execution is then continued.
.p -9,2,3
ZYQ076###IOERC###25,Too long input line
.s
EXPLANATION:##The input line cannot fit into the image text.
.s
USER ACTION:##A new input line can be given after the PROCEED command.
.p -9,2,3
.index ^^PROCEDURE call, error message
.index ^^Parameters to PROCEDUREs, error message
ZYQ100###PHERR###0,Actual parameter is an expression - assignment is illegal
.p -9,2,3
ZYQ101###PHERR###1,Function name passed as actual parameter - value needed
.s
EXPLANATION:##The actual parameter is just a procedure name, but a value is
	required.
.p -9,2,6
ZYQ102###PHERR###2,Invalid actual parameter to "QUICK" procedure - incorrect type or too complicated
.s
EXPLANATION: This corresponds to either of the compile-time errors SIM417
	or SIM420. See these. The error could not be determined at compile time.
.p -9,2,3
ZYQ103###PHERR###3,Assignment to formal parameter - r.h.s. not subclass of l.h.s.
.p -9,2,3
ZYQ104###PHERR###4,Illegal use of a parameter which is a text constant
.s
EXPLANATION:##A text constant, passed as an actual parameter which 
	matches a text parameter by name, is used in a place where a
	text constant is not allowed, e#g on the right or left hand side of an
	(implied or explicit) denotes (:-) statement, on the left hand
	side of an assignment statement or in another context which would affect
	the contents of the text constant or change its position indicator.
.s
USER ACTION:##Specify the formal parameter by value or use COPY on the
	calling side.
.p -9,2,3
ZYQ106###PHERR###6,Wrong number of parameters to formal or virtual procedure
.p -9,2,3
ZYQ107###PHERR###7,Wrong actual parameter type
.p -9,2,3
ZYQ110###PHERR###10,Text constant by reference is illegal
.s
USER ACTION:##See app. C, message SIM366.
.p -9,2,3
ZYQ111###PHERR###11,Wrong qualification on actual parameter
.p -9,2,3
ZYQ112###PHERR###12, Actual/formal types incompatible
.p -9,2,3
ZYQ113###PHERR###13,Wrong kind of actual parameter
.p -9,2,3
ZYQ121###RDERR###1,DISCRETE: wrong number of subscripts
.p -9,2,3
ZYQ122###RDERR###2,ERLANG: first parameter not positive
.index ^^Random drawing, error message
.index ^^Pseudo-random drawing, error message
.p -9,2,3
ZYQ123###RDERR###3,ERLANG: second parameter not positive
.p -9,2,3
ZYQ124###RDERR###4,HISTD: wrong number of subscripts
.p -9,2,3
ZYQ125###RDERR###5,HISTO: wrong number of subscripts
.p -9,2,3
ZYQ126###RDERR###6,HISTO: incompatible array parameters
.p -9,2,3
ZYQ127###RDERR###7,LINEAR: wrong number of subscripts
.p -9,2,3
ZYQ130###RDERR###10,LINEAR: array bounds do not match
.p -9,2,3
ZYQ131###RDERR###11,NEGEXP: first argument not positive
.p -9,2,3
ZYQ132###RDERR###12,NORMAL: standard deviation not positive
.p -9,2,3
ZYQ133###RDERR###13,RANDINT or UNIFORM: interval negative
.p -9,2,3
ZYQ134###RDERR###14,RANDINT or UNIFORM: too long interval
.p -9,2,3
ZYQ135###SAERR###0,Garbage collection not possible
.s
EXPLANATION:##The SIMDDT command USE may invoke the Garbage Collector
		in a state when a garbage collection cannot be done.
		This can occur after certain run time errors.
.s
USER ACTION:##Do not issue the USE command in this case.
.p -9,2,3
ZYQ136###SAERR###1,Cannot get enough core for object pool
.s
EXPLANATION:##The requisite data area could not be allocated for the SIMULA
		program to run. This error will sometimes occur when
		a separately compiled module used by your program
		was not loaded.
.s
USER ACTION:##Obtain more core if possible or try to make core
		requirements smaller.
.p -9,2,3
ZYQ144###SUERR###1,EVTIME: object NONE
.index ^^SIMULATION, CLASS, error message
.p -9,2,3
ZYQ145###SUERR###2,EVTIME: passive process
.p -9,2,3
ZYQ146###SUERR###3,Reactivation of terminated process
.p -9,2,3
ZYQ147###SUERR###4,SQS empty
.s
EXPLANATION:##The last active process has been taken out of the sequencing set,
		and no process can be resumed. This is usually caused by 
		cancelling or passivating the main program of SIMULATION.
.s
USER ACTION:##Activate the main program at some remote time. Do not cancel
	or passivate main.
.p -9,2,3
ZYQ154###TXERR###0,NOTEXT in editing procedure
.p -9,2,3
ZYQ155###TXERR###1,PUTFRAC or OUTFRAC: number of digits negative
.p -9,2,3
ZYQ156###TXERC###2,PUTFIX or OUTFIX: number of digits negative
.s
SIMDDT ACTION: The error message is followed by the text:
.s
	TO CONTINUE TYPE PROCEED
.s
	At exit from SIMDDT the user may give a PROCEED command
	to continue the execution of the simula program.
	If PROCEED is given the following text is issued:
.s
	GIVE NEW INTEGER ARGUMENT
.s
	after which the user must enter an integer.
	The execution is then continued.

.p -9,2,3
ZYQ157###TXERC###3,PUTREAL or OUTREAL: number of digits negative
.s
SIMDDT ACTION: The error message is followed by the text:
.s
	TO CONTINUE TYPE PROCEED
.s
	At exit from SIMDDT the user may give a PROCEED command
	to continue the execution of the simula program.
	If PROCEED is given the following text is issued:
.s
	GIVE NEW INTEGER ARGUMENT
.s
	after which the user must enter an integer.
	The execution is then continued.
.p -9,2,3
ZYQ160###TXERC###4,PUTCHAR: pos out of range
.s
SIMDDT ACTION: The error message is followed by the text:
.s
	TO CONTINUE TYPE PROCEED
.s
	At exit from SIMDDT the user may give a PROCEED command
	to continue the execution of the simula program.
	If PROCEED is given the following text is issued:
.s
	GIVE NEW INTEGER ARGUMENT
.s
	after which the user must enter an integer.
	The execution is then continued.
.p -9,2,3
ZYQ161###TXERC###5,GETCHAR: pos out of range
.index ^^TEXT editing, error message
.s
SIMDDT ACTION: The error message is followed by the text:
.s
	TO CONTINUE TYPE PROCEED
.s
	At exit from SIMDDT the user may give a PROCEED command
	to continue the execution of the simula program.
	If PROCEED is given the following text is issued:
.s
	GIVE NEW INTEGER ARGUMENT
.s
	after which the user must enter an integer.
	The execution is then continued.
.p -9,2,3
ZYQ162###TXERC###6,SUB: 1st parameter out of range
.s
SIMDDT ACTION: The error message is followed by the text:
.s
	TO CONTINUE TYPE PROCEED
.s
	At exit from SIMDDT the user may give a PROCEED command
	to continue the execution of the simula program.
	If PROCEED is given the following text is issued:
.s
	GIVE NEW INTEGER ARGUMENT
.s
	after which the user must enter an integer.
	The execution is then continued.
.p -9,2,3
ZYQ163###TXERC###7,SUB: 2nd parameter out of range
.s
SIMDDT ACTION: See above  message ZYQ162.
.p -9,2,3
ZYQ164###TXERC###10,Text assignment: r.h.s. text too long
.s
SIMDDT ACTION:##The error message is followed by the text:
.s
	TO CONTINUE TYPE PROCEED
.s
	At exit from SIMDDT the user may give a PROCEED command
	to continue the execution of the SIMULA program.
.s
RTS ACTION:##The text is truncated to the right after PROCEED.
.p -9,2,3
ZYQ165###TXERR###11,GETINT: no digits found or number too large
.s
EXPLANATION: The first character that caused the error
is printed. If this character is a digit, then the number is too large.
.p -9,2,3
ZYQ166###TXERR###12,GETREAL: did not find digits
.p -9,2,3
ZYQ167###TXERR###13,GETREAL: item too large
.p -9,2,3
ZYQ170###TXERR###14,GETFRAC: no item found or item too large
.s
EXPLANATION: The first character that caused the error is printed.
If this character is a digit, then the number is too large.
.p -9,2,3
ZYQ171###TXERC###15,BLANKS: parameter out of range
.s
SIMDDT ACTION: The error message is followed by the text:
.s
	TO CONTINUE TYPE PROCEED
.s
	At exit from SIMDDT the user may give a PROCEED command
	to continue the execution of the simula program.
	If PROCEED is given the following text is issued:
.s
	GIVE NEW INTEGER ARGUMENT
.s
	after which the user must enter an integer.
	The execution is then continued.
.p -9,2,3
ZYQ172###TXERR###16,LOWTEN: Illegal parameter
.p -9,2,3
ZYQ173###TXERC###17,ININT: no digits found or number too large
.s
EXPLANATION: The first character that caused the error
is printed. If this character is a digit, then the number is too large.
.s
USER ACTION:##After the PROCEED command the input text where the error occurred
is displayed and the user can give a new input line to replace this text.
.p -9,2,3
ZYQ174###TXERC###20,INREAL: did not find digits
.s
USER ACTION:##After the PROCEED command the input text where the error occurred
is displayed and the user can give a new input line to replace this text.
.p -9,2,3
ZYQ175###TXERC###21,INREAL: item too large
.s
USER ACTION:##After the PROCEED command the input text where the error occurred
is displayed and the user can give a new input line to replace this text.
.p -9,2,3
ZYQ176###TXERC###22,INFRAC: no item found or item too large
.s
EXPLANATION: The first character that caused the error is printed.
If this character is a digit, then the number is too large.
.s
USER ACTION:##After the PROCEED command the input text where the error occurred
is displayed and the user can give a new input line to replace this text.
.p -9,2,3
ZYQ212###Debug mode entered from line
.s
.index ^^ENTERDEBUG procedure, SIMDDT message
EXPLANATION:##SIMDDT was entered via the ENTERDEBUG procedure. Execution may continue after issuing
any SIMDDT commands which may be useful.
.p -9,2,3
ZYQ213###Execution terminated via ABORT procedure
.s
.index ^^ABORT procedure, SIMDDT message
EXPLANATION:##Invoked via the ABORT utility procedure. If a message was given as
parameter, ABORT has output that message to the terminal and to Sysout if
Sysout is not the terminal.
.p -9,2,3
ZYQ214###Error in utility procedure
.s
EXPLANATION:##Reserved error number for errors in utility procedures (usually written in MACRO-10)
.p -9,2,3
ZYQ215###Error in FORTRAN library subroutine
.s
.index ^^Mathematical functions, error message
.index ^^FORTRAN library, error message
EXPLANATION:##An error occurred in a mathematical
 		procedure like SQRT or SIN which SIMULA has taken
		directly from the FORTRAN library.
		The procedure name, which is usually different from the SIMULA
		name, was given in a preceding message to the TTY.
.p -9,2,3
ZYQ216###Illegal UUO executed
.s
EXPLANATION:##Either a MACRO-10 or FORTRAN subroutine used an UUO which
		is not recognized by the SIMULA system, or a unexpected error
		occurred such that execution got out of control.
		See explanation for ZYQ016.
.s
USER ACTION:##Check especially for I/O in external FORTRAN procedures. This is not
	allowed. If the error cannot be traced to subroutines outside the 
		SIMULA system, report to the SIMULA maintenance group.
.p -9,2,3
ZYQ217###RTS logic error
.s
EXPLANATION:##This message indicates that the run time system has encountered a
		situation with which it cannot cope, i e the data structures
		are inconsistent or a coding error exists in the RTS.
.s
USER ACTION:##Report to the SIMULA maintenance group, after making the checks suggested for ZYQ016.
.S 2;.IF dummy2
.page
EXPLANATION:
.EI dummy2
SIMDDT DIAGNOSTICS
.s 2;The messages starting with ZYD apply to the SIMDDT system.
.br;Some of the messages ZYD001 to ZYD177 may also appear. The description is found
in the corresponding ZYQ entry, ZYD signals that the error occurred while SIMDDT was active.
SIMDDT uses some of the RTS routines, e.g. the GETINT routine which is called
when an integer is expected in the input command.
If no integer is found the message ZYD165 is issued. Note that
SIMDDT processing may continue in most cases.
.s 2;SIMDDT will output the command followed by an appropriate message when an
error is detected in an input command. The input command will be reproduced
up to and including the last character that was analysed by SIMDDT.
.p -9,2,3
?ZYD476 ERROR WHILE INITIATING SIMDDT
.skip1
EXPLANATION: It was not possible to initiate SIMDDT and
processing can not continue.
.s
USER ACTION: Report the problem to the SIMULA maintenance group.
.p -9,2,3
?ZYD477 ERROR WHILE PROCESSING ERROR
.s
EXPLANATION: A new error was detected while SIMDDT was processing
an error. It is not possible to continue.
.s
USER ACTION: Report the problem to the SIMULA maintenance group.
.s 2;.IF dummy2
EXPLANATION:
.EI dummy2
INFORMATION TEXT
.s
The messages ZYD500 to ZYD547 are used  in SIMDDT 
to create information  text. The ZYDnnn number is suppressed.
.p -9,2,3
ZYD500###CHAR
.p -9,2,3
ZYD501###=
.p -9,2,3
ZYD502###CURRENT BLOCK POINTER AT LINE
.s
EXPLANATION:##The approximate line on which the current block starts is
given after each INSPECT command.
 
.p -9,2,3
ZYD503###LENGTH=
.p -9,2,3
ZYD504###POS=
.p -9,2,3
ZYD505###SUBTEXT STARTS AT POSITION=
.p -9,2,3
ZYD506###TERMINATED
.p -9,2,3
ZYD507###INSPECT BLOCK
.p -9,2,3
ZYD510###PREFIXED BLOCK
.p -9,2,3
ZYD511###EVTIME=
.p -9,2,3
ZYD512###TO CONTINUE TYPE PROCEED
.s
EXPLANATION: This message is issued after the error message
for errors where a possibility to continue exist.
.p -9,2,3
ZYD513###GIVE NEW INPUT LINE TO REPLACE THE LINE GIVEN ABOVE:
.s
EXPLANATION: This message is output after PROCEED after an error
with continuation code = QDSNIM.
.p -9,2,3
ZYD514###GIVE NEW INTEGER ARGUMENT:
.s
EXPLANATION: This message is output after PROCEED after an error
with continuation code =QDSNIN.
.p -9,2,3
ZYD515###FILE:
.p -9,2,3
ZYD516###CLOSED
.p -9,2,3
ZYD517###PROCEDURE VALUE
.p -9,2,3
ZYD540###SIMDDT STARTED
.s
EXPLANATION: This message is issued before any user program statement
has been executed.
SIMDDT and SIMRTS are initialized.
.s
USER ACTION: Issue a HELP, set breakpoint, USE or PROCEED command.
.s
SIMDDT ACTION: SIMDDT outputs an asterisk (*) on a new line and waits for a command.
User program execution will commence when SIMDDT receives a PROCEED command.
.p -9,2,3
ZYD541###? ERROR IN JOB
.s
EXPLANATION: When an error occurs SIMDDT is invoked and 
an error message is routed both to TTY and SYSOUT. The line on which
the error occurred will be given and a ZYQnnn message will follow.
.s
USER ACTION: To get information on the cause of the error the user can issue
any of the commands OUTPUT, CHAIN, SCHEDULED, USE and ALL. The EXIT command
should be issued to terminate the program and close all files.
_^C can be used to exit without closing any files.
.p -9,2,3
ZYD542###DETACHED
.p -9,2,3
ZYD543###NO SCHEDULED PROCESSES
.p -9,2,3
ZYD544###SCHEDULED PROCESSES
.p -9,2,3
ZYD545###OPERATING CHAIN
.p -9,2,3
ZYD547###VARIABLES
.p -9,2,10
ZYD550###LINE OVERFLOW ON INPUT
.s
EXPLANATION: A maximum of 135 characters are allowed in the input command.
.skip
USER ACTION: Give new command.
.s
SIMDDT ACTION: Command is not processed.
.p -9,2,3
ZYD551###COMMAND NOT RECOGNIZED
.s
EXPLANATION: Either the command is misspelled or the name given is not unique.
Example: The INPUT command must be given as INP while OUTPUT
can be shortened to a single O. SIMDDT has a table of all special 
keywords and IN is one of them.
.p -9,2,3
ZYD552###NOT VALID IN DEBUG MODE
.p -9,2,3
ZYD553###NOT VALID IN ERROR MODE
.s
EXPLANATION: It is not possible to continue processing after an error with a zero continuation code has ocurred.
The set breakpoints, INPUT, REMOVE and PROCEED commands cannot be used.
.p -9,2,3
ZYD554###PROCEED NOT ALLOWED AFTER THIS ERROR OR AFTER A NOPROCEED COMMAND
.s
EXPLANATION: PROCEED in error mode is allowed only for errors with a
non zero continuation code (i.e. errors starting with xxERC not xxERR in the 
error message, where xx is a module name).
.p -9,2,3
ZYD556###ASSIGNMENT TO SYSTEM PROCEDURE IS NOT POSSIBLE
.s
EXPLANATION: System procedures are not allowed as left hand side operands.
The only exception is text.MAIN.
.p -9,2,3
ZYD557###TEXT ATTRIBUTE IS NOT MAIN
.s
EXPLANATION: The only text attribute handled by SIMDDT is MAIN.
.p -9,2,3
ZYD560###IDENTIFIER IS A LABEL
.s
EXPLANATION: Labels are not handled by SIMDDT.
.s
SIMDDT ACTION: Command is ignored.
.p -9,2,8
ZYD561###IDENTIFIER IS A NAME PARAMETER
.s
EXPLANATION: Parameters of mode name are not handled by SIMDDT.
.s
SIMDDT ACTION: Command is ignored.
.p -9,2,10
ZYD562###IDENTIFIER IS A PROCEDURE, NOT HANDLED BY SIMDDT IN THIS SITUATION
.s
EXPLANATION: Procedures handled by SIMDDT are MAIN, SYSIN, SYSOUT, FIRST,
LAST, SUC, PRED, PREV, EVTIME, NEXTEV, TIME and CURRENT.
.break
A type procedure identifier is handled by SIMDDT if the current block is the procedure block.
The identifier can however not be used in connection with the IF and the IFCHANGED features in a
breakpoint command or on the right hand side in an INPUT command.
.s
SIMDDT ACTION: Command is ignored.
.p -9,2,3
ZYD563###IDENTIFIER IS A CLASS
.s
EXPLANATION: Class identifier can only be handled by SIMDDT
in connection with the relation operators IS and IN or the keywords THIS and QUA.
.s
SIMDDT ACTION: Command is ignored.
.p -9,2,3
ZYD564###IDENTIFIER IS UNDEFINED
.s
EXPLANATION: The identifier is not in the symbol table.
.s
SIMDDT ACTION: Command is ignored.
.p -9,2,3
ZYD565###DOT NOTATION ONLY VALID WITH REF OR TEXT
.s
SIMDDT ACTION: Command is ignored.
.p -9,2,3
ZYD566###IDENTIFIER EXPECTED IN INPUT
.s
SIMDDT ACTION: Command is ignored.
.p -9,2,17
ZYD567###IDENTIFIER NOT VISIBLE IN SYMBOL TABLE
.s
EXPLANATION: 
.break
1) The identifier name is misspelled
.break
2) The identifier is not visible from the current program block (CB).
For an INPUT or OUTPUT command CB is the block in which  program execution was interrupted or
the block which the CB was moved to with the INSPECT command and
for a breakpoint command  CB is the block which contains the
statement referenced via the line number.
Note that no identifiers  can be reached via the  OUTPUT or INPUT commands before
the user program has been started.
.break
3) The generation of linenumber or symbol table was suppressed during compilation.
.s
SIMDDT ACTION: Command is ignored.
.p -9,2,5
ZYD570###SUBSCRIPTS VALID ONLY WITH ARRAY IDENTIFIER
.s
SIMDDT ACTION: Command is ignored.
.p -9,2,3
ZYD571###SUBSCRIPTS MISSING AFTER ARRAY IDENTIFIER
.s
SIMDDT ACTION: Command is ignored.
.p -9,2,3
ZYD572###, OR ) OR ] EXPECTED AFTER SUBSCRIPTS
.s
SIMDDT ACTION: Command is ignored.
.p -9,2,3
ZYD573###ATTRIBUTE IDENTIFIER EXPECTED AFTER DOT
.s
SIMDDT ACTION: Command is ignored.
.p -9,2,3
ZYD574###WRONG NUMBER OF SUBSCRIPTS IN IDENTIFICATION
.s
EXPLANATION: When an array element is referenced in a 
breakpoint command the number of subscripts cannot be checked until the
breakpoint statement is reached.
.s
SIMDDT ACTION: The breakpoint command is removed.
 
.p -9,2,3
ZYD575###SUBSCRIPT LESS THAN LOWER BOUND
.s
SIMDDT ACTION: See previous  message.
.p -9,2,3
ZYD576###SUBSCRIPT GREATER THAN UPPER BOUND
.s
SIMDDT ACTION: See previous message.
.p -9,2,3
ZYD577###END OF INPUT OR COMMA EXPECTED
.s
EXPLANATION: The COMMA should precede the next identification.
.p -9,2,11
ZYD600###NO MORE FREE WORK AREA , REMOVE BREAKPOINTS
.s
EXPLANATION: The area in which an internal form of the breakpoint
commands are saved is full.
.s
SIMDDT ACTION: The new command is ignored.
.s
USER ACTION: Give a STOP BREAKS command and REMOVE the less useful breakpoints.
.p -9,2,3
ZYD601###QUALIFICATION ERROR (NONE?)
.s
EXPLANATION: A common error is that a reference type variable
used via dot notation has the value NONE.
.s
SIMDDT ACTION: See message ZYD574.
.p -9,2,3
ZYD602###RELATION OPERATOR EXPECTED
.s
EXPLANATION: The keyword IF has been found in the command and
 a <RELATION OPERATOR> is expected after the identification.
.s
SIMDDT ACTION: Command is ignored.
.p -9,2,3
ZYD603###END OF INPUT EXPECTED
.s
EXPLANATION: This is often a command syntax error.
.s
SIMDDT ACTION: An AT or BREAKS command is ignored.
An INPUT command is processed.
.p -9,2,3
ZYD604###MORE THAN ONE LOOP COUNTER
.s
SIMDDT ACTION: Command is ignored.
.p -9,2,3
ZYD605###INVALID LOOP COUNTER VALUE
.s
SIMDDT ACTION: Command is ignored.
.p -9,2,3
ZYD606###NO MORE FREE BREAKPOINT ENTRIES
.s
EXPLANATION: The maximum number of different breakpoints that
can be set up is 20.
.s
SIMDDT ACTION:  The new breakpoint command is ignored.
.s
USER ACTION: Use STOP BREAKS and remove some of the uninteresting breakpoints.
.p -9,2,3
ZYD611###COLON MISSING AFTER MODULE NAME
.s
SIMDDT ACTION: Command is ignored.
.p -9,2,3
ZYD612###CHARACTER CONSTANT, CLOSING ' MISSING
.s
SIMDDT ACTION: Command is ignored.
.p -9,2,3
ZYD613###:= OR :- EXPECTED
.s
EXPLANATION: The INPUT command must contain an assignment operator.
.s
SIMDDT ACTION: Command is ignored.
.p -9,2,3
ZYD614###DENOTES ONLY VALID AFTER REF OR TEXT VARIABLE
.s
SIMDDT ACTION: Command is ignored.
.p -9,2,3
ZYD615###:= NOT VALID AFTER REF VARIABLE
.s
SIMDDT ACTION: Command is ignored.
.p -9,2,3
ZYD616###TEXT VALUE CONSTANT NOT VALID IN TEXT REFERENCE ASSIGNMENT
.s
SIMDDT ACTION: Command is ignored.
.p -9,2,3
ZYD617###DIFFERENT TYPES IN INPUT COMMAND
.s
EXPLANATION: No conversion between real and integer or vice versa
is made by SIMDDT. The types must be equal except for LONG REAL and
REAL variables which can be mixed.
.s
SIMDDT ACTION: Command is ignored.
.p -9,2,3
ZYD620###NO BREAKPOINT
.s
EXPLANATION: No breakpoint has been set at the statement specified
via the linenumber.
.s
SIMDDT ACTION: Command is ignored.
.p -9,2,3
ZYD621###AT OR END OF INPUT EXPECTED
.s
SIMDDT ACTION: Command is ignored.
.p -9,2,3
ZYD622###REMOVE OR END OF INPUT EXPECTED
.s
EXPLANATION: The command STOP BREAKS was given.
.s
SIMDDT ACTION: The last listed breakpoint command is kept.
.p -9,2,3
ZYD623###SIMDDT ENTERED, PROGRAM INTERRUPTED AT
.s
.index ^^REENTER, error message
EXPLANATION: The program was interrupted, probably via _^C and
then entered via the REENTER monitor command. This message also appears when the
program was entered via the CONTINUE command after program exit.
The SIMRTS routine fetched
SIMDDT from disk if it was not already started and entered SIMDDT.
This feature can be used to detect where a program is looping.
.p -9,2,3
ZYD625###FINAL " MISSING IN TEXT CONSTANT
.s
SIMDDT ACTION: Command is ignored.
.p -9,2,4
ZYD626###LENGTH OF RIGHT HAND SIDE > LEFT HAND SIDE IN TEXT VALUE ASSIGNMENT
.s
SIMDDT ACTION: Command is ignored.
.p -9,2,3
ZYD627###ATTRIBUTE IDENTIFIER NOT FOUND IN SYMBOL TABLE
.s
SIMDDT ACTION: The input command up to the last character which
has been processed by SIMDDT is written to the TTY to help the user find the
invalid attribute identifier.
Command is ignored.
.p -9,2,3
ZYD630###IDENTIFICATION OR CONSTANT OF CORRECT TYPE EXPECTED IN INPUT
.s
EXPLANATION: See message ZYD617. No type conversion is
done by SIMDDT.
.s
SIMDDT ACTION: Command is ignored.
.p -9,2,3
ZYD631###TYPE ERROR IN DYNAMIC RECORD
.s
EXPLANATION: This message should not normally be given. One of
the dynamic records in the storage pool has a type which is not
recognized by SIMDDT. The message may appear while processing
the  VARIABLES or the ALL commands.
.s
SIMDDT ACTION: Command processing is terminated.
.s
USER ACTION: If you cannot explain the error, e.g. use of MACRO 10 procedures,
use of the switches -A or -Q in compilation of the main program or any
external procedure or class,
please report the problem to the SIMULA maintenance group.
.p -9,2,3
ZYD632###GARBAGE COLLECTOR NOT CALLED BEFORE VARIABLES TYPED
.s
EXPLANATION: SIMDDT will call the garbage collector routine
unless the /-GC switch,  the program was interrupted (see ZYD623) or a 
critical error occurred (e.g. storage allocation error).
.p -9,2,6
ZYD635###SIMDDT IN DEBUG MODE AND USE FILE USED BY USER PROGRAM
.s
EXPLANATION: It is only possible to let SIMDDT continue to write on an open
user file if an error has occurred.
.s
SIMDDT ACTION: Command is ignored.
.p -9,2,3
ZYD636###INVALID MODULE NAME
.s
EXPLANATION: MAIN or the SIMULA name of a separately compiled
class or procedure are valid module names.
.s
SIMDDT ACTION: Command is ignored.
.p -9,2,3
ZYD637###LINE NUMBER NOT FOUND IN TABLE
.s
EXPLANATION: The line is not found in the current line number
table. That is the line number table found via the module name
if any, or found via the module in which the current block
is placed.
The line number must fall within the table but if no exact
match is found the first larger number is chosen.
One reason may be that the source module was compiled
with the switch -I.
.s
SIMDDT ACTION: Command is ignored.
.p -9,2,10
ZYD640###NO MORE WORK AREA FOR TEXT OR REF VARIABLE, REMOVE BREAKPOINTS 
.s
EXPLANATION: The number of text and ref identifiers which
can be used in the breakpoint commands is limited.
.s
SIMDDT ACTION: The command is ignored.
.s
USER ACTION: See message ZYD600
.p -9,2,3
ZYD641###IDENTIFIER AND OPERATOR INCOMPATIBLE
.s
SIMDDT ACTION: Command is ignored.
.p -9,2,3
ZYD642###VALID CLASS IDENTIFIER EXPECTED
.s
EXPLANATION: The class identifier must follow the IS or IN operator
in the breakpoint command or the keywords THIS and QUA.

A class identifier must be declared in the same module in which
the breakpoint is placed.
.s
SIMDDT ACTION: Command is ignored.
.p -9,2,3
ZYD643###REF OR ARRAY VARIABLE NOT INITIALIZED
.s
EXPLANATION: An unusual situation has occurred. The user program execution
was interrupted while setting up a dynamic record.
.p -9,2,3
ZYD644###COMMAND NOT ALLOWED WHEN PROGRAM EXECUTION WAS INTERRUPTED
.s
EXPLANATION: 
There are some command restrictions when SIMDDT was entered after the
user program was interrupted. The restrictions hold only when the
message ZYD623 was given at entry to SIMDDT. 
The USE command, the DISPLAY command, the @ command and a set breakpoint command which contains a
text constant are not allowed as they may lead to a garbage collection.
.s
USER ACTION: Find a statement in the program which will be executed
immediately  or very soon after the interrupted point.
Set a STOP AT breakpoint there
 and PROCEED to it.
.s;A hint: INSPECT/START will tell you where your program was interrupted.
Try to set a breakpoint on the next line!
.p -9,2,6
ZYD645###CURRENT BLOCK IS TERMINATED
.s
EXPLANATION: It is an unusual case that the current block is terminated.
.s
SIMDDT ACTION: The garbage collection is inhibited.
.p -9,2,6
ZYD646###USE FILE IS NOT AN OUTFILE
.s
EXPLANATION: The use file is used by the program
but it is not an outfile.
.s
SIMDDT ACTION: Command is ignored.
.p -9,2,3
ZYD647###- OR END OF LINE EXPECTED
.s
EXPLANATION: Line or line interval expected in DISPLAY command.
.s
SIMDDT ACTION: Command is ignored.
.p -9,2,8
ZYD650###LINE INTERVAL ERROR
.s
EXPLANATION: Line or line interval is not correct in a DISPLAY command.
.s
SIMDDT ACTION: Command is ignored.
.p -9,2,8
ZYD651###LINE NOT FOUND IN MODULE
.s
EXPLANATION: The line or lines that were requested in a DISPLAY command
was not found in the source program file.
 
.p -9,2,8
ZYD652###/RETURN OR /UP NOT ALLOWED
.s
EXPLANATION: The command INSPECT /RETURN or /UP is not valid if
the current block is terminated or /RETURN given when the current block is
a detached class instance.
.s
SIMDDT ACTION: The current block is unchanged.
.p -9,2,8
ZYD653###KEYWORD EXPECTED AFTER /
.s
EXPLANATION: /UP, /RETURN, /START or /RESET expected in the INSPECT command.
.s
SIMDDT action: Command is ignored.
.p -9,2,8
ZYD654###OBJECT REFERENCE EXPECTED
.s
EXPLANATION: Object reference or /keyword expected in an INSPECT command.
This message is also given when the object reference variable has the value NONE.
.s
SIMDDT ACTION: Command is ignored.
.p -9,2,8
ZYD655###VALUE NOT ACCESSIBLE FROM TERMINATED BLOCK
.s
EXPLANATION: The only variables that are accessible in a terminated class
instance are the class attributes.
.s
SIMDDT ACTION: Command is ignored.
.p -9,2,3
ZYD656###* NOT VALID
.s
EXPLANATION: * not valid after IF or IFCHANGED in a breakpoint command.
.s
SIMDDT ACTION: Command ignored.
.p -9,2,3
ZYD657###CLOSE OR END OF INPUT EXPECTED
.s
EXPLANATION: The command STOP CLOSE was given.
.s
SIMDDT ACTION: The file name is given again.
.s
USER ACTION:	Answer CLOSE or carriage return.
.p -9,2,3
ZYD660###YOU MAY ISSUE THE NOPROCEED COMMAND AND REENTER CURRENT COMMAND AGAIN
.p -9,2,3
.s
SIMDDT ACTION: Command is ignored.
.p -9,2,5
ZYD661###INVALID KEYWORD AFTER / IN OUTPUT, VARIABLES OR ALL COMMAND
.s
EXPLANATION: /-ARRAY, /-TEXT and /-GC are allowed.
.s
SIMDDDT ACTION: Rest of command ignored.
.p -9,2,5
ZYD662###SIMDDT EXPECTS INPUT FROM TERMINAL:
.s
EXPLANATION: End of input file found.
.p -9,2,6
ZYD663###SIMDDT ENTERED AT A BREAKPOINT
.s
EXPLANATION: The program was interrupted via the control-C-REENTER monitor commands.
.p -9,2,6
ZYD664###NO TYPE PROCEDURE
.s
EXPLANATION: Only type procedure identifiers can be handled by SIMDDT.
.p -9,2,6
ZYD674###BREAKPOINT UUO FOUND, BUT BREAKPOINT NOT KNOWN TO SIMDDT
.s
EXPLANATION: It is probably a SIMDDT error.
.p -9,2,3
ZYD675###SIMDDT TERMINATION ERROR
.s
SIMDDT ACTION: The program is terminated.
.s
USER ACTION: Report the problem to the SIMULA maintenance group.
.p -9,2,3
ZYD676###INVALID MESSAGE NUMBER
.s
EXPLANATION: An message number that is new to the SIMDDT program has
been detected.
The unknown message number is placed at the start of this message, 
e.g. ZYD700 ZYD676 INVALID MESSAGE NUMBER
.s
USER ACTION: Report the problem to the SIMULA maintenance group.
.p -9,2,3
ZYD677###COMMAND OR FEATURE NOT IMPLEMENTED
.s
EXPLANATION: The command is recognized but the implementation is not part of this
version of SIMDDT.
.s
SIMDDT ACTION: The command is ignored.
.skip 2
.p -5,2,3
END OF RUN-TIME AND DEBUG DIAGNOSTICS
.EI dummy2
.subtitle APPENDIX E HOW TO WRITE AN EXTERNAL FORTRAN OR MACRO-10 PROCEDURE
.nojustify
.paper size 55,65
.fill
.left margin 5
.tab stops 13,21,29,37,45,53,61,69,77
.page
.figure 3
.indent -5
.index ^^FORTRAN, external procedure
.index ^^external procedure in MACRO-10 or FORTRAN
.index ^^separately compiled procedure in MACRO-10 or FORTRAN
.index ^^procedure in MACRO-10 or FORTRAN
.index ^^MACRO-10, external procedure
.index ^^Assembly language, external procedure
APPENDIX E HOW TO WRITE AN EXTERNAL FORTRAN OR MACRO-10 PROCEDURE
.indent -5
=================================================================
.skip 2
The handling of external FORTRAN and MACRO-10 procedures may
be visualized by the aid of the following figure
which shows the relation between the processors and files involved:
.skip 2
.nofill
			proc.sim	####proc.for/mac
			###!			#!
			###v			#v
		###-----------------####------------------
		###[SIMULA COMPILER]####[FORTRAN/MACRO-10]
		###-----------------####------------------
			###!			#!
			###v			#!
			proc.atr		#!
			###!			#!
			###v			#!
		###-----------------		#!
	main.sim-->[SIMULA COMPILER]		#!
		###-----------------		#!
			###!			#!
			###!			#!
			###v	###--------	#v
			main.rel-->[LOADER]<--proc.rel
				###--------
				######!
				######v
				###main.sav
.skip 2
.fill
IMPORTANT: The .ATR and .REL file names for an external FORTRAN
or MACRO-10 procedure should be identical except for the extension,
and should be stored under the same ppn. If they are stored in library
files, the libraries should be identical except for the extension
(.ATR for ATR-file libraries and .REL for REL-file libraries) and
be stored under the same ppn.
.subtitle APPENDIX E.1  EXTERNAL FORTRAN PROCEDURES.
.page
.indent -5
E.1##EXTERNAL FORTRAN PROCEDURES
.index ^^FORTRAN external procedure
.index ^^external procedure in FORTRAN
.index ^^separately compiled FORTRAN procedure
.skip 2
To create an attribute file, a corresponding procedure heading must be compiled by the
SIMULA compiler. Preceding the procedure heading there must be an OPTIONS statement of the form:
.skip 1
	OPTIONS(/nEXTERNAL:codeword,entry);
.skip 1
where codeword is FORTRAN or F40.
FORTRAN signals that the procedure is compiled with the FORTRAN-10 compiler and
F40 that the procedure is compiled with the old FORTRAN compiler.
.break
The entry point of the procedure is named "entry".
It is the same as the name of the SUBROUTINE or FUNCTION
in the FORTRAN program.
.skip 1
*****##IMPORTANT: You are strongly recommended to use
the same identifier for the
following entities:
.skip 1;.indent -2
> The "entry" in the OPTIONS statement above,
.indent -2
>#The name of the FORTRAN SUBROUTINE or FUNCTION,
.indent -2
>#The name of the FORTRAN source program file,
.indent -2
>#The name of the SIMULA specification file (containing the SIMULA heading
corresponding to the FORTRAN SUBROUTINE),
.indent -2
>#The SIMULA name for the procedure,
.break
even though certain combinations where some of these identifiers are
different will sometimes work.
.skip 1
Parameter restrictions:
.break
Only the types ( SHORT ) INTEGER, ( LONG ) REAL, CHARACTER
and BOOLEAN can be transmitted. An argument of type CHARACTER should be
treated as an integer in the FORTRAN program.
.skip 1
Allowed transmission modes:
.break
Simple types: VALUE default, NAME optional.
.break
ARRAYs: VALUE optional, reference default.
.skip 1
The effect of a call by NAME is: before the FORTRAN procedure is entered,
the actual parameter is evaluated.
If it is a variable, a reference to that variable is transmitted,
otherwise (constant or expression) the value is stored in a cell and a reference to that cell
is transmitted.
.skip 1
In an external FORTRAN procedure one must not use any
.index ^^high segment of FORTRAN
.index ^^FORTRAN external procedures using i/o
.index ^^FORTRAN external procedures using the FORTRAN high segment
.index ^^input/output, in FORTRAN subroutines called from SIMULA
.index ^^I/O, in FORTRAN subroutines called from SIMULA
.index ^^FORSIM utility program
.index ^^output in FORTRAN subroutines called from SIMULA
.index ^^restrictions with FORTRAN as called from SIMULA
facilities that demand the FORTRAN high segment (e.g. I/O).
However, calls to the FORTRAN high segment in FORTRAN subroutines
to SIMULA programs can often be intercepted, using the programs
FORSIM in the libraries LIBSIM.ATR and LIBSIM.REL.
You need only insert a call to these procedures in your SIMULA
program.
.skip 1
Errors may occur for FORTRAN procedures with more than one entry point,
if parameters are passed to the procedure using one entry point and
used by the procedure after a call to another entry point.
.skip 1
The SIMULA compiler will generate an attribute file but no rel-file.
.break
A SIMULA procedure heading has to be compiled before
the main program and this should be done via the COMPILE or R
monitor commands since no rel file is generated.
Care must be taken when giving an EXECUTE or LOAD command to ensure
that the correct REL files are loaded.
.subtitle APPENDIX E.2  FORTRAN PROGRAMMING EXAMPLE.
.page
.indent -5
E.2##FORTRAN PROGRAMMING EXAMPLE
.index ^^FORTRAN programming example
.skip 2
In this example we have a FORTRAN procedure which compares
two real arrays of the same size.
.skip
FORTRAN program:
.nofill
.skip
		LOGICAL FUNCTION equala(a1,a2,n)
	C
		DIMENSION a1(n),a2(n)
	C
		equala=.TRUE.
	C
		DO 1 i=1,n
		IF( a1(i) .NE. a2(i) ) GOTO 2
	1	CONTINUE
		RETURN
	2	equala=.FALSE.
		RETURN
		END
.skip 2
The SIMULA specification program (1):
.fn 10
.skip 2
.center
------------------------------------
(1) Note that the SIMULA specification may be built into the
FORTRAN code by disguising SIMULA code as comments:
.break
COMMENT; OPTIONS(/E: ....);
.break
COMMENT; ...
.break
and then making the whole FORTRAN code a SIMULA comment:
.nofill
COMMENT
########<FORTRAN code>
COMMENT;
.fill
!
.skip
	OPTIONS(/E:FORTRAN,equala);
	BOOLEAN PROCEDURE equala(a1,a2,n);
	ARRAY a1,a2;
	INTEGER n;;
.skip 2
.fill
If we have a declaration ARRAY a,b[c:d,e:f] then
.skip 1
	equala(a,b,(d-c+1)*(f-e+1))
.skip 1
is true if and only if the arrays a and b are equal element for element.
.subtitle APPENDIX E.3  EXTERNAL MACRO-10 PROCEDURES.
.page
.indent -5
E.3##EXTERNAL MACRO-10 PROCEDURES
.index ^^MACRO-10 procedures called from SIMULA
.index ^^Assembly language procedures called from SIMULA
.index ^^External procedure in MACRO-10
.index ^^Separately compiled procedure in MACRO-10
.skip 2
To create an attribute file, a corresponding procedure heading (1)
.footnote 7
.skip 2
.center
----------------------
(1) By judicious use of the comment conventions, the SIMULA specification for
an external MACRO-10 procedure can be written in the same file as the MACRO-10
code. See E.6 for examples.
!
must be separately compiled by the SIMULA compiler.
The procedure heading must be preceded by an OPTIONS statement
of one of the following forms:
.skip 1
.nofill
	OPTIONS(/nEXTERNAL:codeword,entry);
	OPTIONS(/nEXTERNAL:codeword,checkoption,entry);
.index ^^QUICK, external MACRO-10 procedure
.skip 1
.fill
where codeword is CODE or QUICK, checkoption is CHECK or NOCHECK (-CHECK is
also a valid form).
Here CODE or QUICK signals that the procedure is written in MACRO-10.
The entry point is named "entry" in the MACRO-10 module.
.skip 1
If checkoption is the word CHECK, or checkoption is not given,
the SIMULA compiler will check all actual parameters.
The exact meaning of this is:
.break
All parameters must be specified. The SIMULA compiler will check the actual parameters
versus the formal and they must correspond in number and have compatible types.
All necessary type conversions will be performed by the system.
.skip
If checkoption is NOCHECK (-CHECK), the procedure heading must not specify any
formal parameters, implying that the formal parameters are
unknown to the compiler.
The compiler can thus not perform any parameter checking.
This implies the following:
.break
All parameters are transmitted by NAME.
The number of actual parameters may vary from call to call but may not
exceed 31 (5 if codeword is QUICK).
.skip 1
If codeword is CODE, the procedure is called in the same way as a procedure
coded in SIMULA. If codeword is QUICK, however, a special, very efficient
calling sequence is used, where all parameters are passed in accumulators,
and no procedure block is allocated. The procedure is called directly without
run time system intervention (see calling standard, E.5.1).
.index ^^Efficient call on MACRO-10 procedures
.break
- A maximum of 5 to 10 parameters, depending on the types, kinds and modes of actual parameters, is allowed.
.break
- Parameters specified PROCEDURE, LABEL or SWITCH may not be specified by
NAME.
.break
- The actual parameter corresponding to a formal parameter by NAME may
not be an expression. Exact type correspondence is required for arithmetic
parameters by NAME.
.skip 1
Note that QUICK,NOCHECK implies that all parameters (at most 5) are transmitted
by name, subject to the special restrictions on name mode parameters.
.skip 1
In all cases, the SIMULA compiler will generate an attribute file but no rel-file.
.subtitle APPENDIX E.4  MACRO-10 CALLING STANDARD.
.p 0,2,42
.indent -5
E.4##MACRO-10 CALLING STANDARD
.skip 2
.indent -5
E.4.1##Accumulator conventions:
.skip 1
At entry:
.skip
AC17(XPDP) is a stack pointer.
.break
AC15(XCB)##points to the procedure instance of this call (see appendix B).
.skip 1
When calling a RTS-routine:
.skip
Three conventions TA1, TA2 and TA3 are used in the run-time system.
.break
For all routines: The accumulators 0,1,2 and 16 are destroyed. AC15 and AC17 must have the same value
as on entry.
.break
For type TA1 routines: All the other accumulators may also be destroyed.
.break
For type TA2 routines: All the other accumulators are preserved over the call.
.break
For type TA3 routines: The accumulators 3 up to N are preserved over the call. N and a
map of which accumulators point directly at dynamic objects are parameters in the call.
No accumulator may point into a dynamic object.
.skip 1
.skip 1
During execution of the MACRO-10 procedure:
.skip 1
If correct error diagnostics are desired, AC15 should not be touched inside the
procedure. AC17 may be used as push-down stack pointer but for no other purpose.
If any action is requested from the RTS which may lead to garbage collection,
any ac's which contain pointers into the dynamic data area must be saved
in an accumulator stack. Note that the right hand side of such an ac must point
to the start of a record in the stack. Any offset should be in the left half or
in another ac. Addresses in the left halves of ac's cannot be relocated by the
garbage collector.
.skip 1
At exit:
.skip
AC15 and AC17 must have the same value as on entry.
All the other ac's may be destroyed.
.p 0,2,42
.indent -5
E.4.2##Calling sequence to "QUICK" procedures
.skip 1
A MACRO-10 procedure corresponding to a specification file of the form
.break
.nofill
###OPTIONS(/EXTERNAL:QUICK,[,NOCHECK],entry);
###[<type>] PROCEDURE <SIMULA-name>[<parameter list>;
###<parameter specifications>;]
.fill
is called very efficiently by a SIMULA program.
.skip 2
Parameters to QUICK procedures
.skip 1
All parameters are computed to accumulators, starting with the first ac not
occupied by temporary results, normally XWAC1=AC3. The representation of
parameters is as shown in App B.3.
Depending on the specification, a parameter may occupy one or two ac's.
Since at most 10 ac's are available, this means that the maximum number of
parameters ranges from 5 to 10. If NOCHECK is specified, all
parameters are transmitted by name, and since a parameter descriptor for
a name parameter occupies two words, at most 5 parameters may be passed.

.skip 2
Entering a QUICK procedure
.skip 1
After computation of parameters, the procedure is called by PUSHJ##XPDP,entry,
where XPDP=AC17.
.skip 1
If the procedure has no type (pure procedure), no intermediate results will
exist in ac's when the procedure is called. Thus the first parameter is always
in XWAC1 (AC3). Subject to the restrictions in E.4.1, the ac's may be used
freely within the MACRO-10 procedure.
.skip 1
If the procedure is a function, i e has a type, it may be used in an expression,
which means that temporary results may exist in accumulators.
Thus the first parameter may be in some other ac than XWAC1, and the MACRO-10
procedure must be told where to find the first parameter. This is done via AC2
(XTAC), which is loaded with the number of the first parameter ac.
XTAC may thus contain the number 3, 4, etc. For example, the first parameter may
be loaded by MOVE###x,(XTAC), the second by MOVE###y,1(XTAC), assuming single
length parameters. When only a few parameters are involved, they may be
loaded to standard ac's (XWAC1, XWAC2, etc) by EXCH instructions, at the
same time saving the standard ac's. Any extra registers must be saved on the stack
(XPDP) before use. On return, unstacking is followed by the same EXCH instructions
in reverse order.
.skip 1
If NOCHECK was specified, AC2 is used to specify the number of actual parameters
as follows:
.break
The left half is -n, where n is the number of actual parameters.
The right half contains the number of the top ac as explained above. AC2 is
loaded also for pure procedures in this case.
.skip 2
Exit from QUICK procedures
.skip 1
On exit from a pure procedure, nothing is assumed about the contents of ac's
except AC15 and AC17, which must be preserved. On exit from a function,
however, the following conditions must hold:
.break
- The result must be in the top ac, i e the one pointed to by XTAC on entry.
For double length results the next ac is also implied.
.break
- AC0, AC1, AC2 and AC16 may be destroyed.
.break
- The parameter ac's not used for the result may be destroyed.
.break
- All other ac's must be preserved over the call.
.skip 2
Restrictions
.skip 1
Some restrictions are given in E.3. Since intermediate results may exist in
ac's, core allocation must be avoided.
Procedures as parameters should be avoided.
Typical applications of QUICK procedures are:
.break
- Small procedures to give access to monitor information related to the
current job, such as cpu time used, time of day, core available.
.break
- Additional text handling procedures, etc.
.break
Any complicated MACRO-10 procedure should be written as a CODE procedure.
.subtitle APPENDIX E.5  STANDARD MACROS AND CONSTANTS IN MACSIM.
.p 0,2,42
.indent -5
E.5##STANDARD MACROS
.skip 2
To facilitate communication between SIMULA and MACRO-10 programs,
some macros and assembly-time constants are defined in the UNIVERSAL MACSIM.
They are:
.skip 2
	MACRO	SPECIFY(specifications)
.index ^^SPECIFY, utility macro for external MACRO-10 procedures
.skip 1
The argument of this macro is a list of specifications of the procedure and parameters.
As a result all parameters not called by NAME (and the function value)
are directly accessible through their names.
Parameters called by NAME are operated on through the macros GETADD,
GETTADD, GETAADD, GETVAL, ASSIGN, GETTYPE, GETKIND and SETTYPE.
SPECIFY may be used also for QUICK procedures if the macro
QUICKPROC is invoked or the assembly parameter QUICK is defined > 0.
.index ^^QUICK, assembly parameter in MACSIM
.index ^^QUICKPROC, macro in MACSIM
.skip 2
	MACRO	PROC	name,parameters
.index ^^PROC, utility macro for external MACRO-10 procedures
.skip 1
This macro should be the first macro inside the SPECIFY argument.
It gives the name of the procedure and of the parameters.
.skip 2
.nofill
	MACRO	VALUE	##par1,par2...
.index ^^VALUE, utility macro for external MACRO-10 procedures
	MACRO	NAME	##par1,par2...
.index ^^NAME, utility macro for external MACRO-10 procedures
	MACRO	INTEGER	##par1,par2...
.index ^^INTEGER, utility macro for external MACRO-10 procedures
	MACRO	REAL	##par1,par2...
.index ^^REAL, utility macro for external MACRO-10 procedures
	MACRO	LONGREAL##par1,par2...
.index ^^LONGREAL, utility macro for external MACRO-10 procedures
	MACRO	CHARACTER#par1,par2...
.index ^^CHARACTER, utility macro for external MACRO-10 procedures
	MACRO	BOOLEAN	##par1,par2...
.index ^^BOOLEAN, utility macro for external MACRO-10 procedures
	MACRO	TEXT	##par1,par2...
.index ^^TEXT, utility macro for external MACRO-10 procedures
	MACRO	REF	##par1,par2...
.index ^^REF, utility macro for external MACRO-10 procedures
	MACRO	ARRAY	##par1,par2...
.index ^^ARRAY, utility macro for external MACRO-10 procedures
	MACRO	PROCEDURE#par1,par2...
.index ^^PROCEDURE, utility macro for external MACRO-10 procedures
	MACRO	LABEL	##par1,par2...
.index ^^LABEL, utility macro for external MACRO-10 procedures
	MACRO	SWITCH	##par1,par2...
.index ^^SWITCH, utility macro for external MACRO-10 procedures
.fill
.skip 1
These macros are valid as arguments to the SPECIFY macro.
They specify the type, kind and mode of the parameters and of the procedure value.
.p 0,2,42
	MACRO	RETURN
.index ^^RETURN, utility macro for external MACRO-10 procedures
.skip 1
This macro returns control to the calling SIMULA program.
.skip 2
	MACRO	GETCHANNEL
.index ^^GETCHANNEL, utility macro for external MACRO-10 procedures
.skip 1
This macro expands into a call to a RTS-routine
which reserves a free I/O-channel and returns it in AC1.
It is a type TA1 routine.
.skip 2
	MACRO	FREECHANNEL   chan [,ac<16>]
.index ^^FREECHANNEL, utility macro for external MACRO-10 procedures
.skip 1
This macro returns the channel in location chan to the pool.
ac is a temporary accumulator used by the macro.
.skip 2
	MACRO	INIMAGE
.index ^^INIMAGE, utility macro for external MACRO-10 procedures
.skip 1
This macro expands into a call to a RTS-routine
which performs INIMAGE on the file object pointed to by AC3.
It is a type TA1 routine.
.skip 2
	MACRO	OUTIMAGE
.index ^^OUTIMAGE, utility macro for external MACRO-10 procedures
.skip 1
This macro expands into a call to a RTS-routine
which performs OUTIMAGE on the file object pointed to by AC3. It is a type TA1 routine.
.skip2
	MACRO	IFEOF	ac
.index ^^IFEOF, utility macro for external MACRO-10 procedures
.skip 1
This macro causes the next instruction to be skipped if
ENDFILE=FALSE in the file object pointed to by ac.
.skip 2
	MACRO	IFNEOF	ac
.index ^^IFNEOF, utility macro for external MACRO-10 procedures
.skip 1
This macro causes the next instruction to be skipped if
ENDFILE=TRUE in the file object pointed to by ac.
.p 0,2,42
The following macros define access to name mode parameters. They should not
be used in QUICK procedures.
.skip 2
	MACRO	GETADD	par [,N,maprh]
.index ^^GETADD, utility macro for external MACRO-10 procedures
.skip 1
This macro expands into a call to a RTS-routine
which loads the dynamic address of a parameter called by NAME (not TEXT or ARRAY)
to ac N+1 (AC3 if N is missing) (and  ac N+2 (AC4) if double word).
N is the highest ac saved. maprh is a list of those ac's which need relocation of their
right halfword in case of garbage collection.
The left halfwords must not contain any relocatable information.
Thus the routine is of type TA3.
.skip 2
	MACRO	GETTADD	par[,N,maprh]
.index ^^GETTADD, utility macro for external MACRO-10 procedures
.skip 1
This macro expands into a call to a RTS-routine
which loads the dynamic address of a TEXT parameter called by NAME. For
the rest see GETADD.
.skip 2
	MACRO	GETAADD	par[,N,maprh]
.index ^^GETAADD, utility macro for external MACRO-10 procedures
.skip
This macro expands into a call to a RTS-routine
which loads the dynamic address of an ARRAY called by NAME.
It is the only way of accessing such a parameter.
For the rest see GETADD.
.skip 2
	MACRO	GETVAL	par[,N,maprh]
.index ^^GETVAL, utility macro for external MACRO-10 procedures
.skip 1
This macro expands into a call to a RTS-routine
which loads the value of a parameter called by name. For
the rest see GETADD.
.skip 2
	MACRO	ASSIGN	par,aclhs,acrhs
.index ^^ASSIGN, utility macro for external MACRO-10 procedures
.skip 1
This macro expands into a call to a RTS-routine
which performs an assignment to a parameter called by
NAME. The dynamic address of the parameter has previously been computed to AC aclhs
(and  aclhs+1 if dynamic address is 2 words).
The value to be assigned has been computed to AC acrhs (and  acrhs+1 if doubleword value).
The SIMRTS-routine performs all necessary type conversion and qualification checking.
It is a type TA2 routine.
.p 0,2,42
	MACRO	GETTYPE ac,par
.index ^^GETTYPE, utility macro for external MACRO-10 procedures
.skip 1
This macro loads ac with the type of an actual parameter called by NAME.
.skip 2
	MACRO	GETKIND ac,par
.skip 1
This macro loads ac with the kind of an actual parameter called by NAME.
.skip 2
.index ^^SETTYPE, utility macro for external MACRO-10 procedures
	MACRO	SETTYPE typ,par[,ac<16>]
.skip 1
This macro sets the formal type to typ for a parameter called by NAME.
It is used to force type conversion in GETVAL and ASSIGN.
ac is a temporary accumulator.
.skip 2
The macros GETTYPE, GETKIND and SETTYPE are useful in NOCHECK procedures.
.skip 2
The following macros can be used in procedures called with all parameters in
ac's (QUICK procedures):
.skip 1
	MACRO	QUICKPROC
.skip 1
This macro should be called directly after "search MACSIM" in a QUICK
procedure.
It defines QUICK=1.
.index ^^QUICKPROC, macro in MACSIM
.skip 4
Some useful constants:
.skip 2
.nofill
	CONSTANT###QNOTYPE
	CONSTANT###QINTEGER
	CONSTANT###QREAL
	CONSTANT###QLONGREAL
	CONSTANT###QCHARACTER
	CONSTANT###QBOOLEAN
	CONSTANT###QTEXT
	CONSTANT###QREF
	CONSTANT###QLABEL
.skip 1
These constants define the type codes.
.skip 2
	CONSTANT###QSIMPLE
	CONSTANT###QARRAY
	CONSTANT###QCLASS
	CONSTANT###QPROCEDURE
.fill
.skip 1
These constants define the kind codes. SWITCH has type QLABEL and kind
QPROCEDURE.
.skip 2
.p 0,2,4
	CONSTANT###NONE
.skip 1
This constant defines the representation of the object constant NONE.
.skip 2
	CONSTANT###IMAGE
.skip 1
This constant defines the offset of the attribute IMAGE 
in a file object.
.subtitle APPENDIX E.6  MACRO-10 PROGRAMMING EXAMPLES.
.p 0,2,42
.indent -5
E.6##MACRO-10 PROGRAMMING EXAMPLES
.index ^^MACRO-10 programming examples
.skip 2
.indent -5
E.6.1##Example on CODE procedures
.index ^^CODE MACRO-10 procedures, example
.skip 1
In this example we have a MACRO-10 procedure which performs a summation utilizing Jensens device.
.skip 2
.index MACRO-10 procedures, how to write SIMULA specifications
The file contains both the SIMULA specification and the MACRO-10 code.
Note the use of COMMENT and !. Since COMMENT in MACRO-10 is terminated by
a second occurrence of the first non-blank character following the word
COMMENT, the whole SIMULA heading is taken to be a comment by the MACRO-10
compiler. In MACRO-10, a semicolon turns the rest of a line into a comment.
If every semicolon in the MACRO-10 code part is followed by !, the MACRO-10
code is regarded as a series of comments by SIMULA. The last comment is
terminated by the semicolon following END.
The file extension should be .MAC, which means that the SIMULA specification
must be compiled via .R SIMULA, since the MAC extension forces MACRO-10 to be
used if a COMPILE, EXECUTE, or DEBUG command is issued.
.nofill
.p 0,2,15
	COMMENT * SIMULA specification;
	OPTIONS(/E:CODE,CHECK,sument);
	REAL PROCEDURE sum(m,n,f,i);
	NAME f,i;
	REAL f;
	INTEGER m,n,i;
.skip 1
	COMMENT The corresponding SIMULA code would be:
.skip 1
_!      BEGIN
_!  	  REAL s;
_!  	  FOR i:=m STEP 1 UNTIL n DO
_!  	  s:=s+f;
_!  	  sum:=s;
_!      END;
.p 0,2,14
	_!*;! MACRO-10 code !*;!
.skip 1
	TITLE	sum
	SEARCH	macsim
	ENTRY	sument
.skip
	SPECIFY<
		PROC	sum,<m,n,f,i>
		NAME	f,i
		REAL	sum,f
		INTEGER	m,n,i
		>
.p 0,1,10
sument:	MOVE	3,m	;! Start index of loop
.skip
loop:	CAMLE	3,n
	RETURN		;! at end of interval
	GETADD	i,3
	ASSIGN	i,4,3
	GETVAL	f,3
	FADRM	4,sum	;! add f into sum
	AOJA	3,loop	;! STEP 1, go to start of loop
	END;
.skip 2
.fill
Note that the END statement must not contain any start address.
The ENTRY statement gives the start address of the procedure and 
the start address for the main program is created by the SIMULA compiler.
Then  sum(1,n,i,i) = n*(n+1)/2
and  sqrt(sum(1,n,a(i)**2,i)) = length of vector a
.skip 2
The following monitor commands will compile and execute the modules in the
example (assuming MACSIM.UNV is available on DSK:, UNV: or SYS:):
.p 0,1,6
.nofill
_.R SIMULA
*sum.mac
*_^C
_.EXECUTE sum.mac,main
.skip 1
.fill
Note that the ATR file must be generated by SIMULA before the EXECUTE command
can be used.
.p 0,4,15
.indent -5
E.6.2##Example on QUICK procedures
.index ^^QUICK MACRO-10 procedures, example
.skip 1
This example shows how a QUICK procedure is written to perform a text handling
task. Refer to B.1 for the text variable representation. Note that MACSIM
is used with the assembly parameter QUICK=1. Since the text parameter is used
also to return the result, the procedure name is not used.
The dot in the procedure name avoids name clashes.
Note also that one file, e g REST.MAC, can be compiled both
with SIMULA and MACRO-10 through use of the comment conventions.
See E.6.1.
.p 0,2,7
COMMENT * SIMULA specification;
.skip 1
.nofill
	OPTIONS(/EXTERN:QUICK,REST);
	TEXT PROCEDURE rest(t); TEXT t;
	COMMENT Computes t.sub(t.pos,t.length+1-pos);
.p 0,2,14
_!*;! MACRO-10 code !*;!
.skip 1
	TITLE	REST
	SUBTTL	Compute text reference to text after pos
	SALL
	SEARCH	MACSIM
	ENTRY	REST
	QUICK==1
	SPECIFY<
	PROC	.REST,T
	TEXT	.REST,T
	>
.p 0,1,16
REST:	EXCH	T,(XTAC)	;!Parameter to standard ac's
	EXCH	T+1,1(XTAC)
	HLRZ	X0,T+1		;!Length
	SUBI	X0,(T+1)	;! - pos + 1
	JUMPLE	X0,L1		;!Anything left?
	HLRZ	X1,T		;!Subtext offset
	ADDI	X1,(T+1)	;! + pos - 1 gives
	HRLM	X1,T		;!New offset
	HRLZM	X0,T+1		;!New length, Pos=1
	GOTO	L2
L1:	SETZB	T,T+1		;!NOTEXT
L2:	EXCH	T+1,1(XTAC)
	EXCH	T,(XTAC)
	RETURN
	END;
.p 0,2,12
REST could be called by the following piece of code:
.skip 1
BEGIN
    EXTERNAL TEXT PROCEDURE rest;
    TEXT t1,t2;
    t1:-Copy("1234567");
    t1.setpos(5);
    t2:-rest(t1);
    Outtext("rest(t1)="); Outtext(t2); Outimage;
END;
.p 0,2,13
The statement t2:-rest(t1) is compiled to:
.skip 1
	DMOVE	3,2(15)	;t1
	MOVEI	2,3	;Indicate top ac=3
	PUSHJ	17,rest
	DMOVEM	3,4(15)	;t2
.skip 2
The program output will be:
.skip 1
rest(t1)=567
.fill
.tab stops 1
^^
.spacing 1
.nojustify
.fill
.left margin 5
.paper size 55,65
.subtitle APPENDIX F RUN-TIME SYSTEM COMPONENTS
.page
.index ^^Object time system, entry points
.index ^^High segment at run time, entry points
.index ^^Run-Time systems components, entry points
.index ^^Components, Run-Time system, entry points
.skip 2
.indent -5
APPENDIX F RUN-TIME SYSTEM COMPONENTS
.break
.indent -5
=====================================
.skip 2
The Run-Time System contains several modules corresponding to files with extension MAC and the
compiled REL files. The most frequently used modules are loaded in the
high segment, and the rest is loaded with the SIMULA program in the
low segment.
In this appendix the modules are listed with their most important entry points,
corresponding to system classes, procedures or special SIMULA constructs.
.skip 1
The following modules are loaded in the high segment (SIMRTS).
.index ^^SIMRTS, entry points
.index ^^high segment components, Run Time System, entry points
.skip 2
.left margin 12
.indent -7
.index ^^CP module, entry points
CP#####handles classes and prefixed blocks.
.skip 1
.tab stops 32
.nofill
Subroutine	SIMULA notation
.skip 1
#.CPCA	CALL
#.CPDT	DETACH
#.CPNE	NEW <class identifier>
#.CPRS	RESUME
#.CPSP	<class id> BEGIN
.fill
.skip 2
.indent -7
.index ^^CS module, entry points
CS#####central part, handles some run-time tasks
performed in most SIMULA programs.
.skip 2
.indent -7
.index ^^IO module, entry points
.index ^^IONF module, entry points
IO#and IONF  perform I/O handling.
.skip 1
.nofill
Subroutine	SIMULA notation
.skip 1
#.IOBO	BREAKOUTIMAGE
#.IOCL	CLOSE
#.IOEJ	EJECT
#.IOFD	FIELD
#.IOIG	INIMAGE
#.IOLI	LASTITEM
#.IOLP	LINES PER PAGE
#.IOLT	LOCATE
#.IOOG	OUTIMAGE
#.IOOP	OPEN
#.IOSP	SPACING
.fill
.test page 16
.skip 2
.indent -7
.index ^^IOED module, entry points
IOED###performs I/O handling in connection with
text handling (editing functions)
.skip 1
.nofill
Subroutine	SIMULA notation
.skip 1
#.IOIC	INCHAR
#.IOIF	INFRAC
#.IOII	ININT
#.IOIR	INREAL
#.IOIT	INTEXT
#.IOOC	OUTCHAR
#.IOOF	OUTFRAC
#.IOOI	OUTINT
#.IOOR	OUTREAL
#.IOOT	OUTTEXT
#.IOOX	OUTFIX
.skip 2
.indent -7
.fill
.index ^^PH module, entry points
PH#####handles parameter transmissions for procedures.
.skip 2
.indent -7
.index ^^OCIN module, entry points
.index ^^OCIO module, entry points
OCIN and OCIO initialize a SIMULA program execution,
handle file specifications.
.skip 2
.indent -7
.index ^^OCEP module, entry points
OCEP###handles end of SIMULA programs, traps and UUO's
and loads SIMDDT
.skip 2
.indent -7
.index ^^SA module, entry points
SA#####handles storage allocation, garbage collection.
.skip 2
.indent -7
.index ^^SIMRT1, SIMRT2 modules, entry points
SIMRT1 and SIMRT2 contain transfer vectors for references to
the high segment from the low segment and the code to swap high segments.
The modules are used in the two high segments version
of the run time system.
.skip 2
.indent -7
.index ^^SIMRTS module, entry points
SIMRTS#contains the transfer vector for references to
the high segment from the low segment.
This module is used in the single high segment version of the run time system.
.skip 2
.indent -7
.page
.index ^^TX module, entry points
.index ^^TXBL module, entry points
TX and TXBL perform text handling.
.skip 2
.nofill
Subroutine	SIMULA notation
.skip 1
#.TXBL	BLANKS
#.TXCY	COPY
#.TXGC	GETCHAR
#.TXGF	GETFRAC
#.TXGI	GETINT
#.TXGR	GETREAL
#.TXLT	LOWTEN
#.TXMN	MAIN
#.TXPC	PUTCHAR
#.TXPF	PUTFRAC
#.TXPI	PUTINT
#.TXPR	PUTREAL
#.TXPX	PUTFIX
#.TXRE	Value relation (e.g. T1<=T2)
#.TXSE	SETPOS
#.TXST	STRIP
#.TXSU	SUB
#.TXVA	Value assignment (e.g. T1:=T2)
.skip 4
.fill
.left margin 5
.page
.index ^^Low segment, RTS, entry points
.index ^^SIMLIB, library file, entry points
.index ^^Mathematical subroutines in SIMLIB, entry points
.index ^^FORLIB functions, entry points
.index ^^FORTRAN library functions used in SIMULA, entry points
The following modules contain routines to be loaded into the
low segment with the SIMULA program.
The corresponding rel files are collected by FUDGE2 into the library file
SIMLIB.REL.
Some routines are taken from SYS:FORLIB. These are marked with an asterisk (*).
.skip 3
.left margin 12
.indent -7
ACOS.##ARCCOSINE single precision
.index ^^ARCCOSINE single precision, entry point
.skip 1
subroutine	SIMULA name
.break
* ACOS.	ARCCOS
.skip 2
.indent -7
ALOG.##contains logarithm function single precision.
.index ^^logarithm function single precision, entry point
.skip 1
.nofill
subroutine	SIMULA name
* ALOG.	LN
.fill
.skip 2
.indent -7
ASIN.##contains ARCSINE function single precision.
.index ^^ARCSINE function single precision, entry point
.skip 1
subroutine	SIMULA name
.break
* ASIN.	ARCSIN
.skip2
.indent -7
ATAN.##contains ARCTANGENT single precision.
.index ^^ARCTANGENT single precision, entry point
.skip 1
subroutine	SIMULA name
.break
* ATAN.	ARCTAN
.skip 2
.indent -7
CFRXIT FORTRAN interface
.skip 1
subroutine
.break
* CEXIT.	used when returning from F40
.break
                library subroutine
.skip 2
.indent -7
COSH.##hyperbolic COSINE single precision
.skip 1
subroutine	SIMULA name
.break
* COSH.	COSH
.skip 2
.indent -7
.test page 4
DATAN.#contains ARCTANGENT double precision
.skip 1
subroutine	SIMULA name
.break
* DATAN.	ARCTAN
.skip 2
.indent -7
.test page 4
DEXP.##contains exponential function double precision
.index ^^exponential function double precision, entry point
.skip 1
subroutine	SIMULA name
.break
* DEXP.	EXP
.skip 2
.indent -7
.test page 5
DEXP.2#computes a floating point number in double precision
raised to an integer power.
.skip 1
subroutine	SIMULA notation
.break
* DEXP2.	A**B
.indent -7
.skip 2
.test page 6
DEXP.3#computes a floating point number in double precision
raised to a floating point number in double precision.

.skip 1
subroutine	SIMULA notation
.break
* DEXP.3	A**B
.skip 2
.indent -7
.test page 4
DLOG.##logarithm function double precision.
.index ^^logarithm function double precision, entry point
.skip 1
subroutines	SIMULA name
.break
* DLOG.	LN
.skip 2
.indent -7
.test page 5
DSIN.##contains SINE and COSINE double precision
.skip 1
.nofill
subroutines	SIMULA name
* DCOS.	COS
* DSIN.	SIN
.fill
.skip 2
.indent -7
.test page 4
DSQRT.#computes square root double precision.
.skip 1
subroutine	SIMULA name
.break
* DSQRT.	SQRT
.skip 2
.indent -7
.test page 4
EXIDOT#FORTRAN interface
.skip 1
subroutine
.break
.left margin 21;.indent -16
* EXIT.		Performs EXIT UUO - FORTRAN program (final) exit
.left margin 12
.skip 2
.indent -7
.test page 4
EXP.###exponential function single precision
.skip 1
subroutine	SIMULA name
.break
* EXP.	EXP
.skip 2
.indent -7
.test page 5
EXP1###calculates an integer raised to an integer power, single precision.
.skip 1
subroutine	SIMULA notation
.break
* EXP1.	A**B
.fill
.skip 2
.indent -7
.test page 5
EXP2###calculates a floating point number
raised to a fixed point power.
.skip 1
subroutine	SIMULA notation
.break
* EXP2.	A**B
.skip 2
.indent -7
.test page 5
EXP3###calculates a floating point number raised to a
floating point power, single precision.
.skip 1
subroutine	SIMULA name
.break
* EXP3.	A**B
.skip 1
.indent -7
.test page 4
FORXIT#handles FORTRAN interface
.index ^^FORTRAN interface, entry points
.skip 1
subroutine
.break
.left margin 21;.indent -16
* EXIT		Program exit initiated from F40 library subroutine
.left margin 12
.skip 2
.indent -7
.test page 5
.index ^^MA module, entry points
MA#####contains auxiliary mathematical subroutines.
.skip 1
.nofill
subroutines	function
#.MACI	convert from long real to integer
.index ^^long real to integer, entry point
#.MACL	convert from integer to long real
.index ^^integer to long real, entry point
.fill
.skip 2
.indent -7
.index ^^OCSP module, entry points
OCSP###sets up the environment for a SIMULA program,
	loads the (initial) high segment and passes control
	to OCIN.
.skip 2
.indent -7
PHFO###handles interface between SIMULA and FORTRAN.
.index ^^PHFO module, entry points
.skip 2
.indent -7
.test page 2
PHPT###handles parameter transmission to formal, virtual and
external MACRO-10 procedures.
.index ^^MACRO-10 procedures, external, entry points
.skip 2
.indent -7
.test page 14
.index ^^RD module, entry points
RD#####random drawing routines.
.index ^^random drawing routines, entry points
.break
.skip 1
.nofill
subroutine	SIMULA name

#.RDDI	DISCRETE
#.RDDR	DRAW
#.RDER	ERLANG
#.RDHI	HISTD
#.RDHO	HISTO
#.RDLI	LINEAR
#.RDNE	NEGEXP
#.RDNO	NORMAL
#.RDPO	POISSON
#.RDRA	RANDINT
#.RDUN	UNIFORM
.fill
.skip 2
.indent -7
.index ^^SANE module, entry points
SANE###allocates event notices for SIMULATION.
.skip 2
.indent -7
.test page 6
SIN####contains routines to handle SINE and COSINE, single precision.
.skip 1
.nofill
subroutine	SIMULA name
* COS.	COS
* SIN.	SIN
.fill
.skip 2
.indent -7
.test page 4
SINH###hyperbolic SINE function, single precision.
.skip 1
subroutine	SIMULA name
.break
* SINH.	SINH
.skip 2
.indent -7
.test page 4
SQRT###square root single precision
.index ^^square root single precision, entry point
.skip 1
subroutine	SIMULA name
.break
* SQRT.	SQRT
.skip 2
.indent -7
.test page 17
.index ^^SS module, entry points
SS#####implements SIMSET
.skip 2
.nofill
subroutine	SIMULA name
#.SSCA		CARDINAL
#.SSCL		CLEAR
#.SSEY		EMPTY
#.SSFO		FOLLOW
#.SSHD		HEAD
#.SSIT		INTO
#.SSLG		LINKAGE
#.SSLK		LINK
#.SSOU		OUT
#.SSPC		PRECEDE
#.SSPD		PRED
#.SSSC		SUC
#.SSST		SIMSET
.skip 1
.indent -7
.test page 14
.index ^^SU module, entry points
SU#####implements SIMULATION.
.skip 1
.nofill
subroutine	SIMULA name
#.SUAC	ACTIVATE,REACTIVATE
#.SUAM	ACCUM
#.SUCA	CANCEL
#.SUEV	EVTIME
#.SUHO	HOLD
#.SUMA	MAIN PROGRAM
#.SUNE	NEXTEV
#.SUPA	PASSIVATE
#.SUPS	PROCESS
#.SUSI	SIMULATION
#.SUWA	WAIT
.skip 2
.indent -7
.test page 4
.index ^^TAN module, entry point
TAN####contains TANGENT single precision
.index ^^TANGENT single precision, entry point
.skip 1
subroutine	SIMULA name
.break
TAN.		TAN
.skip 2
.indent -7
.test page 4
TANH###hyperbolic TANGENT single precision.
.skip 1
subroutine	SIMULA name
.break
* TANH.	TANH
.page
.indent -7
Run-Time module sizes (may be changed in the future).
.index ^^Run-Time module sizes, entry points
.index ^^Core size of run time system, entry points
.skip 1
Module	Size(octal)
.skip 1
ACOS.	55
ALOG.	111
ASIN.	54
ATAN.	66
CFRXIT	6
COSH.	45
CP	370
CS	704
DATAN.	141
DEXP.	163
DEXP.2	74
DEXP.3	62
DLOG.	205
DSIN.	211
DSQRT.	101
EXIDOT	1
EXP.	74
EXP1	102
EXP2	143
EXP3	111
FORXIT	5
IO	2411
IOED	321
IONF	1557
MA	40
OCEP	1260
OCIN	3445
OCIO	545
OCSP	367
PH	330
PHFO	300
PHPT	577
RD	567
SA	1772
SANE	67
SIMRT1	306
SIMRT2	306
SIMRTS	210
SIN.	113
SINH.	74
SQRT	46
SS	274
SU	677
TAN	61
TANH.	63
TX	2006
TXBL	402
.fill
.tab stops 1
^^
.spacing 1
.nojustify
.fill
.left margin 5
.paper size 55,65
.subtitle APPENDIX G RESERVED SIMULA WORDS AND STANDARD IDENTIFIERS
.page
.index ^^Reserved SIMULA words
.index ^^Operator words in SIMULA
.index ^^Identifiers, standard
.index ^^Functions, standard
.index ^^SIMULA, reserved words
.indent -5
APPENDIX G RESERVED SIMULA WORDS AND STANDARD IDENTIFIERS
.break
.indent -5
=========================================================
.skip 2
The following words are reserved SIMULA words 
and must not be used for other purposes.
.skip 2
.tab stops 15,35
.nofill
	ACTIVATE	LE
	AFTER	LONG
	AND	LT
	ARRAY	NAME
	AT	NE
	BEFORE	NEW
	BEGIN	NONE
	BOOLEAN	NOT
	CHARACTER	NOTEXT
	CLASS	OR
	COMMENT	OPTIONS
	DELAY	OTHERWISE
	DO	PRIOR
	ELSE	PROCEDURE
	END	PROTECTED
	EQ	QUA
	EQV	REACTIVATE
	EXTERNAL	REAL
	FALSE	REF
	FOR	SHORT
	GE	STEP
	GO	SWITCH
	GOTO	TEXT
	GT	THEN
	HIDDEN	THIS
	IF	TO
	IMP	TRUE
	IN	UNTIL
	INNER	VALUE
	INSPECT	VIRTUAL
	INTEGER	WHEN
	IS	WHILE
	LABEL
.fill
.page
.index ^^SIMULA Standard identifiers
.index ^^Standard identiiers
The following words are SIMULA standard identifiers
and not reserved words, i.e. they may be redeclared.
.skip 2
.tab stops 10 28 46
.nofill
	ABS	HOLD	OUTREAL
	ACCUM	IDLE	OUTTEXT
	ARCCOS	IMAGE	PASSIVATE
	ARCSIN	INCHAR	POISSON
	ARCTAN	INFILE	POS
	BLANKS	INFRAC	PRECEDE
	BREAKOUTIMAGE	INIMAGE	PRED
	CALL	ININT	PREV
	CANCEL	INREAL	PRINTFILE
	CARDINAL	INTEXT	PROCESS
	CHAR	INTO	PUTCHAR
	CLEAR	LAST	PUTFIX
	CLOSE	LASTITEM	PUTFRAC
	COPY	LENGTH	PUTINT
	COS	LETTER	PUTREAL
	COSH	LINE	RANDINT
	CURRENT	LINEAR	RANK
	DETACH	LINESPERPAGE	RESUME
	DIGIT	LINK	SETPOS
	DIRECTFILE	LINKAGE	SIGN
	DISCRETE	LN	SIMSET
	DRAW	LOCATE	SIMULATION
	EJECT	LOCATION	SIN
	EMPTY	LOWTEN	SINH
	ENDFILE	MAIN	SPACING
	ENTIER	MOD	SQRT
	ERLANG	MORE	STRIP
	EVTIME	NEGEXP	SUB
	EXP	NEXTEV	SUC
	FIRST	NORMAL	SYSIN
	FOLLOW	OPEN	SYSOUT
	GETCHAR	OUT	TAN
	GETFRAC	OUTCHAR	TANH
	GETINT	OUTFILE	TERMINATED
	GETREAL	OUTFIX	TIME
	HEAD	OUTFRAC	UNIFORM
	HISTD	OUTIMAGE	WAIT
	HISTO	OUTINT
.fill
.tab stops
.subtitle APPENDIX H  SAMPLE JOB LISTINGS
.nofill
.nojustify
.tab stops 1
.left margin 0
^^
.paper size 55,70
.spacing 1
.page
.skip 3
APPENDIX H SAMPLE JOB LISTINGS
==============================
.SKIP 2
H.1 THE R COMMAND
.fill
.left margin 5
     The following command cause the system to input to the  compiler  the
     concatenation  of  two  source files, SRC1.SIM and SRC2.SIM.  The
     compiler produces object code in the file OBJECT.REL and LIST.LST
     contains  a  listing  of the complete input file together with a cross
     reference table.
.nofill
.left margin 0
.SKIP 1
  .R SIMULA
.SKIP 1
  *OBJECT.REL,LIST.LST=SRC1/C,SRC2
.SKIP 1
  NO ERRORS DETECTED
  *SIMPRO/C/I
.SKIP 1
         8     OPTIONS(/H);
  SIM005  W LINE     8     HELP NOT VALID IN OPTIONS STATEMENT,
                           IGNORED
 
        17     LOOP:
        18     SYSUT.OUTTEXT("WHICH RECORD?");
  SIM362  E LINE    17     IDENTIFIER SYSUT IS NOT DECLARED 
        23    LOCATION(I);
  SIM337  E LINE    23     INCORRECT NUMBER OF PARAMETERS TO LOCATION 
.SKIP 1
  ERRORS DETECTED:
      1 TYPE W MESSAGES
      2 TYPE E MESSAGES
.SKIP 1
  *_^C
  .
.SKIP 2
.fill
.left margin 5
     The last command  to  the  compiler  caused  the  source  program
     SIMPRO.SIM  to  be  compiled.   A  cross  reference  listing  was
     generated and named SIMPRO.LST and the created object  code  file
     was  called  SIMPRO.REL.  A line number table 
in the rel file was also generated.
     The program contains errors and messages were output on the TTY.
.nofill
.nojustify
.left margin 0
.page
H.2 THE COMPILE COMMAND
.index ^^Compile monitor command, example
     To concatenate source files when using the COMPILE command, a
     + sign  should  be  used.   A cross reference listing of both
     source files, named SRC1.LST, will be created.
.SKIP 1
  .COMPILE/CREF SRC1+SRC2
.SKIP 1
  SIMULA:  SRC1
.SKIP 1
  EXIT
.SKIP 1
  .
.SKIP 2
H.3 THE LOAD COMMAND
.index ^^LOAD monitor command, example
.SKIP 1
     SIMPRO, the same source file  as  above,  is  compiled.   The  -W
     switch  suppresses the warning message.  The switch -A suppresses
     code for array bounds checking.  Switches  given in this  way  
     (via COMPIL) must not be separated by comma or slash.
.SKIP 1
  .LOAD SIMPRO(-W-A)
.SKIP 1
  SIMULA:  SIMPRO
   LOOP:
      SYSUT.OUTTEXT("WHICH RECORD?");
  SIM362  E LINE    17     IDENTIFIER SYSUT IS NOT DECLARED 
      LOCATION(I);
  SIM337  E LINE    23     INCORRECT NUMBER OF PARAMETERS TO LOCATION 
.SKIP 1
  ERRORS DETECTED:
      1 TYPE W MESSAGES
      2 TYPE E MESSAGES
  LINK:  Loading
.SKIP 1
  EXIT
.SKIP 1
  .
.page
H.4 THE EXECUTE COMMAND
.SKIP 1
  .EXECUTE DF1A
.SKIP 1
  SIMULA:  DF1A
  LINK:  Loading
  [LNKXCT DF1A Execution]
  NUMBER OF RECORDS IN DF1.DAT =    49
.SKIP 1
  1 Garbage collection executed during 0 ms
.SKIP 1
  End of SIMULA program execution.
  CPU time: 1.45  Elapsed time: 7.84 
.SKIP 1
  .
.SKIP 2
H.5 THE DEBUG COMMAND
.index ^^DEBUG monitor command, example
.SKIP 1
     The SIMULA compiler may also be invoked using the debug  command.
     For further examples on the use of SIMDDT see paragraph 9 of this
     appendix!
.SKIP 1
  .DEBUG DF1A
.SKIP 1
  SIMULA:  DF1A
  LINK:  Loading
  [LNKXCT DF1A Execution]
  SIMDDT STARTED 
  *P
  NUMBER OF RECORDS IN DF1.DAT =    49
.SKIP 1
  1 Garbage collection executed during 18 ms
.SKIP 1
  End of SIMULA program execution.
  CPU time: 1.41  Elapsed time: 3.60 
.SKIP 1
  .
.page
.fill
.index ^^Control cards in batch
.index ^^Batch
.index ^^CARD batch example
.index ^^$SIMULA card
H.6 CONTROL CARDS IN BATCH
.left margin 5
.SKIP 1
The $SIMULA card can be used if the SPRINT program
(Spooling PRocessor for INpuT) is modified to recognize this control card.
The general format of the $SIMULA card is:
.break
$SIMULA dev:prog.sim[PPN](SS...)/SW1/SW2.../SWn
.break
where
.break
(SS...) is processor switches in short notation
.break
/SW1/SW2.../SWn is the switches that control the mode
of input interpretation and the listing of the compiled program.
.break
For a detailed description refer to 3.4.
.skip
The example below illustrates how data can be input to a SIMULA program
when the program is executing in the batch system.
.left margin 2
.nofill
.tab stops 8,16
.skip 2
$JOB name [proj,prog]
$PASSWORD:password
$DECK SYSIN
SYSIN ON DSK
$EOD
$SIMULA PROG.SIM(-WC)
BEGIN
	SYSIN.IMAGE:-SYSOUT.IMAGE;
	INIMAGE;
	OUTIMAGE;
END
$EOD
$EXECUTE
*DEFAULT IS SYSIN FROM TTY
_.ASS DSK SYSIN
$EXECUTE
;DSK:SYSIN created by the $DECK SYSIN card is read.
_.ASS CDR SYSIN
$DATA
SYSIN ON SPOOLED CDR
$EOD
;The $DATA card will generate a funny named spooled CDR file.
;In this example SYSIN is used, but other files can be used in
;the same way.
$EOJ
.skip 2
.page
.left margin 5
When the file above on cards or on a disk file is input to SPRINT
the following CTL file will be generated and submitted.
.left margin 2
.skip 2
_.COMPIL /COMP/SIM DSK:PROG.SIM(-WC)/LIST
_.EXECUT /LINK/REL DSK:PROG.REL
*DEFAULT IS SYSIN FROM TTY
_.ASS DSK SYSIN
_.EXECUT /LINK/REL DSK:PROG.REL
;DSK:SYSIN created by the $DECK SYSIN card is read
_.ASS CDR SYSIN
_.SET CDR TD9
_.EXECUT /LINK/REL DSK:PROG.REL
;The $DATA card will generate a funny named spooled CDR file.
;In this example SYSIN is used, but other files can be used in
;the same way.
%FIN:: .DELETE DSK:TD9.CDR
.left margin 5
.skip 2
The job will produce the following log file:
.skip 2
.left margin 2
12:42:52 STDAT	16-OCT-74 QZ 601A7vm  SPRINT Version 1(634)
		 Running on DSK
12:42:52 STCRD	$JOB name [proj,prog]
12:42:52 STERR	%SPTEPF Extraneous Password Card Found - Ignored
12:42:52 STCRD	$DECK SYSIN
12:42:52 STMSG	File  DSK:SYSIN.  Created - 1 Cards Read - 
		1 Blocks Written
12:42:52 STCRD	$EOD
12:42:52 STCRD	$SIMULA PROG.SIM(-WC)
12:42:53 STMSG	File  DSK:PROG.SIM  Created - 5 Cards Read - 
		1 Blocks Written
12:42:53 STCRD	$EOD
12:42:53 STCRD	$EXECUTE
12:42:53 STCRD	$EXECUTE
12:42:53 STCRD	$DATA
12:42:53 STMSG	File  DSK:TD9.CDR  Created - 1 Cards Read - 
		1 Blocks Written
12:42:53 STCRD	$EOD
12:42:53 STCRD	$EOJ
12:42:53 STSUM	End of File After 26 Cards
12:42:53 STSUM	Batch Input Request Created


12:42:58 BVERS  BATCON 10(107) INP: SUBJOB 01 OF 14
12:42:58 BDATE  16-Oct-74
12:42:58 BASUM  name[proj,prog] FOR **[proj,prog]
		 Log file in [proj,prog] 
		Request created at  12:42:55 16-Oct-74
		Unique: 2 Restart: 1
12:42:58 MONTR  
12:42:58 MONTR  .LOGIN proj/prog
12:43:02 USER   JOB 18 QZ 601A7vm TTY76
12:43:04 USER   Means left: -291607,50 Kr
12:43:04 USER   [LGNJSP Other jobs same PPN]
12:43:07 USER   1243	16-Oct-74	Wed
12:43:12 USER   
12:43:12 USER   QZ 601A7vm 12:43:08 TTY76
12:43:12 USER   Job 18   User OWNER
12:43:12 USER   .SET TIME 0
12:43:12 MONTR  .SET TIME 300
12:43:12 MONTR  
12:43:12 MONTR  .SET SPOOL ALL
12:43:13 MONTR  
12:43:13 MONTR  ..COMPIL /COMP/SIM DSK:PROG.SIM(-WC)/LIST
12:43:17 USER   
12:43:17 USER   SIMULA:  PROG
12:43:24 MONTR  
12:43:24 MONTR  EXIT
12:43:24 MONTR  
12:43:24 MONTR  ..EXECUT /LINK/REL DSK:PROG.REL
12:43:26 USER   LINK:	Loading
12:43:28 USER   [LNKXCT PROG Execution]
12:43:29 USER   *DEFAULT IS SYSIN FROM TTY
12:43:29 USER   DEFAULT IS SYSIN FROM TTY
12:43:29 USER   
12:43:29 USER   End of SIMULA program execution.
12:43:29 USER   CPU time: 0.11	Elapsed time: 0.62 
12:43:29 MONTR  
12:43:29 MONTR  ..ASS DSK SYSIN
12:43:29 MONTR  DSK assigned
12:43:29 MONTR  
12:43:29 MONTR  ..EXECUT /LINK/REL DSK:PROG.REL
12:43:30 USER   LINK:	Loading
12:43:33 USER   [LNKXCT PROG Execution]
12:43:33 USER   SYSIN ON DSK
12:43:33 USER   	
12:43:33 USER   1 Garbage collection executed during 19 ms
12:43:33 USER   
12:43:33 USER   End of SIMULA program execution.
12:43:33 USER   CPU time: 0.13	Elapsed time: 1.06 
12:43:34 MONTR  
12:43:34 MONTR  .
		;DSK:SYSIN created by the $DECK SYSIN card is read
12:43:34 MONTR  .ASS CDR SYSIN
12:43:34 MONTR  %Logical name was in use, Spooled CDR assigned
12:43:34 MONTR  
12:43:34 MONTR  ..SET CDR TD9
12:43:34 MONTR  
12:43:34 MONTR  ..EXECUT /LINK/REL DSK:PROG.REL
12:43:35 USER   LINK:	Loading
12:43:36 USER   [LNKXCT PROG Execution]
12:43:37 USER   SYSIN ON SPOOLED CDR
12:43:37 USER   	
12:43:37 USER   1 Garbage collection executed during 0 ms
12:43:37 USER   
12:43:37 USER   End of SIMULA program execution.
12:43:37 USER   CPU time: 0.12	Elapsed time: 0.28 
12:43:37 MONTR  
12:43:37 MONTR  .
		;The $DATA card will generate a funny named spooled
		 CDR file.
		;In this example SYSIN is used, but other files can be
		 used in
		;the same way.
.tab stops 1
.SKIP 2
H.7 EXAMPLE OF CTL FILE IN BATCH
.index ^^CTL file, example
.SKIP 1
     The following CTL file was used:
.SKIP 1
 .execute df2a
 .execute df2d
 *5
 *000000
 *150
 *old end
 *160
 *new end
 *155
 *000000
 *-1
.SKIP 2
     The following LOG file was generated:
     (Only relevant parts of LOG file shown)
.SKIP 1
14:39:15 MONTR  ..execute df2a
14:39:22 USER   
14:39:22 USER   SIMULA:  DF2A
14:39:40 USER   LINK:   Loading
14:39:40 USER   [LNKXCT DF2A Execution]
14:39:53 USER   NUMBER OF RECORDS IN DF2.DAT =   150
14:39:53 USER     
14:39:53 USER   1 Garbage collection executed during 30 ms
14:39:53 USER   
14:39:53 USER   End of SIMULA program execution.
14:39:53 USER   CPU time: 1.52   Elapsed time: 13.06 
14:39:58 MONTR  
14:39:58 MONTR  ..execute df2d
14:40:00 USER   
14:40:00 USER   SIMULA:  DF2D
14:40:10 USER   LINK:   Loading
14:40:10 USER   [LNKXCT DF2D Execution]
14:40:10 USER   WHICH RECORD?
14:40:10 USER   *5
14:40:10 USER   OLD RECORD:
14:40:10 USER   000153040110020
14:40:10 USER   NEW RECORD:
14:40:10 USER   *000000
14:40:10 USER   WHICH RECORD?
14:40:10 USER   *150
14:40:10 USER   OLD RECORD:
14:40:10 USER   001683100614210
14:40:10 USER   NEW RECORD:
14:40:10 USER   *old end
14:40:11 USER   WHICH RECORD?
14:40:11 USER   *160
14:40:11 USER   OLD RECORD:
14:40:11 USER   --NON-EXISTENT--
14:40:11 USER   NEW RECORD:
14:40:11 USER   *new end
14:40:11 USER   WHICH RECORD?
14:40:11 USER   *155
14:40:11 USER   OLD RECORD:
14:40:11 USER   /*
14:40:11 USER   NEW RECORD:
14:40:11 USER   *000000
14:40:12 USER   WHICH RECORD?
14:40:12 USER   *-1
14:40:12 USER   END OF UPDATE
14:40:12 USER     
14:40:12 USER   1 Garbage collection executed during 11 ms
14:40:12 USER   
14:40:12 USER   End of SIMULA program execution.
14:40:12 MONTR  CPU time: 0.26   Elapsed time: 2.66 
14:40:12 MONTR  
14:40:12 MONTR  .
.page
H.8 SOURCE CODE LISTING WITH ERRORS AND
           CROSS REFERENCE TABLE
.SKIP 2
.left margin 5
.fill
.index ^^Title in program listing
.index ^^Page, new, in program listing
.index ^^Program listing
.index ^^Source program listing
     The first line of the header shows the version  of  the  compiler
     and  the  creation date and time of the listing.  The second line
     contains information on the source text: Name, PPN, creation date
     and  time.   Text  given  in  a  PAGE switch will be added to the
     standard header.  The page  number  consists  of  a  main  number
     updated  at  form feeds in the source text and a secondary number
     updated at line overflow or PAGE switches.  The default value  is
     55 lines per page including the header.
     The BEGIN/END numbers are printed in the left margin.  If several
     BEGINs  and/or  ENDs appear on the same line, only the numbers of
     the first BEGIN and last  END  are  printed.   Line  numbers  are
     provided  if  they  are not present in the source text.  If there
     are faulty line numbers present  they  are  replaced  by  correct
     ones.
     An error message is inserted in the listing after the source code
     line  to which it refers.  If a faulty statement covers more than
     one line the error message appears after the  last  faulty  line.
     If,  on  the  other  hand, there are  several  statements  on  a
     line the faulty one is marked like the one in line 22 below.
.page
.left margin 0
.nofill
.nojustify
     SIMULA    1   2-OCT-1974  13:22             PAGE    1
     SIMPRO.SIM   [13,325]   2-OCT-1974  12:52  
.SKIP 1
     B1   1      BEGIN
          2 
          3 COMMENT  ***  DF2D         ***
          4    ***  THIS PROGRAM UPDATES  ***
          5    ***  RECORDS IN DF2.DAT    ***
          6 ;
          7 
          8    OPTIONS(/H);
.SKIP 1
     SIM005  W LINE     8     HELP NOT VALID IN OPTIONS STATEMENT,
                              IGNORED 
.SKIP 1
          9 
         10    REF(DIRECTFILE) FIL1;
         11    INTEGER  I;
         12    FIL1:-NEW DIRECTFILE("FIL1 DF2.DAT/I:15");
         13 
         14    INSPECT FIL1 DO
     B2  15        BEGIN
         16       OPEN(BLANKS(15));
         17    LOOP:
         18       SYSUT.OUTTEXT("WHICH RECORD?");
.SKIP 1
     SIM362  E LINE    17     IDENTIFIER SYSUT IS NOT DECLARED 
.SKIP 1
         19       SYSOUT.OUTIMAGE;
         20       SYSIN.INIMAGE;
         21       I:=SYSIN.ININT;
         22       IF I = -1 THEN GOTO 0VER;  LOCATION(I);
.SKIP 1
     SIM154  E LINE    22     MISSING BINARY OPERATOR 
     SIM362  E LINE    22     IDENTIFIER VER IS NOT DECLARED 
     SIM360  E LINE    22     INVALID OPERAND TYPE OF OPERATOR GOTO 
     SIM337  E LINE    22:1   INCORRECT NUMBER OF PARAMETERS TO
                              LOCATION 
.SKIP 1
         23       SYSOUT.OUTTEXT("OLD RECORD:"); SYSOUT.OUTIMAGE;
         24       IF ENDFILE THEN
         25          SYSOUT.OUTTEXT("--NON-EXISTENT--")
     B3  26           ELSE  BEGIN
         27          INIMAGE;
         28          SYSOUT.OUTTEXT(IMAGE.STRIP)
     E3  29              END;
         30       SYSOUT.OUTIMAGE;
         31       OUTTEXT(BLANKS(15));
         32       SETPOS(1);
         33       SYSOUT.OUTTEXT("NEW RECORD:");
.page
     SIMULA    1   2-OCT-1974  13:22             PAGE   1-1
     SIMPRO.SIM   [13,325]   2-OCT-1974  12:52  
.SKIP 1
         34       SYSOUT.OUTIMAGE;
         35       SYSIN.INIMAGE;
         36       LOCATE(I);
         37       OUTTEXT(SYSIN.IMAGE.STRIP); OUTIMAGE;
         38       GOTO LOOP;
         39    OVER: CLOSE;
     E2  40        END;
         41    OUTTEXT("END OF UPDATE"); OUTIMAGE;
     E1  42     END
.SKIP 2
     DEFAULT SWITCHES USED
.SKIP 2
     ERRORS DETECTED:
         1 TYPE W MESSAGES
         5 TYPE E MESSAGES
.page
     SIMULA    1   2-OCT-1974  13:22             PAGE    2
     SIMPRO.SIM   [13,325]   2-OCT-1974  12:52   CROSS REFERENCE TABLE
.SKIP 2
     BLANKS           16       31   
     CLOSE            39   
     DIRECTFILE       10       12   
     ENDFILE          24   
     FIL1             10D      12       14   
     I                11D      21       22M      36   
     IMAGE            28       37   
     INIMAGE          20       27       35   
     ININT            21   
     LOCATE           36   
     LOCATION         22   
     LOOP             17D      38   
     OPEN             16   
     OUTIMAGE         19       23       30       34       37       41
     OUTTEXT          18       23       25       28       31       33
                      37       41   
     OVER             39D  
     SETPOS           32   
     STRIP            28       37   
     SYSIN            20       21       35       37   
     SYSOUT           19       23M      25       28       30       33
                      34   
     SYSUT            18   
     VER              22   
.SKIP 1
     The cross reference table shows where identifiers  were  declared
     and used.  For each identifier the line numbers of all references
     are listed.  The line number may be  succeeded  by  one  or  more
     letters with the following meaning:
.SKIP 1
     D  line contains declaration
     E  external identifier
     M  more than one reference to same identifier on this line
^^
.nofill
.spacing 1
.subtitle APPENDIX H.9 SIMDDT EXAMPLES, PROGRAM LISTING
.page
.left margin 5
.right margin 65
.index SIMDDT examples
SIMULA    1A(121)  30-SEP-1974  20:50				 PAGE    1
DEMDDT.SIM#####[13,127]##27-SEP-1974##11:50
B1	    1##	BEGIN 	COMMENT simddt demonstration program;
#	    #2##	    INTEGER indexb1;  REAL rb1;  BOOLEAN bb1;
	    ##3##	    TEXT tb1;  TEXT ARRAY tab1[1:3];
	    ##4##	
	    ##5##	    TEXT PROCEDURE p1(fip1);
	    ##6##	    INTEGER fip1;
B2	    7##	    BEGIN
	    ##8##	        p2("TYPE INPUT TEXT");
	    ##9##	        p1:-Intext(fip1);
E2	   10##	    END p1;
##	   11	
	   ##12##	    PROCEDURE p2(ftp2);
	   ##13##	    VALUE ftp2; TEXT ftp2;
B3	   14##	    BEGIN
	   ##15##	        Outtext(ftp2);
	   ##16##	        Outimage;
E3	   17##	    END p2;
##	   18	
B4	   19##	    Simulation BEGIN
	   ##20##	        INTEGER isb;  REF (pc) refpc;
##	   21	
	   ##22##	        Process CLASS pc;
B5	   23##	        BEGIN
	   ##24##	            INTEGER ipc;  LONG REAL lrpc;
	   ##25##	            CHARACTER ARRAY chapc[-1:2,0:1];
	   ##26	
	   ##27##	            ls:	ipc:=ipc+1;
	   ##28##	            Hold (10);
	   ##29##	            GOTO ls;
E5	   30##	        END of pc;
##	   31	
	   ##32##	        p2("ENTER SIMULATION");
##	   33##	        isb:=10;
	   ##34##	        refpc:-NEW pc;
	   ##35##	        ACTIVATE refpc;
	   ##36##	        REACTIVATE Current AT 100;
	   ##37##	        INSPECT refpc DO
	   ##38##	        lrpc:=-1;
	   ##39##	        p2("EXIT SIMULATION");
E4	   40##	    END of simulation block;
	   ##41##	
	   ##42##	    tb1:-p1(3);
	   ##43##	    p2("PROGRAM IS LOOPING WHEN BB1 IS FALSE");
	   ##44##	    l:IF NOT bb1 THEN GOTO l;
	   ##45##	    p2("ERROR WHEN INDEXB1 IS 0");
	   ##46##	    tab1[indexb1]:-tb1;
	   ##47##	    p2("ERROR CORRECTED");
E1	   48##	END of simddt demonstration program;
.subtitle APPENDIX H.9 SIMDDT EXAMPLES, ERROR DETECTED
.page
;in appendix H.9 all user input
;is given with lower case letters
;and the output from the system with
;upper case.
;
;Terminal dialogue, error is found
_.debug demddt/list
LINK:	Loading
[LNKXCT DEMDDT Execution]
SIMDDT STARTED 
*; set breakpoints
stop at 27 ,6 "6"
*stop at 38 if ipc=isb
*proceed
ENTER SIMULATION
STOP AT MAIN:27 "6    " ,6
*scheduled
SCHEDULED PROCESSES 
###	EVTIME=  5.0000000E+01	PC O 022157  DETACHED MAIN:29
###	EVTIME=  1.0000000E+02	MAIN_PROGRAM O 021517  DETACHED 
*input chapc[0,1]:='c'
*input  chapc[-1,0]:='	'
*proceed
STOP AT MAIN:38 IPC = 10
*chain
OPERATING CHAIN 
###	PC O 022157  DETACHED MAIN:29 INSPECT BLOCK 
###	PREFIXED BLOCK SIMULATION O 021502  DETACHED MAIN:37
*output refpc.lrpc,chapc,isb
REFPC.LRPC = 0
CHAPC[-1:2,0:1]
###	[-1,0] = CHAR 9 
###	[0,1] = 'c'
ISB = 10
*proceed
EXIT SIMULATION
TYPE INPUT TEXT
123
PROGRAM IS LOOPING WHEN BB1 IS FALSE
_^C
_^C
_.reenter
ZYD623 SIMDDT ENTERED, PROGRAM INTERRUPTED AT MAIN:43
*input bb1:=true
*input tab1[1]:-tb1
*input tb1:="56"
*proceed
 ... CONTINUING ...
ERROR WHEN INDEXB1 IS 0
? ERROR IN JOB 10 AT  MAIN:46
ZYQ002 ARRAY INDEX OUT OF BOUNDS 
*variables
VARIABLES 
MAIN O 000243  DETACHED O 000000
###	BB1	= TRUE
###	TB1	== O 022132 LENGTH= 3 POS= 4 "56
###	TAB1[1:3]
######		[1] == O 022132 LENGTH= 3 POS= 4 "56
INFILE O 021130  TERMINATED 
###	IMAGE	== O 021154 LENGTH= 72 POS= 4 "123
PRINTFILE O 021175  TERMINATED 
###	IMAGE	== O 021224 LENGTH= 72 POS= 1 " 
PREFIXED BLOCK SIMULATION O 021451  TERMINATED 
###	ISB	= 10
###	REFPC	== PC O 022101  DETACHED MAIN:29
###	MAIN	== MAIN_PROGRAM O 021466  DETACHED O 003350
MAIN_PROGRAM O 021466  DETACHED O 003350
PC O 022101  DETACHED MAIN:29
###	IPC	= 10
###	LRPC	= -1.000000000000000E+00
###	CHAPC[-1:2,0:1]
######		[-1,0] = CHAR 9 
######		[0,1] = 'c'
*exit
1 Garbage collection executed during 17 ms
End of SIMULA program execution.
CPU time: 0.77	Elapsed time: 17.24 

_.
.spacing 1
.subtitle APPENDIX H.9 SIMDDT EXAMPLES, ERROR CORRECTED
.page
.nofill
.left margin 5
.right margin 65
^^
;terminal dialogue, error is corrected
;
_.execute demddt
LINK:	Loading
[LNKXCT DEMDDT Execution]
ENTER SIMULATION
EXIT SIMULATION
TYPE INPUT TEXT
_^C
_.reenter
190
ZYD623 SIMDDT ENTERED, PROGRAM INTERRUPTED AT MAIN:9
*; enter simddt via _^C and reenter
; monitor commands, note that user input must
; be given before simddt can start
input bb1:=true
*input indexb1:=3
*proceed
PROGRAM IS LOOPING WHEN BB1 IS FALSE
ERROR WHEN INDEXB1 IS 0
ERROR CORRECTED
End of SIMULA program execution.
CPU time: 0.29	Elapsed time: 12.74 
_.continue
ZYD623 SIMDDT ENTERED, PROGRAM INTERRUPTED AT MAIN:49
*; enter simddt after normal program exit
noarrays
VARIABLES EXCEPT ARRAYS 
ZYD632 GARBAGE COLLECTOR NOT CALLED BEFORE VARIABLES TYPED 
MAIN O 000243  DETACHED O 000000
###	INDEXB1	= 3
###	BB1	= TRUE
INFILE O 021130  TERMINATED 
###	IMAGE	== O 021154 LENGTH= 72 POS= 4 "190
PRINTFILE O 021175  TERMINATED 
PREFIXED BLOCK SIMULATION O 021502  TERMINATED 
###	ISB	= 10
###	REFPC	== PC O 022157  DETACHED MAIN:29
###	MAIN	== MAIN_PROGRAM O 021517  DETACHED O 003350
MAIN_PROGRAM O 021517  DETACHED O 003350
P2 O 022131  MAIN:33
###	FTP2	== O 022142 LENGTH= 16 POS= 1 "ENTER SIMULATION"
PC O 022157  DETACHED MAIN:29
###	IPC	= 10
###	LRPC	= -1.000000000000000E+00
P2 O 022226  MAIN:40
###	FTP2	== O 022237 LENGTH= 15 POS= 1 "EXIT SIMULATION"
P1 O 022253  MAIN:42
###	FIP1	= 3
P2 O 022266  MAIN:9
###	FTP2	== O 022277 LENGTH= 15 POS= 1 "TYPE INPUT TEXT"
P2 O 022315  MAIN:44
###	FTP2	== O 022326 LENGTH= 36 POS= 1 "PROGRAM IS LOOPING WHEN BB1 IS FALSE"
P2 O 022346  MAIN:46
###	FTP2	== O 022357 LENGTH= 23 POS= 1 "ERROR WHEN INDEXB1 IS 0"
P2 O 022374  MAIN:48
###	FTP2	== O 022405 LENGTH= 15 POS= 1 "ERROR CORRECTED"
_*_^C
_.
.spacing 1
.nofill
.subtitle APPENDIX H.9 SIMDDT EXAMPLES, TRACING
.page
.left margin 5
.right margin 65
^^
;terminal dialogue, use simddt for tracing
;
_.load demddt
LINK:	Loading
EXIT
_.save
Job saved
_.reenter
SIMDDT STARTED 
*; use simddt for program tracing
; set breakpoints
at 8 fip1
*at 14 ftp2
*at 28 if ipc<=4
*at 39 ifchanged refpc.lrpc
*stop at 43 if tb1 =/=notext
*; direct simddt output to file
use demtra.lst
*; list the breakpoints
breaks
*proceed
ENTER SIMULATION
EXIT SIMULATION
TYPE INPUT TEXT
*111
STOP AT MAIN:43 TB1 == O 022736 LENGTH= 3 POS= 4 "111"
*output bb1,indexb1
BB1 = FALSE
INDEXB1 = 0
*input bb1:=true
*input indexb1:=2
*proceed
PROGRAM IS LOOPING WHEN BB1 IS FALSE
ERROR WHEN INDEXB1 IS 0
ERROR CORRECTED
1 Garbage collection executed during 0 ms
FILE: DEMTRA CLOSED AT TERMINATION
End of SIMULA program execution.
CPU time: 0.71	Elapsed time: 7.72 
;
;
;
;
_.type demtra.lst

.spacing 1
^^
.right margin 65
.left margin 5
.nofill
STOP AT MAIN:43 IF TB1 =/= NOTEXT
AT MAIN:39 IFCHANGED REFPC.LRPC
AT MAIN:28 IF IPC <= 4
AT MAIN:15 FTP2
AT MAIN:8 FIP1
#
AT MAIN:15 FTP2 == O 022574 LENGTH= 16 POS= 1 "ENTER SIMULATION"
AT MAIN:28 IPC = 1
AT MAIN:28 IPC = 2
AT MAIN:28 IPC = 3
AT MAIN:28 IPC = 4
AT MAIN:39 REFPC.LRPC = -1.000000000000000E+00
AT MAIN:15 FTP2 == O 022671 LENGTH= 15 POS= 1 "EXIT SIMULATION"
AT MAIN:8 FIP1 = 3
AT MAIN:15 FTP2 == O 022731 LENGTH= 15 POS= 1 "TYPE INPUT TEXT"
STOP AT MAIN:43 TB1 == O 022736 LENGTH= 3 POS= 4 "111"
#
BB1 = FALSE
INDEXB1 = 0
#


AT MAIN:15 FTP2 == O 022760 LENGTH= 36 POS= 1 "PROGRAM IS LOOPING WHEN BB1 IS FALSE"
AT MAIN:15 FTP2 == O 023011 LENGTH= 23 POS= 1 "ERROR WHEN INDEXB1 IS 0"
AT MAIN:15 FTP2 == O 023037 LENGTH= 15 POS= 1 "ERROR CORRECTED"
.subtitle APPENDIX H.9 SIMDDT EXAMPLES, BATCH  
.page
_.type demct4.ctl
;
;
;
;simula batch job with input
; data placed in the control file.
;demddb is equal to demddt with loop
; removed, lines 43 and 44 start with !.
;simddt will be called when the error is detected
; and when simddt requests input the batch control
; system will stop the execution (? in output) and
; start the monitor command after the 
; .if (noerror) batch command.
;the reenter command will cause simddt
; to continue where it was interrupted.
_.execute demddb
*888
*999
_.IF (NOERROR) .GOTO OK
_.REENTER
*;simddt  will read the commands
*;placed after the reenter monitor
*;command.
*output indexb1
*exit
OK::.
.skip 2
^^
.spacing 1
.left margin 5
.right margin 65
.nofill
_.submit demct4.ctl
;
;
;
;
;terminal dialogue, run batch job
;
_.type demct4.log
_.
_.
_.
20:27:24 MONTR  .
20:27:24 MONTR  .execute demddb
20:27:28 USER   
20:27:29 USER   SIMULA:  DEMDDB
20:27:35 USER   LINK:	Loading
20:27:37 USER   [LNKXCT DEMDDB Execution]
20:27:40 USER   ENTER SIMULATION
20:27:40 USER   EXIT SIMULATION
20:27:40 USER   TYPE INPUT TEXT
20:27:40 USER   *888
20:27:44 USER   ERROR WHEN INDEXB1 IS 0
20:27:44 USER   
20:27:44 USER   ? ERROR IN JOB 13 AT  MAIN:46
20:27:44 USER   ZYQ002 ARRAY INDEX OUT OF BOUNDS 
20:27:44 USER   *
		##############*999
20:27:44 BATCH  .IF (NOERROR) .GOTO OK
20:27:45 MONTR  .REENTER
20:27:45 USER   
20:27:45 USER    ... continuing ...
20:27:45 USER   *;simddt  will read the commands
20:27:47 USER   *;placed after the reenter monitor
20:27:47 USER   *;command.
20:27:47 USER   *output indexb1
20:27:48 USER   0
20:27:48 USER   *exit
20:27:49 USER   
20:27:49 USER   End of SIMULA program execution.
20:27:49 USER   CPU time: 0.25	Elapsed time: 9.04 
20:27:49 MONTR  
20:27:49 MONTR  .
		##############OK:
20:27:50 MONTR  .
^^
.spacing 1
.left margin 5
.right margin 65
.skip 2
.nofill
.subtitle APPENDIX H.9 SIMDDT EXAMPLES, SEPARATE COMPILATION
.page
SIMULA    1A(121)  30-SEP-1974  20:50				 PAGE    1
p2.SIM	[13,127]  25-SEP-1974  22:22	

##
#	    1##	OPTIONS(/EXTERNAL);
#	    2##PROCEDURE p2(ftp2);
#	    3#######		VALUE ftp2; TEXT ftp2;
B1	   4#######		BEGIN
	    #5############			Outtext(ftp2);
	    #6############			Outimage;
E1	   7#######		END of p2;
#

SWITCHES CHANGED FROM DEFAULT:
#
   E EXTERNAL CLASS/PROCEDURE
#

NO ERRORS DETECTED
.spacing 1
.nofill
^^
.left margin 5
.right margin 65
.skip 5
SIMULA    1A(121)  30-SEP-1974  20:50				 PAGE    1
DEMDDE.SIM#####[13,127]##27-SEP-1974##11:50
B1	    1##	BEGIN 	COMMENT simddt demonstration program;
#	    #2##	    INTEGER indexb1;  REAL rb1;  BOOLEAN bb1;
	    ##3##	    TEXT tb1;  TEXT ARRAY tab1[1:3];
	    ##4##	
	    ##5##	    TEXT PROCEDURE p1(fip1);
	    ##6##	    INTEGER fip1;
B2	    7##	    BEGIN
	    ##8##	        p2("TYPE INPUT TEXT");
	    ##9##	        p1:-Intext(fip1);
E2	   10##	    END p1;
##	   11	
	   ##12##	    EXTERNAL PROCEDURE p2;
	   ##13
##	   14
	   ##15
	   ##16
E3	   17
##	   18
B3	   19##	    Simulation BEGIN
_.
_.
_.
_.
^^
.spacing 1
.nofill
.left margin 5
.right margin 65
.page
;terminal dialogue, separate compilation
; of simula modules.
;
.index separate compilation, SIMDDT example
;when no special switches are set (see next page)
;the extension of the first file in the debug
;command determines which debug system is used.
;
;
;
_.debug p2,demdde
SIMULA:p2
SIMULA:demdde
LINK:	Loading
[LNKXCT DEMDDE Execution]
SIMDDT STARTED 
*;debugging external modules
stop at p2:6
*proceed
STOP AT P2:6 
*chain
OPERATING CHAIN 
###	P2 O 022137  MAIN:33
###	PREFIXED BLOCK SIMULATION O 021510  DETACHED MAIN:20
*remove at 6
*stop at 42
 stop at 42
ZYD637 INVALID LINE NUMBER 
*stop at main:42
*proceed
ENTER SIMULATION
EXIT SIMULATION
STOP AT MAIN:42 
*output bb1
FALSE
*exit
End of SIMULA program execution.
CPU time: 0.29	Elapsed time: 11.88 
_.
.spacing 1
^^
.left margin 5
.right margin 65
.subtitle APPENDIX H.9 SIMDDT EXAMPLES, BOTH DDT AND SIMDDT
.page
.skip2
.nofill
;terminal dialogue, use of both ddt and simddt
;
.index DDT 
.index SIMDDT and DDT
_.debug %"debug:ddt" demddt
LINK:	Loading
[LINKDEB DDT Execution]
####
$g
simddt STARTED
_*stop at 7
_*proceed
STOP AT MAIN:7
_*;exit SIMddt and enter DDT
_^C
_.ddt
15/	27030
jrst 2,@.jbren$x
_... CONTINUING ...
;simddt entered from ddt
;simddt still expecting command
output bb1
FALSE
_*;continue normal processing
_.
_.
_.
_.
^^
.fill
.nojustify
.spacing 1
.left margin 5
.subtitle APPENDIX I ERROR REPORT
.page
.skip 2
.indent -5
APPENDIX I##ERROR REPORT
.index ^^Error report
.index ^^SPR
.index ^^Software performance report
.index ^^Software problem report
.break
.indent -5
========================
.skip 2
Software errors in the SIMULA system should be reported to 
SIMULA maintenance, Section 142, Swedish National Defence Research Institute, S-104 50 STOCKOLM 80, SWEDEN using the error report
form on the next page (or a copy of it).
.skip 1
The failing program and relevant input data (listings
and, if necessary, convenient storage medium) should be submitted
together with the report. If the error can be isolated in a smaller and simpler program, this program should
be submitted.
.skip 1
If there has been any changes made to the SIMULA system
at your installation, please indicate this on the error
report and submit listings of changed software components
with all modifications indicated.
.page
.left margin 0
.paper size 60,70
.nofill
.center
DECsystem-10 SIMULA ERROR REPORT
.skip 1
------------------------------------------------------------------
.center
Send report to SIMULA maintenance, Section 142, Swedish National###
.center
Defence Research Institute, S-104 50, STOCKHOLM 80, SWEDEN.##
------------------------------------------------------------------
INSTALLATION:################################RELEASE NO:
CUSTOMER'S NAME:#############################TELEPHONE:
ADDRESS:#####################################YOUR REFERENCE:
.skip 1
ATTACHED TO THIS REPORT ARE:##################COMPILATION LISTING []
TTY OR LOG LISTING###[]###SOURCE PROGRAM []###OBJECT PROGRAM######[]
TEST MATERIAL########[]############OTHER []:
.skip 1
PLEASE INDICATE MODIFICATIONS TO THE SIMULA SYSTEM:
NO []#####YES [] COMPONENTS:
.skip 1
PROBLEM DESCRIPTION:
.skip 18
#####################################################CONTINUED []
-----------------------------------------------------------------
.center
For use by FOA/ENEA:###########
-----------------------------------------------------------------
PROBLEM ANALYSIS:
.skip 4
CORRECTIVE ACTION TAKEN:#####################DATE:
.skip 4
CORRECTED IN RELEASE NO:
DATE FOR CUSTOMER CONTACT:
-----------------------------------------------------------------
################!  !  !  !  !  !  !  PLEASE REFER TO THIS NUMBER
REGISTRATION NO !  !  !  !  !  !  !  IN FURTHER CORRESPONDENCE.
.fill
.paper size 55,65
.paper size 55,65
^^
.LEFT MARGIN 5
.NOJUSTIFY
.SPACING 1
.SUBTITLE APPENDIX J PROGRAM MEASUREMENT SYSTEM
.PAGE
.INDENT -5
APPENDIX J: PROGRAM MEASUREMENT SYSTEM.
.BREAK
.INDENT -5
=======================================
.index ^^Program measurement and optimization
.index ^^Frequency count on program execution
.index ^^Tracing of programs
.index ^^Optimization of programs
.index ^^Performance measurements
.index ^^FQC program for program measurements
.SKIP 1
FQC - MEASUREMENT AND TRACING SYSTEM FOR SIMULA PROGRAMS
.br;========================================================
.s 1;If a SIMULA program has been developed which will be used very
often, e.g.  as a part in a regularly used production system, it
is often profitable to make some efforts to optimize the program.
.s;A central and sometimes non-trivial problem in program optimization
is to find the innermost loops of the program.
Once the execution profile of a program is known it is usually
easy to make it faster with a few changes such as modifications
in processing algorithms or by using a small machine language
subroutine.
.s 1;DEC-10 SIMULA is delivered with a frequency measurement system
which assists in spotting frequently executed parts of a SIMULA
program.  The system consists of two SIMULA programs, FQCRED and
FQCLST.
.s 1;The system is used as follows:
.s 1;The program to be analyzed must have been tested well enough to
run to normal completion.  It is read by the program FQCRED which
produces two modified versions of it, one of which is a
compilable SIMULA program (.FQ1+.FQ2) and the other a listing later
used to produce the frequency listing (.FQD).  The modified compilable
program is automatically compiled (.FQR), linked and started.
It will, if normally terminated, produce
a file of measured frequencies (.FQS) (subsequent runs
will optionally update the frequencies in .FQS). This file is merged with the
listing output from FQCRED by the program FQCLST, which produces the
final output (.FQL).
.s 1;The user may also measure the execution time for different
parts of his program by editing calls to a procedure Z__T(I)
into his program. A call with I > 0 initiates a timing which is
ended by a call with the corresponding negative I. The logic
is as follows:
.br;+100>=I>0  T0[I]:= cptime;
.br;-100<=I<0  J:=-I; ACC[J]:= ACC[J]+(cptime-T0[J]);
.br;Calls to Z__T may be overlapping (even partly).
.tp 15;.s 1;.nf;.nj;For example:
.b;BEGIN
	....
	Z__T(+1);------------+
	....                |
	Z__T(+2);---------+  |
	....             |  |
	Z__T(+3);------+  |  |
	....          |  |  |
	Z__T(-2);------)--+  |
	....          |     |
	Z__T(-3);------+     |
	....                |
	Z__T(-1);------------+
	....
END
.f;.s 1;The resulting CPU-times will be presented at the end of
the result file (.FQL). For reliable results, do not try
to measure too small intervals (depending on the precision
of the timing). Note that only such measurements that
yielded accumulated times > 0 will be printed.
.s 1;The measured program should satisfy some restrictions:
.ls;.le;The program must not contain the identifiers Z__Q, Z__T or Z____.
.le;The program should not use any files on DSK: named
<program name>.FQ1 .FQ2 .FQR .FQD .FQS .FQL or .FQT.
.le;The program should terminate through its last END.
I.e. not through a call to Exit or via SIMDDT.
.le;The source code lines should preferably not contain
	any internal TABs (leading TABs are OK). If so, the
produced frequency indicators (|) might be misplaced
(within such a line). TABs may be removed with
_.COPY temp.sim=prog.sim(W).
.els
.s 1;Note that the frequency indicators will be positioned at the
first position of the symbol counted. Its related number should
be interpreted as the number of times this symbol has been
PASSED during the execution. An indicated label (L:) will thus
tell how many times control passed the label from left,
excluding explicit jumps (GO TO L).
.p 0,1,3;TRACING
.s 1;By adding the switch /T to the file specification requested
by FQCRED a trace file (.FQT) will be produced, containing
the number of each executed (counted) statement. This may
be useful when debugging Simulation programs or programs
making use of Resume/Detach. If the program terminates with
an error the file with logical name TRACE must be closed
before leaving SIMDDT (*Close TRACE).
.s 1;The result file (.FQL) will contain information about the number
of the first traced statement on each source line. Consecutive
numbers will be indicated as  xx-yy in .FQT. Note that
the file is created in APPEND mode adding new traces to the
end of the file. The trace file will contain the first six
characters of the traced symbol followed by its statement
number.
.s 1;Adding a number to the trace switch (/T:x) will trace
the executed statements the first x times. Every statement
number will be displayed (no xx-yy compacting). X must be >= 0,
/T:0 is equivalent to /T.
.s 1;The use of tracing will considerably increase the execution
time of the modified program. Thus it is not recommended to
use timing (Z__T) together with tracing. The tracing may be
switched off by calling the procedure TRACEOFF. It may be
activated again by calling TRACEON.
.s 1;If you want to include any of your external modules in the
analysis, run the program SIMEXP prior to FQCRED.
.s 1;The following session illustrates the use of the system on the
SIMULA program FLOPY.SIM.
.s 1;.nf;.lm 10;_.RUN PUB:FQCRED
.s 1;Program:flopy
.s 1;FQCRED: CPU time: 1.40]
Running modified program: SIMULA:  FLOPY
LINK:	Loading
[LNKXCT FLOPY Execution]
.s 1;If you want to have the result run FQCLST.
To accumulate the frequencies just type: START
.s 1;End of SIMULA program execution.
CPU time: 1.44	Elapsed time: 3.08 
.s 1;_; The program may also be rerun
.br;_; with .EX[/REL flopy.FQR]
.s 1;_.RUN PUB:FQCLST
.s 1;Program:flopy
.s 1;Result on file: DSK:FLOPY.FQL
.s 1;_.DIRECT/F flopy
.s 1;FLOPY.SIM    User program
FLOPY.FQ1    Modified file part 1 (prolog)
FLOPY.FQ2    Modified file part 2 (epilog)
FLOPY.FQD    Edited skeleton file with bars (|)
FLOPY.FQR    REL-file from compilation of FQ1+FQ2
FLOPY.FQS    Frequency + timing data (binary)
FLOPY.FQL    Result file (merged FQS+FQD)
.s 2;_.TYPE flopy.fql
.s 1;        BEGIN COMMENT FREQUENCY MEASUREMENT EXAMPLE;
            INTEGER u,k;   TEXT t;
            z__t(+1);
     1      |1
            WHILE Draw(0.999,u) DO u:= u+2;
  1636      |1                     |1636
            z__t(-1);
     1      |1
            z__t(+2);
     1      |1
            FOR u:= 1 STEP 1 UNTIL 5000 DO
     1      |1
            IF t = NOTEXT THEN k:=k+1;
  5000      |5000              |5000
            z__t(-2);
     1      |1
            z__t(+3);
     1      |1
            FOR u:= 1 step 1 UNTIL 5000 DO
     1      |1
            IF t == NOTEXT THEN k:=k+1;
  5000      |5000               |5000
            z__t(-3);
     1      |1
            z__t(+4);
     1      |1
            FOR u:= 1 step 1 UNTIL 5000 DO
     1      |1
            IF TRUE THEN k:=k+1;
  5000      |5000        |5000
            z__t(-4);
     1      |1
        END;
     1  |1
.tp 16;.s 1;FQC results:
Max frequency:      5000
Sum frequency:     31649
No. of executions:     1
.s 1;CPU timing: Total   1.08 sec.
.s 1;Call no.    Time spent    % of runtime
    1          0.095           8.77
    2          0.499          46.08
    3          0.250          23.08
    4          0.239          22.07
.lm 5;.f;.s 2;Cleaning up afterwards might be done with .DELETE *.FQ?
^^
.spacing 1
.fill
.subtitle APPENDIX K TECO, SOS OR EDITS ON SIMULA PROGRAMS
.paper size 58,65
.page
.left margin 5
.nojustify
.indent -5
K.###USING TECO, SOS OR EDITS ON SIMULA PROGRAMS
.break
===========================================
.skip 3
.index ^^editing of SIMULA source programs
.index ^^TECO text editor
.index ^^line numbered files
.index ^^text editing of SIMULA source programs
.indent -5
K.1##WHY LINE NUMBERED SIMULA SOURCE PROGRAMS?
.skip 1
Run time error messages in SIMULA include the number of the source program line
at which the error occurred. With the SIMULA debugging
system (SIMDDT) you can place breakpoints at given lines in the source pogram.
.skip 1
.index ^^SIMDDT, handling of line numbered source programs
.index ^^debugging system (SIMDDT) and line numbers
.index ^^breakpoints, line numbers for
It is possible to use SIMDDT without line numbered source programs. The SIMULA compiler
will then number all lines in the source program seqentially starting with 1.
This numbering is printed on source program listings produced by the compiler.
.skip 1
However, every time you insert a new line into a source program, the numbers
of all later lines will be changed. This means that you cannot
always use a slightly out-of-date
program listing to decide where to put your breakpoints or to find out
at which line the error occurred.
.skip 1
.index ^^old source program listings, validity of line numbers
If you use line numbered source files, the line number is usually
incremented by 10 or more between successive lines. This gives you the
possibility to insert new lines into a source program without changing
all following line numbers. An old source program listing is then
often sufficient when debugging with SIMDDT.
.skip 1
If you have a line numbered file with the line number incremented by 10
between successive lines, you can even insert more than 9 new lines between
two old lines with TECO and SIMULA.
.skip 1
You can give the new lines blank line numbers. The SIMULA compiler
will then assign line numbers to the blank numbered
lines during the compilation.
.skip 1
.index ^^blank line numbers
.index ^^line numbers, blank
The SIMULA compiler will increment the line number by 1 until a source
line is encountered which has a number larger than that incremented
by the SIMULA compiler. If a file has three lines with numbers
140, 150 and 160,
and 15 lines with blank number fields
are put between line 140 and 150, then the SIMULA
compiler will assign the numbers 141 to 155 to the new lines,
and the old line 150 will be numbered 156.
Line 160 and later lines in the source file will
keep their original numbers.
.skip 1
.index ^^renumbering of source program lines
The algorithm in the SIMULA compiler is to compare the line number
in the source file (if any) with the previous line number incremented
by 1, and assign the larger of the two numbers to the line.
.skip 1
You can also let TECO or PIP renumber the file instead of accepting
the automatic renumbering done by the SIMULA compiler.
.skip 1
.test page 10
Example:
.skip 1
.nofill
File with 15 inserted new lines between two old lines:
00140###comment line before insertion;
########comment first inserted line with blank line number;
########comment second inserted line with blank line number;
 . . . etc . . .
########comment 15th inserted line;
00150###comment line after insertion;
00160###comment line after line after insertion;
.skip 1
.test page 8
File as numbered by the SIMULA compiler:
00140###comment line before insertion;
##141###comment first inserted line with blank line number;
##142###comment second inserted line with blank line number;
 . . . etc . . .
##155###comment 15th inserted line;
##156###comment line after insertion;
00160###comment line after line after insertion;
.skip 1
.fill
As you can see from the example above, only one line after the
insertion had to be renumbered by the SIMULA compiler. All succeeding
lines keep their old numbers.
.skip 2
.test page 5
.left margin 0
K.2##WHICH TEXT EDITOR SHOULD YOU USE?
.skip 1
.index ^^text editor, selection of
.index ^^EDITS text editor
.index ^^TECO text editor
.index ^^SOS text editor
.index ^^STOPGAP, SON OF, text editor
.index ^^SON OF STOPGAP text editor
.index ^^LINED text editor
.index ^^text editor
.left margin 5
.fill
You may find it natural to use a line number oriented
text editor like SOS or EDITS for line numbered files.
TECO has, however, the advantage of blank line numbers
which means that there is no limit to the number of new
lines you can insert between successive old lines
in the file without renumbering the file.
WARNING: SOS does not accept such files with blank
line numbers that TECO can produce.
.p -5,2,10
K.3  HOW TO USE SOS OR EDITS ON SIMULA SOURCE PROGRAMS
.skip 1
When using SOS or EDITS
you often split a file into several pages, each with its own
line sequencing.  When given such a file, however,
the SIMULA compiler will have to renumber parts of pages with
overlapping line numbers and this might cause a lot of warning
messages.  To avoid this you are advised to resequence the file
monotonically by using the NP-command of SOS or N-command of EDITS:
.center
NP#<step>#,/1:/*,M
.break
where####2<=###step###<=entier(65535/number#of#lines).
.break
If there are less than 650 lines in your file you may accordingly
use the default step size of 100.  The step size must not be 1,
because the page marks that EDITS or SOS inserts will be given
line numbers by the SIMULA compiler and a step size of 1 would 
cause the rest of the file to be resequenced.
.skip 1
If you prefer to use TECO, you should read
the rest of this appendix.
.left margin 0
.skip 2
.test page 5
K.4##HOW TO GIVE A FILE NEW LINE NUMBERS WITH TECO
.skip 1
.left margin 5
If you want to put line numbers on a previously unnumbered file, or
if you want to resequence a file with new line numbers with the
increment 10 between succeeding lines, then you should use the
switch GENLSN with the .TECO or EB commands.
.skip 1
.index ^^GENLSN switch for TECO
.test page 6
Example:
.skip 1
TECO simprg.sim/genlsn
.skip 1
R TECO
.break
EBsimprg.sim/genlsn$y$$
.skip 2
.test page 5
.left margin 0
K.5##EDITING A LINE NUMBERED FILE WITH TECO
.skip 1
.left margin 5
Editing a line numbered file is very similar to editing a file without
line numbers. You only have to remember that each line begins with a
line number. This line number is either five digits followed by a TAB
or five spaces followed by a TAB.
.skip 1
.index ^^line numbers, format of
When you insert new lines into a file, you need not give them any
line number. TECO will automatically give them a line number of
five spaces and a TAB when the file is output on disk.
.skip 1
If you wish, you can give new lines explicit line numbers by
inserting the new line number, followed by a tab, into the beginning
of the new line.
.skip 1
.test page 12
Example:
.skip 1
.nofill
File before editing:
00140###Comment line before insertion;
00150###Comment line after insertion;
.skip 1
to insert a new line with blank line number you can write:
s00150$0licomment new line to get a blank line number;$$
.skip 1
to insert a new line with the line number 145 you can write:
s00150$0li145###comment new line with line number and TAB;$$
.skip 1
.fill
If you want a new line to begin with a sequence consisting of five or less
spaces or digits followed by a TAB, but do not want the sequence
to be interpreted by TECO as a line number, then just insert five spaces and
a TAB in front of that sequence.
.index ^^TAB character, use after line numbers
.paper size 55,65
.nojustify
.subtitle APPENDIX L AUTOMATIC EDITING OF SIMULA PROGRAMS
.page
.sp 1
APPENDIX L AUTOMATIC EDITING OF SIMULA PROGRAMS
===============================================
.lm 5
.skip 2
.index ^^Automatic editing of SIMULA programs by the SIMED program
.index ^^SIMED program for editing SIMULA program files
.index ^^Editing SIMULA programs automatically by the SIMED program
.index ^^Improving the layout of SIMULA programs automatically (SIMED program)
.fill
The SIMED program converts SIMULA source program files.
The program is able to
.p 0,1,0
.ls
.le;Indent the program (for better readability),
and at the same time -
.le;Count the number of BEGIN-END pairs.
.le;Convert reserved words, standard and user identifiers to
1) UPPER CASE 2) lower case or 3) Edit Case (1st char. upper case).
.le;[Re]number the output file.
.els
.s;Lines which become too long at indentation are split up at an appropriate
position.
Long text constants will be split up according to the new, concatenated text
constant format:
.br;"ABC"
.br;"DEF"
.s;Split up lines will not be indented properly if they contain
BEGIN or END. Also, numerical constants containing
blanks may occasionally be improperly split.
The programmer is recommended to start source code lines
with BEGIN and END resp.
.s;New command format for SIMED version 2:
.s;[outfile=]infile[/switches...]
.s;for example:
.s;outfile=infile/i:4/r:80/e:13200
.br;(Devices NUL: and TTY: are accepted.)
.s;Default switches:
.lm 25
.tab stops 25
.i -20;/I:4	Indent step 4. Removes leading blanks and tabs.
If negative then leading blanks
and tabs will be kept.
.s;.i -20;/E:13200(UEL00)	Perform editing on the following items:
reserved words, standard ids, own ids,
Comments_&Options, Text_&Character
constants resp. 1 (U) = Upper CASE,
2 (L) = Lower Case, 3 (E) = Edit case,
0 = no change.
.s;.i -20;/R:80	Outfile record length 80.
.s;.i -20;Other switches:
.i -20;/SIMSET	Recognize SIMSET identifiers
(default for SIMSET and SIMULATION blocks)
.s;.i -20;/-SIMSET	Do not recognize SIMSET ids
.s;.i -20;/SIMULATION	Recognize SIMULATION identifiers
(default for SIMULATION blocks)
.s;.i -20;/-SIMULATION	Do not recognize SIMULATION ids
.s;.i -20;/TABS	Use tabs in indentation (default)
.s;.i -20;/-TABS	Do not use tabs
.s;.i -20;/NUMBERED:xx	Produce line numbered output, incr. xx
(default 100). Explicit increment will
renumber the file.
The switch is default if input file has
line numbers.
.s;.i -20;/-NUMBERED	Suppress line numbers on output.
(default if input file lacks line numbers).
.s;.i -20;/Z:n	Suppress indentation for n block levels
(default 0). May be < 0 (>= -10),
assuming surrounding levels.
.s;.i -20;/G	Perform last COMPIL command after processing
.s;.i -20;!xxx	Run program XXX after processing
.lm 5
.s;Your own default switches can also be given in a file SWITCH.INI on your
area with format:
.s;SIMED	/switch/switch...
.s;Example: If you want files to be edited with reserved words in lower case,
your own identifiers in upper case, and standard identifiers with upper case
initial letter, standard indentation=2, record length=100, put the following
line in SWITCH.INI:
.s;SIMED	/E:LEU/I:2/R:100
.s;Trailing zeros in the E switch may be omitted - the system default will be
used in those positions.
You can always override the default values in the command to SIMED.
.s;Default extension is SIM. Default outfile name is infile name.
.s;If you want only default values, the command string to edit the file X.SIM
with the same output file name is simply X.
.s;The shortest possible command to apply SIMED to a file X.SIM is -
.s;	.R SIMED-X
.s;SIMED will take what follows after a minus sign as the first command and
exit after editing. CONTINUE will put SIMED in command mode, expecting
further commands. START or START-<command-string> may also be used in that
situation.
.s;Exit from SIMED by entering _^Z or _^C.
.s;[The file SYS:SIMED.DAT used by SIMED version 1 is no longer
required.]
.spacing 1
.nojustify
.paper size 55,65
.nofill
.subtitle ^^APPENDIX M CONVERSION OF SIMULA PROGRAMS
.page
APPENDIX M CONVERSION OF SIMULA PROGRAMS
========================================
.left margin 5
.fill
.skip 2
.indent -5
M.1   CONVERSION FROM IBM 360/370 SIMULA TO DEC SYSTEM-10 SIMULA
.skip 1
.indent -5
M.1.1 WHAT IS DONE BY THE IBMSIM PROGRAM
.skip 1
The program IBMSIM can be used to perform the following conversion tasks:
.skip 1
.indent -2
> Change the IBM source input control records like %PAGE, %TITLE, %SOURCE etc.
to their DEC 10 equivalents.
.skip 1
.indent -2
> Eliminate IBM source control cards %(NO)LIST, %INDENT=n and %(NO)RESWD etc.
In order to indent your program, use the SIMED program (see appendix L) afterwards.
.skip 1
.indent -2
> Convert long real constants to DEC 10 format.
.skip 1
.indent -2
> Issue a warning if numerical constants are out of range.
.skip 1
.indent -2
> Eliminate card sequence numbers if present.
.skip 2
.indent -5
M.1.2 WHAT IS NOT CONSIDERED BY THE IBMSIM PROGRAM
.skip 1
.indent -2
> Conversion of hexadecimal constants to DEC 10 format.
.skip 1
.indent -2
> IBM file names longer than six characters will not be  unique
if the 
first parts of two of more filenames are equal.
.skip 1
.indent -2
.indent -2
> Maximal number of subscripts is 10 on DEC 10 and 127 on IBM.
.skip 1
.indent -2
> Virtual quantities may may only be of
the types defined in the COMMON BASE: LABEL, SWITCH or PROCEDURE.
This problem is due to the extension of the IBM system and
could often be overcome by the use of virtual type procedures.
.skip 1
.indent -2
> Subscript checking is done for each element separately in the DEC 10 SIMULA
system. In the IBM system only the resulting index is checked.
.skip 1
.indent -2
> The standard procedures RANK and CHAR return different results due
to
different collating sequences. However, programs could often be written
to be independent of this effect.
.skip 1
.indent -2
> The facilities for creating and using EXTERNAL modules are much more powerful, and thus different, on the DEC 10.
.skip 1
.indent -2
> Some of the mathematical standard procedures
are not supplied in double precision in the first DEC 10 SIMULA
release. (The compiler will warn you in such cases.)
.skip 1
.indent -2
> The maximum floating point number is approx. 1.7_&+38, while for IBM
it is about _&+75. A warning will be issued if the
program contains real constants out of range.

.skip 1
.indent -2
>#The input file must not contain line numbers.
.skip 2
.test page 15
.skip 2
.indent -5
M.2 CONVERSION FROM DEC SYSTEM-10 TO IBM 360/370 SIMULA
.skip 1
.indent -5
M.2.1 WHAT IS DONE BY THE SIMIBM PROGRAM
.skip 1
The program SIMIBM can be used to perform the following conversion tasks:
.skip 1
.indent -2
> All lower case letters are translated to upper case.
.skip 1
.indent -2
> Long real numerical constants are converted to IBM format.
.skip 1
.indent -2
> All calls to standard procedure BREAKOUTIMAGE are replaced with
OUTIMAGE.
.skip 1
.indent -2
> The special COMMENT symbol '!' is converted to "COMMENT ".
.skip 1
.indent -2
> The exponentiation symbol '_^' is converted to "**".
.skip 1
.indent -2
> All square brackets are converted to parentheses.
.skip 1
.indent -2
> All lines longer than 72 characters are split. The program tries to
split the line at an appropriate position.
However, numerical constants containing
blanks or tabs could occasionally be improperly split.
.skip 1
.indent -2
> The NOT symbol '_\' and the NOT-EQUAL symbol '_\=' are converted to NOT and NE respectively.
.skip 1
.indent -2
> All tabs are translated to blank(s).
.skip 1
.indent -2
> OPTIONS is translated to COMMENT.
.index ^^conversion of SIMULA programs
.SKIP 1
.INDENT -5
M.2.2 WHAT IS NOT DONE BY THE SIMIBM PROGRAM
.SKIP 1
.INDENT -2
>#External declarations must be removed before processing.
Use the SIMEXP program before running SIMIBM.
.skip 1
.indent -2
>#The input file must not contain line numbers.
.skip 2
.test page 15
.INDENT -5
M.3##CONVERSION FROM CDC SIMULA TO DEC SYSTEM-10 SIMULA
.skip 1
.index ^^conversion from CDC to DEC of SIMULA programs
.index ^^CDC SIMULA program conversion to DEC
.index ^^Control Data SIMULA program conversion
.index ^^Source program conversion
.index ^^CDCSIM conversion program
.index ^^Transport of SIMULA programs from CDC
.index ^^Portability of SIMULA from CDC to DEC
.indent -5
M.3.1 WHAT IS DONE BY THE CDCSIM PROGRAM
.skip 1
The program CDCSIM can be used to perform the following conversion tasks:
.skip 1
.indent -2
>#Change characters from the CDC to the ASCII character set.
.skip 1
.indent -2
>#Change certain SIMULA words which are differently
spelled on CDC and DEC (e.g. "POWER" to "**", ".," to ";").
.skip 1
.indent -2
>#Find CDC identifiers longer than 12 characters, which are
different but equal in their first 12 characters, and
rename a few characters in one of them since only the first 12 characters are
significant on DEC SIMULA.
.skip 1
.indent -2
>#Rename identifiers which are reserved words on DEC but not
on CDC (e.g. ELSE or THEN).
.skip 1
.indent -2
>#Remove the delimiters surrounding operator words on CDC.
.skip 1
.indent -2
>#Optionally change CDC REAL variables and constants to DECsystem-10
LONG REAL, because of the smaller precision of REAL on the DECsystem-10.
.index ^^precision, of REAL's: CDC compared to DEC
.index ^^CDC REAL precision higher than on DEC
.index ^^REAL precision on CDC and on DEC
.skip 1
.indent -2
>#Remove blanks inside identifiers.
.skip 1
.indent -5
M.3.2 WHAT IS NOT DONE BY THE CDCSIM PROGRAM
.skip 1
Here is an incomplete list of things not done by the CDCSIM
program:
.skip 1
.indent -2
>#Conversion of TEXT and CHARACTER constants.
.skip 1
.indent -2
>#Conversion of COMMENTS.
.skip 1
.indent -2
>#Conversion of the format of declarations of external
FORTRAN and ASSEMBLY procedures.
.skip 1
.indent -2
>#Conversion because RANK and CHAR work differently with the CDC
and the ASCII character codes.
.skip 1
.indent -5
M.3.3 PROBLEMS WHICH MAY OCCUR
.skip 1
You may have trouble with multi-line text constants in
some special cases.
.skip 1
Since the conversion of the CDCSIM program from IBM to
DEC SIMULA, it has only been tested on one very large
CDC program, which program however was converted correctly.
CDCSIM has however been tested very thoroughly on many IBM SIMULA
installations before conversion to DEC.
.skip 1
.indent -5
M.3.4 HOW TO USE THE CDCSIM PROGRAM
.skip 1
Just run the program and answer the questions put to you.
The program will ask for:
.indent -2
>#File name for input CDC program and output DEC program.
.indent -2
>#If you want to list the output program on the TTY.
.indent -2
>#If you want the program to modify long identifiers to
avoid name clashes.
.indent -2
>#If you want to modify yourself the first 8 characters
of such clashing identifiers.
.skip 1
The program will use default values for all input
parameters except the file name of the CDC program.
Help is available by answering ? to the questions given
by the program.
.skip 1
If you modify long identifiers, then the program will produce
a temporary file TEMP.TMP.
.skip 1
The program also has a facility to convert from UNIVAC to IBM
SIMULA, but this facility has not been tested on DEC.
The facility is triggered by a line "%CON" in the input file.
.index ^^UNIVAC SIMULA programs conversion to DEC
.index ^^Conversion of SIMULA programs from UNIVAC to DEC
.skip 1
.indent -5
M.3.5 ACKNOWLEDGEMENT
.skip 1
.index ^^Norwegian Computing Center
.index ^^CONVERT source program conversion program
CDCSIM was originally produced by the Norwegian Computing
Center for converting UNIVAC and CDC SIMULA programs to
IBM. We are very grateful for their permission to
modify it for CDC to DEC conversion.
.subtitle ^^APPENDIX N, THE DEC SYSTEM-10 SIMULA PROGRAM LIBRARY
.spacing 1
.nojustify
.left margin 5
.paper size 55,65
.page
.figure 3
.index ^^program library
.index ^^distribution of library programs
.index ^^library of programs
.index ^^SIMULA program library
.index ^^utility programs library
.indent -5
APPENDIX N: THE DEC SYSTEM-10 SIMULA PROGRAM LIBRARY
.break
.indent -5
=====================================================
.skip 2
.fill
This APPENDIX has been moved to the DECsystem-10 SIMULA Language
Handbook Part III.
^^
.subtitle APPENDIX O DUMP OF GENERATED CODE
.page
.nofill
.spacing 1
.left margin 5
.right margin 65
.index ^^generated code
.index ^^Macro 10 listing of generated code
.index ^^DUMP monitor command
APPENDIX O DUMP OF CODE GENERATED BY THE SIMULA COMPILER
========================================================
.skip 3
;The simula compiler does not contain any
;built-in routine for generating a Macro 10
;listing of the generated code.
;It is possible to get such a listing with the
;help of the monitor command DUMP (or the DUMP program).
;You need a program listing with the
;line number table (Y switch set on
;during compilation) and a link map listing.
;
;
_.load /map simcod(ly)

SIMULA: SIMCOD
LINK: Loading
EXIT
_.save
Job saved
_.type simcod.lst
.skip 1


SIMULA    1A(121)   1-OCT-1974  17:40				 PAGE    1
SIMCOD.SIM	[13,127]   1-OCT-1974  17:35	
.skip 1

B1	    1	BEGIN
##	    2	    INTEGER ARRAY a[1:2];
##	    3	    PROCEDURE p;;
##	    4	    a[1]:=a[1]+1;
##	    5	    p;
E1	    6	END
.skip 1


DEFAULT SWITCHES USED

.skip 1

NO ERRORS DETECTED
.skip 2
SIMULA    1A(121)   1-OCT-1974  17:40				 PAGE    2
SIMCOD.SIM	[13,127]   1-OCT-1974  17:35		LINE NUMBER TABLE
.skip 1
0##000052
1##000060
2##000062
3##000067
3##000070
4##000071
5##000100
6##000102
7##000104
.SKIP 4
.page
_.type simcod.map
.skip 2
		LINK-10 symbol map of	SIMCOD		page 1
	Produced by LINK-10 version 1B(131) on  1-Oct-74
.skip 1
Low  segment starts at  0 ends at 710 length 711 = 1P
####	Start address is    212, located in program .MAIN
####
####		*************

JOBDAT-INITIAL-SYMBOLS

####	Zero length module

####		*************

.skip 1
_.MAIN	from DSK:SIMCOD.REL[13,127]	created by SIMULA /KI10
####	Low  segment starts at 140 ends at 363 length 224 

.skip 1
####	.MAIN	         212	Global symbol	Relocatable	
####	.MAINL         313	Global symbol	Relocatable	

####		*************

OCSP	from SYS:SIMLIB.REL[1,4]
_.
_.
;Suppose that you want to get a listing of the
;code generated from statements in lines 4-6 in the
;simcod program. Then look at the line number table
;entries for these lines and also at the LINK-10 map
; for the program, where you find the .MAIN module 
;start address which is usually 140.
;Line 4 starts at address 000071 and
;line 6 ends at 000103.
_.get simcod
Job setup
.skip 1
_.dump /OUT:TTY:/MODE:SYM/WIDTH:30/JUSTIFY:L/IRADIX:8
 /d [(140+71) _& (140+103)
.skip 1

231/	MOVE   5,2(15)                
232/	MOVEI  6,1                    
233/	CAML   6,4(5)                 
234/	CAMLE  6,5(5)                 
235/	UUO001 2                      
236/	ADD    6,2(5)                 
237/	AOS    3,(6)                  
240/	MOVEI  1,251                  
241/	PUSHJ  17,400011              
242/	MOVEI  1,                     
243/	DPB    1,143                  
.skip 1
EXIT
.subtitle ^^APPENDIX P, CONVERSION FROM DEC 10 ALGOL TO DEC 10 SIMULA
.fill
.spacing 1
.nojustify
.left margin 5
.paper size 55,65
.page
.figure 3
.indent -5
APPENDIX P: CONVERSION FROM DEC 10 ALGOL TO DEC 10 SIMULA
.index ^^ALGOL, conversion from ALGOL to SIMULA
.index ^^conversion from ALGOL to SIMULA
.index ^^DECsystem-10 ALGOL, conversion into SIMULA
.break
.indent -5
=========================================================
.skip 2
.indent -5
.index ^^efficiency of SIMULA compared to ALGOL
.index ^^speed of SIMULA as compared to ALGOL
.index ^^cost of using SIMULA as compared to ALGOL
.index ^^optimization, degree of in the compiler
P.1##WHY TRANSLATE FROM ALGOL TO SIMULA?
.skip 1
Here are some reasons why you may want to go over from
DECsystem-10 ALGOL to DECsystem-10 SIMULA:
.skip 1
.indent -2
>#To use facilities which SIMULA has but not ALGOL, e.g. better
data structuring, a garbage collector,
simulation facilities, the SIMDDT system,
higher security against programming errors, direct access i/o.
.skip 1
.indent -2
>#To use the text string handling in SIMULA, which is roughly five times
faster than in ALGOL.
.index ^^text string handling, efficiency of
.index ^^string handling, efficiency of
.skip 1
.indent -2
>#To use the formatted i/o in SIMULA, which is
roughly twice as fast in SIMULA as in ALGOL.
.index ^^input-output, efficiency of
.index ^^output, efficiency of
.index ^^formatted i/o, efficiency of
.skip 1
On the other hand, a SIMULA compilation takes nearly twice as long
CPU time and requires about twice as much core as an ALGOL compilation.
For vector and matrix operations, SIMULA is faster with array bound
check, ALGOL is faster without array bound check.
.index ^^array bound checking, efficiency of
.index ^^input-output, efficiency of
.index ^^output, efficiency of
.index ^^formatted i/o, efficiency of
.skip 1
What is said above applies to ALGOL version 3B and SIMULA version 3.
.skip 1
If you want to make your own comparisons of the efficiency of
ALGOL versus SIMULA, you are advised to compile the SIMULA programs
with the option settings options(/-q/-a/-i/-d). This will remove
some debugging features from SIMULA which ALGOL version 3B does not
have, and thus give a more just comparison.
.skip 1
.test page 10
.indent -5
.index ^^compatibility with SIMULA on other computers
P.2##WHY SIMULA IS NOT COMPATIBLE WITH DEC 10 ALGOL?
.skip 1
.index ^^compatibility with SIMULA on other computers
.index ^^compatibility with DECsystem-10 ALGOL
.index ^^input-output, efficiency of
.index ^^output, efficiency of
.index ^^formatted i/o, efficiency of
The DECsystem-10 SIMULA system is made highly compatible with SIMULA
on other computers, in order to make it easy to transfer SIMULA programs
between computers of different manufacture.
Unfortunately, this compatibility with other SIMULA systems had to
mean less good compatibility with DECsystem-10 ALGOL.
.skip 1
The main areas of bad compatibility between ALGOL and SIMULA
on the DECsystem-10
are input-output and text string
handling.
.index ^^input-output, efficiency of
.index ^^output, efficiency of
.index ^^formatted i/o, efficiency of
.skip 1
This appendix does not give a complete description of all that has
to be changed to translate a program from ALGOL to SIMULA but some
of the major points of difficulty are illustrated with examples.
.test page 8
.skip 1
.indent -5
.index ^^TEXT string handling in ALGOL versus SIMULA
.index ^^string handling in ALGOL versus SIMULA
P.3##TEXT STRING HANDLING
.skip 1
.index ^^STRING concept of ALGOL 60
Change STRING to TEXT when declaring text string variables.
.skip 1
.index ^^TEXT constant used in assignments
In SIMULA, a TEXT variable may not refer to a constant.
Change T:= "TEXT CONSTANT" to T:- COPY("TEXT CONSTANT").
.skip 1
Redeclare all INTEGER variables, which you use to store single
characters, as CHARACTER variables. In the following, the
letter C indicates such a variable.
.skip 1
Change C:= T.[N] into C:= FETCHAR(T,N). Often repeated such ALGOL
statements can be replaced by a single T.SUB operation in SIMULA.
(FETCHAR must be declared as an EXTERNAL CHARACTER PROCEDURE.)
.skip 1
.index ^^LINK as used in DECsystem-10 ALGOL
Instead of the procedure LINK, use the concatenation procedure CONC.
(CONC must be declared as an EXTERNAL TEXT PROCEDURE.)
.skip 1
Replace LENGTH(T) by T.LENGTH. Often, the SIMULA procedure MORE can
be used instead of the ALGOL procedure LENGTH as in the following example:
.break
Change
.break
FOR I:= 1 UNTIL LENGTH(T) DO IF T.[I] = " ".[1] THEN ...
.break
into
.break
WHILE T.MORE DO IF T.GETCHAR = ' ' THEN ...
.skip 1
.index ^^COPY TEXT procedure
Replace COPY(T,M) by COPY(T.SUB(1,M)), or by only T.SUB(1,M), if you are
not going to independently modify the two texts.
.skip 1
.index ^^NEWSTRING (DECsystem-10 ALGOL)
Replace NEWSTRING(N,7) by BLANKS(N). Only 7-bit byte strings
can be handled using the TEXT concept of SIMULA.
.skip 1
.index ^^DELETE (DECsystem-10 ALGOL)
Remove DELETE procedure calls from your program. SIMULA has a garbage
collector, so you need not bother with deallocation
of core. However, at a few special occasions, it might be worthwile to
replace DELETE(T) by T:-NOTEXT.
.skip 1
.test page 10
.indent -5
.index ^^INPUT/OUTPUT in ALGOL versus SIMULA
.index ^^OUTPUT in ALGOL versus SIMULA
.index ^^DATA TRANSMISSION in ALGOL versus SIMULA
P.4##INPUT/OUTPUT
.skip 1
.index ^^INSYMBOL (DECsystem-10 ALGOL)
Replace INSYMBOL(C) by C:= INCHAR.
(Sometimes, the procedure GETCH is preferable. GETCH
must be declared as an EXTERNAL CHARACTER PROCEDURE.)
.skip 1
.index ^^NEXTSYMBOL (DECsystem-10 ALGOL)
Replace NEXTSYMBOL(C) by
.break
C:= IF MORE THEN IMAGE.SUB(POS,1).GETCHAR ELSE CHAR(13);
.skip 1
.index ^^OUTSYMBOL (DECsystem-10 ALGOL)
Replace OUTSYMBOL(C) by OUTCHAR(C).
(Sometimes, OUTSYMBOL is better replaced by OUTCHR(SYSOUT,C,1).
OUTCHR must be declared as an EXTERNAL PROCEDURE.)
.skip 1
.index ^^BREAKOUTPUT (DECsystem-10 ALGOL)
Replace BREAKOUTPUT by BREAKOUTIMAGE.
.skip 1
.index ^^WRITE (DECsystem-10 ALGOL)
Replace WRITE(T) where T is a string variable or constant,
by OUTTEXT(T).
.skip 1
.index ^^[ (DECsystem-10 ALGOL)
IMPORTANT: You cannot use the special line editing characters
inside output strings in SIMULA. Replace them by calls to
the corresponding explicit procedures. For example, convert
.break
WRITE("FIRST LINE[N]SECOND LINE");
.break
into
.break
OUTTEXT("FIRST LINE"); OUTIMAGE; OUTTEXT("SECOND LINE");
.skip 1
.index ^^PAGE (DECsystem-10 ALGOL)
Replace PAGE by EJECT(1) and NEWLINE by OUTIMAGE.
.skip 1
.index ^^SPACE (DECsystem-10 ALGOL)
.index ^^TAB (DECsystem-10 ALGOL)
Replace SPACE(N) by SETPOS(POS+N) and TAB by OUTCHAR(CHAR(9)).
.skip 1
.index ^^READ (DECsystem-10 ALGOL)
.index ^^PRINT (DECsystem-10 ALGOL)
Instead of READ and PRINT you must choose the appropriate SIMULA
procedure depending on the type of the argument. For example,
if R is a real value, PRINT(R,10,5) is converted into
OUTFIX(R,5,17) and PRINT(R,0,5) is converted into
OUTREAL(R,6,12).
.skip 1
.index ^^power-of-ten symbol
.index ^^10, power of, symbol
.index ^^ten, power of, symbol
Note that SIMULA normally expects that the letter E is used in
input data for the power-of-ten symbol. This can however be
changed to other characters with the SIMULA built-in procedure
LOWTEN.
.skip 1
.index ^^BACKSPACE (DECsystem-10 ALGOL)
.index ^^ENDFILE (DECsystem-10 ALGOL)
.index ^^REWIND (DECsystem-10 ALGOL)
BACKSPACE, ENDFILE and REWIND are not currently available in
DECsystem-10 SIMULA (version 3).
.skip 1
.index ^^READOCTAL (DECsystem-10 ALGOL)
.index ^^IOCHAN (DECsystem-10 ALGOL)
READOCTAL must be programmed in SIMULA, IOCHAN must be programmed
in MACRO 10, except when you use IOCHAN to test for end-of-file.
In the latter case, use the SIMULA built-in procedure ENDFILE.
.skip 1
.index ^^TTY input and output
.index ^^terminal input and output
.index ^^conversational input and output
For ordinary input and output to the TTY, you can
in SIMULA directly use ININT, INREAL, OUTINT etc. If you want
to use other devices, the following information may be helpful:
.skip 1
Instead of
.skip 1
.index ^^OUTPUT (DECsystem-10 ALGOL)
.index ^^OPENFILE (DECsystem-10 ALGOL)
.index ^^INPUT (DECsystem-10 ALGOL)
.test page 2
OUTPUT(5,"DSK");
.break
OPENFILE(5,"TEST.DAT",%177,%000011000050);
.skip 1
write for example
.skip 1
.test page 3
REF (OUTFILE) CHANNEL5;
.break
CHANNEL5:- NEW OUTFILE("DSK: TEST.DAT[11,50] <177>");
.break
CHANNEL5.OPEN(BLANKS(130));
.skip 1
.test page 3
.index ^^CLOSEFILE (DECsystem-10 ALGOL)
Instead of CLOSEFILE(5) write for example CHANNEL5.CLOSE.
.skip 1
.index ^^RELEASE (DECsystem-10 ALGOL)
Remove calls to the procedure RELEASE, since this function
is automatically performed by the garbage collector in SIMULA.
In some cases, you might have to replace RELEASE(5) by
CHANNEL5:- NONE.
.skip 1
.index ^^SELECTINPUT (DECsystem-10 ALGOL)
Instead of SELECTINPUT(5) you can for example
write
.break
INSPECT CHANNEL5 DO
.break
BEGIN ... END;
.skip 1
The effect of SELECTINPUT might be simulated by:
.nofill
	REF (Outfile) ARRAY outchannels[1:10];
	REF (Outfile) outchannel;
	PROCEDURE selectinput(i); INTEGER i;
	outchannel:-outchannels[i];
	...
	outchannel.Outtext(...)
	etc...
.fill
.skip 1
.test page 10
.indent -5
P.5##MISCELLANEOUS
.skip 1
.index ^^fat comma comment convention of ALGOL 60
The so called "fat comma" method of inserting comments into procedure
statements is not allowed in SIMULA. Use ordinary comments instead.
Example:
.break
SPUR (A)  ORDER:(7)  RESULT TO:(V)
.break
can be changed to:
.break
SPUR (A, !ORDER; 7, !RESULT TO; V);
.skip 1
If you use "." as a readability symbol in identifiers, change it
to "__". Example: TOP.OF.STACK in ALGOL is changed to TOP__OF__STACK
in SIMULA.
.skip 1
.index ^^_# (DECsystem-10 ALGOL)
Not equal is "_#" in ALGOL, "NE" in SIMULA.
.skip 1
Octal constants in SIMULA begin with "8R", not with "%".
.skip 1
.index ^^__ (DECsystem-10 ALGOL)
"__" may not be used in SIMULA as an alternative to ":=".
.skip 1
.index ^^DIV operator (DECsystem-10 ALGOL)
"DIV" in ALGOL is "//" in SIMULA.
.skip 1
.index ^^REM operator (DECsystem-10 ALGOL)
The operator "REM" in ALGOL should be changed
to use the built-in INTEGER PROCEDURE  "MOD" in SIMULA.
.skip 1
.index ^^BOOL (DECsystem-10 ALGOL)
.index ^^INT (DECsystem-10 ALGOL)
.index ^^IMIN (DECsystem-10 ALGOL)
.index ^^IMAX (DECsystem-10 ALGOL)
.index ^^RMIN (DECsystem-10 ALGOL)
.index ^^RMAX (DECsystem-10 ALGOL)
SIMULA does not have the ALGOL built-in procedures BOOL, INT,
IMIN, IMAX, RMIN, RMAX.
.skip 1
The LONG REAL and REAL standard procedures (SIN etc.) have the same name in
SIMULA. The type of the procedure depends on the type of the
argument. Some of them are however always REAL.
.skip 1
.index ^^CHECKON (DECsystem-10 ALGOL)
.index ^^CHECKOFF (DECsystem-10 ALGOL)
.test page 5
"CHECKON 1" in ALGOL is "OPTIONS(/ARRAY)" in SIMULA,
.break
"CHECKOFF 1" in ALGOL is "OPTIONS(/-ARRAY)" in SIMULA.
.break
Unlike ALGOL, checking of array bounds is default in SIMULA,
and must be explicitly set off if you do not want it.
.skip 1
.index ^^FORWARD declarations (DECsystem-10 ALGOL)
.index ^^FORWARD declarations
FORWARD declarations in ALGOL can be removed in SIMULA.
.skip 1
.index ^^LISTON (DECsystem-10 ALGOL)
.index ^^LISTOFF (DECsystem-10 ALGOL)
"LISTON" in ALGOL is "OPTIONS(/LIST)" in SIMULA.
.break
"LISTOFF" in ALGOL is "OPTIONS(/-LIST)" in SIMULA.
.skip 1
.index ^^OWN (DECsystem-10 ALGOL)
.index ^^OWN declaration
SIMULA does not have the OWN concept of ALGOL. You can get something
similar (but much more powerful) by using a SIMULA class.
.skip 1
Only the twelve first characters of an identifier are significant
in SIMULA.
.skip 1
.index ^^power-of-ten symbol
.index ^^10, power of, symbol
.index ^^ten, power of, symbol
The "@" symbol cannot be used for powers-of-ten in SIMULA source programs.
Use "_&" instead.
The power-of-ten symbol for input data can be set dynamically with
the SIMULA built-in procedure LOWTEN. Default is "E".
.skip 1
.index ^^[ (DECsystem-10 ALGOL)
Do not double the characters [, ] and ; in SIMULA TEXT constants.
However, " is doubled just as in ALGOL.
.skip 1
Assignments inside expressions are not allowed in SIMULA.
Change e.g.#A:= B + (C:= D + E); into C:= D + E; A:= B + C;
.skip 1
You cannot in SIMULA omit the STEP in FOR-statements. Change
FOR V:= E1 UNTIL E3 DO S into FOR V:= E1 STEP 1 UNTIL E3 DO S.
.skip 1
Simple variables (not TEXTs or ARRAYs) are in SIMULA
.index ^^VALUE parameter transmission, ALGOL versus SIMULA
.index ^^NAME parameter transmission, ALGOL versus SIMULA
.index ^^parameter transmision, ALGOL versus SIMULA
.index ^^PROCEDURE parameters, ALGOL versus SIMULA
by default transferred by VALUE in procedure calls,
not by NAME. If you need NAME transmission, this must
be explicitly declared, e.g.
.break
PROCEDURE P(X); NAME X; REAL X;
.skip 1
If an actual TEXT parameter is a constant,
the corresponding formal parameter must in SIMULA always be
declared as either VALUE or NAME in the
procedure heading.
.skip 1
The procedures DIM, LB, UB, GFIELD, SFIELD are not available
in SIMULA but can easily be written as external MACRO 10 procedures to
SIMULA.
.skip 1
.index ^^FORTRAN calls, ALGOL versus SIMULA
The method of calling external FORTRAN procedures is slightly different
in SIMULA. For example instead of CALL(FORT,X,Y) you write in SIMULA:
.skip 1
.nofill
OPTIONS(/E:F40,FORT);#################-_\  In a file called
PROCEDURE FORT(A,B); REAL A, B;;######-/  FORT.SIM
 ...
EXTERNAL PROCEDURE FORT;
 ...
FORT(X,Y);
.fill
.skip 1
Input-output is not allowed in FORTRAN when called from SIMULA.
.skip 1
Further information about calling FORTRAN is given in appendix E.
.subtitle INDEX
.page
.index ^^index
.skip 2
INDEX
.break
=====
.skip 2
.print index