Guarantee that the never type ! is zero-sized and 1-aligned. - #2309
Guarantee that the never type ! is zero-sized and 1-aligned.#2309zachs18 wants to merge 2 commits into
! is zero-sized and 1-aligned.#2309Conversation
This comment has been minimized.
This comment has been minimized.
|
@rustbot label I-lang-nominated cc @traviscross |
|
Error: Label I-lang-nominated can only be set by Rust team members Please file an issue on GitHub at triagebot if there's a problem with this bot, or reach out on #triagebot on Zulip. |
| r[type.never.coercion] | ||
| Expressions of type `!` can be coerced into any type. | ||
|
|
||
|
|
There was a problem hiding this comment.
no need for two blank lines here, one should be enough
There was a problem hiding this comment.
Latest push removes the extra blank line.
| assert_eq!(0, size_of::<E4>()); | ||
| assert_eq!(0, size_of::<E5>()); | ||
| assert_eq!(0, size_of::<E6>()); | ||
| assert_eq!(0, size_of::<E7>()); |
There was a problem hiding this comment.
there should also be an example in the test block here
| assert_eq!(0, size_of::<!>()); |
There was a problem hiding this comment.
Latest push adds this example at the top of the list just after ()'s line, so they're still in the same order as the list in the prose.
|
@traviscross has proposed to merge this. The next step is review by the rest of the tagged team members:
No concerns currently listed. Once a majority of reviewers approve (and at most 2 approvals are outstanding), this will enter its final comment period. If you spot a major issue that hasn't been raised at any point in this process, please speak up! cc @rust-lang/lang-advisors: FCP proposed for lang, please feel free to register concerns. |
|
@rfcbot reviewed |
Needs T-lang FCP.