How to solve this problem? The program works. But the methods in Gogland are highlighted in red. Qt version 5.8 is added.
Gogland (1.0 Preview) 1.0 EAP
Build #GO
The methods are defined in a big generated file that is not indexed by Gogland. To change the limit you should change idea.max.intellisense.filesize.
To do this, open custom properties file via Help | Edit Custom Properties
menu and add something like this: idea.max.intellisense.filesize=4500
for 4.5 MB limit. The size is in Kilobytes.
Please use carefully, indexing large files may influence index update speed dramatically.
Possibly not valid for the original context, but the workaround I discovered is to rename the file where the method or other identifier is defined, allow Goland to reindex, and then rename it back to the original name.
Ran into this recently with a project in 'bitbucket.org' GOPATH not finding ones in 'github.com'. Checked the "Index entire GOPATH" box and it fixed it.
This option is present at: Files > Settings (Preferences) > Go > GOPATH
This can also happen if go.mod
is copied from another project without updating the project name:
// go.mod
module github.com/org/new-project
go 1.15