mirror of
https://github.com/vishapoberon/compiler.git
synced 2026-04-06 14:32:24 +00:00
separated Kernel, Files. Texts modules for bootstrapping and general use
This commit is contained in:
parent
e0a915b319
commit
e1f76da278
41 changed files with 3226 additions and 323 deletions
|
|
@ -2,7 +2,7 @@ MODULE BrowserCmd; (* RC 29.10.93 *) (* object model 4.12.93, command line ver
|
|||
|
||||
IMPORT
|
||||
OPM, OPS, OPT, OPV,
|
||||
Texts := CmdlnTexts, Console, Args;
|
||||
Texts := Texts0, Console, Args;
|
||||
|
||||
CONST
|
||||
OptionChar = "-";
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@ MODULE OCatCmd; (* J. Templ, 13-Jan-96 *)
|
|||
|
||||
(* looks at the OBERON search path and writes one or more Oberon or ascii texts to standard out *)
|
||||
|
||||
IMPORT Args, Console, Files, Texts := CmdlnTexts;
|
||||
IMPORT Args, Console, Files := Files0, Texts := Texts0;
|
||||
|
||||
PROCEDURE Cat*;
|
||||
VAR path: ARRAY 128 OF CHAR; i: INTEGER; T: Texts.Text; R: Texts.Reader; ch: CHAR; tab: BOOLEAN;
|
||||
|
|
|
|||
50
src/tools/vmake/compatIn.Mod
Normal file
50
src/tools/vmake/compatIn.Mod
Normal file
|
|
@ -0,0 +1,50 @@
|
|||
MODULE compatIn;
|
||||
(* module created to compile Make utility from Trianus v4 system with less changes in original file ; -- noch *)
|
||||
IMPORT Args, IntStr := oocIntStr;
|
||||
|
||||
VAR Done* : BOOLEAN;
|
||||
argnum : INTEGER;
|
||||
|
||||
PROCEDURE Open*;
|
||||
BEGIN
|
||||
argnum := 0;
|
||||
Done := FALSE;
|
||||
END Open;
|
||||
|
||||
PROCEDURE Name*(VAR name : ARRAY OF CHAR);
|
||||
BEGIN
|
||||
INC(argnum);
|
||||
|
||||
IF argnum < Args.argc THEN
|
||||
Args.Get(argnum, name);
|
||||
Done := TRUE
|
||||
ELSE
|
||||
Done := FALSE
|
||||
END
|
||||
END Name;
|
||||
|
||||
PROCEDURE Int*(VAR i : INTEGER);
|
||||
VAR l : LONGINT;
|
||||
r : IntStr.ConvResults;
|
||||
name : ARRAY 32 OF CHAR;
|
||||
BEGIN
|
||||
INC(argnum);
|
||||
|
||||
IF argnum < Args.argc THEN
|
||||
Args.Get(argnum, name);
|
||||
IntStr.StrToInt(name, l, r);
|
||||
IF r = IntStr.strAllRight THEN
|
||||
i := SHORT(l);
|
||||
Done := TRUE
|
||||
ELSE
|
||||
Done := FALSE
|
||||
END
|
||||
ELSE
|
||||
Done := FALSE;
|
||||
END
|
||||
END Int;
|
||||
|
||||
|
||||
BEGIN
|
||||
Open();
|
||||
END compatIn.
|
||||
|
|
@ -5,7 +5,7 @@ VOC = /opt/voc/bin/voc
|
|||
|
||||
|
||||
all:
|
||||
$(VOC) -M vmake.Mod
|
||||
$(VOC) -s compatIn.Mod vmake.Mod -M
|
||||
|
||||
clean:
|
||||
rm *.o
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue