This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: patch to add typedef for "logical line" [ping]
- From: Per Bothner <per at bothner dot com>
- To: Gcc Patch List <gcc-patches at gcc dot gnu dot org>
- Date: Mon, 04 Aug 2003 16:26:24 -0700
- Subject: Re: patch to add typedef for "logical line" [ping]
- References: <3F25B387.6030005@bothner.com>
See http://gcc.gnu.org/ml/gcc-patches/2003-07/msg02667.html
This is a patch to add a typedef for the "logical lines" that are
managed by line-map.c. I suggest "fileline" as the typedef, but
possible alternatives include logical_line or line_index. (I don't
much care for the latter.)
The patch also added comments to indicating that long-term we want
to replace struct location_s (in input.h) by the fileline type. This
may be controversial: The big plus is tha fileline cookies are much
more compact, and can store extra state (such as include file
hierarchies and potentially column numbers) in 32 bits. However, the
are currently mainly used by cpplib. Furthermore, decoding a fileline
to a printable filename and linenumber is slower, and less convenient
(especially while debugging).
--
--Per Bothner
per@bothner.com http://per.bothner.com/