mirror of https://gitlab.com/ita1024/waf.git
Do not truncate _task suffixes from Task class names
This commit is contained in:
parent
0ba6b042d5
commit
508b20679d
|
@ -43,3 +43,5 @@ NEW IN WAF 1.9 preview 1
|
||||||
still define their own mappings to override the defaults, but in that case all mappings
|
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.
|
must be present. This feature was not used in Waf 1.8.
|
||||||
- Unused attribute 'mac_resources' is no longer supported, use mac_files (see demos/mac_app)
|
- 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
|
||||||
|
|
||||||
|
|
|
@ -85,8 +85,6 @@ class store_task_type(type):
|
||||||
super(store_task_type, cls).__init__(name, bases, dict)
|
super(store_task_type, cls).__init__(name, bases, dict)
|
||||||
name = cls.__name__
|
name = cls.__name__
|
||||||
|
|
||||||
if name.endswith('_task'):
|
|
||||||
name = name.replace('_task', '')
|
|
||||||
if name != 'evil' and name != 'TaskBase':
|
if name != 'evil' and name != 'TaskBase':
|
||||||
global classes
|
global classes
|
||||||
if getattr(cls, 'run_str', None):
|
if getattr(cls, 'run_str', None):
|
||||||
|
@ -392,8 +390,6 @@ class Task(TaskBase):
|
||||||
uses a hash value (from :py:class:`waflib.Task.Task.signature`) which is persistent from build to build. When the value changes,
|
uses a hash value (from :py:class:`waflib.Task.Task.signature`) which is persistent from build to build. When the value changes,
|
||||||
the task has to be executed. The method :py:class:`waflib.Task.Task.post_run` will assign the task signature to the output
|
the task has to be executed. The method :py:class:`waflib.Task.Task.post_run` will assign the task signature to the output
|
||||||
nodes (if present).
|
nodes (if present).
|
||||||
|
|
||||||
.. warning:: For backward compatibility reasons, the suffix "_task" is truncated in derived class names. This limitation will be removed in Waf 1.9.
|
|
||||||
"""
|
"""
|
||||||
vars = []
|
vars = []
|
||||||
"""Variables to depend on (class attribute used for :py:meth:`waflib.Task.Task.sig_vars`)"""
|
"""Variables to depend on (class attribute used for :py:meth:`waflib.Task.Task.sig_vars`)"""
|
||||||
|
@ -439,7 +435,7 @@ class Task(TaskBase):
|
||||||
tgt_str = ' '.join([a.path_from(a.ctx.launch_node()) for a in self.outputs])
|
tgt_str = ' '.join([a.path_from(a.ctx.launch_node()) for a in self.outputs])
|
||||||
if self.outputs: sep = ' -> '
|
if self.outputs: sep = ' -> '
|
||||||
else: sep = ''
|
else: sep = ''
|
||||||
return '%s: %s%s%s' % (self.__class__.__name__.replace('_task', ''), src_str, sep, tgt_str)
|
return '%s: %s%s%s' % (self.__class__.__name__, src_str, sep, tgt_str)
|
||||||
|
|
||||||
def keyword(self):
|
def keyword(self):
|
||||||
name = self.__class__.__name__
|
name = self.__class__.__name__
|
||||||
|
|
Loading…
Reference in New Issue