Re: [RFC/dwarf-2] Add support for included files

Eli Zaretskii
2004-01-02T14:45:21Z

> Date: Fri, 2 Jan 2004 08:25:00 +0100
> From: Joel Brobecker <brobecker@gnat.com>
>
> This capability can be reproduced in C as well, using #include.

Doesn't this happen with C++ programs (which have code fragments on
header files) as well? What about Yacc- and Lex-processed code?

> If we want to support the case above, I don't see any other way but to
> scan the line table as well.

How about if we only do that scan when the file name is not found in
the partial symbols, i.e. just before GDB is about to give up and
report the file as nonexistent? Assuming that the cases you have in
mind are rare, this would mean faster operation in most cases.