def lazyload(reference: str, *args, **kw):
assert check_argument_types()<EOL>def lazily_load_reference(self):<EOL><INDENT>ref = reference<EOL>if ref.startswith('<STR_LIT:.>'):<EOL><INDENT>ref = traverse(self, ref[<NUM_LIT:1>:])<EOL><DEDENT>return load(ref, *args, **kw)<EOL><DEDENT>return lazy(lazily_load_reference)<EOL>
Lazily load and cache an object reference upon dereferencing.

    Assign the result of calling this function with either an object reference passed in positionally:

            class MyClass:
                    debug = lazyload('logging:debug')

    Or the attribute path to traverse (using `marrow.package.loader:traverse`) prefixed by a period.

            class AnotherClass:
                    target = 'logging:info'
                    log = lazyload('.target')

    Additional arguments are passed to the eventual call to `load()`.