diff options
| -rw-r--r-- | kconfiglib.py | 38 |
1 files changed, 19 insertions, 19 deletions
diff --git a/kconfiglib.py b/kconfiglib.py index b65fe00..f111fe5 100644 --- a/kconfiglib.py +++ b/kconfiglib.py @@ -2875,25 +2875,6 @@ class Symbol(object): return (1,) - def _rec_invalidate_if_has_prompt(self): - """ - Invalidates the symbol and its dependent symbols, but only if the - symbol has a prompt. User values never have an effect on promptless - symbols, so we skip invalidation for them as an optimization. - - Prints a warning if the symbol has no prompt. In some contexts (e.g. - when loading a .config files) assignments to promptless symbols are - normal and expected, so the warning can be disabled. - """ - for node in self.nodes: - if node.prompt: - self._rec_invalidate() - return - - if self.kconfig._warn_no_prompt: - self.kconfig._warn(self.name + " has no prompt, meaning user " - "values have no effect on it") - def _invalidate(self): """ Marks the symbol as needing to be recalculated. @@ -2933,6 +2914,25 @@ class Symbol(object): if item._cached_vis is not None: item._rec_invalidate() + def _rec_invalidate_if_has_prompt(self): + """ + Invalidates the symbol and its dependent symbols, but only if the + symbol has a prompt. User values never have an effect on promptless + symbols, so we skip invalidation for them as an optimization. + + Prints a warning if the symbol has no prompt. In some contexts (e.g. + when loading a .config files) assignments to promptless symbols are + normal and expected, so the warning can be disabled. + """ + for node in self.nodes: + if node.prompt: + self._rec_invalidate() + return + + if self.kconfig._warn_no_prompt: + self.kconfig._warn(self.name + " has no prompt, meaning user " + "values have no effect on it") + class Choice(object): """ Represents a choice statement: |
