perm filename GEN.COM[S,AIL] blob sn#071743 filedate 1973-11-10 generic text, type T, neo UTF8
COMMENT ⊗   VALID 00016 PAGES 
RECORD PAGE   DESCRIPTION
 00001 00001
 00004 00002
 00005 00003		1) GEN vs. 2) GEN[S,AIL]	SRCCOM	11-10-73	13:35	PAGES 1,1
 00009 00004		1) GEN vs. 2) GEN[S,AIL]	SRCCOM	11-10-73	13:35	PAGES 1,1
 00012 00005		1) GEN vs. 2) GEN[S,AIL]	SRCCOM	11-10-73	13:35	PAGES 1,1
 00016 00006		1) GEN vs. 2) GEN[S,AIL]	SRCCOM	11-10-73	13:35	PAGES 1,1
 00018 00007		1) GEN vs. 2) GEN[S,AIL]	SRCCOM	11-10-73	13:35	PAGES 9,9
 00021 00008		1) GEN vs. 2) GEN[S,AIL]	SRCCOM	11-10-73	13:35	PAGES 16,16
 00023 00009		1) GEN vs. 2) GEN[S,AIL]	SRCCOM	11-10-73	13:35	PAGES 18,18
 00026 00010		1) GEN vs. 2) GEN[S,AIL]	SRCCOM	11-10-73	13:35	PAGES 21,21
 00029 00011		1) GEN vs. 2) GEN[S,AIL]	SRCCOM	11-10-73	13:35	PAGES 23,23
 00032 00012		1) GEN vs. 2) GEN[S,AIL]	SRCCOM	11-10-73	13:35	PAGES 31,31
 00035 00013		1) GEN vs. 2) GEN[S,AIL]	SRCCOM	11-10-73	13:35	PAGES 36,36
 00038 00014		1) GEN vs. 2) GEN[S,AIL]	SRCCOM	11-10-73	13:35	PAGES 47,48
 00041 00015		1) GEN vs. 2) GEN[S,AIL]	SRCCOM	11-10-73	13:35	PAGES 49,50
 00044 00016		1) GEN vs. 2) GEN[S,AIL]	SRCCOM	11-10-73	13:35	PAGES 50,51
 00045 ENDMK
⊗;
	1) GEN vs. 2) GEN[S,AIL]	SRCCOM	11-10-73	13:35	PAGES 1,1

******** GEN **** PAGE 1
1)	COMMENT ⊗   VALID 00055 PAGES
1)	C REC  PAGE   DESCRIPTION
1)	C00001 00001
1)	C00005 00002	HISTORY
1)	C00018 00003		LSTON	(GEN)
1)	C00026 00004	TABLEDATA (EXEC ROUTINES -- GLOBAL VARIABLES)
1)	C00031 00005	TABCONDATA (EXEC ROUTINES -- GLOBAL VARIABLES)
1)	C00034 00006	DSCR GENINI
1)	C00038 00007	DSCR GETOP, GETADL, GETAD
1)	C00040 00008	DSCR -- SAIL DECLARATION EXECS
1)	C00045 00009	DSCR TYPSET, VALSET, XOWSET,  etc.
1)	C00048 00010	DSCR TCON, BTRU, BFAL, BNUL, BINF
1)	C00051 00011	DSCR TWID10, ECHK, ESET
1)	C00054 00012	DSCR DWN, BLOCK, BLNAME, ENTID, UP, NAMCHK, etc.
1)	C00062 00013	↑ENTID:	
1)	C00068 00014	
1)	C00074 00015	 Check for match on block names.
1)	C00075 00016	DSCR RQ00, RQSET, SRCSWT
1)	C00079 00017	
1)	C00080 00018	
1)	C00085 00019	↑SRCSWT:
1)	C00087 00020	DSCR DFPREP, DCPREP, DWPREP, DFPINS, DFSET, DFENT, MACOFF, MACON 
1)	C00100 00021	DSCR STCAT
1)	C00110 00022	DSCR DCLNT1,DCLNT2
1)	C00116 00023	DSCR CNDRCY, CNDRCN, CNDRCP 
1)	C00121 00024	DSCR LETSET, LETENT
1)	C00124 00025	DSCR TWCOND,SWICHP,SWPOFF,PSWICH,OKEOF
1)	C00132 00026	↑SETWHL: EXCH	SP,STPSAV	 GET STRING POINTER
1)	C00146 00027		SUBTTL	EXECS for Entry Declaration
1)	C00148 00028	DSCR ALOT
1)	C00153 00029	↑ALOT:				ROUTINE TO HANDLE ALLOCATION
1)	C00156 00030	
1)	C00160 00031	Comment 
1)	C00167 00032	EMIT SYMBOLS FOR THIS BLOCK
1)	C00176 00033	LOADER BLOCK FOR POLISH FIXUP
1)	C00178 00034	DSCR PDOUT
1)	C00185 00035	DOLVIN:	PUSH	P,PNT2
1)	C00187 00036	ROUTINE TO PUT OUT LOCAL VAR INFO -- USED BY DIS
1)	C00192 00037	Allo -- Allocate One Type of Symbol
1)	C00197 00038	ROUTINE TO ALLOCATE SPACE FOR TEMP CELLS AND TO OUTPUT
1)	C00201 00039	REQINI -- USER REQUIRED INITIALIZTIONS
1)	C00204 00040	DSCR DONES
1)	C00206 00041	
1)	C00211 00042	REN <
1)	C00213 00043	
1)	C00217 00044	
1)	C00222 00045	MEMORY  and LOCATION EXECS, ALSO UINCLL
	1) GEN vs. 2) GEN[S,AIL]	SRCCOM	11-10-73	13:35	PAGES 1,1

