Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Represent the result of parsing all `#[repr(...)]` attributes on a type as a high-level type which is only capable of representing valid combinations of `#[repr(...)]` attributes and processes them into a concise representation that's easier for high-level code to work with. This prepares us to more easily fix #1748. While we're here, we make a number of other improvements. 1) Errors are now converted to `TokenStream`s as late as possible rather than as early as possible, which was the previous behavior. This allows us to bail early when deriving an implied trait fails (e.g., deriving `TryFromBytes` when the user wrote `#[derive(FromZeros)]`). 2) Avoid re-computing some repr information in `TryFromBytes` enum support.
- Loading branch information