Browse Source

Fixed 'superclass has not default ctor' class extension issue..

Mark Sibly 9 năm trước cách đây
mục cha
commit
42867aafe7
1 tập tin đã thay đổi với 1 bổ sung2 xóa
  1. 1 2
      src/mx2cc/class.monkey2

+ 1 - 2
src/mx2cc/class.monkey2

@@ -273,14 +273,13 @@ Class ClassType Extends Type
 				If func.ftype.argTypes Continue
 				hasDefaultCtor=True
 			Next
-		Else
+		Else If Not cdecl.IsExtension
 			If superType And Not superType.hasDefaultCtor
 				Try
 					Throw New SemantEx( "Super class '"+superType.Name+"' has no default constructor" )
 				Catch ex:SemantEx
 				End
 			Endif
-			
 			hasDefaultCtor=True
 		Endif