1)	C00225 00046	DSCR MAKBUK, FREBUK
1)	C00227 00047	BEGIN	ERRORS
1)	C00233 00048	DSCR SCNBAK,POPBAK,KILPOP,QREM2,QTYPCK
1)	C00238 00049	DSCR  UNDEC -- Undeclared identifiers
1)	C00245 00050	DSCR  QDEC0,1,2   QARSUB  QARDEC QPARM QPRDEC
1)	C00252 00051	BEGIN SCOMM
1)	C00253 00052	BEGIN  INLINE
1)	C00255 00053	DSCR CODNIT, WRDNIT, ONEWRD, SETSIX, SETOP, CODIND, CODREG, etc.
1)	C00261 00054	
1)	C00266 00055	BEGIN COUNT
1)	C00269 ENDMK
1)	C⊗;
1)	COMMENT ⊗HISTORY
1)	AUTHOR,REASON
1)	021  102100000000  ⊗;
1)	COMMENT ⊗
1)	VERSION 17-1(0) 7-26-73 BY RHT **** VERSION 17 ****
*** GEN[S,AIL] *** PAGE 1
2)	COMMENT ⊗   VALID 00056 PAGES VERSION 17-1(11)
2)	RECORD PAGE   DESCRIPTION
2)	 00001 00001
2)	 00006 00002	HISTORY
2)	 00020 00003		LSTON	(GEN)
2)	 00028 00004	TABLEDATA (EXEC ROUTINES -- GLOBAL VARIABLES)
2)	 00033 00005	TABCONDATA (EXEC ROUTINES -- GLOBAL VARIABLES)
2)	 00036 00006	DSCR GENINI
2)	 00040 00007	DSCR GETOP, GETADL, GETAD
2)	 00042 00008	DSCR -- SAIL DECLARATION EXECS
2)	 00047 00009	DSCR TYPSET, VALSET, XOWSET,  etc.
2)	 00050 00010	DSCR TCON, BTRU, BFAL, BNUL, BINF
2)	 00052 00011	DSCR TWID10, ECHK, ESET
2)	 00055 00012	DSCR DWN, BLOCK, BLNAME, ENTID, UP, NAMCHK, etc.
2)	 00063 00013	↑ENTID:	
2)	 00069 00014	
2)	 00075 00015	 Check for match on block names.
2)	 00076 00016	DSCR RQ00, RQSET, SRCSWT
2)	 00080 00017	
2)	 00081 00018	
2)	 00085 00019	↑SRCSWT:
2)	 00087 00020	DSCR DFPREP, DCPREP, DWPREP, DFPINS, DFSET, DFENT, MACOFF, MACON 
2)	 00100 00021	DSCR STCAT
2)	 00112 00022	DSCR DCLNT1,DCLNT2
2)	 00118 00023	DSCR CNDRCY, CNDRCN, CNDRCP 
2)	 00125 00024	DSCR LETSET, LETENT
2)	 00128 00025	DSCR TWCOND,SWICHP,SWPOFF,PSWICH,OKEOF
2)	 00136 00026	↑SETWHL: EXCH	SP,STPSAV	 GET STRING POINTER
2)	 00149 00027		SUBTTL	EXECS for Entry Declaration
2)	 00151 00028	DSCR ALOT
	1) GEN vs. 2) GEN[S,AIL]	SRCCOM	11-10-73	13:35	PAGES 1,1

