Revert auto-propagating the mustHaveAppFlag from classes to their static methods, if any, and explicitly set the flag on only those static methods that need it instead.

This commit is contained in:
Robin Dunn
2017-03-21 15:55:10 -07:00
parent 088ba0ccdf
commit 875c9677ac
12 changed files with 42 additions and 9 deletions

View File

@@ -428,11 +428,10 @@ from .%s import *
if klass.ignored:
return
# Propagate mustHaveApp setting to the ctors and static methods
# Propagate mustHaveApp setting to the ctors
if klass.mustHaveAppFlag:
for item in klass.allItems():
if isinstance(item, extractors.MethodDef) and \
(item.isCtor or item.isStatic):
if isinstance(item, extractors.MethodDef) and item.isCtor:
item.mustHaveApp(True)
# write the class header