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

Strange segfault during compilation #867

Closed
nsf opened this issue Jun 15, 2010 · 4 comments
Closed

Strange segfault during compilation #867

nsf opened this issue Jun 15, 2010 · 4 comments

Comments

@nsf
Copy link

nsf commented Jun 15, 2010

Before filing a bug, please check whether it has been fixed since
the latest release: run "hg pull -u" and retry what you did to
reproduce the problem.  Thanks.

What steps will reproduce the problem?
1. Save the attached code to test2.go
2. Try to compile using 8g: 8g test2.go
3. Segfault.

What is the expected output?
An error message.

What do you see instead?
Segfault.


What is your $GOOS?  $GOARCH?
linux, 386


Which revision are you using?  (hg identify)
f776656df34c release.2010-06-09/release

Please provide any additional information below.
I guess it's somehow related to the type switch statement. There is a bug in the code
itself, it should be "*ast.FuncDecl" in case statement instead of
"ast.FuncDecl". But compiler says nothing and just dies with segfault.

Attachments:

  1. test2.go (303 bytes)
@gopherbot
Copy link
Contributor

Comment 1 by zerohp:

I am tripping over another compiler segfault with both 8g and 6g.  It is similar to
yours.  See attached.
113ec27f29f1+ release.2010-06-21/release

Attachments:

  1. bad.go (459 bytes)

@robpike
Copy link
Contributor

robpike commented Jun 24, 2010

Comment 2:

Owner changed to k...@golang.org.

Status changed to Accepted.

@robpike
Copy link
Contributor

robpike commented Jun 24, 2010

Comment 3:

Labels changed: added compilerbug.

@ken
Copy link
Contributor

ken commented Jun 28, 2010

Comment 4:

This issue was closed by revision 2795282.

Status changed to Fixed.

@nsf nsf added fixed labels Jun 28, 2010
@nsf nsf assigned ken Jun 28, 2010
@golang golang locked and limited conversation to collaborators Jun 24, 2016
@rsc rsc unassigned ken Jun 22, 2022
This issue was closed.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

4 participants