2)	 00156 00029	↑ALOT:				ROUTINE TO HANDLE ALLOCATION
2)	 00160 00030	
2)	 00164 00031	Comment 
2)	 00170 00032	NOSY:	PUSHJ	P,URGSTR	IF ON STRING RING....
2)	 00179 00033	LOADER BLOCK FOR POLISH FIXUP
2)	 00181 00034	DSCR PDOUT
2)	 00188 00035	DOLVIN:	PUSH	P,PNT2
2)	 00190 00036	ROUTINE TO PUT OUT LOCAL VAR INFO -- USED BY DIS
2)	 00195 00037	 %AA% -- SDFLTS
2)	 00196 00038	Allo -- Allocate One Type of Symbol
2)	 00201 00039	ROUTINE TO ALLOCATE SPACE FOR TEMP CELLS AND TO OUTPUT
2)	 00205 00040	REQINI -- USER REQUIRED INITIALIZTIONS
2)	 00208 00041	DSCR DONES
2)	 00210 00042	
2)	 00215 00043	REN <
2)	 00217 00044	
2)	 00221 00045	
2)	 00226 00046	MEMORY  and LOCATION EXECS, ALSO UINCLL
2)	 00229 00047	DSCR MAKBUK, FREBUK
2)	 00231 00048	BEGIN	ERRORS
2)	 00237 00049	DSCR SCNBAK,POPBAK,KILPOP,QREM2,QTYPCK
2)	 00242 00050	DSCR  UNDEC -- Undeclared identifiers
2)	 00250 00051	DSCR  QDEC0,1,2   QARSUB  QARDEC QPARM QPRDEC
2)	 00257 00052	BEGIN SCOMM
2)	 00258 00053	BEGIN  INLINE
2)	 00260 00054	DSCR CODNIT, WRDNIT, ONEWRD, SETSIX, SETOP, CODIND, CODREG, etc.
2)	 00266 00055	
2)	 00271 00056	BEGIN COUNT
2)	 00274 ENDMK
2)	⊗;
2)	COMMENT ⊗HISTORY
2)	AUTHOR,REASON
2)	021  102100000013  ⊗;
2)	COMMENT ⊗
2)	VERSION 17-1(11) 10-31-73 BY HJS BUG #OS# DETECT UNDECLARED ARGUMENT TO CVMS 
2)	VERSION 17-1(10) 10-30-73 BY RHT BUG #OB# SDFLTS NEEDED TO DO CLRSET
2)	VERSION 17-1(9) 10-23-73 BY JRL FEATURE %AG% ITEM_START STUFF
2)	VERSION 17-1(8) 9-27-73 BY KVL %AC% REMOVE GLOBAL DECLARATION OPTION IN ERROR RECOVERY
2)	VERSION 17-1(7) 9-27-73 
2)	VERSION 17-1(6) 9-21-73 BY HJS INHIBIT LISTING OF FALSE PART OF CONDITIONAL COMPILATION 
2)	VERSION 17-1(5) 9-19-73 BY HJS ADD CVPS AND EVALREDEFINE
2)	VERSION 17-1(4) 9-1-73 BY RHT FEATURE %AA% -- SPROUT DEFAULTS
2)	VERSION 17-1(3) 8-16-73 BY jrl REMOVE REFERENCES TO LEP SWITCH
2)	VERSION 17-1(2) 8-12-73 BY JRL BUG #NQ# STRING ITEMVAR IS NOT A STRING
2)	VERSION 17-1(1) 8-12-73 
2)	VERSION 17-1(0) 7-26-73 BY RHT **** VERSION 17 ****


	1) GEN vs. 2) GEN[S,AIL]	SRCCOM	11-10-73	13:35	PAGES 1,1

******** GEN **** PAGE 4
1)	LEP <	
1)		FN 	<LEAP>		;CALL LEAP!
*** GEN[S,AIL] *** PAGE 4
2)		FN 	<LEAP>		;CALL LEAP!


******** GEN **** PAGE 4
1)	>;LEP
1)		FN	<BEXIT>		;BLOCK EXITER
*** GEN[S,AIL] *** PAGE 4
2)		FN	<BEXIT>		;BLOCK EXITER


******** GEN **** PAGE 5
1)	LEP<
1)		LPARRAY				; LEAP ARRAY
1)	>;LEP
1)		XWD SBSCRP,0			; NORMAL ARRAY
*** GEN[S,AIL] *** PAGE 5
2)		LPARRAY				; LEAP ARRAY
2)		XWD SBSCRP,0			; NORMAL ARRAY


******** GEN **** PAGE 6
1)	LEP <
1)		PUSHJ	P,LEPINI	;INITIALIZE LEAP VARIABLES
1)	>;LEP
1)	; ******
*** GEN[S,AIL] *** PAGE 6
2)		PUSHJ	P,LEPINI	;INITIALIZE LEAP VARIABLES
2)	; ******


******** GEN **** PAGE 9
1)	LEP<
1)	↑ARYSET: SKIPA  A,[LPARRAY]
*** GEN[S,AIL] *** PAGE 9
2)	↑ARYSET: SKIPA  A,[LPARRAY]


******** GEN **** PAGE 9
1)	>;LEP
1)	↑HELAR2: MOVE	B,BITS
*** GEN[S,AIL] *** PAGE 9
2)	↑HELAR2: MOVE	B,BITS


	1) GEN vs. 2) GEN[S,AIL]	SRCCOM	11-10-73	13:35	PAGES 9,9

******** GEN **** PAGE 10
1)	LEP <  
1)		SKIPGE  A,(A)		;NEG IF INF. WITHIN SUBLIST SELECTOR
1)		JRST	LINF		;LIST INFIN. LOCATED IN LEAP
1)	    >;LEP
1)	NOLEP <
1)		MOVE	A,(A)
1)	    >;NOLEP
1)		MOVEM	A,GENLEF+1	;SET UP FOR LENGTH
*** GEN[S,AIL] *** PAGE 10
2)		SKIPGE  A,(A)		;NEG IF INF. WITHIN SUBLIST SELECTOR
2)		JRST	LINF		;LIST INFIN. LOCATED IN LEAP
2)		MOVEM	A,GENLEF+1	;SET UP FOR LENGTH


******** GEN **** PAGE 13
1)	LEP <
1)	; FOLLOWING REMOVED TO ALLOW INTRODUCTION OF STRING ITEMS.
*** GEN[S,AIL] *** PAGE 13
2)	; FOLLOWING REMOVED TO ALLOW INTRODUCTION OF STRING ITEMS.


******** GEN **** PAGE 13
1)		AOS	A,ITEMNO		;MAKE A NEW NUMBER FOR IT
1)		AOS 	ITMCNT			;TOTAL NUMBER OF DECLARED ITEMS
*** GEN[S,AIL] *** PAGE 13
2)	;; %AG% LH(ITEMNO) NOW CONTAINS ITEM_START
2)		AOS	A,ITEMNO		;MAKE A NEW NUMBER FOR IT
2)		HRRZS	A
2)	;; %AG%
2)		AOS 	ITMCNT			;TOTAL NUMBER OF DECLARED ITEMS


******** GEN **** PAGE 13
1)	>;LEP
1)	IDLIS:	TRNN	TBITS,PROCED
*** GEN[S,AIL] *** PAGE 13
2)	IDLIS:	TRNN	TBITS,PROCED


******** GEN **** PAGE 16
1)		| "some characters"     | ERROR_MODES
1)	 PNAMES and SOURCE_FILE are handled specially
*** GEN[S,AIL] *** PAGE 16
2)	 PNAMES and SOURCE_FILE are handled specially


******** GEN **** PAGE 16
	1) GEN vs. 2) GEN[S,AIL]	SRCCOM	11-10-73	13:35	PAGES 16,16

1)	LEP <
1)		JUMPE	B,PNAM			;PNAMES......
1)	>;LEP
1)		MOVE	A,SCNVAL		;THE CONSTANT
*** GEN[S,AIL] *** PAGE 16
2)		JUMPE	B,PNAM			;PNAMES......
2)		MOVE	A,SCNVAL		;THE CONSTANT


******** GEN **** PAGE 16
1)		JRST	MODSET		; error_modes
1)	LBSET:	SKIPA	B,[LBTAB]		;LIBRARY OUTPUT BLOCK ADDR
*** GEN[S,AIL] *** PAGE 16
2)		JRST	ITMSTRT
2)	LBSET:	SKIPA	B,[LBTAB]		;LIBRARY OUTPUT BLOCK ADDR


******** GEN **** PAGE 18
1)	MODSET:	PUSH	P,FF			;SAVE FF
1)		HLLZ	FF,%ERFLGS		;GET MODES
1)		MOVE	A,GENLEF+1		;GET STRING CONSTANT
1)		SKIPN	B,$PNAME(A)		;STRING LENGTH
1)		 POPJ	P,
1)		MOVE	A,$PNAME+1(A)		;THE STRING
1)		HRRZ 	B,B
1)	REP..:	SOJGE	B,UNNCDE
1)		POP	P,FF
1)		POPJ	P,
1)	UNNCDE:	ILDB	C,A			;FIRST LETTER
1)		CAIN	C,"-"
1)		 JRST	[SETCA	FF,		;LITTLE TRICKERY HERE
1)			ILDB	C,A
1)			JRST .+1]
1)		CAIL	C,133			;UPPER CASE?
1)		 SUBI	C,40
1)		CAIN	C,"A"
1)		 TLO	FF,AUTO+MINUS		;MINUS SIGNALS THAT WE CAUGHT SOMETHING
1)		CAIN	C,"Q"
1)		 TLO	FF,QUIET+MINUS
1)		CAIN	C,"K"
1)		 TLO	FF,KEEP+MINUS
1)		CAIN	C,"N"
1)		 TLO	FF,NUMBS+MINUS
1)		CAIN	C,"L"
1)		 JRST	[TLO	FF,LOGGIN+MINUS
1)			SKIPN	TEMP,SRCFIL
1)			 MOVE	TEMP,[SIXBIT /ERRORS/]
1)			MOVEM	TEMP,%ERFIL
	1) GEN vs. 2) GEN[S,AIL]	SRCCOM	11-10-73	13:35	PAGES 18,18

1)			MOVE	TEMP,[SIXBIT/LOG   /]
1)			HLLZM	TEMP,%ERFIL+1
1)			JRST	.+1]
1)		TLNN	FF,MINUS		;CATCH ANYTHING?
1)		 JRST	[ERR	<REQUIRE ERROR_MODES RECOGNIZES ONLY A,Q,K,N,L OR ->,1
1)			MOVE	FF,%ERFLGS
1)			JRST	REP..]
1)		TRNE	FF,-1
1)		 SETCA	FF,
1)		TLZ	FF,MINUS
1)		HLLM	FF,%ERFLGS
1)		JRST	REP..
1)	↑SRCSWT:
*** GEN[S,AIL] *** PAGE 18
2)	↑SRCSWT:


******** GEN **** PAGE 20
1)	↑EVMCOF: SKIPE	EVLDEF		; TURN OFF MACRO EXPANSION ONLY IF 
1)		POPJ	P,		;  EVALDEFINE IS NOT IN PROGRESS 
1)	↑MACOFF: TLO	FF,NOMACR	;NO MACRO EXPANSIONS WHEN REDEFINING!
*** GEN[S,AIL] *** PAGE 20
2)	↑EVMCOF: SKIPN	EVLDEF		; TURN OFF MACRO EXPANSION ONLY IF 
2)					;  EVALDEFINE IS NOT IN PROGRESS 
2)	↑MACOFF: TLO	FF,NOMACR	;NO MACRO EXPANSIONS WHEN REDEFINING!


******** GEN **** PAGE 21
1)	↑STCAT: MOVE	LPSA,GENLEF		; PREPARE TO LOOK UP THE STRING 
1)		HLRZ	LPSA,%TLINK(LPSA)	;  AND ENTER IT IN THE SYMBOL 
1)		MOVE	TEMP,$PNAME(LPSA)	;  TABLE IF NOT ALREADY THERE.
1)		SUBI	TEMP,2			; THE ONLY DIFFERENCE BETWEEN THE 
*** GEN[S,AIL] *** PAGE 21
2)	↑STCAT: TLZ	FF,NOMACR		; TURN MACRO EXPANSION BACK ON 
2)	;;#OS# 10-31-73 HJS CHECK FOR UNDECLARED MACRO NAME 
2)		SKIPE	LPSA,GENLEF		; IS THIS A DECLARED MACRO? 
2)		JRST	CVMSOK			; YES, 
2)		ERR	<NOT A MACRO NAME SUPPLIED TO CVMS> ; NO, RETURN A NULL STRING 
2)		SETZM	PNAME			; 
2)		SETZM	PNAME+1			; 
2)		JRST	UNDCVM			; 
2)	CVMSOK:	HLRZ	LPSA,%TLINK(LPSA)	; CONVERT TO STRING AND ENTER IT IN THE 
2)						;  SYMBOL TABLE IF NOT ALREADY THERE.  
2)	RM1770:	MOVE	TEMP,$PNAME(LPSA)	;
2)		SUBI	TEMP,2			; THE ONLY DIFFERENCE BETWEEN THE 


******** GEN **** PAGE 21
	1) GEN vs. 2) GEN[S,AIL]	SRCCOM	11-10-73	13:35	PAGES 21,21

1)		PUSH	P,BITS			;
1)		PUSHJ	P,STRINS		;
*** GEN[S,AIL] *** PAGE 21
2)	UNDCVM:	PUSH	P,BITS			;
2)		PUSHJ	P,STRINS		;


******** GEN **** PAGE 21
1)		TLZ	FF,NOMACR		; TURN MACRO EXPANSION BACK ON
1)		POPJ	P,			;
1)	DSCR SPRZER, XOWST1, VALST1, HELAR3, HELST1, TYPST1, RSTST1, MKINT
*** GEN[S,AIL] *** PAGE 21
2)		POPJ	P,			;
2)	DSCR CVPFRM, ASGOFF 
2)	PRO CVPFRM, ASGOFF 
2)	DES These routines are used to implement the CVPS construct which converts a macro 
2)	 actual parameter to a string.  
2)	 CVPS(formal parameter name).  
2)	CVPFRM	This routine fetches the appropriate parameter from the VARB ring associated 
2)		with the cureent invocation of the macro and strips off the 177-0 at its end 
2)		and converts it to a string.  
2)	ASGOFF	This routine turns off the flag which inhibits the expansion of macro actual 
2)		parameters in case an error has occurred.  
2)	⊗ 
2)	↑CVPFRM: SETZM	ASGFLG			; TURN OFF ACTUAL MACRO PARAMETER EXPANSION 
2)		MOVE	B,GENLEF		;  INHIBITION FLAG AND GET SEMBLK OF ACTUAL 
2)		MOVE	LPSA,DEFRNG		;  PARAMETER TO BE CONVERTED TO A STRING 
2)	GETITP:	SOJE	B,RM1770		; 
2)		RIGHT	,%RVARB,		; 
2)		JRST	GETITP			; 
2)	↑ASGOFF: SETZM	ASGFLG			; TURN OFF ACTUAL MACRO PARAMETER EXPANSION 
2)		POPJ	P,			;  INHIBITION FLAG 
2)	DSCR SPRZER, XOWST1, VALST1, HELAR3, HELST1, TYPST1, RSTST1, MKINT


