@_with_ast_loc<EOL>def _set_bang_to_py_ast(ctx: GeneratorContext, node: SetBang) -> GeneratedPyAST:
assert node.op == NodeOp.SET_BANG<EOL>val_temp_name = genname("<STR_LIT>")<EOL>val_ast = gen_py_ast(ctx, node.val)<EOL>target = node.target<EOL>assert isinstance(<EOL>target, (HostField, Local, VarRef)<EOL>), f"<STR_LIT>"<EOL>if isinstance(target, HostField):<EOL><INDENT>target_ast = _interop_prop_to_py_ast(ctx, target, is_assigning=True)<EOL><DEDENT>elif isinstance(target, VarRef):<EOL><INDENT>target_ast = _var_sym_to_py_ast(ctx, target, is_assigning=True)<EOL><DEDENT>elif isinstance(target, Local):<EOL><INDENT>target_ast = _local_sym_to_py_ast(ctx, target, is_assigning=True)<EOL><DEDENT>else:  <EOL><INDENT>raise GeneratorException(<EOL>f"<STR_LIT>", lisp_ast=target<EOL>)<EOL><DEDENT>return GeneratedPyAST(<EOL>node=ast.Name(id=val_temp_name, ctx=ast.Load()),<EOL>dependencies=list(<EOL>chain(<EOL>val_ast.dependencies,<EOL>[<EOL>ast.Assign(<EOL>targets=[ast.Name(id=val_temp_name, ctx=ast.Store())],<EOL>value=val_ast.node,<EOL>)<EOL>],<EOL>target_ast.dependencies,<EOL>[ast.Assign(targets=[target_ast.node], value=val_ast.node)],<EOL>)<EOL>),<EOL>)<EOL>
Return a Python AST Node for a `set!` expression.