On 3 June 2013 15:53, Gary Johnson <[email protected]> wrote: > On 2013-06-03, A. S. Budden wrote: >> On 1 June 2013 15:13, ChengYi Lin wrote: >> > give cscope full path >> > $ find `pwd` | cscope -i - >> >> This indeed makes it work. That was what I was trying to show in my >> example code. > > But that is solving a different problem than the one described in > the forwarded message.
Yes, sorry: re-reading my email it wasn't very explicit. > The forwarded message describes a problem with using relative path > names for the name of the database file. The command above, using > find, addresses the problem of relative path names _in_ the database > file. Correct. >> However, I think this should be done by Vim automatically when >> using the "cs add" command. > > The ":cs add" command does provide a solution for the problem of > relative path names _in_ the database file. That's what the > pre-path argument is for. Yes, but as you said above, this is a different one to the one I described in my bug report to Bram. > However, the ":cs add" command can't very well know what that > argument should be "automatically" because it is the path to the > directory in which cscope was run when it built the database, which > is not necessarily the directory in which vim is being run when the > ":cs add" command is executed. cs add can't know the second argument automatically (hence the need for the pre-path argument), but it can know the location of the cscope database automatically as it will either be provided as a complete path or will be relative to the current working directory. From my understanding (as I described in the original post), the fix would be to make cs add filename do an implicit fnamemodify(filename, ':p'). However, I looked at the cs_add_common code in if_cscope.c and it scared me enough that I didn't feel sufficiently qualified to write a patch to that effect: hence submitting it as a bug report instead. Al -- -- You received this message from the "vim_dev" maillist. Do not top-post! Type your reply below the text you are replying to. For more information, visit http://www.vim.org/maillist.php --- You received this message because you are subscribed to the Google Groups "vim_dev" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/groups/opt_out.
