Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Trailing slash in oracle scope triggers bug #751

Closed
tbg opened this issue Mar 4, 2016 · 2 comments
Closed

Trailing slash in oracle scope triggers bug #751

tbg opened this issue Mar 4, 2016 · 2 comments

Comments

@tbg
Copy link

tbg commented Mar 4, 2016

Expected behavior

:GoCallers should omit the trailing slash at the end of the line

vim-go: oracle -format plain -pos='/Users/tschottdorf/go/src/github.com/tschottdorf/goplay/oracle_tes
t_boom/main.go':#40 -tags= callers 'github.com/tschottdorf/goplay/oracle_test_boom/'

Actual behavior

it uses the trailing slash in the package scope, which triggers golang/go#14584 (comment)

Steps to reproduce:

  go get github.com/tschottdorf/goplay &&  vim $GOPATH/src/github.com/tschottdorf/goplay/oracle_test_boom/main.go

Use :GoCallers on anything, get

   /Users/tschottdorf/go/src/github.com/tschottdorf/goplay/oracle_test_boom/main_test.go:10:2: invalid operation: (&(main.X literal)) (value of type *github.com/tschottdorf/goplay/oracle_test_boom.X) has no field or method Foo
oracle: couldn't load packages due to errors: github.com/tschottdorf/goplay/oracle_test_boom/_test

Configuration

vim version:

VIM - Vi IMproved 7.4 (2013 Aug 10, compiled Oct 15 2015 17:40:14)

vim-go version:

fd5661a

go version:

1.6

@fatih fatih closed this as completed in bba8b39 Mar 13, 2016
@fatih
Copy link
Owner

fatih commented Mar 13, 2016

Thanks @tschottdorf for the detailed bug report and how to reproduce it (it really helped me!). I've fixed it by removing trailing slashes for each path in the scopes. I've also tested it and it works well. Please pull the latest header to test it. You are free to reopen if the bug still exists. Thanks.

@tbg
Copy link
Author

tbg commented Mar 13, 2016

Thanks!

On Sun, Mar 13, 2016, 11:01 Fatih Arslan notifications@github.com wrote:

Closed #751 #751 via bba8b39
bba8b39
.


Reply to this email directly or view it on GitHub
#751 (comment).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants