stamblerre / gocode

An autocompletion daemon for the Go programming language
MIT License
394 stars 28 forks source link

include overlay to go/packages #21

Closed marwan-at-work closed 5 years ago

marwan-at-work commented 5 years ago

This should enable non saved imports to be auto completed :)

stamblerre commented 5 years ago

@marwan-at-work, does this actually fix the problem for you? I'd imagine the fix should actually be naming the empty variable in ParseFile "data".

marwan-at-work commented 5 years ago

@stamblerre tl;dr I didn't notice the empty variable and things did work.

Looking at go/packages we definitely need to pass data as part of the Config.Overlay...I'm not sure if we actually should or shouldn't shadow the data variable through the empty variable. Let me know and I'll update the pr!

stamblerre commented 5 years ago

oh you're totally right, the file contents wouldn't actually change. sorry about that - thanks for doing this!