This is the mail archive of the gdb@sources.redhat.com mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: pathmap (again)


Well, I like it this way.  It does not hurt the CLI language at all
so if you are looking for an "approval in principle" or something like that
consider it given.  I will not pest you with requests to change the command
interface anymore :-)

I can only answer for the CLI aspects though.  But I understood that people 
liked the idea of having this around, so if I did not misunderstood I believe
everybody is sort of waiting for the patch already.

The "insert" operation is interesting.  I think J.T. gave a good example of
a situation where it can be useful.  But I guess it is a simple thing to add
at any time, so we may test the concept by initially not providing it and
seeing if someone asks for it (out of a personal need) or even send a patch.

IMO you should go ahead with this and submit a patch.

Fernando


David Taylor wrote:
> 
> Okay, I don't think there was complete agreement on the syntax and the
> semantics, but here's a stab at what I think was agreeable to most...
> 
> Proposed Interface:
> 
>     pathmap add <from> <to>
> 
>         append a mapping from directory <from> to directory <to>
>         to the current list of mappings.
> 
>     pathmap delete <optional-list>
> 
>         delete the mappings indexed by <optional-list> from the
>         list of known mappings.  All subsequent mappings move up
>         the list.  (For example, if you delete mapping 2, then mapping
>         3 becomes mapping 2, mapping 4 becomes mapping 3, and so on.)
> 
>     pathmap list <optional-list>
> 
>         list the specified mappings.  If no list is given, all
>         mappings are listed.
> 
> and potentially:
> 
>     pathmap insert <index> <from> <to>
> 
>         As for 'pathmap add', but insert the mapping immediately after
>         mapping <index>.  All subsequent mappings move down the list.
>         If <index> is zero, then the mapping is inserted before the
>         first mapping.
> 
> Where:
> 
>     <from> and <to> are directory path prefixes
> 
>     <optional-list> is a list in the same format as for the
>                 breakpoint commands
> 
>     <index> is a non negative integer
> 
> And the mappings are not regular expressions -- that is left as a
> potential enhancement for the future.  Also, I'm unconvinced of the
> need for the "pathmap insert" functionality.
> 
> Comments?
> 


-- 
Fernando Nasser
Red Hat - Toronto                       E-Mail:  fnasser@redhat.com
2323 Yonge Street, Suite #300
Toronto, Ontario   M4P 2C9

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]