I'm trying to write documentation in Texinfo format (must be traditional to Emacs, I guess). And it is a nightmare... Anyway, I could get to the point, where the source gives me less error then when I started, but the errors are impossible to understand and thus fix.
All of the errors boil down to "bad" next / previous / up nodes. And they all happen in places, where there can be no "next", no "previous" and no "up" nodes. I.e. The last node in the list does not have a next node, similarly, the first can't have a previous, and the top-level can't have an "up". Node. These are the exact messages I'm getting:
./i-iterate/info/i-iterate.texi:385: Next field of node `dot-product|join|distinct' not pointed to (perhaps incorrect sectioning?).
./i-iterate/info/i-iterate.texi:392: This node (return) has the bad Prev.
./i-iterate/info/i-iterate.texi:199: Next field of node `initially' not pointed to (perhaps incorrect sectioning?).
./i-iterate/info/i-iterate.texi:120: This node (for) has the bad Prev.
./i-iterate/info/i-iterate.texi:29: Next field of node `Top' not pointed to (perhaps incorrect sectioning?).
./i-iterate/info/i-iterate.texi:120: This node (for) has the bad Prev.
My texti file structure is as follows:
- Top
|- menu-0
| |- menu-2
|- menu-1
<list of nodes>
I.e. nodes mentioned in menu-2
should have their top node in menu-0
, and Top
is the top node for nodes in menu-0
and menu-1
.
for
node is the first node in the menu-0
, return
node is the first node in the menu-1
, dot-product|join|distinct
is the last node in menu-2
, initially
is the last node of the menu-0
.
Top node can't have previous / next / up nodes... for obvious reasons.
As requested, the offending nodes:
@node for, with, , Top
@node return, collect, , Top
@node dot-product|join|distinct, , permutations, for
@node initially, , finally, Top
Some more info. I could actually "fix" it by specifying the return
node as the next node of initially
and initially
as a previous node of return
. But this is not the desired effect, because they two belong in different sets of nodes.
Also, this is how the entire menu looks like:
@menu
* for:: A multi-purpose driver for doing variety of things.
* with:: A driver for variable declaration.
* generate:: A general purpose generator driver.
* repeat:: A simple driver for performing iteration N number of itmes.
* finally:: A driver that runs when the iteration finishes normally.
* initially:: A driver that runs before any code in the iteration.
@end menu
@strong{Keywords}
@menu
* return:: Returns the control flow to the form outside the loop.
* collect:: Generates a list with the cells being the experssion given.
* hash:: Generates a hash-table with the provided keys and values.
* skip:: Skips the execution of the rest of the loop body.
* previous:: Gives the value of the variable from the previous iteration.
* next:: Gives the value of the variable from the next iteration.
* output:: Prints the variable to the dedicated stream.
* insert:: Generates a vector and inserts elements into it.
* minimize:: Finds the minimum value of the variable.
* maximize:: Finds the maximum value of the variable.
* count:: Counts the number ot times this expression was executed.
* sum:: Sums the values of this variable.
* multiply:: Multiplies the values of this variable.
* reduce:: General purpose accumulation handler.
@end menu
@node for, with, , Top
@chapter Multi-purpose driver
... description of what for node is ...
@strong{For continuations}
@menu
* in|on:: Iterates over lists.
* upfrom|from|downfrom:: Iterates numberically.
* across|reverse|binary:: Iterates over arrays.
* depth-first|breadth-first:: Iterates over trees.
* keys|values|pairs:: Iterates over hash-tables.
* random:: Produces unique random each iteration.
* chars|words|lines:: Iterates over entities in buffer.
* permutations:: Generates permutation of an array.
* dot-product|join|distinct:: Iterates over sets.
@end menu
Just use @node for
and @node return
without the extra arguments. Texinfo will then automatically figure out the prev/next/up links based on @chapter
and other sectioning commands.