2 回答

TA貢獻(xiàn)1852條經(jīng)驗(yàn) 獲得超7個(gè)贊
gopls
這是官方 golang 包中分發(fā)的工具中的一個(gè)錯(cuò)誤。
問(wèn)題報(bào)告中的信息:
internal/lsp: use Go/cgo source files instead of generated files
Using CompiledGoFiles was causing metadata lookups to fail for cgo
packages because it includes generated files in the Go build cache
when the built-in 'go list' driver is used.? GoFiles includes both
Go and cgo original file names, allowing metadata lookups to
succeed.

TA貢獻(xiàn)2016條經(jīng)驗(yàn) 獲得超9個(gè)贊
這是 VSCode 的一個(gè)錯(cuò)誤,我已經(jīng)為此問(wèn)題寫(xiě)了一篇中等文章。
https://medium.com/@mourya.g9/setting-up-confluence-kafka-client-for-golang-with-vscode-7a27bb94220b。希望這可以幫助。

TA貢獻(xiàn)1821條經(jīng)驗(yàn) 獲得超5個(gè)贊
問(wèn)題是導(dǎo)入之間有額外的新行,您可以嘗試以下操作:
// #cgo CFLAGS: -g -Wall
// #include <stdio.h>
// #include <stdlib.h>
// #include <string.h>
// #include "cutils.h"
import "C"
import (
? ? "bufio"
? ? "encoding/json"
// ...
)
- 2 回答
- 0 關(guān)注
- 275 瀏覽
添加回答
舉報(bào)