Created
September 25, 2020 02:33
-
-
Save rvalyi/e7d1feceb59b0bbbe422a1903630d68f to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- generateDS-2.36.2.py 2020-09-24 23:28:32.078256200 -0300 | |
+++ /usr/local/bin/generateDS.py 2020-09-24 23:31:04.373630855 -0300 | |
@@ -1103,7 +1103,7 @@ | |
if self.isMixed(): | |
return True | |
base = self.getBase() | |
- if base and base in ElementDict: | |
+ if base and base in ElementDict and str(base) != self.type: | |
parent = ElementDict[base] | |
return parent.hasMixedInChain() | |
else: | |
@@ -1119,7 +1119,7 @@ | |
def checkMixedBasesChain(self, child, childMixed): | |
base = self.getBase() | |
- if base and base in ElementDict: | |
+ if base and base in ElementDict and str(base) != self.type: | |
parent = ElementDict[base] | |
if childMixed != parent.isMixed(): | |
self.mixedExtensionError = 1 | |
@@ -1426,7 +1426,7 @@ | |
for child in self.children: | |
elementNames.add(child.getCleanName()) | |
base = self.getBase() | |
- if base and base in ElementDict: | |
+ if base and base in ElementDict and str(base) != self.type: | |
parent = ElementDict[base] | |
count += 1 | |
if count > 100: | |
@@ -3096,7 +3096,7 @@ | |
def countChildren(element, count): | |
count += len(element.getChildren()) | |
base = element.getBase() | |
- if base and base in ElementDict: | |
+ if base and base in ElementDict and str(base) != element.type: | |
parent = ElementDict[base] | |
count = countChildren(parent, count) | |
return count | |
@@ -4736,7 +4736,7 @@ | |
def buildCtorArgs_multilevel_aux(addedArgs, add, element): | |
parentName, parentObj = getParentName(element) | |
- if parentName: | |
+ if parentName and parentName != element.type: | |
buildCtorArgs_multilevel_aux(addedArgs, add, parentObj) | |
buildCtorArgs_aux(addedArgs, add, element) | |
@@ -7722,7 +7722,7 @@ | |
def buildCtorParams_aux(addedArgs, add, element): | |
parentName, parentObj = getParentName(element) | |
- if parentName: | |
+ if parentName and parentName != element.name: | |
buildCtorParams_aux(addedArgs, add, parentObj) | |
attrDefs = element.getAttributeDefs() | |
for key in element.getAttributeDefsList(): | |
@@ -8493,8 +8493,8 @@ | |
parentName in SimpleTypeDict): | |
generateClasses(wrt, prefix, element, 1) | |
generatedClasses.add(element.getCleanName()) | |
- else: | |
- PostponedExtensions.insert(0, element) | |
+# else: | |
+# PostponedExtensions.insert(0, element) | |
# | |
# Disable the generation of SAX handler/parser. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment