We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent cff09d2 commit a2a2e93Copy full SHA for a2a2e93
go/extractor/extractor.go
@@ -1949,7 +1949,15 @@ func getObjectBeingUsed(tw *trap.Writer, ident *ast.Ident) types.Object {
1949
obj1 := getObjectBeingUsed1(tw, ident)
1950
obj2 := getObjectBeingUsed2(tw, ident)
1951
if obj1 != obj2 {
1952
- log.Fatalf("different results!\nobj1 = %s\nobj2=%s\n", obj1.String(), obj2.String())
+ string1 := "nil"
1953
+ if obj1 != nil {
1954
+ string1 = obj1.String()
1955
+ }
1956
+ string2 := "nil"
1957
1958
+ string2 = obj1.String()
1959
1960
+ log.Fatalf("different results!\nobj1 = %s\nobj2 = %s\n", string1, string2)
1961
}
1962
return obj2
1963
0 commit comments