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

Use static assertions to bound-check const generics #1019

Merged
merged 1 commit into from
Feb 27, 2021

Conversation

Amanieu
Copy link
Member

@Amanieu Amanieu commented Feb 27, 2021

This builds on top of #1018 and prevents invalid constants from reaching LLVM and triggering assertions.

Thanks @lcnr and @RalfJung for helping me find a construct that works with const generics!

@rust-highfive
Copy link

@Amanieu: no appropriate reviewer found, use r? to override

@Amanieu Amanieu merged commit 3b52e06 into rust-lang:master Feb 27, 2021
@Amanieu Amanieu deleted the static_assert branch February 27, 2021 16:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants