Added and corrected some comments

This commit is contained in:
ceriel 1987-07-13 13:34:56 +00:00
parent 6a8547cca0
commit b93dc94cdb
2 changed files with 14 additions and 8 deletions

View file

@ -15,9 +15,9 @@ Conversion.mod
Semaphores.mod
random.mod
Strings.mod
Traps.mod
Arguments.c
catch.c
Traps.mod
LtoUset.e
StrAss.c
absd.c

View file

@ -52,13 +52,19 @@ DEFINITION MODULE PascalIO;
(* Advances the "read pointer" by one character *)
PROCEDURE Eoln(InputText: Text): BOOLEAN;
(* Returns TRUE if the next character of the InputText is a linefeed *)
(* Returns TRUE if the next character of the InputText is a linefeed.
Unlike Pascal however, it does not produce a runtime error when
called when Eof(InputText) is TRUE.
*)
PROCEDURE Eof(InputText: Text): BOOLEAN;
(* Returns TRUE if the end of the InputText is reached *)
PROCEDURE ReadChar(InputText: Text; VAR Char: CHAR);
(* Read a character from the InputText, and leave result in "Char" *)
(* Read a character from the InputText, and leave result in "Char".
Unlike Pascal, if Eoln(InputText) is true, the newline character
is put in "Char".
*)
PROCEDURE ReadLn(InputText: Text);
(* Skip the rest of the current line of the InputText,
@ -74,9 +80,9 @@ DEFINITION MODULE PascalIO;
PROCEDURE ReadCardinal(InputText: Text; VAR Cardinal: CARDINAL);
(* Skip leading blanks, read a cardinal from the InputText, and leave the
result in "card".
result in "Cardinal".
If no cardinal is read, or when overflow occurs, a runtime error results.
Input stops at the character following the integer.
Input stops at the character following the cardinal.
*)
PROCEDURE ReadReal(InputText: Text; VAR Real: REAL);
@ -87,7 +93,7 @@ DEFINITION MODULE PascalIO;
[ E [(+|-)] digit {digit} ]
If no real is read, or when overflow/underflow occurs, a runtime error
results.
Input stops at the character following the integer.
Input stops at the character following the real.
*)
(***************************************************************************
@ -118,8 +124,8 @@ DEFINITION MODULE PascalIO;
PROCEDURE WriteBoolean(OutputText: Text; Boolean: BOOLEAN; Width: CARDINAL);
(* Write boolean "Boolean" to the OutputText, using at least "Width" places,
blank-padding to the left if needed.
Equivalent to WriteString(" TRUE", Width), or
WriteString("FALSE", Width)
Equivalent to WriteString(OutputText, " TRUE", Width), or
WriteString(OutputText, "FALSE", Width)
*)
PROCEDURE WriteString(OutputText: Text;