Trailing-Edge
-
PDP-10 Archives
-
decuslib20-01
-
decus/20-0003/paslny.mac
There is 1 other file named paslny.mac in the archive. Click here to see a list.
title PASLNX - paslnk for rescan version of Pascal
twoseg
search monsym,pasunv
extern resetf,clofil,quit
entry pushf,popf,runlink,clribf,curnam
reg==b
reg1==c
reg2==d
reg3==e
reg4==f
reg5==g
reg6==h
p==17
t==1
t0==0
reloc 0
oldf: block filcmp+1
oldfen=.-1
reloc 400000
pushf: hrl t,reg ;copy old fcb
hrri t,oldf
blt t,oldfen
pushj p,init.b## ;reinit the fcb
setz a, ;text file
seto reg3, ;[2] so we can see errors
setzb reg4,reg5 ;[2]
movei reg6,30 ;[2] let us see open errors and EOL char
pushj p,resetf
popj p,
popf: push p,reg
setz reg1,
pushj p,clofil
pop p,reg
hrli t,oldf
hrr t,reg
blt t,filcmp(reg)
popj p,
clribf: movei a,.priin
cfibf
popj p,
runlink:movsi a,(gj%old!gj%sht)
hrroi b,[asciz /sys:link.exe/]
gtjfn
jrst quit
move 17,a ;where to put jfn
seto a, ;remove pages
MOVSI B,.FHSLF ; FREOM THIS FORK
MOVE C,[PM%CNT+1000] ; ALL 1000 PAGES
MOVE D,[RUNCOD,,10] ;MOVE REST OF CODE TO
BLT D,16 ; ACS 10-16
JRST 10 ;DO IT THERE
RUNCOD: PMAP ;DELETE ALL PAGES FROM MAP
MOVSI A,.FHSLF ;GET INTO THIS FORK
HRR A,17 ;FROM THIS FILE
GET ;GO GET IT
MOVEI A,.FHSLF ;OUR FORK
GEVEC ;GET FORKS ENTRY VECTOR
JRST 1(B) ;START FORK
;curname(file,string)
; put current file spec into string
;b - FCB
;c - string addr
;d - string length
curnam: addi d,4 ;d _ string length in words
idivi d,5
move t0,[ascii / /] ;now init string to blanks
movem t0,(c)
hrli a,(c)
hrri a,1(c)
add d,c
blt a,-1(d)
hrro a,c ;now do jfns
hrrz b,filjfn(b)
move c,[exp 111110000001] ;full file spec
setz d,
jfns
movei t0,40 ;put blank in over null at end
idpb t0,a
popj p,
if2,< purge get>
end