def make_assignment(instr, queue, stack):
    """
    Make an ast.Assign node.
    """
    value = make_expr(stack)

    # Make assignment targets.
    # If there are multiple assignments (e.g. 'a = b = c'),
    # each LHS expression except the last is preceded by a DUP_TOP instruction.
    # Thus, we make targets until we don't see a DUP_TOP, and then make one
    # more.
    targets = []
    while isinstance(instr, instrs.DUP_TOP):
        targets.append(make_assign_target(queue.popleft(), queue, stack))
        instr = queue.popleft()

    targets.append(make_assign_target(instr, queue, stack))

    return ast.Assign(targets=targets, value=value)
def make_assignment ( instr , queue , stack ) : value = make_expr ( stack ) targets = [ ] while isinstance ( instr , instrs . DUP_TOP ) : targets . append ( make_assign_target ( queue . popleft ( ) , queue , stack ) ) instr = queue . popleft ( ) targets . append ( make_assign_target ( instr , queue , stack ) ) return ast . Assign ( targets = targets , value = value )
Make an ast.Assign node.