[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [help-texinfo] line offset strangeness in info index

From: Robert Dodier
Subject: Re: [help-texinfo] line offset strangeness in info index
Date: Fri, 17 Nov 2006 09:09:14 -0700

Karl, about this phenomenon,

You mean that the index entry should be:

* quad_qaws:                             Definitions for QUADPACK.
                                                             (line  484)

instead of 485?

Experimentally I've observed that the line number stated in the
index is the last line in a function definition that spills over multiple lines.
So it's not exactly an off-by-one error. If the function defintion
contains m lines then the line number stated is (m - 1) lines too many.

Looking at the makeinfo code, I believe the point at which the line
number is captured for later output is line 207 in makeinfo/index.c,

 new->output_line = no_headers ? output_line_number : node_line_number;

There doesn't appear to be any adjustment for multiple-line
definitions there. I am not familiar with that code so I could be
off the mark there.

I guess what needs to happen is to record the line number of the
line on which a function definition starts, and store that instead of
the current line number.

In the manual that I'm working on, most function definitions take
up one line, but there are several which take up two lines.

Thanks for your help,

Robert Dodier

reply via email to

[Prev in Thread] Current Thread [Next in Thread]