This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [patch 2/9] Code cleanup: Drop IS_ABSOLUTE_PATH checks
> Date: Sat, 19 Jan 2013 15:09:14 +0100
> From: Jan Kratochvil <jan.kratochvil@redhat.com>
> Cc: gdb-patches@sourceware.org
>
> On Sat, 19 Jan 2013 07:50:13 +0100, Eli Zaretskii wrote:
> > > Could you give an example? Previously it was forbidden/unspecified what
> > > happens when you call compare_filenames_for_search
> > > with IS_ABSOLUTE_PATH (search_name).
> >
> > Any absolute file name would be an example.
>
> Could you state literal SEARCH_NAME, literal FILENAME, what is a result you
> expect and what do you you think is the actual result with this patch?
>
> I have double/triple checked this patch and I do not see a bug there.
It might not be a bug, but the code doesn't tell what it means, and
has no comments to explain its subtleties. IOW, it isn't clean.
> For example when asking for a breakpoint at:
> c:\filename.c:main
> it must not match a debug info filename:
> d:\foo\c:\filename.c
Why not?
> Moreover this patch is a "Code cleanup" and the callers were already using
> IS_ABSOLUTE_PATH. So if IS_ABSOLUTE_PATH is wrong (which IMO so far it is
> not) then it is still a new patch / unrelated fix, not the scope of this
> patch.
Whatever. I'm still unconvinced, I think the code is not sufficiently
cleaned up. But I'm tired of arguing.