def _higher_function_scope(node):
current = node<EOL>while current.parent and not isinstance(current.parent, nodes.FunctionDef):<EOL><INDENT>current = current.parent<EOL><DEDENT>if current and current.parent:<EOL><INDENT>return current.parent<EOL><DEDENT>return None<EOL>
Search for the first function which encloses the given
    scope. This can be used for looking up in that function's
    scope, in case looking up in a lower scope for a particular
    name fails.

    :param node: A scope node.
    :returns:
        ``None``, if no parent function scope was found,
        otherwise an instance of :class:`astroid.scoped_nodes.Function`,
        which encloses the given node.