-
Notifications
You must be signed in to change notification settings - Fork 12.8k
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 derive macro for HashStable #56864
Conversation
(rust_highfive has picked a reviewer for you, use r? to override) |
This comment has been minimized.
This comment has been minimized.
fa13d01
to
8067955
Compare
Looks promising! |
This comment has been minimized.
This comment has been minimized.
8067955
to
4482fd6
Compare
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
[WIP] Allocate HIR on an arena Blocked on #56864
436166c
to
87dca52
Compare
This comment has been minimized.
This comment has been minimized.
87dca52
to
4f03dfb
Compare
This comment has been minimized.
This comment has been minimized.
Create a derive macro for HashStable and allow proc macros in rustc A combination of #56864 and #56795. There were complications with using `serde_derive` as rustc doesn't know which crate to use for the host when there is a serde_derive in the sysroot and cargo passes another on the command line built from crates.io. r? @eddyb (for proc macro changes) @alexcrichton (for rustbuild changes) @michaelwoerister (for the macro itself)
pub struct EnumDef { | ||
pub variants: HirVec<Variant>, | ||
} | ||
|
||
#[derive(Clone, RustcEncodable, RustcDecodable, Debug)] | ||
#[derive(Clone, RustcEncodable, RustcDecodable, Debug, HashStable)] | ||
pub struct VariantKind { | ||
pub ident: Ident, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This seems to be missing a projection attribute.
pub enum AssociatedItemKind { | ||
Const, | ||
Method { has_self: bool }, | ||
Type, | ||
Existential, | ||
} | ||
|
||
#[derive(Clone, RustcEncodable, RustcDecodable, Debug)] | ||
#[derive(Clone, RustcEncodable, RustcDecodable, Debug, HashStable)] | ||
pub struct ForeignItem { | ||
pub ident: Ident, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This too.
Beautiful, thanks @Zoxc! r=me with the two nits addressed. @rust-lang/compiler, please marvel at the diff stats of this PR |
@bors r=michaelwoerister |
📌 Commit bc3a84a has been approved by |
⌛ Testing commit bc3a84a with merge 09cf073a10bb65a550dd3082e2a7511a7d43dd8f... |
💥 Test timed out |
@bors retry |
Use derive macro for HashStable Blocked on #56795
☀️ Test successful - checks-travis, status-appveyor |
Blocked on #56795