diff options
Diffstat (limited to 'src/id.cc')
| -rw-r--r-- | src/id.cc | 10 | 
1 files changed, 2 insertions, 8 deletions
@@ -66,44 +66,38 @@ void ID::advance_helper()  {  	signed int s1, s2, s3;  	Mnemonic m; -	Type t;  	if (curr_instr->mnemonic == NOP)  		this->status = OK;  	else {  		s1 = curr_instr->slot_A; -		get_instr_fields(s1, s2, s3, m, t); +		get_instr_fields(s1, s2, s3, m);  		if (this->status == OK) {  			curr_instr->operands.integer.slot_one = s1;  			curr_instr->operands.integer.slot_two = s2;  			curr_instr->operands.integer.slot_three = s3;  			curr_instr->mnemonic = m; -			curr_instr->type = t;  		}  	}  }  void ID::get_instr_fields( -	signed int &s1, signed int &s2, signed int &s3, Mnemonic &m, Type &t) +	signed int &s1, signed int &s2, signed int &s3, Mnemonic &m)  {  	unsigned int type;  	this->split_instr(s1, type, m);  	switch (type) {  	case 0b00: -		t = R;  		this->decode_R_type(s1, s2, s3, m);  		break;  	case 0b01: -		t = I;  		this->decode_I_type(s1, s2, s3, m);  		break;  	case 0b10: -		t = J;  		this->decode_J_type(s1, s2, s3, m);  		break;  	case 0b11: -		t = INV;  		this->status = OK;  	}  }  | 
