Nope! You can put any type for result, and still get the same error.
I’m not sure why you are bringing up arrays. Operations between vectors result in a vector, and they have to be the same length. Even if you use @splat, it will not fill in the rest.
Vectors do coerce to/from arrays, but that isn’t relevant to this issue.
It is also not specifically the length, but the whole result type that @splat doesn’t know.
Please try to compile and run code before answering people.
you’re asking why this cannot be deduced when the only valid right hand to the + operator on foo should be a Vector(2, i16). Problem is that it doesn’t have to be a @Vector(2, i16) just any @Vector(2, X)