mirror of
https://gitlab.cern.ch/wotsubo/endcap-sl-software-ri-generator.git
synced 2025-02-23 00:57:08 +09:00
fix: add explicit casting in single Ux field generation (Now, it atually passed compiling!)
This commit is contained in:
parent
d2f9cd603f
commit
cb67f9648b
1 changed files with 1 additions and 1 deletions
|
@ -297,7 +297,7 @@ fn generate_single_ux_field(
|
|||
};
|
||||
let code_setter = quote! {
|
||||
pub fn #setter_name(&self, val: #field_type) -> Self {
|
||||
let update: #base_type = val & #mask_name;
|
||||
let update: #base_type = (val as #base_type) & #mask_name;
|
||||
let mut inner = self.inner;
|
||||
inner &= !#mask_name;
|
||||
inner |= update;
|
||||
|
|
Loading…
Reference in a new issue