Skip to content

TypeSize is not granular enough #650

@onbjerg

Description

@onbjerg

Reproducible steps

TypeSize stores ceil(bit_len/8), so int_literal[1] covers the range 0-255.

This means we can't distinguish edge cases like 127 (fits in int8) from 128 (doesn't fit), which is problematic for implicit and explicit integer conversions.

See #633 (comment) for additional discussion.

Solar version

N/A

Metadata

Metadata

Assignees

Labels

C-bugCategory: this is a bug

Type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions