Trailing-Edge
-
PDP-10 Archives
-
BB-4157D-BM
-
sources/format.bli
There are 12 other files named format.bli in the archive. Click here to see a list.
!THIS SOFTWARE IS FURNISHED UNDER A LICENSE AND MAY ONLY BE USED
! OR COPIED IN ACCORDANCE WITH THE TERMS OF SUCH LICENSE.
!COPYRIGHT (C) 1972,1977 BY DIGITAL EQUIPMENT CORPORATION
!AUTHOR: T.E. OSTEN/FJI/HPW/DBT
MODULE FORMAT(RESERVE(0,1,2,3),SREG=#17,FREG=#16,VREG=#15,DREGS=4)=
BEGIN
GLOBAL BIND FORMV = 2^24+0^18+31; !VERSION DATE: 30-JUN-1974
%(
REVISION HISTORY
29 ----- ----- COMMENT OUT CODE WHICH SELECTIVELY ALLOWS OPTIONAL COMMAS
AND MAKE COMMAS ALWAYS OPTIONAL
30 ----- ----- ADD THE R FORMAT SPECIFICATION
)%
REQUIRE FMTLEX.BLI;
STRUCTURE STRING[I]=@(.STRING+.I);
STRUCTURE VECTX[I]=[I] .VECTX+.I;
BIND VECTOR FLEX=PLIT(
FLEXNAME GLOBALLY NAMES
%0% PLIT'ILLEGAL CHARACTER',
%1% PLIT'"$"',
%2% PLIT'LITSTRING',
%3% PLIT'"("',
%4% PLIT'")"',
%5% PLIT'END OF STATEMENT?0',
%6% PLIT'"+"',
%7% PLIT'","',
%8% PLIT'"-"',
%9% PLIT'"."',
%10% PLIT'"/"',
%11% PLIT'CONSTANT',
%12% PLIT'"A"',
%13% PLIT'"D"',
%14% PLIT'"E"',
%15% PLIT'"F"',
%16% PLIT'"G"',
%17% PLIT'"I"',
%18% PLIT'"L"',
%19% PLIT'"O"',
%20% PLIT'"P"',
%21% PLIT'"R"',
%22% PLIT'"T"',
%23% PLIT'"X"');
BIND LEFTBUILD = 0;
REQUIRE FRMBNF.BLI;
REQUIRE LOOKFM.BLI;
SWITCHES NOLIST;
REQUIRE FIRST.BLI;
SWITCHES LIST;
! BIND VECTX TYPE[0]= BNFTBL<24,12>,
! VECTX SUBP[0]= BNFTBL<12,12>,
! VECTX NUMBER[0]= BNFTBL<0,12>,
! VECTX LEXNUM[0]= BNFTBL<12,6>,
! VECTX OPNUM[0]= BNFTBL<18,6>;
STRUCTURE TYPSTR[I] = (.TYPSTR+.I)<24,12>;
STRUCTURE SUBSTR[I] = (.SUBSTR+.I)<12,12>;
STRUCTURE NUMSTR[I] = (.NUMSTR+.I)<0,12>;
BIND TYPSTR TYPE = BNFTBL,
SUBSTR SUBP = BNFTBL,
NUMSTR NUMBER = BNFTBL;
FORWARD
FORMATSYN,
ORERROR;
EXTERNAL LSAVE,LEXL,ISN,LEXICAL,FATLEX,WARNLEX,ENTRY,NAME;
EXTERNAL GSTFMTLEX;
% OWN NOCOMM; %
EXTERNAL E0,E2,E3,E70,E61;
% THE FOLLOWING TABLE IS ACCESSED BY LEXICAL( .GSTFMTLEX )
IN ORDER TO RETURN THE PROPER LEXEME CODE %
% THE CODES WHICH ACCESS THE NON-LETTER LEXEMES ARE THE STANDARD
LEXICAL CHARACTER CODES %
BIND DUMDUM = PLIT (
FMTLET GLOBALLY NAMES FMTLEX GLOBALLY NAMES
0, % ADJUSTMENT%
% "A"= #101 % ACHAR ^18+ %ILL % ILLCHAR ,
% "B"= #102 % ILLCHAR ^18+ %TAB % ILLCHAR ,
% "C"= #103 % ILLCHAR ^18+ %LT % ILLCHAR ,
% "D"= #104 % DCHAR ^18+ %BLANK % ILLCHAR ,
% "E"= #105 % ECHAR ^18+ %SPEC % ILLCHAR ,
% "F"= #106 % FCHAR ^18+ %DIGIT % CONST ,
% "G"= #107 % GCHAR ^18+ %UPPER % ILLCHAR ,
% "H"= #110 % ILLCHAR ^18+ %LOWER % ILLCHAR ,
% "I"= #111 % ICHAR ^18+ %FOS % LINEND ,
% "J"= #112 % ILLCHAR ^18+ %EOB % ILLCHAR ,
% "K"= #113 % ILLCHAR ^18+ %REMARK % ILLCHAR ,
% "L"= #114 % LCHAR ^18+ %ANDSGN % ILLCHAR ,
% "M"= #115 % ILLCHAR ^18+ %LPAREN % LPAREN ,
% "N"= #116 % ILLCHAR ^18+ %RPAREN % RPAREN ,
% "O"= #117 % OCHAR ^18+ %COLON % ILLCHAR ,
% "P"= #120 % PCHAR ^18+ %COMMA % COMMA ,
% "Q"= #121 % ILLCHAR ^18+ %DOLLAR % DOLLAR ,
% "R"= #122 % RCHAR ^18+ %MINUS % MINUS ,
% "S"= #123 % ILLCHAR ^18+ %SLASH % SLASH ,
% "T"= #124 % TCHAR ^18+ %PLUS % PLUS ,
% "U"= #125 % ILLCHAR ^18+ %ASTERISK% ILLCHAR ,
% "V"= #126 % ILLCHAR ^18+ %EQUAL % ILLCHAR ,
% "W"= #127 % ILLCHAR ^18+ %LTSGN % ILLCHAR ,
% "X"= #130 % XCHAR ^18+ %GTSGN % ILLCHAR ,
% "Y"= #131 % ILLCHAR ^18+ %NEQSGN % ILLCHAR ,
% "Z"= #132 % ILLCHAR ^18+ %DOT % PERIOD ,
%SEMICOL% ILLCHAR ,
%LITSGN % LITSTRING ,
%OCTSGN % ILLCHAR ,
%COMNTSGN% ILLCHAR ,
%DEBUGSGN% ILLCHAR ,
%UPAROW % ILLCHAR
);
% THE FOLLOWING BIND SPECIFIES THE LEXEMES FOR WHICH FOLLOWING COMMAS ARE
OPTIONAL %
% BIND OKNCM = 1^XCHAR + 1^LITSTRING + 1^SLASH ; %
GLOBAL ROUTINE FORMATSYN (STKNODE) =
BEGIN
EXTERNAL LEXICAL,GSTFMTLEX;
REGISTER NODE,SUBNODE,T2;
NO