I started noticing odd behavior from cscope recently, so I ran 'git
bisect' and found the problem at this commit:

    $ git bisect good
    dc21552c9a83413a018a91e61649cc632929d6a1 is the first bad commit
    commit dc21552c9a83413a018a91e61649cc632929d6a1
    Author: Bram Moolenaar <[email protected]>
    Date:   Sun Sep 25 17:03:26 2022 +0100

        patch 9.0.0584: cscope test with wrong executable name fails
        
        Problem:    Cscope test with wrong executable name fails.
        Solution:   Use /bin/sh to execute the command. (Yegappan Lakshmanan)

     src/if_cscope.c             | 27 ++++++++++++++++-----------
     src/testdir/test_cscope.vim | 14 +++++---------
     src/version.c               |  2 ++
     3 files changed, 23 insertions(+), 20 deletions(-)

I build a GNU Global database in a project's root directory, and
then use that database with vim's :cscope commands to find
references to symbols.  I doesn't matter where I start vim in the
project's directories because vim knows how to construct the full
pathname to each target file.

Since that commit, however, I've had to start vim in the project's
root directory for the :cs find s <symbol>" command to work.
Otherwise, vim leaves out part of the path to the file.

For example, I have my vim repo at ~/src/vim/vim, and that's where
my GTAGS, etc., files are located.

 1.  $ cd ~/src/vim/vim
 2.  $ cd src
 3.  $ vim -N -u NONE
 4.  :set cscopeprg=gtags-cscope
 5.  :cs add /home/gary/src/vim/vim/GTAGS /home/gary/src/vim/vim -a
 6.  :set cscopequickfix=a-,c-,d-,e-,f0,g0,i-,s-,t-
 7.  :cs find s parse_printoptions

Vim opens ~/src/vim/vim/hardcopy.c.  Note that this should be
~/src/vim/vim/src/hardcopy.c--the "src/" component was omitted.

This works properly if vim is started in the ~/src/vim/vim directory
or is a version older than 9.0.0584.

Version of Vim

 9.0.658
 but this been happening since patch 9.0.0584

Environment

 Operating system:  Ubuntu 20.04
 Terminal:          XTerm(370)
 Value of $TERM:    xterm-256color
 Shell:             bash 5.0.17
 GNU Global and gtags-cscope: 6.6.4

Regards,
Gary

-- 
-- 
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].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/vim_dev/20221013014140.GI24999%40phoenix.

Raspunde prin e-mail lui