[meta] Delegate finding the default value to OperandKind instead of its builder.
This applies both to the default_member value (which is now determined at runtime, instead of pre-computed) and the rust_type value (which is determined in the Operand's ctor, instead of the builder).
This commit is contained in:
@@ -127,7 +127,7 @@ impl InstructionFormatBuilder {
|
||||
pub fn imm(mut self, operand_kind: &OperandKind) -> Self {
|
||||
let field = FormatField {
|
||||
kind: operand_kind.clone(),
|
||||
member: operand_kind.default_member.unwrap(),
|
||||
member: operand_kind.default_member().unwrap(),
|
||||
};
|
||||
self.imm_fields.push(field);
|
||||
self
|
||||
|
||||
Reference in New Issue
Block a user