simplify apply_requires
This commit is contained in:
parent
a14e156a63
commit
9a912376b9
|
@ -624,17 +624,20 @@ class Settings(object):
|
||||||
:param path: the option's path in the config
|
:param path: the option's path in the config
|
||||||
:type path: str
|
:type path: str
|
||||||
"""
|
"""
|
||||||
if opt.impl_getrequires() == []:
|
current_requires = opt.impl_getrequires()
|
||||||
return frozenset()
|
|
||||||
|
|
||||||
# filters the callbacks
|
# filters the callbacks
|
||||||
if debug:
|
if debug:
|
||||||
calc_properties = {}
|
calc_properties = {}
|
||||||
else:
|
else:
|
||||||
calc_properties = set()
|
calc_properties = set()
|
||||||
|
|
||||||
|
if not current_requires:
|
||||||
|
return calc_properties
|
||||||
|
|
||||||
context = self._getcontext()
|
context = self._getcontext()
|
||||||
all_properties = None
|
all_properties = None
|
||||||
for requires in opt.impl_getrequires():
|
for requires in current_requires:
|
||||||
for require in requires:
|
for require in requires:
|
||||||
option, expected, action, inverse, \
|
option, expected, action, inverse, \
|
||||||
transitive, same_action = require
|
transitive, same_action = require
|
||||||
|
|
Loading…
Reference in New Issue