home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
64'er 1991 Janurary
/
64er_Magazin_91-01_1991_Markt__Technik_de_Side_A.d64
/
cross-reference
(
.txt
)
< prev
next >
Wrap
Commodore BASIC
|
2022-10-26
|
2KB
|
59 lines
1 goto5
2 w=w+1:l%(w)=l:r$(w)=right$(s$+m$,5):print" , ";m$;:m$="":return
3 get#1,a$:a=asc(a$+chr$(0)):t=c(a):return
4 gosub3:on-(a=32)goto4:return
5 n=900:dimr$(n),l%(n),c(255):print"cross-reference-listing"
6 s$=" ":z$(1)="zeilen-nr":z$(2)="variablen":z$(3)="zeilen+variablen"
7 print"bitte waehlen sie":input"1=zeilen-nr,2=variablen,3=beides";p$:p=val(p$)
8 input"prg-datei=";p$:b$(1)=chr$(34):fori=65to90:c(i)=8:next
9 open1,8,3,p$+",p,r":open15,8,15:input#15,e:ifethenprint"diskerr=";e:end:run
10 fori=1to22:readz,c(z):next:b$(2)=":":gosub3:gosub3:onpgoto12,22,34:goto7
11 close1:w$=chr$(13):d=3:gosub49:end
12 gosub3:l=a:gosub3:print:ifl+a=0then11
13 gosub3:l=a:gosub3:l=a*256+l:print"zeile ";l;"=>";
14 gosub4:goto18
15 m$=m$+a$
16 gosub4:ont+1goto17,17,17,17,17,16,15,17,17,17,17
17 ifm$<>""thengosub2:ifa=44then16
18 q$=b$(t):ont+1goto14,19,19,19,12,14,14,16,14,14,14
19 gosub3:ifa>0anda$<>q$then19
20 ift=4then12
21 goto14:w=w+1:l%(w)=l:r$(w)=m$:print" , ";m$;:m$="":goto18
22 gosub3:l=a:gosub3:print:ifl+a=0then11
23 gosub3:l=a:gosub3:l=a*256+l:print"zeile ";l;"=>";
24 gosub4:goto25
25 q$=b$(t):ont+1goto24,26,26,26,22,24,24,24,31,24,24
26 gosub3:ifa>0anda$<>q$then26
27 ift=4then22
28 goto24
29 m$=m$+a$:gosub4:ift=10then32
30 goto33
31 m$=m$+a$:gosub4:ont+1goto33,33,33,33,33,32,31,33,31,29,32
32 m$=m$+a$
33 w=w+1:l%(w)=l:r$(w)=m$:print" , ";m$;:m$="":goto25
34 gosub3:l=a:gosub3:print:ifl+a=0then11
35 gosub3:l=a:gosub3:l=a*256+l:print"zeile ";l;"=>";
36 gosub4:goto40
37 m$=m$+a$
38 gosub4:ont+1goto39,39,39,39,39,38,37,39,39,39,39
39 ifm$<>""thengosub2:ifa=44then38
40 q$=b$(t):ont+1goto36,41,41,41,34,36,36,38,46,36,36
41 gosub3:ifa>0anda$<>q$then41
42 ift=4then34
43 goto36
44 m$=m$+a$:gosub4:ift=10then47
45 goto48
46 m$=m$+a$:gosub4:ont+1goto48,48,48,48,48,47,46,48,46,44,47
47 m$=m$+a$
48 w=w+1:l%(w)=l:r$(w)=m$:print" , ";m$;:m$="":goto40
49 r$(w+1)="[255]"
50 open2,d:print#2,z$(p);" cross-referenz von pg:";p$
51 forx=1tow:fory=x+1tow
52 ifr$(y)<=r$(x)thenr$=r$(y):r$(y)=r$(x):r$(x)=r$:l=l%(y):l%(y)=l%(x):l%(x)=l
53 next:ifr$(x)<>r$(x-1)thenprint#2,left$(w$+r$(x)+s$,7);"=>";l%(x);:goto55
54 ifl%(x)<>l%(x-1)thenprint#2," , ";l%(x);
55 next:print#2:close2:input" 0=ende,3=crt,4=drucker";d:
56 ifd>=3andd<=4then50
57 return:data 48,6,49,6,50,6,51,6,52,6,53,6,54,6,55,6,56,6,57,6
58 data0,4,32,5,34,1,131,2,143,3,137,7,138,7,141,7,167,7,36,9,37,9,40,10