Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cmd/compile: internal compiler error: exporter: unexpected type alias in inlined function body #24173

Closed
skipor opened this issue Feb 28, 2018 · 3 comments

Comments

Projects
None yet
4 participants
@skipor
Copy link

commented Feb 28, 2018

What version of Go are you using (go version)?

go version go1.10 darwin/amd64

Does this issue reproduce with the latest release?

Yes

What did you do?

package main
type mapAlias = map[interface{}]interface{}
func main() {
	println(mapAlias{})
}
func Foo() {
	println(mapAlias{}) // Works when commented. 
}

https://play.golang.org/p/ukZwewCW0be

What did you expect to see?

The program compiles and print result.

What did you see instead?

<autogenerated>:1:0: internal compiler error: exporter: unexpected type alias mapAlias in inlined function body

@bradfitz bradfitz added the NeedsFix label Feb 28, 2018

@bradfitz bradfitz changed the title internal compiler error: exporter: unexpected type alias in inlined function body cmd/compile: internal compiler error: exporter: unexpected type alias in inlined function body Feb 28, 2018

@bradfitz bradfitz added this to the Go1.11 milestone Feb 28, 2018

@bradfitz

This comment has been minimized.

Copy link
Member

commented Feb 28, 2018

@griesemer griesemer self-assigned this Feb 28, 2018

@griesemer

This comment has been minimized.

Copy link
Contributor

commented Feb 28, 2018

Slightly minimized reproducer:

package p

type notExported = struct{}

func Exported() {
	_ = notExported{}
}
@gopherbot

This comment has been minimized.

Copy link

commented Feb 28, 2018

Change https://golang.org/cl/97719 mentions this issue: cmd/compile: fix unexpected type alias crash

@gopherbot gopherbot closed this in b3f00c6 Feb 28, 2018

@golang golang locked and limited conversation to collaborators Feb 28, 2019

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
You can’t perform that action at this time.