mirror of
https://github.com/roc-lang/roc.git
synced 2025-09-28 22:34:45 +00:00
provide target info to number alignment function
This commit is contained in:
parent
0298013346
commit
fbd26c598e
3 changed files with 32 additions and 16 deletions
|
@ -1341,10 +1341,10 @@ impl<'a> Builtin<'a> {
|
|||
// since both of those are one pointer size, the alignment of that structure is a pointer
|
||||
// size
|
||||
match self {
|
||||
Int(int_width) => int_width.alignment_bytes(),
|
||||
Float(float_width) => float_width.alignment_bytes(),
|
||||
Int(int_width) => int_width.alignment_bytes(target_info),
|
||||
Float(float_width) => float_width.alignment_bytes(target_info),
|
||||
Bool => align_of::<bool>() as u32,
|
||||
Decimal => IntWidth::I128.alignment_bytes(),
|
||||
Decimal => IntWidth::I128.alignment_bytes(target_info),
|
||||
Dict(_, _) => ptr_width,
|
||||
Set(_) => ptr_width,
|
||||
// we often treat these as i128 (64-bit systems)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue