Do not define the empty prec object on task_gen instances by default

This commit is contained in:
Thomas Nagy 2016-04-26 19:22:56 +02:00
parent 508b20679d
commit ba1932ebc2
No known key found for this signature in database
GPG Key ID: 67A565EDFDF90E64
2 changed files with 5 additions and 10 deletions

View File

@ -39,9 +39,9 @@ NEW IN WAF 1.9 preview 1
- Better consistency between check_cfg and check_cc variables
- Subclass waflib.Build.ConfiguredContext to enable configuration-dependent user commands
- Remove Task.dep_vars as it is never used (define Task.vars on instances if necessary)
- task_gen.mapping is not defined by default on instances anymore, but instances can
still define their own mappings to override the defaults, but in that case all mappings
must be present. This feature was not used in Waf 1.8.
- task_gen.mapping and task_gen.prec are not defined by default on instances anymore, but
instances can still define their own mappings to override the defaults, but in
that case all mappings/precedences must be present. These features were not used in Waf 1.8.
- Unused attribute 'mac_resources' is no longer supported, use mac_files (see demos/mac_app)
- The _task suffix is no longer truncated from Task class names

View File

@ -61,11 +61,6 @@ class task_gen(object):
List of method names to execute (it is usually a good idea to avoid touching this)
"""
self.prec = Utils.defaultdict(list)
"""
Precedence table for sorting the methods in self.meths
"""
self.features = []
"""
List of feature names for bringing new methods in
@ -160,7 +155,7 @@ class task_gen(object):
#. The tasks created are added to :py:attr:`waflib.TaskGen.task_gen.tasks`
"""
if getattr(self, 'posted', None):
#error("OBJECT ALREADY POSTED" + str( self))
#error("Task Generator already posted" + str(self))
return False
self.posted = True
@ -177,7 +172,7 @@ class task_gen(object):
# copy the precedence table
prec = {}
prec_tbl = self.prec or task_gen.prec
prec_tbl = self.prec
for x in prec_tbl:
if x in keys:
prec[x] = prec_tbl[x]