You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Trying to compile the following code snippet with 6g will reproduce the
segmentation fault:
type A struct {a A}
func foo() {new(A).bar()}
func (a A) bar() {}
Without the method call, 6g correctly reports the invalid recursive type.
As far as I can tell, exportassignok() (go/src/cmd/gc/typecheck.c) gets
caught up in an endless recursion.
The bug also surfaces when chaining 2 or more types together.
Some other information:
GOARCH=amd64
GOBIN=~/bin
GOOS=linux
GOROOT=~/go
I'm at changeset 4031:b2ccee5ff169
The text was updated successfully, but these errors were encountered:
by moshevds:
The text was updated successfully, but these errors were encountered: