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

"reflect.Value.Slice3: slice of unaddressable array" when slicing arrays when iterating over maps #926

Open
zapateo opened this issue Dec 13, 2021 · 0 comments
Labels
bug Bug: something already implemented does not work as it should needsInvestigation Need to investigate RuntimeError A bug in Scriggo caused an error/panic at runtime

Comments

@zapateo
Copy link
Member

zapateo commented Dec 13, 2021

This code:

package main

func main() {

	m := map[string][3]int{}
	m["x"] = [3]int{10, 20, 30}

	for _, v := range m {
		s := v[:]
		_ = s
	}

}

should be valid, but it panics the Scriggo runtime with this error:

reflect.Value.Slice3: slice of unaddressable array

Note that this issue may be partially related to #376.

@zapateo zapateo added bug Bug: something already implemented does not work as it should needsInvestigation Need to investigate RuntimeError A bug in Scriggo caused an error/panic at runtime labels Dec 13, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Bug: something already implemented does not work as it should needsInvestigation Need to investigate RuntimeError A bug in Scriggo caused an error/panic at runtime
Projects
None yet
Development

No branches or pull requests

1 participant