|
DataMuseum.dkPresents historical artifacts from the history of: RC4000/8000/9000 |
This is an automatic "excavation" of a thematic subset of
See our Wiki for more about RC4000/8000/9000 Excavated with: AutoArchaeologist - Free & Open Source Software. |
top - metrics - download
Length: 32256 (0x7e00) Types: TextFile Names: »ntedit1«
└─⟦621cfb9a2⟧ Bits:30002817 RC8000 Dump tape fra HCØ. Detaljer om "HC8000" projekt. └─⟦0364f57e3⟧ └─⟦584a817f6⟧ »cgndit« └─⟦this⟧
\f ; rc 17.6.69 editor i, tape 1, page 1. ; pk. ; corrected 9.1.70 / bøt, pk ;corrected 1.11.70 / bøt ; the editor is kept on four tapes. ; translation: ; the editor is a fp-utility program and shall be translated together ; with the h-names of the file processer. ; during translation some parameters to the editor can be redefined. ; see tape 1, page 3. ; allocation: ; with buffers the editor occupay a minimum of 10000 bytes inclusive ; the fileprocesser: ; editor program: 4100 ; correction line: 128 ; source string: 128 + remainder/2 ; object string: remainder/2 ; correction string: 512 ; source buffers: 1024 ; object buffer : 512 ; communications with peripheral devices: ; the file processor is used for external communications. ; commands to the editor is input from current input. ; messages from the editor is output on current output. ; source documents and object document are input and output in dobbelt ; buffer mode with buffers and zone descriptors local to the editor. ; the commands may intermidiate be stored in a working area on the ba- ; cking storage: this transport is performed in single buffer mode ; with buffer and zone descriptor local to the editor. ; program structure: ; the editor program consist of a preprocessor, of an executer, and ; of an initializing part. ; ; during initializing connection is made to the object document. if ; the object document is specified by an empty note a work area is ; created on the backing storage. ; a work area is also created for the saving of commands. ; ; both the commands and the text from the source document are input ; line by line and transfered to an internal representation with one ; byte per character. ; the preprocessor analyse the commands and produce a string of in- ; structions and text to the executer. correction line is used for ; input of commands, and the produced string is stored in the cor- ; rection string. if there is no room for the total commands the ; correction string is stored on the backing storage. \f ; rc 25.3.72 editor i, tape 1, page 2. ; the source text and the object text are kept on internal reprsenta- ; tion in the source string and the object string respectively. the ; text can be moved both forward and backward between the two strings ; thus obtaining a quick way of backspacing a few lines. backspacing ; above the line kept in the object string is obtained by copying the ; remainder of the source document to the object document and then ; upspacing the object document, which now is taken as source, to the ; wanted place. ; a work area on the backing storage used as object document may be ; extended: the already produced object area is copyed into an exten- ; ded area, and the old area is removed. s. g4 ; begin segment, labels for insertproc d. p.<:fpnames:>; fpnames l. b. c43 , d17 ; begin block with global program entries: w. ; c0 first word of editor: ; c1 proc. input line ; c2 entr. composing input line ; c5 - byte to obj ; c7 - save correction ; c8 - create obj file ; c9 - init source ; c10 - close obj ; c11 - output line ; c12 - search comp ; c13 - read name ; c14 - read integer ; c15 - input corr line ; c16 - print value ; c17 - print text ; c18 - error terminate editor ; c19 entr. after corr ; c20 - start preprocessor ; c21 - start executor ; c22 - terminate editor ; c23 proc. alarm (position not found) ; c24 - alarm (backspace error) ; c25 - alarm (syntax) ; c26 - alarm (line to big) ; c27 - alarm (obj to big) ; c28 entr. execute verification ; c29 proc. alarm (editor error) ; c30 entr. initializing the editor, first word of buffer areas ; c31 tabl. global variable ; c32 entr. addr init editor ; c33 - addr start preprocessor ; c34 proc. alarm (empty source) ; c35 - . source param(integer) ; c36 - . alarm(character) ; c37 - . alarm(work area) ; c38 - . alarm(corr. area) ; c39 - . alarm(parity error) ; c40 - . outblanks ; c41 - . print searched string ; c42 entr. addr init editor ( addr of c32. ) ; c43 proc. print text but in contary to c17 their is no outend. c0: d13 ; first word of editor: editor length jl. 2 ; dummy instruction al. w0 c0. ; w0:= first word address; jl. c42. ; goto addr init editor; \f ; rc 1.11.70 editor i, tape 1, page 3. b. g58,f110,b42 ; begin block with system definitions ; global definitions, global variable, ; and instructions: w. ; system definitions: d1 = 36 ; standard num mark = $ d2 = 37 ; standard line mark = % d3 = 38 ; standard char mark = & d4 = 128 ; max line length in bytes d5 = 100 ; max line back up d6 = 1 ; no of source line one d7 = 8 ; initial obj work area no of blocks d8 = 8 ; increment obj work area d9 = 8 ; corr no of blocks on drum d10 = 500 ; min no of bytes for object and source string d11 = 512 ; object buffer no of bytes d12 = 512 ; source buffer no of bytes d14 = 512 ; drum track size d16 = 38 ; parity verification char; d15 = 1 ; mark is standard (1=true, -1=false) d17 = 150 ; no of blanks on punch ; d13 = editor length m.redefine editor parameter. i. t. ; global definitions: ; bit definitions g20 = -1<11 ; <special> g21 = 1<10 ; <comp> g22 = 1<9 ; <non gr> g23 = 1<8 ; <blind> g24 = 1<7 ; <skipped> ; byte definitions: ; g1 see byte table ; <nl> ; g2 - - - ; <cr> ; g3 - - - ; <bs> ; g4 - - - ; <sp> ; g5 - - - ; <underline> ; g6 - - - ; <bar> ; g7 - - - ; <em> g8 = g23+10 ; <nl 1> g9 = g20+1 ; <no line> g10 = g20+2 ; <top of line> g11 = g20+3 ; <first corr> g12 = g20+4 ; <obj bot> g13 = g20+5 ; <empty source> g14 = g20+6 ; <first source> \f ; rc 17.6.69 editor i, tape 1, page 4. ; source descriptor, (double buffer): ; part 0, buffer and share description: w. 0 ; h0: base buffer area 0 ; +2: last of buffer 0 ; +4: used share 0 ; +6: first share 0 ; +8: last share ; part 1, process description: h. 0 , 0 ; h1: 1<11+mode, kind w. 0,0,0,0 ; +2: document name 0 ;+10: name address 0 ;+12: file count 0 ;+14: block count 0 ;+16: segment count ; part 2, status handling: 0 ; h2: give up mask (=0) 0 ; +2: give up action (=0) 0 ; +4: partial word 0 ; +6: free f10=k ; part 3, record description: 0 ; h3: record base 0 ; +2: last byte 0 ; +4: record length ; +6: free (omitted) ; part 4, users parameterts: (omitted). f11=k ; share descriptor 1: 0 ; +0: state 0 ; +2: first shared 0 ; +4: last shared 0,0,0,0,0,0,0,0 ; +6: latest message 0 ;+22: block length f12=k ; share descriptor 2: 0 ; +0: state 0 ; +2: first shared 0 ; +4: last shared 0,0,0,0,0,0,0,0 ; +6: latest message 0 ;+22: block length \f ; rc 1.11.70 editor i, tape 1, page 5. ; object descriptor, ( single buffer): ; part 0: w. 0,0,0,0,0 ; h0: +2: +4: +6: +8: ; part 1: 0,0,0,0,0,0,0,0,0 ; h1: +2: +10: +12: +14: +16: ; part 2: 0,0,0,0 ; h2: +2: +4: +6: f80=k ; part 3: 0,0,0 ; h3: +2: +4: f81=k ; share descriptor: 0,0,0 ; +0: +2: +4: 0,0,0,0,0,0,0,0 ; +6: 0 ;+22: ; correction descriptor, (single buffer): ; part 0: 0,0,0,0,0 ; h0: +2: +4: +6: +8: ; part 1: 0,0,0,0,0,0,0,0,0 ; h1: +2: +10: +12: +14: +16: ; part 2: 0,0,0,0 ; h2: +2: +4: +6: f2=k ; part 3: 0,0,0 ; h3: +2: +4: f7=k ; share descriptor: 0,0,0 ; +0: +2: +4: 0,0,0,0,0,0,0,0 ; +6: 0 ;+22: \f ; rc 17.6.69 editor i, tape 1, page 6. ; preprocessor: ; comment: the preprocessor inputs a sequence of ; control command, analyse the sequence for syntax ; error, and output a corresponding sequence of ; instructions and text to the executor. ; the analyses is performed by means of a command ; table and a processing table. the first letter of the ; commands leads via the command table to an ; entry in the processing table. guided by the content of the ; processing table the preprocessing is executed. ; when a sequence of commands is terminated ; control is transferred to the executor; b. a36 ; begin block with preprocess entries: b. e47, j43 ; begin block with definitions and table entries: h. f4: ; command table: ; comment: from the command table references are made ; to the entries in the process table corresponding to the ; first letter of the command; ; a , b , c , d , e , f , g , h ;append , back , correct, delete , - , finis , global , - e16 , e14 , e7 , e3 , e0 , e11 , e6 , e0 ; i , j , k , l , m , n , o , p ; insert , jump , - , line , mark , next , - , print e4 , e18 , e0 , e1 , e8 , e15 , e0 , e2 ; q , r , s , t , u , v , w , x ; - ,replace , source , - , - , verify , where , xit e0 , e5 , e12 , e0 , e0 , e9 , e10 , e17 ; y , z , æ , ø , å ; - , - , - , - , - e0 , e0 , e0 , e0 , e0 \f ; rc 17.6.69 editor i, tape 1, page 7. ; process table: ; comment: the table contains references to the pre- ; processes to be executed and instructions to be out- ; put to the executor. ; as comments are also shown the command- ; instruction transformation; h. ; line <position> ; ; top : to top ; bottom : set bot, copy ; backward : rel, <integer>, back up ; forward : rel, <integer>, copy, uphead ; substring : search, copy, <string 1>, head ; pos , - , - , - , - , - j21: e21 , j5. , j6. , j7. , j8. , j9. ; print <position> ; ; top : store line, to top, reset line, print, uphead ; bottom : set bot, print, uphead ; backward : store line, rel, <integer>, back up, reset line, ; print, uphead ; forward : rel, <integer>, print, uphead ; substring : search, print, <string 1>, the line, print, uphead ; pos , - , - , - , - , - , out 2, <print>, <uphead> j22: e21 , j1. , j2. , j3. , j4. , j11., e26 , b14 , b27 ; term print e22 ; delete <position> ; ; top : store line, to top, reset line, delete line ; bottom : set bot, delete line ; backward : store line, rel, <integer>, back up, reset line, ; delete line ; forward : rel, <integer>, delete line ; substring : search, delete search, <string 1>, the line, ; delete line ; pos , - , - , - , - , - , out 1 , <delete line> , term j23: e21 , j1. , j2. , j3. , j4. , j12., e27 , b15 , e23 \f ; rc 17.6.69 editor i, tape 1, page 8. ; insert <del> <string2> <del> ; ; ab corr, copy, <string2>, uphead ; out 2, <ab corr>, <copy>, delim, test nl,insmark , out string2 j24: e26 , b12 , b13 , e30 , e40 , e46 , e32 ; out 1, <uphead>, term e27 , b27 , e23 ; replace <del> <string 1> <del> <string 2> <del> ; ; search, repl, <string 1>, delete fix, ab corr, ; copy, <string 2> , head ; out 2, <search>, <repl>, delim, outstring 1, out 3 j25: e26, b11 , b18 , e30 , e31 , e25 ; <delete fix> , <ab corr>, <copy>, out string 2, out 1 b24 , b12 , b13 , e32 , e27 ; <head> , term b37 , e23 ; global <position> <del> <string 1> <del> <string 3> <del> ; ; top : store line, to top, reset line ; gen return, <last instr addr>, search, gen, <string 3> ; delete fix, ab corr, copy, <string 1>, repeat gen ; up head ; bottom : set bot, - - - ; backward : store line, rel, <integer>, back up, reset line, - - - ; forward : rel, <integer>, - - - ; pos , - , - , - , - , - , prep last, out 2, <gen return> j26: e21 , j1. , j2. , j3. , j4. , j19., e33 , e26 , b23 ; 0 , out 2, <search>, <gen>, delim, outstring 3, out 3 0 , e26 , b11 , b19 , e30 , e41 , e25 ; <delete fix> , <ab corr>, <copy>, outstring 1, out 1 b24 , b12 , b13 , e31 , e27 ; <repeat gen>, set last, out 1, <uphead>, term b22 , e34 , e27 , b27 , e23 \f ; rc 17.6.69 editor i, tape 1, page 9. ; correct <nl> <string not containing nl> <nl> ; ; the line, ad core print, ; out 3 , <the line>, <ad corr print>, <corr input>, to nl j27: e25 , b10 , b17 , b25 , e38 ; mark <mark kind> <char> ; ; standard: num, <stnum>, char, <stchar>, line, <st line> ; empty : num, -1 , char, -1 , line, -1 ; num : num, <char> , ; char :char, <char> ; line :line, <char> ; mark kind, - , - , - , - , - j28: e35 , j13., j14., j15., j16., j17. ; verify <yes or no> ; ; yes : verify yes ; no : verify no ; read yes or no, <verify yes>, <verify no>, term j29: e37 , b32 , b33 , e23 ; where ; ; line no printing ; out 1, <line no printing>, term j30: e27 , b34 , e23 ; finis ; ; set bot, copy, finish ed ; out 2, <set bot>, <copy>, out 1, <finish ed>, term j31: e26 , b9 , b13 , e27 , b36 , e23 ; xit ( exit) ; ; xit editor. ; out 1, <xit ed >, term j41: e26 , b42 , e23 ; source <integer> ; ; source, <integer byte> ; out 1, <source>, out integer byte, term j32: e27 , b39 , e42 , e23 ; back <position> ; ; top ; to top; ; bottom ; illegal ; backward ; illegal ; forward ; backward ; subtring ; to top , search ; pos , , , , , , , j33: e21 , j5., j0., j7., j37., j38. ; next <position> ; top ; illegal ; bottom ; set bot, copy ; bacward ; illegal ; forward ; rel, <integer at least 1>,copy , uphead ; substring ; next line,search,copy, <string 1>,head ; pos , , , , , , , j34: e21 , j0. , j6. , j0. , j36., j39. ; jump <absolut position> ; top ; to top ; bottom ; to bottom ; backward ; illegal ; forward ; abs ; substring ; next line,search,copy,<string1> uphead ; pos , , , , , , , j42: e21 , j5., j6. , j0. , j43., j39. ; append <del> <string2> <del> ; ; next line , ab corr, copy, <string2>, head ; out 2 , <nline> , <copy> j35: e26 , b10 , b13 ; out 2, <ab corr>, <copy> , delim , test nl , insmark , out string 2 e26 , b12 , b13 , e30 , e40 , e46 , e32 ; out 1, <uphead>, term e27 , b27 , e23 \f ; rc 17.6.69 editor i, tape 1, page 10. ; syntax j0: e20 ; out 3, <store line>, <to top>, <reset line>, return j1: e25 , b20 , b26 , b21 , e29 ; out 1, <set bot>, return j2: e27 , b9 , e29 ; out1, <store line>, out rel, out 2, <back up>, <reset line> j3: e27, b20 , e28 , e26 , b28 , b21 ; return j19: e29 ; out rel, return j4: e28 , e29 ; out 1, <to top>, term j5: e27 , b26 , e23 ; out 2, <set bot>, <copy>, term j6: e26 , b9 , b13 , e23 ; out rel, out 1, <back up>, term j7: e28 , e27 , b28 , e23 ; out rel, out 2, <copy>, <uphead>, term j8: e28 , e26 , b13 , b27 , e23 ; out 1, <to top> j38: e27 , b26 ; out 2, <search> , <copy>, delim, outsting 1 e26 , b11 , b13 , e30 , e31 ; out 1, <head> , term e27 , b37 , e23 ; out 2, <line> , <copy> j39: e26 , b10 , b13 ; out 2, <search>, <copy>, delim, outstring 1 j9: e26 , b11 , b13 , e30 , e31 ; out 1, <head>, term e27 , b37 , e23 ; out 2, <search>, <print>, delim, outstring 1, out 1 j11: e26 , b11 , b14 , e30, e31 , e27 ; <the line>, return b10 , e29 ; out 2, <search>, <delete search> , delim, outstring 1 j12: e26 , b11 , b16 , e30 , e31 ; out 1, <the line>, return e27 , b10 , e29 \f ; rc 17.6.69 editor i, tape 1, page 11. ; out 6, <num>, <st num>, <char>, <st char>, <line>, st line>, term j13: e24 , b29 , d1 , b31 , d3 , b30 , d2 , e23 ; out 6, <num>, -1 , <char>, -1 , <line>, -1 , term j14: e24 , b29 , -1 , b31 , -1 , b30 , -1 , e23 ; out 1, <num>, read char, term j15: e27 , b29 , e36 , e23 ; out 1, <char>, read char, term j16: e27 , b31 , e36 , e23 ; out 1, <line>, read char, term j17: e27 , b30 , e36 , e23 ; out 3, <first corr>, <ab corr>, <copy>, out string 2, out 3 j18: e25, g11 , b12 , b13 , e32 , e25 ; <nl 1>, <uphead>, <executed>, to excutor g8 , b27 , b6 , e39 ; out rel 1, out 2 , <copy> , <uphead >, term j36: e43, e26 , b13 , b27 , e23 ; out rel -1 , out 1 , <back up>, term j37: e44 , e27 , b28 , e23 ; out abs , term j43: e47 , e23 ; used by jump absolute \f ; rc 17.6.69 editor i, tape 1, page 12. w. c20: ; start preprocessor: ; comment: the editor is initialized to start input ; of a new sequence of commands. ; the general use of w-registers in the preprocessor ; are as follows: ; w0: aviable ; w1: cur in : pointing at the input bytes ; w2: cur corr : pointing at the output bytes ; w3: cur pr : pointing at bytes in the process ; table dl. w1 f31. ; descriptor:= corr descriptor; ds. w1 f33. ; line address:= curr in:= corr line address; al w0 g9 ; byte (cur in):= <no line>; hs w0 x1 ; rl. w2 f49. ; cur corr:= corr top; al w0 g11 ; byte (cur corr):= <first corr> hs w0 x2 ; al w2 x2+1 ; cur corr:= cur corr + 1; al w0 0 ; rs. w0 f69. ; corr no:= 0; ; goto next command; \f ; rc 17.6.69 editor i, tape 1, page 13. a1: ; next command: ; comment: save point is set to cur corr. ; a name is read and cur pr is found in the ; command table corresponding to the name read ; corr no is increased by one, and the byte <command> ; is output, after which control is transferred to next pr 3; rs. w2 f63. ; save point:= cur corr; jl. w2 c13. ; letter:= read name; rl. w2 f63. ; cur corr:= save point; am (0) ; bl. w3 f4.-65 ; cur pr:= command table (letter); rl. w0 f69. ; ba. w0 1 ; corr no:= corr no + 1; rs. w0 f69. ; al w0 b35 ; byte:= <command> b0: al. w3 x3 ; goto out corr and next pr 3; a2: ; out corr and next pr 3: hs w0 x2 ; byte(cur corr):= byte; al w2 x2+1 ; cur corr:= cur corr + 1; sn. w2 (f50.) ; if cur corr = corr bottom jl. w2 c7. ; then save correction; jl. a5. ; goto next pr 3; a3: ; next pr 1: rl. w2 f67. ; cur corr:= saved cur corr; a4: ; next pr 2: al w3 x3+1 ; cur pr := cur pr + 1; a5: ; next pr 3: bl w0 x3 ; process action:= process table(cur pr); am (0) ; b1: jl. 0 ; goto action (process action); \f ; rc 17.6.69 editor i, tape 1, page 14. a6: ; pos: ; comment: one of five kinds of position is found: ; top, bottom, backward, forward, or substring. ; the return pr is set equal to cur pr plus five, ; and cur pr is changed to point on a process ; table address selected by the kind of the posi- ; tion; b. h4 ; begin w. ; bl w0 x1 ; byte:= byte (cur in); al w3 x3+5 ; cur pr:= rs. w3 f68. ; return pr:= cur pr + 5; se w0 84 ; if byte = <t> sn w0 116 ; ! byte = <t> jl. h1. ; then goto top; se w0 66 ; if byte = <b> sn w0 98 ; ! byte = <b> jl. h2. ; then goto bottom; se w0 46 ; if byte <> <point> jl. h3. ; then goto relative; ; substring: al w1 x1+1 ; cur in:= cur in + 1; jl. h4. ; goto set pr; ; top: h1: am -1 ; cur pr:= cur pr - 1; ; bottom h2: al w3 x3-3 ; cur pr:= cur pr - 3; rs. w2 f67. ; jl. w2 c13. ; read name; rl. w2 f67. ; jl. h4. ; goto set pr; ; relative: h3: ds. w3 f43. ; save (w2, w3) jl. w2 c14. ; read integer; restore (w2, w3); rl. w0 f66. ; sh w0 -1 ; if integer < =-1 am -1 ; then cur pr := cur pr - 1; al w3 x3-1 ; cur pr:= cur pr - 1; ; set pr: h4: ba w3 x3 ; cur pr:= cur pr + byte(cur pr); jl. a5. ; goto next pr 3; ; e. ; end pos; \f ; rc 17.6.69 editor i, tape 1, page 15. ; terminators: ; comment: the termination of the command is examined ; , : cause call of next command ; <nl>: cause output of <executed> or <executed print> ; and call of start executor; b. h2 ; w. ; a7: ; term print: am b38 ; byte:= <executed print>; goto a; a8: ; term: al w0 b6 ; byte:= <executed> hs w0 x2 ; a: byte (cur corr):= byte; ; next in: h1: bl w0 x1 ; byte:= byte(curr in); al w1 x1+1 ; cur in:= cur in + 1; sn w0 g9 ; if byte = <no line> jl. w1 c15. ; then input corr line; ; nextline; sn w0 g4 ; if byte = <sp> jl. h1. ; then goto next in; sn w0 44 ; if byte = <,> jl. a1. ; then goto next command; se w0 g8 ; if byte <> <nl 1> a25: jl. c25. ; then alarm(syntax) a9: ; to executor: jl. c21. ; goto start executor; h2: rl. w3 f109. ; if not syntaks in insert command then sn w3 0 ; then goto jl. c25. ; alarm (syntax) rl. w3 f69. ; save corr no in syntax dectect. rs. w3 f109. ; jl. c21. ; goto start executer. e. \f ; rc 17.6.69 editor i, tape 1, page 16. ; out: ; comment: a number of bytes are transferred from ; the process table to the corr string; b. h1 ; w. ; a10: ; out 6: am 3 ; no:= 6; goto a; a11: ; out 3: am 1 ; no:= 3; goto a; a12: ; out 2: am 1 ; no:= 2; goto a; a13: ; out 1: al w0 x3+1 ; no:= 1; rs. w0 f67. ; a: h1: al w3 x3+1 ; for cur pr:= cur pr + 1 step 1 until cur pr + no do bl w0 x3 ; begin hs w0 x2 ; byte(cur corr):= byte (cur pr); al w2 x2+1 ; cur corr:= cur corr + 1; sn. w2 (f50.) ; if cur corr = corr bottom jl. w2 c7. ; then save correction; se. w3 (f67.) ; jl. h1. ; end; jl. a4. ; goto next pr 2; e. ; \f ; rc 1.11.70 editor i, tape 1, page 17. b. h1 ; begin w. a31: ; out real exactly 1. al w0 1 ; rs. w0 f66. ; integer := 1. jl. a14. ; goto a14. a30: ; out real negative and at least -1 if f66 is zero al w0 -1 ; wo := -1; rx. w0 f66. ; swop -1 and integer ac w0 (0) ; negate w0 jl. h1. ; continue in h1. a29: ; out real at least one if f66 is zero al w0 1 ; wo := 1. rx. w0 f66. ; swop w0 with integer h1: se w0 0 ; if was = 0 then let it be 1 rx. w0 f66. ; otherwise swop it back. ; continue in outreal e. ; end special out real a14: ; out rel: ; comment: the instruction <rel> and a word containing ; the integer is output to the correction string; b. h2 ; begin w. ; al w2 x2+3 ; cur corr:= cur corr + 3; sl. w2 (f50.) ; if cur corr >= corr bottom jl. h2. ; then goto save buffer; ; store: h1: al w0 b8 ; hs w0 x2-3 ; byte(cur corr - 3):= <rel> rl. w0 f66. ; hs w0 x2-1 ; save integer in ls w0 -12 ; byte(cur corr - 2) and hs w0 x2-2 ; byte(cur corr - 1); jl. a4. ; goto next pr 2 ; save buffer: h2: ws. w2 f50. ; rs. w2 f67. ; missing space:= cur corr - corr bottom jl. w2 c7. ; save correction; wa. w2 f67. ; cur corr:= cur corr + missing space; jl. h1. ; goto store; e. ; end out rel; a36: ; out abs: ; comment: the instruction <rel> and a word containing , ; the abs(integer - current line) is output to the correction string; ; if the integer output is negative then the word ; <backup> is output if posetive then <copy> and <uphead>. b. h4 ; begin w. ; al w2 x2+5 ; cur corr:= cur corr + 5; sl. w2 (f50.) ; if cur corr >= corr bottom jl. h2. ; then goto save buffer; ; store: h1: al w0 b8 ; hs w0 x2-5 ; byte(cur corr - 5):= <rel> rl. w0 f66. ; ws. w0 f44. ; integer := integer - current line. rs. w0 f66. ; store integer. hs w0 x2-3 ; save integer in ls w0 -12 ; byte(cur corr - 4) and hs w0 x2-4 ; byte(cur corr - 3); ; trick!!!!! ; the left part af the integer must ; when considered as a number be ; greater than the whole negative number ; and less than the whole positive number. sl. w0 (f66.) ; if originally number is negative jl. h3. ; then goto back step. al w0 b13 ; byte(cur corr-2) := <copy> hs w0 x2-2 ; al w0 b27 ; byte(cur corr-1) := <uphead> h4: hs w0 x2-1 ; jl. a4. ; goto next pr 2 ; back step: h3: al w2 x2-1 ; cur corr := cur corr - 1. ( org. 5 was assumed but ; because we backup we only need 4). al w0 b28 ; byte (cur corr -1 ) := back up. jl. h4. ; goto next pr. ; save buffer: h2: ws. w2 f50. ; rs. w2 f67. ; missing space:= cur corr - corr bottom jl. w2 c7. ; save correction; wa. w2 f67. ; cur corr:= cur corr + missing space; jl. h1. ; goto store; e. ; end out rel; a15: ; return: ; comment: cur pr is set back to return pr; rl. w3 f68. ; cur pr:= return pr; jl. a4. ; goto next pr 2; a16: ; delim ; comment: a delimiter is input and stored; b. h1 ; begin w. rs. w2 f67. ; save (cur corr); al. w2 f6. ; delim pointer:= first delim ; next: h1: bl w0 x1 ; byte:= byte (cur in); al w1 x1+1 ; cur in:= cur in + 1; sn w0 g4 ; if byte = <sp> jl. h1. ; then goto next; hs w0 x2 ; delim (delim pointer):= byte; al w2 x2+1 ; delim pointer:= delim pointer + 1; sl. w2 f5. ; if delim pointer >= 7 jl. c25. ; then alarm (syntax); sz w0 g21 ; if byte = <comp> jl. h1. ; then goto next jl. a3. ; goto next pr 1; e. ; end delim; ; set insert mark. a32: al w0 1 ;**** rs. w0 f109. ;**** set insert mark to true. jl. a4. ;**** goto next pr. m.rc 25.03.72, editor i, tape1. ▶EOF◀