Odin
Odin copied to clipboard
Slice of fixed array literal is initialized all nils vs literal values
Incorrect initialization of variable of any type Slice of fixed array literal of type any is initialized with nils vs provided literal values
package main
import "core:fmt"
main :: proc() {
a: [][2]any = {
0 ..< 2 = 100,
}
fmt.println(a) // [[<nil>, <nil>], [<nil>, <nil>]]
}
should be
[[100, 100], [100, 100]]