Hi
I think variant "b is a" - valid, but compiler say no
class A{}
class B : A{}
void startGame( string ¶m )
{
A @a;
B @b;
if( a is b )
{}
if( b is a ) // No conversion from 'A@&' to 'B@' available.
{}
}
Hi
I think variant "b is a" - valid, but compiler say no
class A{}
class B : A{}
void startGame( string ¶m )
{
A @a;
B @b;
if( a is b )
{}
if( b is a ) // No conversion from 'A@&' to 'B@' available.
{}
}
Yes, you're probably right. The compiler should probably try an implicit cast of the first operand if the implicit cast of the second operand is not possible.
I'll look into this.
AngelCode.com - game development and more - Reference DB - game developer references
AngelScript - free scripting library - BMFont - free bitmap font generator - Tower - free puzzle game