cgo: define idents referenced only from macros

This commit is contained in:
Ayke van Laethem
2024-11-05 08:58:40 +01:00
committed by Ron Evans
parent 8068419854
commit c4867c8743
6 changed files with 28 additions and 7 deletions
+1 -1
View File
@@ -59,7 +59,7 @@ func TestParseConst(t *testing.T) {
} {
fset := token.NewFileSet()
startPos := fset.AddFile("", -1, 1000).Pos(0)
expr, err := parseConst(startPos, fset, tc.C)
expr, err := parseConst(startPos, fset, tc.C, nil)
s := "<invalid>"
if err != nil {
if !strings.HasPrefix(tc.Go, "error: ") {