******** GEN **** PAGE 22
1)	LEP <
1)		TLNN	FF,LPPROG
1)		PUSHJ	P,OKSTAC
1)	>;LEP
1)		MOVE	A,[XWD ACKTAB,ACKSAV]	; SAVE ACKTAB IN ACKSAV
*** GEN[S,AIL] *** PAGE 22
2)		TLNN	FF,LPPROG
2)		PUSHJ	P,OKSTAC
2)		MOVE	A,[XWD ACKTAB,ACKSAV]	; SAVE ACKTAB IN ACKSAV


******** GEN **** PAGE 23
	1) GEN vs. 2) GEN[S,AIL]	SRCCOM	11-10-73	13:35	PAGES 23,23

1)	DSCR SETRDF, SETEDF, DEFOFF 
*** GEN[S,AIL] *** PAGE 23
2)	DSCR PSHLST, POPLST 
2)	DES PSHLST, POPLST 
2)	DES These routines are used to indicate whether one is in the false part of 
2)		conditional compilation or in the conditional compilation parser.  This 
2)		information is used by the SCANNER so that listing files can hopefully 
2)		reflect the true program that is being compiled.  The basic action of 
2)		the SCANNER is to test the CNDLST flag when it is about to stack a result 
2)		on the parse stack and if one is in  the conditional compilation parser, 
2)		then the listing buffer pointer is reset to the value it had prior to 
2)		scanning the parse token in question.  
2)	PSHLST	This routine is used to indicate that listing should not be happening now.  
2)	POPLST	This routine is used to indicate that one is to revert to the previous mode 
2)		of listing output.  
2)	⊗ 
2)	↑PSHLST: QPUSH(LSTSTK,CNDLST)		; SAVE PREVIOUS COND. COMP. LISTING STATE 
2)		SETOM	CNDLST			; CEASE LISTING 
2)		POPJ	P,			; 
2)	↑POPLST: QPOP(LSTSTK,CNDLST)		; RESTORE PREVIOUS COND. COMP. LISTING STATE 
2)		POPJ	P,			; 
2)	DSCR SETRDF, SETEDF, DEFOFF 


******** GEN **** PAGE 29
1)		TLNN	TBITS,SBSCRP	;IF ¬SBSCRP ∧ STRING,
1)		TRNN	TBITS,STRING	; USE 2D WORD FIXUP
*** GEN[S,AIL] *** PAGE 29
2)	;; #NQ#  ↓ A STRING ITEMVAR IS NOT A STRING
2)		TDNN	TBITS,[SBSCRP,,ITMVAR]	;IF ¬(SBSCRP∨ITEMVAR)∧STRING
2)		TRNN	TBITS,STRING	; USE 2D WORD FIXUP


******** GEN **** PAGE 31
1)	KVSYM:
1)		PUSH	P,SBITS
1)		PUSH	P,A
1)	       	MOVE	SBITS,$PNAME+1(LPSA)
1)		MOVEI	TEMP,-5
1)		PUSHJ	P,LETS
1)		MOVEI	TEMP,-5
1)		PUSHJ	P,LETS
1)		MOVE	A,$TBITS(LPSA)
1)		PUSHJ	P,KVOUT
1)		MOVE	A,$SBITS(LPSA)
1)		PUSHJ	P,KVOUT
1)		MOVE	A,$ADR(LPSA)
1)		PUSHJ	P,KVOUT
	1) GEN vs. 2) GEN[S,AIL]	SRCCOM	11-10-73	13:35	PAGES 31,31

1)		POP	P,A
1)		POP	P,SBITS
1)		POPJ	P,
1)	LETS:	ILDB	A,SBITS
1)		LSH	A,36-7
1)		AOSGE	TEMP
1)		JRST	LETS
1)	KVOUT:	SOSG	SYMCNT
1)		 PUSHJ	P, .KVOUT
1)		IDPB	A,SYMPNT
1)		POPJ	P,
1)	.KVOUT:	OUT	$SYM$,
1)		POPJ	P,
1)		ERR	<IO ERR ON SYMBOLS OUTPUT>,1
1)		POPJ	P,
1)	;EMIT SYMBOLS FOR THIS BLOCK
1)	NOSY:	PUSHJ	P,URGSTR	;IF ON STRING RING....
*** GEN[S,AIL] *** PAGE 31
2)	NOSY:	PUSHJ	P,URGSTR	;IF ON STRING RING....


