Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Switch to using Core.BigInt as the type of the size of a type literal. #4450

Merged
merged 2 commits into from
Oct 28, 2024

Conversation

zygoloid
Copy link
Contributor

This removes one of the few ways in which i32 is special and gets us closer to removing it as a special case.

This removes one of the few ways in which `i32` is special and gets us
closer to removing it as a special case.
Copy link
Contributor

@jonmeow jonmeow left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Basically looks good, but might want to remove things from MakeBigIntLiteral before merging.

toolchain/check/handle_literal.cpp Outdated Show resolved Hide resolved
Comment on lines +56 to +58
// TODO: `IntId`s with different bit-widths are considered different values
// here. Decide how we want to canonicalize these. For now this is only used
// by type literals, so we rely on the lexer picking some consistent rule.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think Chandler was looking at this separately, you might want to talk with him. A TODO here might be lost, because this may be more of a TODO for the numeric literal lexer.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I couldn't find another good place for this TODO to live. I'll try to remember it once Chandler's change lands.

@zygoloid zygoloid enabled auto-merge October 28, 2024 23:27
@zygoloid zygoloid added this pull request to the merge queue Oct 28, 2024
Merged via the queue into carbon-language:trunk with commit df68bf9 Oct 28, 2024
8 checks passed
@zygoloid zygoloid deleted the toolchain-bigint-as-int-size branch October 28, 2024 23:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants