From mboxrd@z Thu Jan 1 00:00:00 1970 From: David Taylor To: Fernando Nasser Cc: Stephane Carrez , gdb@sourceware.cygnus.com Subject: Re: pathmap or dir command on drugs Date: Tue, 07 Nov 2000 10:19:00 -0000 Message-id: <200011071818.NAA00809@texas.cygnus.com> X-SW-Source: 2000-11/msg00035.html Date: Tue, 07 Nov 2000 12:59:54 +0000 From: Fernando Nasser Stephane Carrez wrote: > > David Taylor wrote: > > The other camp is > > > > pathmap add > > pathmap list > > pathmap delete > > Looks good, > > As for dbx, I suggest to give numbers to each pathmap so that deletion is > made on the index rather than on some path. When I last used dbx it didn't have a pathmap command. And my current system doesn't have dbx on it -- would you be willing to summarize the current dbx pathmap command? Yes, the idea is that you can have pathmap delete 3 pathmap delete 4-6 pathmap delete all Deletions on the path are not very practical. When I said I was thinking of the way breakpoints and displays are handled -- you give the numbers you want deleted. > I guess we need some optional argument to 'add' to tell the position of > the new pathmap in the list. After that, the old pathmaps after the new > one, will have their index incremented. Well, like dbx :-) > I suggest an "insert" subcommand: pathmap insert It is like add but it lets the user specify after which entry it should be added. Actually, if there is an insert, then either it should be an insert before or that should be an option or you need to allow to be 0 -- otherwise you cannot insert before the first element. This way there will be no parsing madness trying to decide if something is a path or a number. This could also be done based on 2 vs 3 arguments, but I prefer an approach of having you say what you mean... so I like 'insert' better.