summaryrefslogtreecommitdiff
path: root/support/splint/examples/ld/ldgram.w
diff options
context:
space:
mode:
Diffstat (limited to 'support/splint/examples/ld/ldgram.w')
-rw-r--r--support/splint/examples/ld/ldgram.w202
1 files changed, 137 insertions, 65 deletions
diff --git a/support/splint/examples/ld/ldgram.w b/support/splint/examples/ld/ldgram.w
index 4fb9a9a876..5e7ff73a03 100644
--- a/support/splint/examples/ld/ldgram.w
+++ b/support/splint/examples/ld/ldgram.w
@@ -1,4 +1,4 @@
-@q Copyright 2012-2015 Alexander Shibakov@>
+@q Copyright 2012-2020 Alexander Shibakov@>
@q Copyright 2002-2014 Free Software Foundation, Inc.@>
@q This file is part of SPLinT@>
@@ -16,10 +16,10 @@
@q along with SPLinT. If not, see <http://www.gnu.org/licenses/>.@>
@** The parser.
-\ifx\parsernamespace\UNDEFINED
+\ifbootstrapmode
\def\tokendeffile{ldp.tok}%
\input ldman.sty
- \input limbo.sty
+ \modebootstrap
\input dcols.sty
\setupfootnotes
\def\MRI{}
@@ -334,20 +334,23 @@ script commands.
@G
script_file:
{@>@[TeX_( "/ldlex@@both" );@]@=}
- ifile_list {@>@[TeX_( "/getsecond{/yy(2)}/to/ldcmds/ldlex@@popstate" );@]@=}
+ ifile_list {@>@[TeX_( "/getfifth{/yy(2)}/to/ldcmds/ldlex@@popstate" );@]@=}
;
ifile_list:
ifile_list ifile_p1 {@>@<Add the next command@>@=}
- | {@>@[TeX_( "/yy0{{}{}}" );@]@=}
+ | {@>@[TeX_( "/yy0{/nx/ldinsertcweb{}{}{}{}}" );@]@=}
;
@g
@ @<Add the next command@>=
- @[TeX_( "/getfirst{/yy(1)}/to/toksa/getsecond{/yy(1)}/to/toksb" );@]@;
- @[TeX_( "/getfirst{/yy(2)}/to/toksc/getsecond{/yy(2)}/to/toksd" );@]@;
- @[TeXb( "/yytoksempty{/toksb}{/yy0{/the/yy(2)}}" );@]@;
- @[TeXao( "{/yy0{{/the/toksc}{/the/toksb/noexpand/ldcommandseparator{/the/toksa}{/the/toksc}/the/toksd}}}" );@]@;
+ @[TeX_( "/getsecond{/yy(1)}/to/toksa/getthird{/yy(1)}/to/toksb" );@]@;
+ @[TeX_( "/getfourth{/yy(1)}/to/toksc/getfifth{/yy(1)}/to/toksd" );@]@;
+ @[TeX_( "/getsecond{/yy(2)}/to/tokse/getthird{/yy(2)}/to/toksf" );@]@;
+ @[TeX_( "/getfourth{/yy(2)}/to/toksg/getfifth{/yy(2)}/to/toksh" );@]@;
+ @[TeXb( "/yytoksempty{/toksh}{/yy0{/the/yy(1)}}{/yytoksempty{/toksd}{/yy0{/the/yy(2)}}" );@]@;
+ @[TeXf( " {/yy0{/nx/ldinsertcweb{/the/toksa}{/the/toksb}{/the/toksg}{/the/toksd" );@]@;
+ @[TeXfo( " /nx/ldcommandseparator{/the/tokse}{/the/toksf}{/the/toksc}{/the/toksg}/the/toksh}}}}" );@]@;
@*1 Script internals.
There are a number of different commands. For typesetting purposes,
@@ -377,16 +380,16 @@ the rule that adds the fragment to the script file.
@<\GNU\ \ld\ script rules@>=
@G
ifile_p1:
- memory {@>@[TeX_( "/yy0{{mem}{/the/yy(1)}}" );@]@=}
- | sections {@>@[TeX_( "/yy0{{sect}{/the/yy(1)}}" );@]@=}
+ memory {@>@<Carry on@>@=}
+ | sections {@>@<Carry on@>@=}
| phdrs
| startup
| high_level_library
| low_level_library
| floating_point_support
- | statement_anywhere {@>@[TeX_( "/yy0{{stmt}{/noexpand/ldstatement{/the/yy(1)}}}" );@]@=}
+ | statement_anywhere {@>@<Carry on@>@=}
| version
- | ';' {@>@[TeX_( "/yy0{{none}{}}" );@]@=}
+ | ';' {@>@[TeX_( "/yy0{/nx/ldinsertcweb/the/yy(1){none}{}}" );@]@=}
| TARGET_K '(' NAME ')' {}
| SEARCH_DIR '(' filename ')' {}
| OUTPUT '(' filename ')' {}
@@ -401,7 +404,7 @@ ifile_p1:
'(' input_list ')' {}
| MAP '(' filename ')' {}
| INCLUDE filename {@>@<Peek at a file@>@=}
- ifile_list END {@>@<Add an \prodstyle{INCLUDE} statement@>@=}
+ ifile_list END {@>@<Close the file@>@=}
| NOCROSSREFS '('
nocrossref_list ')' {}
| EXTERN '(' extern_name_list ')'
@@ -427,30 +430,39 @@ input_list:
;
sections:
- SECTIONS '{' sec_or_group_p1 '}' {@>@[TeX_( "/yy0{/noexpand/ldsections{/the/yy(3)}}" );@]@=}
+ SECTIONS '{' sec_or_group_p1 '}' {@>@<Form the \prodstyle{SECTIONS} group@>@=}
;
sec_or_group_p1:
- sec_or_group_p1 section {@>@<Add the next section@>@=}
- | sec_or_group_p1 statement_anywhere {@>@<Add the next statement@>@=}
+ sec_or_group_p1 section {@>@<Add the next section chunk@>@=}
+ | sec_or_group_p1 statement_anywhere {@>@<Add the next section chunk@>@=}
| {@>@[TeX_( "/yy0{}" );@]@=}
;
statement_anywhere:
- ENTRY '(' NAME ')' {}
- | assignment end {@>@<Carry on@>@=}
+ ENTRY '(' NAME ')' {@>@<Form an \prodstyle{ENTRY} statement@>@=}
+ | assignment end {@>@<Form a statement@>@=}
| ASSERT_K {@>@[TeX_( "/ldlex@@expression" );@]@=}
'(' exp ',' NAME ')' {@>@[TeX_( "/ldlex@@popstate" );@]@=}
;
@g
-@ @<Add the next section@>=
- @[TeXb( "/yytoksempty{/yy(1)}{/yy0{/the/yy(2)}}" );@]@;
- @[TeXao( "{/yy0{/the/yy(1)/noexpand/ldsectionseparator/the/yy(2)}}" );@]@;
+@ @<Form the \prodstyle{SECTIONS} group@>=
+ @[TeX_( "/yy0{/nx/ldinsertcweb/the/yy(1){sect}{/nx/ldsections{/the/yy(3)/nx/ldsectionstash/the/yy(4)}}}" );@]
-@ @<Add the next statement@>=
- @[TeXb( "/yytoksempty{/yy(1)}{/yy0{/the/yy(2)}}" );@]@;
- @[TeXao( "{/yy0{/the/yy(1)/noexpand/ldsectionseparator/ldstatement{/the/yy(2)}}}" );@]@;
+@ @<Add the next section chunk@>=
+ @[TeX_( "/getsecond{/yy(2)}/to/tokse/getthird{/yy(2)}/to/toksf" );@]@;
+ @[TeX_( "/getfourth{/yy(2)}/to/toksg/getfifth{/yy(2)}/to/toksh" );@]@;
+ @[TeXb( "/yytoksempty{/yy(1)}{/yy0{/nx/ldsectionstash{/the/tokse}{/the/toksf}/the/toksh}}" );@]@;
+ @[TeXfo( " {/yy0{/the/yy(1)/nx/ldsectionseparator{/the/tokse}{/the/toksf}/the/toksh}}" );@]@;
+
+@ @<Form an \prodstyle{ENTRY} statement@>=
+ @[TeX_( "/yy0{/nx/ldinsertcweb/the/yy(1){stmt}{/nx/ldstatement{/nx/ldentry{/nx/ldregexp{/the/yy(3)}}}}}" );@]
+
+@ @<Form a statement@>=
+ @[TeXb( "/getsecond{/yy(1)}/to/toksa/getthird{/yy(1)}/to/toksb" ); @]@;
+ @[TeXf( "/getfourth{/yy(1)}/to/toksc/getfifth{/yy(1)}/to/toksd" );@]@;
+ @[TeXfo( "/yy0{/nx/ldinsertcweb{/the/toksa}{/the/toksb}{stmt}{/nx/ldstatement{/the/toksd}}}" );@]
@ This is the default action performed by the parser when the parser
writer does not supply one. For a minor gain in efficiency, this
@@ -463,28 +475,25 @@ definition can be made empty.
@[TeX_( "/ldfile@@open@@command@@file{/yy(2)}" );@]@;
@ @<Close the file@>=
- @[TeX_( "/yy0{/noexpand/ldinclude{/the/yy(2)}}/ldlex@@popstate" );@]@;
-
-@ @<Add an \prodstyle{INCLUDE} statement@>=
- @[TeX_( "/yy0{{inc}{/noexpand/ldinclude{/the/yy(2)}}}/ldlex@@popstate" );@]@;
+ @[TeX_( "/yy0{/nx/ldinsertcweb/the/yy(1){inc}{/nx/ldinclude{/the/yy(2)}}}/ldlex@@popstate" );@]@;
@ \tracebadcharstrue
-{\it The \prodstyle{'*'} and \prodstyle{'?'} cases are there because the lexer returns them as
+{\it \setrulecontext{wildcard_name}The \prodstyle{'*'} and \prodstyle{'?'} cases are there because the lexer returns them as
separate tokens rather than as \prodstyle{NAME}.}
\tracebadcharsfalse
@<Grammar rules@>=
@G
wildcard_name:
- NAME {@>@<Carry on@>@=}
- | '*' {@>@[TeX_( "/yy0{{*}{*}}" );@]@=}
- | '?' {@>@[TeX_( "/yy0{{?}{?}}" );@]@=}
+ NAME {@>@<Create a wildcard name@>@=}
+ | '*' {@>@[TeX_( "/yy0{/nx/ldinsertcweb/the/yy(1){wld}{/nx/ldregop{{*}{*}/the/yy(1)}}}" );@]@=}
+ | '?' {@>@[TeX_( "/yy0{/nx/ldinsertcweb/the/yy(1){wld}{/nx/ldregop{{?}{?}/the/yy(1)}}}" );@]@=}
;
@g
@ @<Grammar rules@>=
@G
wildcard_spec:
- wildcard_name {}
+ wildcard_name {@>@<Carry on@>@=}
| EXCLUDE_FILE '(' exclude_name_list ')' wildcard_name
{}
| SORT_BY_NAME '(' wildcard_name ')' {}
@@ -525,8 +534,8 @@ exclude_name_list:
;
file_NAME_list:
- file_NAME_list opt_comma wildcard_spec {@>@[TeX_( "/yy0{/the/yy(1)/noexpand/ldspace/noexpand/ldregexp{/the/yy(2)}}" );@]@=}
- | wildcard_spec {@>@[TeX_( "/yy0{/noexpand/ldregexp{/the/yy(1)}}" );@]@=}
+ file_NAME_list opt_comma wildcard_spec {@>@<Add a wildcard spec to a list of files@>@=}
+ | wildcard_spec {@>@<Start a file list with a wildcard spec@>@=}
;
input_section_spec_no_keep:
@@ -534,51 +543,83 @@ input_section_spec_no_keep:
| sect_flags NAME {}
| '[' file_NAME_list ']' {}
| sect_flags '[' file_NAME_list ']' {}
- | wildcard_spec '(' file_NAME_list ')' {@>@[TeX_( "/yy0{/noexpand/ldregexp{/the/yy(1)}(/the/yy(3))}" );@]@=}
+ | wildcard_spec '(' file_NAME_list ')' {@>@<Add a plain section spec@>@=}
| sect_flags wildcard_spec '(' file_NAME_list ')'
{}
;
@g
+@ @<Create a wildcard name@>=
+ @[TeXf( "/getthird{/yy(1)}/to/toksa/getfourth{/yy(1)}/to/toksb" );@]@;
+ @[TeX_( "/yy0{/nx/ldinsertcweb{/the/toksa}{/the/toksb}{wld}{/nx/ldregexp{/the/yy(1)}}}" );@]
+
+@ @<Add a wildcard spec to a list of files@>=
+ @[TeX_( "/getsecond{/yy(1)}/to/toksa/getthird{/yy(1)}/to/toksb" );@]@;
+ @[TeX_( "/getfourth{/yy(1)}/to/toksc/getfifth{/yy(1)}/to/toksd" );@]@;
+ @[TeX_( "/getsecond{/yy(2)}/to/tokse/getthird{/yy(2)}/to/toksf" );@]@;
+ @[TeX_( "/getfourth{/yy(2)}/to/toksg/getfifth{/yy(2)}/to/toksh" );@]@;
+ @[TeX_( "/yy0{/nx/ldinsertcweb{/the/toksa}{/the/toksb}{flst}{/the/toksd/nx/ldspace/the/toksh}}" );@]
+
+@ @<Start a file list with a wildcard spec@>=
+ @<Carry on@>@;
+
+@ @<Add a plain section spec@>=
+ @[TeX_( "/getsecond{/yy(1)}/to/toksa/getthird{/yy(1)}/to/toksb" );@]@;
+ @[TeX_( "/getfourth{/yy(1)}/to/toksc/getfifth{/yy(1)}/to/toksd" );@]@;
+ @[TeX_( "/getfifth{/yy(3)}/to/toksh" );@]@;
+ @[TeX_( "/yy0{/nx/ldinsertcweb{/the/toksa}{/the/toksb}{sspec}{/the/toksd(/the/toksh)}}" );@]
+
@ @<Grammar rules@>=
@G
input_section_spec:
input_section_spec_no_keep {@>@<Carry on@>@=}
| KEEP '(' {}
- input_section_spec_no_keep ')' {@>@[TeX_( "/yy0{/mathop{/hbox{/noexpand/ttl keep}(/the/yy(4))}}" );@]@=}
+ input_section_spec_no_keep ')' {@>@<Add a \prodstyle{KEEP} statement@>@=}
;
statement:
- assignment end
+ assignment end {@>@<Form a statement@>@=}
| CREATE_OBJECT_SYMBOLS {}
- | ';' {@>@[TeX_( "/yy0{}" );@]@=}
+ | ';' {@>@[TeX_( "/yy0{/nx/ldinsertcweb/the/yy(1){stmt}{}}" );@]@=}
| CONSTRUCTORS {}
| SORT_BY_NAME '(' CONSTRUCTORS ')' {}
- | input_section_spec
+ | input_section_spec {@>@<Form an input section spec@>@=}
| length '(' mustbe_exp ')' {}
| FILL '(' fill_exp ')' {}
| ASSERT_K {@>@[TeX_( "/ldlex@@expression" );@]@=}
'(' exp ',' NAME ')' end {@>@[TeX_( "/ldlex@@popstate" );@]@=}
| INCLUDE filename {@>@<Peek at a file@>@=}
- statement_list_opt END {@>@<Close the file@>@=}
+ statement_list_opt END {@>@<Close the file@>@>@=}
;
statement_list:
statement_list statement {@>@<Attach a statement to a statement list@>@=}
- | statement {@>@<Start a statement list with a statement@>@=}
+ | statement {@>@<Carry on@>@=}
;
statement_list_opt:
- {@>@[TeX_( "/yy0{}" );@]@=}
+ {@>@[TeX_( "/yy0{/nx/insertcweb{}{}{stmt}{}}" );@]@=}
| statement_list {@>@<Carry on@>@=}
;
@g
-@ @<Attach a statement to a statement list@>=
- @[TeX_( "/yy0{/the/yy(1)/yytoksempty{/yy(2)}{}{/yytoksempty{/yy(1)}{}{/noexpand/ldor}{/the/yy(2)}}}" );@]
+@ @<Form an input section spec@>=
+ @[TeXb( "/getsecond{/yy(1)}/to/toksa/getthird{/yy(1)}/to/toksb" ); @]@;
+ @[TeXf( "/getfourth{/yy(1)}/to/toksc/getfifth{/yy(1)}/to/toksd" );@]@;
+ @[TeXfo( "/yy0{/nx/ldinsertcweb{/the/toksa}{/the/toksb}{stmt}{/nx/ldsecspec{/the/toksd}}}" );@]
-@ @<Start a statement list with a statement@>=
- @[TeX_( "/yy0{/yytoksempty{/yy(1)}{}{{/the/yy(1)}}}" );@]
+@ @<Add a \prodstyle{KEEP} statement@>=
+ @[TeX_( "/getfifth{/yy(4)}/to/toksa" );@]@;
+ @[TeX_( "/yy0{/nx/ldinsertcweb/the/yy(1){stmt}{/nx/ldkeep{/the/toksa}}}" );@]
+
+@ @<Attach a statement to a statement list@>=
+ @[TeX_( "/getsecond{/yy(1)}/to/toksa/getthird{/yy(1)}/to/toksb" );@]@;
+ @[TeX_( "/getfourth{/yy(1)}/to/toksc/getfifth{/yy(1)}/to/toksd" );@]@;
+ @[TeX_( "/getsecond{/yy(2)}/to/tokse/getthird{/yy(2)}/to/toksf" );@]@;
+ @[TeX_( "/getfourth{/yy(2)}/to/toksg/getfifth{/yy(2)}/to/toksh" );@]@;
+ @[TeXb( "/yytoksempty{/toksd}{/yy0{/the/yy(2)}}" );@]@;
+ @[TeXf( " {/yy0{/nx/ldinsertcweb{/the/toksa}{/the/toksb}{/the/toksg}{/the/toksd" );@]@;
+ @[TeXfo( " /yytoksempty{/toksh}{}{/yytoksempty{/toksd}{}{/nx/ldor}/the/toksh}}}}" );@]@;
@ @<Grammar rules@>=
@G
@@ -627,22 +668,33 @@ opt_comma: ',' |
assignment:
NAME '=' mustbe_exp {@>@<Process simple assignment@>@=}
| NAME assign_op mustbe_exp {@>@<Process compound assignment@>@=}
- | HIDDEN '(' NAME '=' mustbe_exp ')' {}
- | PROVIDE '(' NAME '=' mustbe_exp ')' {}
- | PROVIDE_HIDDEN '(' NAME '=' mustbe_exp ')' {}
+ | HIDDEN '(' NAME '=' mustbe_exp ')' {@>@<Process a \prodstyle{HIDDEN} assignment@>@=}
+ | PROVIDE '(' NAME '=' mustbe_exp ')' {@>@<Process a \prodstyle{PROVIDE} assignment@>@=}
+ | PROVIDE_HIDDEN '(' NAME '=' mustbe_exp ')' {@>@<Process a \prodstyle{PROVIDE\_HIDDEN} assignment@>@=}
;
@g
@ @<Process simple assignment@>=
- @[TeX_( "/yy0{/noexpand/ldassignment{/noexpand/ldregexp{/the/yy(1)}}{/K}{/the/yy(3)}}" );@]
+ @[TeXb( "/getthird{/yy(1)}/to/toksa/getfourth{/yy(1)}/to/toksb" );@]@;
+ @[TeXfo( "/yy0{/nx/ldinsertcweb{/the/toksa}{/the/toksb}{asgnm}{/nx/ldassignment{/nx/ldregexp{/the/yy(1)}}{/K}{/the/yy(3)}}}" );@]
@ @<Process compound assignment@>=
- @[TeX_( "/yy0{/noexpand/ldassignment{/noexpand/ldregexp{/the/yy(1)}}{/the/yy(2)}{/the/yy(3)}}" );@]
+ @[TeXb( "/getthird{/yy(1)}/to/toksa/getfourth{/yy(1)}/to/toksb" );@]@;
+ @[TeXfo( "/yy0{/nx/ldinsertcweb{/the/toksa}{/the/toksb}{asgnm}{/nx/ldassignment{/nx/ldregexp{/the/yy(1)}}{/the/yy(2)}{/the/yy(3)}}}" );@]
+
+@ @<Process a \prodstyle{HIDDEN} assignment@>=
+ @[TeX_( "/yy0{/nx/ldinsertcweb/the/yy(1){hiddn}{/nx/ldhidden{/nx/ldregexp{/the/yy(3)}}{/the/yy(5)}}}" );@]
+
+@ @<Process a \prodstyle{PROVIDE} assignment@>=
+ @[TeX_( "/yy0{/nx/ldinsertcweb/the/yy(1){prvde}{/nx/ldprovide{/nx/ldregexp{/the/yy(3)}}{/the/yy(5)}}}" );@]
+
+@ @<Process a \prodstyle{PROVIDE\_HIDDEN} assignment@>=
+ @[TeX_( "/yy0{/nx/ldinsertcweb/the/yy(1){prhid}{/nx/ldprovidehid{/nx/ldregexp{/the/yy(3)}}{/the/yy(5)}}}" );@]
@ @<Grammar rules@>=
@G
memory:
- MEMORY '{' memory_spec_list_opt '}' {@>@[TeX_( "/yy0{/noexpand/ldmemory{/the/yy(3)}}" );@]@=}
+ MEMORY '{' memory_spec_list_opt '}' {@>@<Form the \prodstyle{MEMORY} group@>@=}
;
memory_spec_list_opt:
@@ -651,8 +703,8 @@ memory_spec_list_opt:
;
memory_spec_list:
- memory_spec_list opt_comma memory_spec {@>@[TeX_( "/yy0{/the/yy(1)/the/yy(3)}" );@]@=}
- | memory_spec {@>@[TeX_( "/yy0{/the/yy(1)}" );@]@=}
+ memory_spec_list opt_comma memory_spec {@>@<Add a memory spec@>@=}
+ | memory_spec {@>@<Start a list of memory specs@>@=}
;
@@ -661,12 +713,30 @@ memory_spec:
attributes_opt ':'
origin_spec
@t}\vb{\breakline}{@>
- opt_comma length_spec {@>@[TeX_( "/yy0{/noexpand/ldmemoryspec{/the/yy(1)}{/the/yy(3)}{/the/yy(5)}{/the/yy(7)}}" );@]@=}
+ opt_comma length_spec {@>@<Declare a named memory region@>@=}
| INCLUDE filename {@>@<Peek at a file@>@=}
memory_spec_list_opt END {@>@<Close the file@>@=}
;
@g
+@ @<Form the \prodstyle{MEMORY} group@>=
+ @[TeX_( "/yy0{/nx/ldinsertcweb/the/yy(1){mem}{/nx/ldmemory{/the/yy(3)/nx/ldmemspecstash/the/yy(4)}}}" );@]
+
+@ @<Start a list of memory specs@>=
+ @[TeXb( "/getsecond{/yy(1)}/to/toksa/getthird{/yy(1)}/to/toksb" ); @]@;
+ @[TeXf( "/getfifth{/yy(1)}/to/toksc" );@]@;
+ @[TeXfo( "/yy0{/nx/ldmemspecstash{/the/toksa}{/the/toksb}/the/toksc}" );@]@;
+
+@ @<Add a memory spec@>=
+ @[TeXb( "/getsecond{/yy(3)}/to/toksa/getthird{/yy(3)}/to/toksb" ); @]@;
+ @[TeXf( "/getfifth{/yy(3)}/to/toksc" );@]@;
+ @[TeXfo( "/yy0{/the/yy(1)/nx/ldmemspecseparator{/the/toksa}{/the/toksb}/the/toksc}" );@]@;
+
+@ @<Declare a named memory region@>=
+ @[TeXb( "/getthird{/yy(1)}/to/toksa/getfourth{/yy(1)}/to/toksb" );@]@;
+ @[TeXf( "/yy0{/nx/ldinsertcweb{/the/toksa}{/the/toksb}{mreg}" );@]@;
+ @[TeXfo( " {/nx/ldmemoryspec{/the/yy(1)}{/the/yy(3)}{/the/yy(5)}{/the/yy(7)}}}" );@]
+
@ @<Grammar rules@>=
@G
origin_spec:
@@ -735,7 +805,7 @@ mustbe_exp:
;
@g
-@*1 {\ifheader\ninepoint\fi\prodstyle{SECTIONS}} and expressions.
+@*1 {\ifheader\ninepoint\fi\prodstylens{SECTIONS}{\ldnamespace}} and expressions.
The linker supports an extensive range of expressions. The precedence
mechanism provided by \bison\ is used to present the composition of
expressions out of simpler chunks and basic building blocks tied
@@ -790,7 +860,7 @@ exp :
| DATA_SEGMENT_END '(' exp ')' {}
| SEGMENT_START '(' NAME ',' exp ')' {}
| BLOCK '(' exp ')' {}
- | NAME {@>@[TeX_( "/yy0{/noexpand/ldregexp{/the/yy(1)}}" );@]@=}
+ | NAME {@>@[TeX_( "/yy0{/nx/ldregexp{/the/yy(1)}}" );@]@=}
| MAX_K '(' exp ',' exp ')' {}
| MIN_K '(' exp ',' exp ')' {}
| ASSERT_K '(' exp ',' NAME ')' {}
@@ -802,8 +872,8 @@ exp :
@ @<Process a primitive conditional@>=
@q TeX_( "/yy0{/hbox{/nx/ttl let }/nx/xi(0)=/the/yy(5): /nx/xi(/nx/CM0)=/the/yy(3)/hbox{ /nx/ttl do }/xi(/the/yy(1))}" );@>
-@[TeX_( "/yy0{/hbox{/nx/ttl do }/xi(/the/yy(1))/hbox{ /nx/ttl where }" );@>
-@[TeX_( " {/let/nx/{/nx/bigbracedel/nx/xi(x)=/nx/cases{/the/yy(5)& if /inmath{x=0}/cr/the/yy(3)& if /inmath{x/nx/not=0}}}}" );@]
+@[TeXb( "/yy0{/hbox{/nx/ttl do }/xi(/the/yy(1))/hbox{ /nx/ttl where }" );@]@;
+@[TeXfo( " {/let/nx/{/nx/bigbracedel/nx/xi(x)=/nx/cases{/the/yy(5)& if /inmath{x=0}/cr/the/yy(3)& if /inmath{x/nx/not=0}}}}" );@]@;
@ @<Grammar rules@>=
@G
@@ -880,7 +950,7 @@ section:
opt_comma {@>@<Record an overlay section@>@=}
| GROUP {@>@[TeX_( "/ldlex@@expression" );@]@=}
opt_exp_with_type {@>@[TeX_( "/ldlex@@popstate" );@]@=}
- '{' sec_or_group_p1 '}'
+ '{' sec_or_group_p1 '}' {}
| INCLUDE filename {@>@<Peek at a file@>@=}
sec_or_group_p1 END
{@>@<Close the file@>@=}
@@ -888,10 +958,12 @@ section:
@g
@ @<Record a named section@>=
- @[TeXb( "/yy0{/nx/ldnamedsection{/the/yy(1)}{/the/yy(3)}{/the/yy(4)}" );@]@;
+ @[TeXb( "/getthird{/yy(1)}/to/toksa/getfourth{/yy(1)}/to/toksb" );@]@;
+ @[TeXf( "/getfifth{/yy(12)}/to/toksc" );@]@;/* \prodstylens{statement\_list\_opt}{\ldnamespace} contents */
+ @[TeXf( "/yy0{/nx/ldinsertcweb{/the/toksa}{/the/toksb}{osect}{/nx/ldnamedsection{/the/yy(1)}{/the/yy(3)}{/the/yy(4)}" );@]@;
@[TeXf( " {{/the/yy(5)}{/the/yy(6)}{/the/yy(7)}}" );@]@;/* alignment */
- @[TeXf( " {/the/yy(9)}{/the/yy(12)}" );@]@;
- @[TeXfo( " {{/the/yy(15)}{/the/yy(16)}{/the/yy(17)}{/the/yy(18)}}}" );@]@; /*memory specifiers */
+ @[TeXf( " {/the/yy(9)}{/the/toksc}" );@]@;
+ @[TeXfo( " {{/the/yy(15)}{/the/yy(16)}{/the/yy(17)}{/the/yy(18)}}}}" );@]@; /*memory specifiers */
@ @<Record an overlay section@>=