Modify FunctionDef node to directly assign instead of return.

def rewrite_return_as_assignments(func_node, interface):
    """Modify FunctionDef node to directly assign instead of return."""
    func_node = _RewriteReturn(interface).visit(func_node)
    ast.fix_missing_locations(func_node)
    return func_node