The latest SVN revision with the copy constructor changes seems to have broken some my vector bindings (which were working fine before).
class Foo {
Foo() {}
//Foo(int x) {} // Uncomment this to fix the problem
vec2 v;
}
Foo LerpTest() {
Foo p;
p.v = vec2(1, 2);
return p;
}
void Main() {
print(LerpTest().v); // <-7.48036e-16, 7.91734e-43>
}
The above example will print out broken values in the vector, unless there is another constructor with 1 parameter. If you uncomment the second Foo
constructor it will fix the problem, but if you add another parameter to the constructor, it's broken again.
The vec2
copy constructor has a declaration of void f(const vec2 &in)
and a behavior of asBEHAVE_CONSTRUCT
.
Are my vector bindings wrong after all, or is it a bug in the new default copy constructor changes?