def check_cycle(reg, assignments):
 return check_cycle_(reg, assignments, [])

def check_cycle ( reg , assignments ) : return check_cycle_ ( reg , assignments , [ ] )
walk down the assignment list of a register .