******** GEN **** PAGE 32
1)		PUSHJ	P,KVSYM		;PUT OUT FUNNY SYMBOLS
1)		TLNE	TBITS,SBSCRP	;TURN OFF STRING IF ARRAY
*** GEN[S,AIL] *** PAGE 32
2)		TLNE	TBITS,SBSCRP	;TURN OFF STRING IF ARRAY


******** GEN **** PAGE 34
1)		PUSHJ	P,CODOUT		;PUT OUT PROCEDURE TYPE
*** GEN[S,AIL] *** PAGE 34
2)	;;%AA% A NEW FEATURE RHT -- SPROUT DEFAULTS 9-1-73
2)		HLR	A,$VAL(PNT2)		;ADD IN SPROUT DEFAULTS
2)		PUSHJ	P,CODOUT		;PUT OUT PROCEDURE TYPE


******** GEN **** PAGE 36
1)	COMMENT ⊗Allo -- Allocate One Type of Symbol
*** GEN[S,AIL] *** PAGE 36
2)	;; %AA% -- SDFLTS
2)	↑SDFLTS:
2)		MOVE PNT,GENLEF+1;
2)		PUSHJ P,GETAD;	BETTER HAVE AN INTEGER CONSTANT
2)		TRNN TBITS,INTEGR
2)		ERR <YOU NEED AN INTEGER CONSTANT HERE>,1,CPOPJ
2)		MOVE A,$VAL(PNT)
2)		LSH 	A,-4	;THE VALUE SHIFTED TO GET RID OF CONTROL OPTS
2)		SKIPE	SIMPSW	;MAY NOT BE SIMPLE
	1) GEN vs. 2) GEN[S,AIL]	SRCCOM	11-10-73	13:35	PAGES 36,36

2)		ERR 	<YOU CANNOT DO THIS INSIDE A SIMPLE PROCEDURE>,1,CPOPJ
2)		MOVE	PNT2,TPROC	;THE CURRENT PROCEDURE
2)		HRLM	A,$VAL(PNT2)	;SAVE IT AWAY
2)	;;#OB# RHT ↓ 10-31-73 NEED TO SETZM BITS
2)		JRST 	CLRSET		;DONE
2)	COMMENT ⊗Allo -- Allocate One Type of Symbol


******** GEN **** PAGE 42
1)	LEP <
1)		SKIPE	LEAPIS			;ANY LEAP ASKED FOR
1)		HRROS	ITEMNO			;TELL RUNTIMS YES
1)		SKIPN	ITMSTK			;ANY DECLARED ITEMS?
*** GEN[S,AIL] *** PAGE 43
2)		SKIPE	LEAPIS			;ANY LEAP ASKED FOR
2)	;; %AG% GITEMNO NOW CONTAINS THE LEAPIS FLAG
2)		HRROS	GITEMNO			;TELL RUNTIMS YES
2)		SKIPN	ITMSTK			;ANY DECLARED ITEMS?


******** GEN **** PAGE 42
1)	>;LEP
1)	CONQN:
*** GEN[S,AIL] *** PAGE 43
2)	CONQN:


******** GEN **** PAGE 47
1)		IFDIF <CODE><0>,<
1)		 TLO	FF,ERSEEN
1)		 HLLOS	JOBERR		;CAUSES LOADER TO DELETE EXECUTION (HOPEFULLY)
1)	>;CODE
1)		 POPJ	P,
*** GEN[S,AIL] *** PAGE 48
2)		 TLNN	FF,ERSEEN
2)		 POPJ	P,
2)		 SKIPE	CODE
2)		 POPJ	P,		;IF CODE=0, THEN WE RECOVERED SAFELY
2)		 TLO	FF,ERSEEN
2)	;##LN##KVL - MAKES EXECUTION OF BAD CODE HARDER
2)		 HLLOS	JOBERR		;CAUSES LOADER TO DELETE EXECUTION (HOPEFULLY)
2)		 POPJ	P,


******** GEN **** PAGE 47
1)	↑NAME:		PRIN..	0,[ASCIZ /MESSG
1)	/]
1)			POPJ	P,
	1) GEN vs. 2) GEN[S,AIL]	SRCCOM	11-10-73	13:35	PAGES 47,48

1)	  	>
*** GEN[S,AIL] *** PAGE 48
2)	↑NAME:		TERPRI	<MESSG>
2)			POPJ 	P,
2)	  	>


******** GEN **** PAGE 47
1)	DSCR SCNBAK,POPBAK,KILPOP,QREM2,QTYPCK;
*** GEN[S,AIL] *** PAGE 48
2)	XX (ERR123,<CVPS REQUIRES A LEFT PARENTHESIS HERE>) 
2)	XX (ERR124,<ILLEGAL CVPS PARAMETER NAME>) 
2)	DSCR SCNBAK,POPBAK,KILPOP,QREM2,QTYPCK;


