fixed bug in creation of dynamic classes
authorkramm <kramm>
Tue, 30 Dec 2008 23:00:07 +0000 (23:00 +0000)
committerkramm <kramm>
Tue, 30 Dec 2008 23:00:07 +0000 (23:00 +0000)
lib/as3/parser.y

index 9940fa5..19c878b 100644 (file)
@@ -903,6 +903,8 @@ code_t*converttype(code_t*c, classinfo_t*from, classinfo_t*to)
     }
     if(TYPE_IS_FUNCTION(from) && TYPE_IS_FUNCTION(to))
         return c;
+    if(TYPE_IS_CLASS(from) && TYPE_IS_CLASS(to))
+        return c;
     syntaxerror("can't convert type %s to %s", from->name, to->name);
 }