diff options
Diffstat (limited to 'bitbake')
-rw-r--r-- | bitbake/lib/bb/methodpool.py | 17 | ||||
-rw-r--r-- | bitbake/lib/bb/parse/ast.py | 1 | ||||
-rw-r--r-- | bitbake/lib/bb/parse/parse_py/BBHandler.py | 2 |
3 files changed, 10 insertions, 10 deletions
diff --git a/bitbake/lib/bb/methodpool.py b/bitbake/lib/bb/methodpool.py index 3b8e5c1137..2fb5d96a3f 100644 --- a/bitbake/lib/bb/methodpool.py +++ b/bitbake/lib/bb/methodpool.py | |||
@@ -33,9 +33,7 @@ | |||
33 | from bb.utils import better_compile, better_exec | 33 | from bb.utils import better_compile, better_exec |
34 | from bb import error | 34 | from bb import error |
35 | 35 | ||
36 | # A dict of modules we have handled | 36 | # A dict of function names we have seen |
37 | # it is the number of .bbclasses + x in size | ||
38 | _parsed_methods = { } | ||
39 | _parsed_fns = { } | 37 | _parsed_fns = { } |
40 | 38 | ||
41 | def insert_method(modulename, code, fn): | 39 | def insert_method(modulename, code, fn): |
@@ -56,15 +54,18 @@ def insert_method(modulename, code, fn): | |||
56 | else: | 54 | else: |
57 | _parsed_fns[name] = modulename | 55 | _parsed_fns[name] = modulename |
58 | 56 | ||
57 | # A dict of modules the parser has finished with | ||
58 | _parsed_methods = {} | ||
59 | |||
59 | def parsed_module(modulename): | 60 | def parsed_module(modulename): |
60 | """ | 61 | """ |
61 | Inform me file xyz was parsed | 62 | Has module been parsed? |
62 | """ | 63 | """ |
63 | return modulename in _parsed_methods | 64 | return modulename in _parsed_methods |
64 | 65 | ||
65 | 66 | def set_parsed_module(modulename): | |
66 | def get_parsed_dict(): | ||
67 | """ | 67 | """ |
68 | shortcut | 68 | Set module as parsed |
69 | """ | 69 | """ |
70 | return _parsed_methods | 70 | _parsed_methods[modulename] = True |
71 | |||
diff --git a/bitbake/lib/bb/parse/ast.py b/bitbake/lib/bb/parse/ast.py index b88d5f5b39..4d3a623aa2 100644 --- a/bitbake/lib/bb/parse/ast.py +++ b/bitbake/lib/bb/parse/ast.py | |||
@@ -31,7 +31,6 @@ import itertools | |||
31 | from bb import methodpool | 31 | from bb import methodpool |
32 | from bb.parse import logger | 32 | from bb.parse import logger |
33 | 33 | ||
34 | __parsed_methods__ = bb.methodpool.get_parsed_dict() | ||
35 | _bbversions_re = re.compile(r"\[(?P<from>[0-9]+)-(?P<to>[0-9]+)\]") | 34 | _bbversions_re = re.compile(r"\[(?P<from>[0-9]+)-(?P<to>[0-9]+)\]") |
36 | 35 | ||
37 | class StatementGroup(list): | 36 | class StatementGroup(list): |
diff --git a/bitbake/lib/bb/parse/parse_py/BBHandler.py b/bitbake/lib/bb/parse/parse_py/BBHandler.py index 625a2a21fd..2e0647b5df 100644 --- a/bitbake/lib/bb/parse/parse_py/BBHandler.py +++ b/bitbake/lib/bb/parse/parse_py/BBHandler.py | |||
@@ -161,7 +161,7 @@ def handle(fn, d, include): | |||
161 | 161 | ||
162 | # we have parsed the bb class now | 162 | # we have parsed the bb class now |
163 | if ext == ".bbclass" or ext == ".inc": | 163 | if ext == ".bbclass" or ext == ".inc": |
164 | bb.methodpool.get_parsed_dict()[base_name] = 1 | 164 | bb.methodpool.set_parsed_module(base_name) |
165 | 165 | ||
166 | return d | 166 | return d |
167 | 167 | ||