Explorar el Código

Don't generate ifc New() for interfaces.

woollybah hace 8 años
padre
commit
3fc0bb9f87
Se han modificado 1 ficheros con 3 adiciones y 1 borrados
  1. 3 1
      ctranslator.bmx

+ 3 - 1
ctranslator.bmx

@@ -4891,7 +4891,9 @@ End Rem
 		' functions
 		If Not classDecl.IsExtern() Then
 
-			Emit "-New()=" + Enquote("_" + classDecl.munged + "_New")
+			If Not classDecl.attrs & CLASS_INTERFACE Then
+				Emit "-New()=" + Enquote("_" + classDecl.munged + "_New")
+			End If
 			If classHierarchyHasFunction(classDecl, "Delete") Then
 				Emit "-Delete()=" + Enquote("_" + classDecl.munged + "_Delete")
 			End If