git://scm.lunaixsky.com
/
lunaix-os.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
refine the documentation, add extra warning messages
[lunaix-os.git]
/
lunaix-os
/
scripts
/
build-tools
/
lcfg2
/
lazy.py
diff --git
a/lunaix-os/scripts/build-tools/lcfg2/lazy.py
b/lunaix-os/scripts/build-tools/lcfg2/lazy.py
index ddc02edad052be0a5eb1940b88c3efac0cff10be..1c634fd7a2006612b1812af596d0c42e642993f6 100644
(file)
--- a/
lunaix-os/scripts/build-tools/lcfg2/lazy.py
+++ b/
lunaix-os/scripts/build-tools/lcfg2/lazy.py
@@
-84,9
+84,14
@@
class Lazy:
type_ = astn.attr
target = astn.value.id
type_ = astn.attr
target = astn.value.id
+
+ return Lazy.from_type(cfgnode, type_, target)
+
+ @staticmethod
+ def from_type(cfgnode, type_, target):
key = Lazy.get_key_from(type_, target)
key = Lazy.get_key_from(type_, target)
-
lz = cfgnode._lazy_table.get(key)
lz = cfgnode._lazy_table.get(key)
+
if lz:
return key
if lz:
return key
@@
-94,3
+99,4
@@
class Lazy:
cfgnode._lazy_table.put(lz)
return key
cfgnode._lazy_table.put(lz)
return key
+