##// END OF EJS Templates
Attempt to fix negative revision count from pull...
Attempt to fix negative revision count from pull -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Attempt to fix negative revision count from pull manifest hash: 4e8881037d545f4bf76d2c1b06f685b2467cd3a8 -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.0 (GNU/Linux) iD8DBQFCw4yUywK+sNU5EO8RApUkAKCCYTpBG3Wpu15aVeG0iBWE612S5wCgnSBi PEfXF4NI2O9AqWijOMBq6aM= =AyGw -----END PGP SIGNATURE-----

File last commit:

r262:3db70014 default
r529:aace5b68 default
Show More
demandload.py
15 lines | 384 B | text/x-python | PythonLexer
def demandload(scope, modules):
class d:
def __getattr__(self, name):
mod = self.__dict__["mod"]
scope = self.__dict__["scope"]
scope[mod] = __import__(mod, scope, scope, [])
return getattr(scope[mod], name)
for m in modules.split():
dl = d()
dl.mod = m
dl.scope = scope
scope[m] = dl