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

go1: internal compiler error: in build_tree, at go/gofrontend/ #1320

alberts opened this issue Dec 3, 2010 · 5 comments


Copy link

@alberts alberts commented Dec 3, 2010

What steps will reproduce the problem?

Compile with gccgo:

package bork
type x struct {}
func y() (a []byte, e os.Error) {}

What do you see instead?

bork.go:3:25: error: expected package
bork.go:3:1: error: control reaches end of non-void function
In function ‘bork.y’:
go1: internal compiler error: in build_tree, at go/gofrontend/
Please submit a full bug report,
with preprocessed source if appropriate.
See <>; for instructions.

Which compiler are you using (5g, 6g, 8g, gccgo)?


Which operating system are you using?


Which revision are you using?  (hg identify)

URL: svn://
Repository Root: svn://
Repository UUID: 138bc75d-0d04-0410-961f-82ee72b054a4
Revision: 167409
Copy link

@ianlancetaylor ianlancetaylor commented Dec 4, 2010

Comment 1:

Labels changed: added gccgo.

Owner changed to

Copy link

@ianlancetaylor ianlancetaylor commented Dec 4, 2010

Comment 2:

The compiler crash is definitely a bug, but note that this program is invalid.  You need
to add
import "os"
to get a valid program.  If the compiler didn't crash, you would get an error message.
Copy link
Contributor Author

@alberts alberts commented Dec 4, 2010

Comment 3:

Sure. I reduced this test case from a bigger source file where an import or include path
or something is missing, but due to the crash, I couldn't figure out what was wrong.
Copy link

@robpike robpike commented Dec 6, 2010

Comment 4:

Status changed to Accepted.

Copy link

@ianlancetaylor ianlancetaylor commented Dec 7, 2010

Comment 5:

Fixed.  Thanks.

Status changed to Fixed.

@alberts alberts added fixed labels Dec 7, 2010
@golang golang locked and limited conversation to collaborators Jun 24, 2016
This issue was closed.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
4 participants
You can’t perform that action at this time.