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: independent variables should be initialized in declaration order #7962

Open
griesemer opened this Issue May 9, 2014 · 3 comments

Comments

Projects
None yet
3 participants
@griesemer
Copy link
Contributor

griesemer commented May 9, 2014

http://play.golang.org/p/icbjgkx71B

got:
gc produces the initialization order: c b a .

want:
The variables b and c are independent of each other, and b is declared before c, so the
order should be: b c a .

gccgo reports the order: b c a .

Based on spec clarification https://golang.org/cl/99020043 (issue #6703).
@griesemer

This comment has been minimized.

Copy link
Contributor Author

griesemer commented Aug 6, 2014

Comment 1:

Fixing this must consider outcome of issue #8485.
@rsc

This comment has been minimized.

Copy link
Contributor

rsc commented Sep 15, 2014

Comment 2:

I'm happy to change cmd/gc but not for 1.4.

Labels changed: added release-go1.5, removed release-go1.4.

Status changed to Accepted.

@griesemer

This comment has been minimized.

Copy link
Contributor Author

griesemer commented Sep 29, 2014

Comment 3:

issue #8485 was closed with revision 191f9dc7d039 and this current issue remains a bug w/
respect to the latest spec.

@bradfitz bradfitz modified the milestone: Go1.5 Dec 16, 2014

@bradfitz bradfitz removed the release-go1.5 label Dec 16, 2014

@rsc rsc removed accepted labels Apr 14, 2015

@rsc rsc modified the milestones: Go1.6, Go1.5 May 19, 2015

@rsc rsc changed the title cmd/gc: independent variables should be initialized in declaration order cmd/compile: independent variables should be initialized in declaration order Jun 8, 2015

@rsc rsc modified the milestones: Unplanned, Go1.6 Dec 5, 2015

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