MLP Restriction Language Syntax
 
* R E S E R V E D   S Y M B O L S
RESERVED ATOMICS (2)=MAT, SPWORD, SCOPEWORD.
RESERVED OPERATORS (3)= UPONE, DOWN, LEFT, RIGHT, UPTRN, DNTRN, VALUE, PRESENT, NELEM, AND, OR, NOT, IMPLY, ITER, ITERF, ITERT, ITERFT, CANDO, EXEC, EXECUTE, TRUE, RARE, REP, SEGMENT, REPARSE, PARSE, MINWD, INTERSECTOP, INTERSECTCHK, UNIONOP, COMPLEMENTOP, LOOK, STORE, IS, ATTRB, EDIT, TEXTX, ASSIGN, ERASE, HASATT, EMPTY, COMMONAT, GENER, STACK, WRITE, GENSYM, CREATE, COPY, BUILDDOWN, BUILDRIGHT, BUILDUP, REPLACE, INSERTAFTER, INSERTBEFORE, TRANSFORM, CLASS, BUILDWORD, DEACTIVATE, WORDL, PREVL, NEXTL, FRSTL, LASTL, NWORD, NODENAME, HEAD, SUCCESSORS, PREFIX, LOOKATLIST, LOOKATSYMBOL, MEMBER, TESTFORNIL, IDENTICAL, SETLOGSW, CLEARLOGSW, TESTLOGSW, TOGLOGSW, SUFFIX, SUFFIXUNIQ, PREFIXUNIQ, SETGLOBSW, CLEARGLOBSW, TESTGLOBSW, EQUIVMATCH, REPARSESW, CREATE-IDIOM, EVERY-NODE .
RESERVED ROUTINES (4)= STARTAT, NELEMRT, IMMEDIATE, INITIALRT, SUBSUMERT, LOOKAHEAD, $RARE, $REP.
RESERVED ATTRIBUTES (5)=ANYTHING, ROUTINE.
RESERVED TYPES (7)=ATOM.
RESERVED ORDINAL1 (31)=FIRST.
RESERVED ORDINAL2 (47)=SECOND.
RESERVED ORDINAL3 (63)=THIRD.
* S Y N T A X   O F   B N F
<DEFINITION>::='<' <*NAME> '>' ':' ':' '=' <DEFINER> '.' –→(<NAME> [NHEAD] <DEFINER>) .END.(1) |
'<' <*NAME> '>' '*' 'R' ':' ':' '=' <DEFINER> '.' –→(<NAME> [NHEAD], ( 1= (NIL [UNNHEAD] <DEFINER>), 2= (NIL [UNNHEAD], (NULL), (*1,*2) [($REP)])) , (NULL)) .END.(1) |
'<' <*NAME> '>' 'R' '*' ':' ':' '=' <DEFINER> '.' –→(<NAME> [NHEAD], (NULL), ( 3= (NIL [UNNHEAD] <DEFINER>), 4= (NIL [UNNHEAD], (NULL), (*3,*4) [($REP)]))) .END.(1).
<DEFINER>::=<OPTION> (' | ' <OPTION>)*.
<OPTION>::=['-'_($RARE)]1 <ELEMENT>2 (<ELEMENT>)*3 –→(#2:#3 [#1]).
<ELEMENT>::='<' <*NAME> '>' –→<NAME> .TYP.(1) |
'<' '*' <*NAME> '>' –→<NAME> .TYP.(2) |
'(' <DEFINER> ')' –→(NIL [UNNHEAD] <DEFINER>) |
'[' <DEFINER> ']' –→(NIL [UNNHEAD] <DEFINER>:((NULL))) |
<*NAME> –→<NAME> .TXT |
<*TEXT> –→<TEXT> |
<*TEXT> '_' <*TEXT>1 (<IDNODLIT>)*2 –→(<TEXT>:#1:#2).
<IDNODLIT>::='_' <*TEXT> –→<TEXT> .
* S Y N T A X   O F   L I S T S
<LIST>::=<TYPE-LIST> |
<ATTRIBUTE-LIST> |
<GLOBAL-LIST> |
<GENERAL-LIST>.
<TYPE-LIST>::=TYPE <*NAME> '=' <*NODE>1 (',' <*NODE>)*2 '.' –→(<NAME> [NHEAD] #1:#2) .END.(5).
<ATTRIBUTE-LIST>::=ATTRIBUTE '=' <ATT-LIST-ELEM>1 (',' <ATT-LIST-ELEM> )*2 '.' –→(ATTRIBUTE [NHEAD] #1:#2) .END.(5).
<ATT-LIST-ELEM>::=<*ATTRIBUTE> |
<*NAME> –→<NAME> .TYP.(5).
<GLOBAL-LIST>::=GLOBAL '=' <GLOB-LIST-ELEM>1 (',' <GLOB-LIST-ELEM>)*2 '.' –→(GLOBAL [NHEAD] #1:#2) .END.(5).
<GLOB-LIST-ELEM>::=<*ADDRESS> –→<ADDRESS> .TYP.(16).
<GENERAL-LIST>::=LIST <*NAME> '=' <LIST-ELEM-SEQ> '.' –→(<NAME> [NHEAD] <LIST-ELEM-SEQ>) .END.(5).
<LIST-ELEM-SEQ>::=<LIST-ELEM> (',' <LIST-ELEM>)*.
<LIST-ELEM>::=(<*ATTRIBUTE> |
<*TEXT> |
<*NODE>)1 [':' '(' <LIST-ELEM-SEQ> ')']2 –→(#1[#2]) |
'(' <LIST-ELEM-SEQ> ')' –→(<LIST-ELEM-SEQ>).
* S Y N T A X   O F   R O U T I N E S ,   R E S T R I C T I O N S,   AND
* T R A N S F O R M A T I O N S
<RLSENT>::=<ROUTINEDEF> |
<RESTRICTION> |
<ADDRSENT> |
<WORDRESTR>.
<RESTRICTION>::=<*NAME> '=' <HOUSING> <RESTRSENT> '.' –→(<NAME> [NHEAD] <HOUSING>:<RESTRSENT>) .END.(2).
<ROUTINEDEF>::=ROUTINE <*NAME> ['(' <REGLIST> ')']1 [LOCAL '(' <REGLIST> ')']2 '=' <RESTRSENT> '.' –→(<NAME> [NHEAD], ROUTINE, #1, #2): <RESTRSENT> .END.(4).
<REGLIST>::=<*REG>1 (',' <*REG>)*2 –→#1:#2.
<ADDRSENT>::=<*ADDRESS> '=' <RESTRSENT> '.' –→(<ADDRESS> [NHEAD] <RESTRSENT>) .END.(3).
<WORDRESTR>::=<*NAME> '=' <RESTRSENT> '.' –→(<NAME> [NHEAD] <RESTRSENT>) .END.(10).
<HOUSING>::=<INDEF> (<AFTERL> |
<REOPT> |
<*NULL>_(0))1 ':' –→(NIL [(<INDEF>,#1)]) .
<INDEF>::=IN <DEFTYP>1 (',' <DEFTYP>)*2 –→#1:#2.
<DEFTYP>::=<*DEF> |
<*TYPE> |
'(' ')' <*DEF> –→(<DEF> [1]).
<AFTERL>::=AFTER ( <*NODE> –→(4,<NODE>) |
<*NTH> ELEMENT –→(2,<NTH>) |
(OPTION |
OPTIONS) <OPTIONLIST> –→3:<OPTIONLIST>).
<REOPT>::=RE [OPTION |
OPTIONS] <OPTIONLIST> –→1:<OPTIONLIST>.
<OPTIONLIST>::=<*NODE>1 (',' <*NODE>)*2 –→#1:#2 |
<*INTEGER>1 (',' <*INTEGER>)*2 –→#1:#2.
<RESTRSENT>::=<RTESTLIST> (';' <RTESTLIST>)*.
<RTESTLIST>::=<RTEST> ( (WHERE |
WHEREAS |
WHILE) <RTEST> )*.
<RTEST>::=( (IN |
AT) <NSUBJ> [ ',' ] )* <RTEST1>.
<RTEST1>::=<SENTENCE> |
<*ADDRESS> IS TRUE –→(EXEC [<ADDRESS>]) |
<*ADDRESS> IS FALSE –→(NOT [<ADDRESS>]) |
[IT IS] NOT [CASE THAT] <RT> –→(NOT [<RT>]) |
IF <RT>1 [','] ['@'_1]3 THEN <RT>2 [ELSE <RT> –→(<RT>)]4 –→(IMPLY[(#1[#3],#2):#4]) |
EITHER <RT>1 [','] OR <RT>2 –→(OR[(#1,#2)]) |
BOTH <RT>1 [','] ['@'_1]3 AND <RT>2 –→(AND[(#1[#3],#2)]) |
NEITHER <RT>1 NOR <RT>2 –→(NOT[(OR[(#1,#2)])]) |
ONE OF <TESTSEQ> –→(OR[<TESTSEQ>]) |
ALL OF <TESTSEQ> –→(AND[<TESTSEQ>]) |
NONE OF <TESTSEQ> –→(NOT[(OR[<TESTSEQ>])]).
<RT>::=<*ADDRESS> [IS TRUE |
ARE TRUE] |
<RTESTLIST>.
<TESTSEQ>::=(<ADDRESS-COMMA>)* <*ADDRESS> [IS TRUE |
ARE TRUE].
<ADDRESS-COMMA>::=<*ADDRESS> ',' ['@'_1]1 –→(<ADDRESS>[#1]) .
<SENTENCE>::=<RSUBJ> <PREDICATE> |
<MONOSENT> |
<COMMAND> |
<TRANSFORM>.
* RSUBJ: SUBJECT OF RESTRICTION LANGUAGE SENTENCE
* Options are grouped according to whether they leave
* the restriction looking at a node (of the parse tree),
* a list element, or a sentence word:
*      NODESUBJ -- looks at a node of the parse tree
*      LISTSUBJ -- looks at a list element
*      NODEWORD -- looks at a sentence word SENTWORD
*      XSUBJ -- may look at a node, list element, or word
* Note that -ROUTINE- is made the last option, since
* any unclassified name will be accepted as a ROUTINE.
<RSUBJ>::=<NODESUBJ> |
<LISTSUBJ> |
<NODEWORD> <REGST> |
<SENTWORD> <REGST> |
<XSUBJ>.
<NODESUBJ>::=<*NODE> <REGST> [OF <NSUBJ>]1 –→#1:(EXECUTE[(STARTAT[((<NODE>))])]):<REGST> |
VALUE <REGST> [OF <NSUBJ>]1 –→#1:VALUE:<REGST> |
<*NTH> ELEMENT <REGST> [OF <NSUBJ>]1 –→#1 : (EXECUTE[(PRESENT-ELEMENT)], NELEM[<NTH>], EXECUTE[(NELEMRT)]) : <REGST> |
<*NTH> <*NODE> <REGST> [OF <NSUBJ>]1 –→#1 : (EXECUTE[(PRESENT-ELEMENT)], NELEM[(<NTH>[(<NODE>)])], EXECUTE[(NELEMRT)]) : <REGST>.
<LISTSUBJ>::=HEAD <REGST> [OF <LSUBJ>]1 –→#1 : HEAD : <REGST> |
SUCCESSORS <REGST> [OF <LSUBJ>]1 –→#1 : SUCCESSORS : <REGST> |
ATTRIBUTE-LIST <REGST> [OF <LSUBJ>]1 –→#1 : ATTRB : <REGST> |
NAME <REGST> OF <NSUBJ> –→<NSUBJ> : NODENAME : <REGST> |
LIST <*TYPE> –→(LOOKATLIST[<TYPE>]) |
SYMBOL (<*NODE> |
<*ATTRIBUTE>)1 –→(LOOKATSYMBOL[#1]) |
NIL –→(LOOKATSYMBOL).
<NODEWORD>::=WORD (PRECEDING –→(FRSTL, PREVL) |
STARTING –→(FRSTL) |
ENDING –→(LASTL, PREVL) |
FOLLOWING –→(LASTL) ) PRESENT NODE.
<SENTWORD>::=CURRENT WORD –→(WORDL) |
PRECEDING WORD –→(WORDL, PREVL) |
NEXT WORD –→(WORDL, NEXTL).
<XSUBJ>::=<*REG> –→(LOOK[<REG>]) |
(PRESENT-ELEMENT- |
PRESENT-STRING- |
IT-) <REGST> –→ <REGST> |
<ROUTINE> [<*NODE>_((<NODE>)) |
<*TYPE>_(<TYPE>) |
'(' <ARGLIST> ')']1 <REGST> [OF <NSUBJ>]2 –→#2:(EXECUTE[(<ROUTINE> [#1])]):<REGST> .
<ROUTINE>::=<*NAME> –→<NAME> .TYP.(4).
<REGST>::=<*REG> –→(STORE [<REG>]) |
<*NULL>.
* LSUBJ: SUBJECTS WHICH MAY LOOK AT A LIST ELEMENT
<LSUBJ>::=<LISTSUBJ> |
<XSUBJ>.
* NSUBJ: SUBJECTS WHICH MAY LOOK AT A NODE
<NSUBJ>::=<NODESUBJ> |
<XSUBJ>.
<PREDICATE>::=IS <BEPRED> <REGST> |
IS NOT <BEPRED> –→(NOT [<BEPRED>]) |
HAS <HAVEPRED> <REGST> |
DOES NOT HAVE <HAVEPRED> –→(NOT [<HAVEPRED>]) |
EXISTS |
IS OCCURRING (IN |
AS) <OCCPRED> <REGST> |
IS NOT OCCURRING (IN |
AS) <OCCPRED> –→(NOT [<OCCPRED>]) |
DOES NOT OCCUR (IN |
AS) <OCCPRED> –→(NOT [<OCCPRED>]) |
SUBSUMES <SUBPRED> |
DOES NOT SUBSUME <SUBPRED> –→(NOT [<SUBPRED>]).
<BEPRED>::=<ATOM-ATT> |
<ATTRB> |
<*DEF>1 (OR <*DEF>)*2 –→(IS[#1:#2]) |
<*REG> –→(IS[<REG>]) |
IDENTICAL TO <*REG> –→(IDENTICAL [<REG>]) |
<TEXT-LIST> |
OF TYPE <*TYPE> –→(IS[<TYPE>]) |
EMPTY –→(EMPTY) |
NIL –→(TESTFORNIL) |
C-REDUNDANT –→(EXECUTE[(C-REDUNDANT)]) |
ELEMENT OF <OR-NODE> –→(EXECUTE[(ELEMOF[(<OR-NODE>)])]) |
CORE OF <OR-NODE> –→(EXECUTE[(IMMEDIATE[(<OR-NODE>)])]) |
STRING INITIAL –→(EXECUTE[(INITIALRT)]) .
<HAVEPRED>::=VALUE <OR-NODE> –→(VALUE, IS[<OR-NODE>]) |
ATTRIBUTE <ATT> |
NODE ATTRIBUTE <*ATTRIBUTE> –→(HASATT[<ATTRIBUTE>]) |
MEMBER <ATTRB-LIST> –→(MEMBER[<ATTRB-LIST>]) |
ATTRIBUTE-LIST –→ATTRB |
<ROUTINE> [<OR-NODE> –→(<OR-NODE>)]1 –→(EXECUTE[(<ROUTINE>[#1])]).
<OCCPRED>::=<OR-NODE> –→(EXECUTE[(IMMEDIATE[(<OR-NODE>)])]).
<SUBPRED>::=(<ATOM-ATT> |
<TEXT-LIST>)1 –→(EXECUTE[(SUBSUMERT[(#1)])]).
<OR-NODE>::=<*NODE>1 (OR <*NODE>)*2 –→#1:#2 |
<*TYPE>.
<ATOM-ATT>::=<ATOM-LIST> [':' <ATT>]1 –→(IS[<ATOM-LIST>]):#1.
<ATT>::=<ATTRB-LIST> [':' <ATT>]1 –→(ATTRB[<ATTRB-LIST>]):#1.
<ATTRB>::=<*ATTRIBUTE>1 (OR <*ATTRIBUTE>)*2 [':' <ATT>]3 –→(ATTRB[#1:#2]):#3.
<ATOM-LIST>::=<*ATOM>1 (OR <*ATOM>)*2 –→#1:#2.
<ATTRB-LIST>::=<*REG> |
(<*ATTRIBUTE> |
<*TEXT> |
<*NODE>)1 (OR (<*ATTRIBUTE> |
<*TEXT> |
<*NODE>))*2 –→#1:#2 |
<*TYPE>.
<TEXT-LIST>::=<TEXTTEST> |
<XTEXT>1 OR <XTEXT>2 (OR <XTEXT>)*3 –→(OR[#1:#2:#3]).
<TEXTTEST>::=<*TEXT> (<IDTEXT>)*1 –→(TEXTX[<TEXT>:#1]) .
<IDTEXT>::='_' <*TEXT> –→<TEXT> .
<XTEXT>::=<TEXTTEST> –→(<TEXTTEST>).
<MONOSENT>::=RARE SWITCH IS (ON –→(RARE) |
OFF –→(NOT[(RARE)])) |
REP SWITCH IS (ON –→(REP) |
OFF –→(NOT[(REP)])) |
REPARSE SWITCH IS (ON –→(REPARSESW) |
OFF –→(NOT[(REPARSESW)])) |
NON-LOCAL SWITCH <*INTEGER>1 IS ON –→(TESTGLOBSW[#1]) |
NON-LOCAL SWITCH <*INTEGER>1 IS OFF –→(NOT[(TESTGLOBSW[#1])]) |
SEGMENT SWITCH IS (ON –→(SEGMENT) |
OFF –→(NOT[(SEGMENT)])) |
REPARSE –→(REPARSE[0]) |
REPARSE WITH NEXT SEGMENT –→(REPARSE[1]) |
REPARSE WITH PREVIOUS SEGMENT –→(REPARSE[2]) |
PARSE HAS BEEN OBTAINED –→(PARSE) |
THERE IS (<ATOM-ATT> |
<TEXT-LIST>)1 AHEAD –→(EXECUTE [(LOOKAHEAD[(#1)])]) |
THERE ARE AT LEAST <*INTEGER> WORDS AHEAD –→(NWORD[<INTEGER>]) |
EDIT BY <*ADDRESS> –→(EDIT [<ADDRESS>]) |
ASSIGN [PRESENT (ELEMENT | STRING)] NODE ATTRIBUTE <*ATTRIBUTE> [WITH VALUE <NSUBJ> –→ (CANDO [<NSUBJ>:(STORE[X0])])]1 –→#1 : (ASSIGN[<ATTRIBUTE>]) |
ERASE NODE ATTRIBUTE <*ATTRIBUTE> –→(ERASE[<ATTRIBUTE>]) |
THIS IS MIN WORD –→(MINWD) |
LISTS <NSUBJ>1 AND <NSUBJ>2 HAVE COMMON ATTRIBUTE –→(COMMONAT[(#1,#2)]) |
LISTS <NSUBJ>1 AND <NSUBJ>2 HAVE NO COMMON ATTRIBUTE –→(NOT[(COMMONAT[(#1,#2)])]).
<COMMAND>::=GO <WHERE> |
<*REG> ':' '=' <RSUBJ> –→<RSUBJ> : (STORE[<REG>]) |
PREFIX <*REG>1 [':' <*REG>]2 TO <*REG>3 –→ (LOOK[#3], PREFIX[(#1[#2])], STORE[#3]) |
PREFIX UNIQUELY <*REG>1 [':' <*REG>]2 TO <*REG>3 –→ (LOOK[#3], PREFIXUNIQ[(#1[#2])], STORE[#3]) |
SUFFIX <*REG>1 [':' <*REG>]2 TO <*REG>3 –→ (LOOK[#3], SUFFIX[(#1[#2])], STORE[#3]) |
SUFFIX UNIQUELY <*REG>1 [':' <*REG>]2 TO <*REG>3 –→ (LOOK[#3], SUFFIXUNIQ[(#1[#2])], STORE[#3]) |
DESCEND TO <ROUTARG>1 [PASSING THROUGH <ROUTARG>]2 [NOT PASSING THROUGH <ROUTARG>]3 –→(DNTRN[(#1,#2,#3)]) |
ASCEND TO <ROUTARG>1 [PASSING THROUGH <ROUTARG>]2 [NOT PASSING THROUGH <ROUTARG>]3 –→(UPTRN[(#1,#2,#3)]) |
STACK –→(STACK) |
STORE IN <*REG> –→(STORE [<REG>]) |
<ITERATOR> |
<WRITE-CMD> |
TRUE –→(TRUE) |
FALSE –→(NOT[(TRUE)]) |
GENERATE OPTION SPANNING <*REG>1 TO <*REG>2 –→(GENER[(#1,#2)]) |
GENERATE SYMBOL –→(GENSYM) |
<DO-CMD> |
VERIFY <RT> –→(CANDO [<RT>]) |
TEST FOR(<ROUTARG> –→(IS[<ROUTARG>]) |
<*ATTRIBUTE> –→(IS[(<ATTRIBUTE>)]) ) |
EQUIV-MATCH USING (<*REG> |
<*NAME>)1 OF ATT-LISTS <EQIN-REGS>2 INTO <EQOUT-REGS>3 [WITH REJECTION SET (<*REG> |
<*NAME>)]4 –→(EQUIVMATCH[(#1,#2,#3,#4)]) |
INTERSECT <*REG>1 WITH <*REG>2 INTO <*REG>3 –→(INTERSECTOP[(#1,#2,#3)]) |
INTERSECT <*REG>1 WITH <*REG>2 –→(INTERSECTOP[(#1,#2)]) |
INTERSECT-CHK <*REG>1 WITH <*REG>2 –→(INTERSECTCHK[(#1,#2)]) |
UNION <*REG>1 WITH <*REG>2 INTO <*REG>3 –→(UNIONOP[(#1,#2,#3)]) |
COMPLEMENT <*REG>1 WITH <*REG>2 INTO <*REG>3 –→(COMPLEMENTOP[(#1,#2,#3)]) |
FOR EVERY NODE DO <*ADDRESS> –→(EVERY-NODE[<ADDRESS>]) |
SET LOGIC SWITCH <*INTEGER> –→(SETLOGSW[<INTEGER>]) |
CLEAR LOGIC SWITCH <*INTEGER> –→(CLEARLOGSW[<INTEGER>]) |
CLEAR LOGIC (SWITCH |
SWITCHES) ALL –→(CLEARLOGSWALL) |
TOGGLE LOGIC SWITCH <*INTEGER> –→(TOGLOGSW[<INTEGER>]) |
TEST LOGIC SWITCH <*INTEGER> –→(TESTLOGSW[<INTEGER>]) |
SET NON-LOCAL SWITCH <*INTEGER> –→(SETGLOBSW[<INTEGER>]) |
CLEAR NON-LOCAL SWITCH <*INTEGER> –→(CLEARGLOBSW[<INTEGER>]) |
CREATEIDIOM WITH DEFINITION OF <*REG>1 –→(CREATE-IDIOM[#1]) .
<WHERE>::=UP –→(UPONE) |
DOWN –→(DOWN) |
LEFT –→(LEFT) |
RIGHT –→(RIGHT) |
TO (<NODEWORD> |
<*REG> –→(LOOK[<REG>]) |
CURRENT WORD –→(WORDL) |
PRECEDING WORD –→(PREVL) |
NEXT WORD –→(NEXTL) ) .
<EQIN-REGS>::=(<*REG>)*1 –→#1 .
<EQOUT-REGS>::=(<*REG>)*1 –→#1 .
<ITERATOR>::=ITERATE <RT> –→(ITER [(<RT>)]) |
ITERATE <RT>1 UNTIL <RT>2 SUCCEEDS –→(ITER[(#1,#2)]) |
ITERATE <RT>1 UNTIL <RT>2 FAILS –→(ITERF[(#1,#2)]) |
ITERATET <RT>1 UNTIL <RT>2 SUCCEEDS –→(ITERT[(#1,#2)]) |
ITERATET <RT>1 UNTIL <RT>2 FAILS –→(ITERFT[(#1,#2)]) .
<DO-CMD>::=DO (<*ADDRESS> |
<*REG>)1 –→(EXEC[#1]) |
DO <ROUTINE> [ '(' <ARGLIST> ')' ]1 –→(EXECUTE[(<ROUTINE>[#1])]) .
<ARGLIST>::=<ARG> (',' <ARG>)*.
<ARG>::=<ROUTARG> –→(<ROUTARG>).
<WRITE-CMD>::=WRITE ON (DIAG –→1 |
INFO –→2 |
STD –→3)1 (<*TEXT> |
IDENTIFICATION –→1 |
NODE NAME –→2 |
LIST ELEMENT –→2 |
WORD –→2 |
WORDS SUBSUMED –→3 |
END OF LINE –→4 |
SENTEXT –→5 |
LIST –→6 |
PARSE TREE (WITH WORD FORMS –→7 |
<*NULL> –→8) |
PARSE SUBTREE –→9 )2 –→(WRITE[(#1,#2)]) .
<ROUTARG>::=<*NODE>1 (OR <*NODE>)*2 –→#1:#2 |
[TYPE] <*TYPE> |
<*REG>.
<TRANSFORM>::=TRANSFORM <NSUBJ> –→<NSUBJ> : TRANSFORM |
DEACTIVATE –→(DEACTIVATE) |
REPLACE <NSUBJ> BY <STRUCTURE> –→<STRUCTURE> : <NSUBJ> : REPLACE |
DELETE <NSUBJ> –→<NSUBJ> : REPLACE |
BEFORE <NSUBJ> INSERT <STRUCTURE> –→<STRUCTURE> : <NSUBJ> : INSERTBEFORE |
AFTER <NSUBJ> INSERT <STRUCTURE> –→<STRUCTURE> : <NSUBJ> : INSERTAFTER .
<STRUCTURE>::=<ITEM> (<FOLLOWING-ITEM>)*.
<CHILDREN>::='(' <STRUCTURE> ')' –→<STRUCTURE> : BUILDUP .
<ITEM>::='<' <*NODE> '>' <REGST> <WATT> [<CHILDREN>]1 –→(CANDO[ (CREATE[<NODE>]):<REGST>]):BUILDDOWN: <WATT>:#1 |
<*TEXT> <REGST> –→(CANDO[ (CREATE[<TEXT>]):<REGST> ]):BUILDDOWN |
<CLASS-SPEC> –→<CLASS-SPEC> : BUILDDOWN |
<NSUBJ> <CREGST> <CHILDREN> –→(CANDO [<NSUBJ> : COPY : <CREGST> ]) : BUILDDOWN : <CHILDREN> |
<NSUBJ> <CREGST> –→(CANDO [ <NSUBJ> : (COPY[1]) : <CREGST> ]) : BUILDDOWN |
ALL ELEMENTS OF <NSUBJ> –→(CANDO [<NSUBJ>:VALUE:(CANDO[( COPY[1])], BUILDDOWN, ITERFT [((CANDO[(COPY[1], BUILDRIGHT)]), (RIGHT))])]).
<FOLLOWING-ITEM>::='+' ( '<' <*NODE> '>' <REGST> <WATT> [<CHILDREN>]1 –→(CANDO[ (CREATE[<NODE>]):<REGST> ]):BUILDRIGHT: <WATT>:#1 |
<*TEXT> <REGST> –→(CANDO[ (CREATE[<TEXT>]):<REGST> ]):BUILDRIGHT |
<CLASS-SPEC> –→<CLASS-SPEC> : BUILDRIGHT |
<NSUBJ> <CREGST> <CHILDREN> –→(CANDO [<NSUBJ> : COPY : <CREGST> ]) : BUILDRIGHT : <CHILDREN> |
<NSUBJ> <CREGST> –→(CANDO [ <NSUBJ> : (COPY[1]) : <CREGST> ]) : BUILDRIGHT |
ALL ELEMENTS OF <NSUBJ> –→(CANDO [ <NSUBJ> : VALUE : (ITERF [((CANDO [(COPY[1], BUILDRIGHT)] ), (RIGHT))] )] ) ).
<CREGST>::=',' <*REG> –→(STORE [<REG>]) |
<*NULL>.
<CLASS-SPEC>::= CLASS <*ATOM> ':' '(' <ATTRIBS>1 (',' <ATTRIBS>)*2 ')' OF <NSUBJ> <CREGST> –→(CANDO [<NSUBJ> : (CLASS[(<ATOM>[#1:#2 ])]) : <CREGST>]) |
CLASS <*ATOM> ':' <*REG> OF <NSUBJ> <CREGST> –→(CANDO [<NSUBJ> : (CLASS [(<ATOM> [ <REG>])]) : <CREGST>]) |
CLASS <*ATOM> OF <NSUBJ> <CREGST> –→(CANDO [<NSUBJ> : (CLASS[<ATOM>]) : <CREGST>]).
<ATTRIBS>::=<*ATTRIBUTE>1 ':' '(' <*ATTRIBUTE>2 (',' <*ATTRIBUTE>)*3 ')' –→(#1[#2:#3]) |
<*ATTRIBUTE> –→<ATTRIBUTE> .
<WATT>::='=' (<*NAME> –→<NAME> .TXT |
<*TEXT>)1 [':' '(' <NATTRBL> ')']2 ['^' '(' <NATTRBL> ')']3 –→(BUILDWORD [(#1[#2]):#3] ) |
<*NULL>.
* S Y N T A X   O F   W O R D   D I C T I O N A R Y
<WDWORDSENT>::=<WORDDEFN> |
<WDLIST> .
<WORDDEFN>::=<WORD> [<NATTRBL>]1 '.' –→(<WORD> [NHEAD] #1) .END.(6) |
<WORD> '(' <*NAME> ')' '.' –→(<WORD> [NHEAD] <NAME>) .END.(8).
<WORD>::=(<*NAME> |
<*TEXT>)1 (<IDIOM-WORD>)* ['^' –→.DERIV] –→ #1.
<IDIOM-WORD>::='_' (<*NAME> | <*TEXT>)1 –→#1 .IDIOM.
<NATTRBL>::=<ATNODE> (',' <ATNODE>)*.
<ATNODE>::=(<*ATTRIBUTE> |
<*TEXT> |
<*NODE>)1 [':' (<*LINO> | '(' <NATTRBL> ')')]2 –→(#1[#2]) |
'(' <NATTRBL> ')' –→(<NATTRBL>).
<WDLIST>::=<*LINO> '=' <NATTRBL> '.' –→(<LINO> [NHEAD] <NATTRBL>) .END.(7).
<WDCANSENT>::='(' <*NAME> ')' '=' <NATTRBL> '.' –→ (<NAME> [NHEAD] <NATTRBL>) .END.(9).