******** GEN **** PAGE 49
1)		HRRZI	LPSA,PNAME-1		;SET UP LPSA WITH THE ID'S NAME
1)		ERR	<UNDECLARED IDENTIFIER: >,3
1)	IFN 0 <	TERPRI	<DO YOU WANT THIS DECLARED IN THE OUTER-MOST BLOFCK?>
1)		PRINT	<(TYPE Y OR N)→ >
*** GEN[S,AIL] *** PAGE 50
2)		PRINT	<UNDECLARED IDENTIFIER: >
2)		HRRI	A,PNAME			; STUFF TO PRINT THE PNAME OF THE ID
2)		HRRZ	B,(A)
2)		MOVE	A,1(A)
2)		JRST	QPRSL1
2)	QPRSL:	ILDB	C,A
2)		TTCALL	1,C
2)	QPRSL1:	SOJGE	B,QPRSL
2)		ERR 	< >,1			; PRINT REST OF ERROR MESS
2)	IFN 0 <
2)		TERPRI	<DO YOU WANT THIS DECLARED IN THE OUTER-MOST BLOCK?>
2)		PRINT	<(TYPE Y OR N)→ >


******** GEN **** PAGE 49
1)	>; 0
1)	LOCA:	SKIPN	QQBLK			; IF HE HASN'T DECLARED ANYTHING
1)		ERRPRI	<YOUR PROGRAM WILL END FUNNY -- NEXT TIME DECLARE YOUR IDENTIFIERS>
1)	     	HRRZI	A,INTEGR		; SOMETHING SIMPLE TO DECLARE
*** GEN[S,AIL] *** PAGE 50
2)	>; IFN 0
2)	LOCA:	SKIPN	QQBLK			; IF HE HASN'T DECLARED ANYTHING
2)		TERPRI	<YOUR PROGRAM WILL END FUNNY -- NEXT TIME DECLARE YOUR IDENTIFIERS>
2)	     	HRRZI	A,INTEGR		; SOMETHING SIMPLE TO DECLARE


******** GEN **** PAGE 49
	1) GEN vs. 2) GEN[S,AIL]	SRCCOM	11-10-73	13:35	PAGES 49,50

1)	IFN 0 <
1)	GLOBA:	SKIPN	PNT,QQBLK		; GET THE HIGHEST BLOCK WITH DECLARATION
*** GEN[S,AIL] *** PAGE 50
2)	;;%AC% REMOVE  GLOBAL DECLARATION OPTION
2)	IFN 0 <
2)	;The following is how to declare an identifier in the outermost block.
2)	;Social pressures forced its removal from the error recovery, but I
2)	;thought I'd leave it around for a while in case the algorithm is needed
2)	;for another purpose. -kvl
2)	GLOBA:	SKIPN	PNT,QQBLK		; GET THE HIGHEST BLOCK WITH DECLARATION


******** GEN **** PAGE 49
1)	>;0
1)	 
*** GEN[S,AIL] *** PAGE 50
2)	>;  IFN 0
2)	 


******** GEN **** PAGE 50
1)			ERRPRI <UNDECLARED IDENTIFIER DECLARED A LABEL>
1)			JRST .+15]
*** GEN[S,AIL] *** PAGE 51
2)			TERPRI <UNDECLARED IDENTIFIER DECLARED A LABEL>
2)			JRST .+15]


******** GEN **** PAGE 50
1)			ERRPRI <UNDECLARED IDENTIFIER DECLARED A SET>
1)			JRST .+13]
*** GEN[S,AIL] *** PAGE 51
2)			TERPRI <UNDECLARED IDENTIFIER DECLARED A SET>
2)			JRST .+13]


******** GEN **** PAGE 50
1)			ERRPRI <UNDECLARED IDENTIFIER DECLARED AN ARRAY>
1)			JRST .+11]
*** GEN[S,AIL] *** PAGE 51
2)			TERPRI <UNDECLARED IDENTIFIER DECLARED AN ARRAY>
2)			JRST .+11]


******** GEN **** PAGE 50
1)			ERRPRI <UNDECLARED IDENTIFIER DECLARED A INTEGER PROCEDURE>
1)			JRST .+3]
*** GEN[S,AIL] *** PAGE 51
	1) GEN vs. 2) GEN[S,AIL]	SRCCOM	11-10-73	13:35	PAGES 50,51

2)			TERPRI <UNDECLARED IDENTIFIER DECLARED A INTEGER PROCEDURE>
2)			JRST .+3]


******** GEN **** PAGE 50
1)			ERRPRI	<UNDECLARED IDENTIFIER DECLARED AN INTEGER ITEMVAR>
1)			JRST .+1]
*** GEN[S,AIL] *** PAGE 51
2)			TERPRI	<UNDECLARED IDENTIFIER DECLARED AN INTEGER ITEMVAR>
2)			JRST .+1]