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

8g reports "fatal error: split64 int32" with 64-bit slice index #589

Closed
gopherbot opened this issue Feb 5, 2010 · 3 comments
Closed

8g reports "fatal error: split64 int32" with 64-bit slice index #589

gopherbot opened this issue Feb 5, 2010 · 3 comments

Comments

@gopherbot
Copy link

by donald.graham@vastech.co.za:

The following lines cause 8g to report a fatal error:

    len := int64(100)   
    records := make([]int, len) 
    println(records[len-1])


8g reports:

    8g indexBug.go
    indexBug.go:7: fatal error: split64 int32

If the first line (line 5) is changed to:

    len := 100

the program compiles and runs fine.  Note that 6g compiles both versions.  

GOOS=linux
GOARCH=386
release=642f4440a578 tip

A full listing of the test program is given below:    

package main

func main(){    
    len := int64(100)
    records := make([]int, len) 
    println(records[len-1])
}
@rsc
Copy link
Contributor

rsc commented Feb 7, 2010

Comment 1:

Labels changed: added compilerbug.

Owner changed to r...@golang.org.

Status changed to Accepted.

@rsc
Copy link
Contributor

rsc commented Apr 28, 2010

Comment 2:

Labels changed: added priority-high.

@rsc
Copy link
Contributor

rsc commented Apr 30, 2010

Comment 3:

This issue was closed by revision c66b498.

Status changed to Fixed.

@golang golang locked and limited conversation to collaborators Jun 24, 2016
@rsc rsc removed their assignment 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

2 participants