def _get_scope_with_symbol(self, name):
        scope = self
        while True:
            parent = scope.get_enclosing_scope()
            if parent is None:
                return

            if name in parent.symbols:
                return parent

            scope = parent
Return a scope containing passed name as a symbol name.
dataset/ETHPy150Open rspivak/slimit/src/slimit/scope.py/Scope._get_scope_with_symbol