def _scope_lookup(self, node, name, offset=<NUM_LIT:0>):
try:<EOL><INDENT>stmts = node._filter_stmts(self.locals[name], self, offset)<EOL><DEDENT>except KeyError:<EOL><INDENT>stmts = ()<EOL><DEDENT>if stmts:<EOL><INDENT>return self, stmts<EOL><DEDENT>if self.parent:  <EOL><INDENT>pscope = self.parent.scope()<EOL>if not pscope.is_function:<EOL><INDENT>pscope = pscope.root()<EOL><DEDENT>return pscope.scope_lookup(node, name)<EOL><DEDENT>return builtin_lookup(name)<EOL>
XXX method for interfacing the scope lookup