Fix set_immediate_value & update debugging