repro:
using import testing
using import glm
let v1 = (vec4)
test
(typeof v1.st) == vec2
local v2 : vec4
dump (typeof v2.st) # vec4(vectorof i32 0 1)
test
(typeof v2.st) == vec2
This is actually not a bug. The repr string could be more helpful, but the type that's returned here is of supertype
vec-type-accessor
, and has to be cast tovec2
manually:(v2.st as vec2)
. This happens when the source value is a reference, so that the accessor can be used to perform assignments.