Skip to content

Commit

Permalink
Auto merge of #65690 - flip1995:readd_derives_clippy, r=Centril
Browse files Browse the repository at this point in the history
Readd some PartialEq and Hash derives used by Clippy

cc #65647

r? @Centril cc @Manishearth
  • Loading branch information
bors committed Oct 22, 2019
2 parents 57bfb80 + 67c8a0f commit 68cfd58
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 4 deletions.
9 changes: 6 additions & 3 deletions src/libsyntax/ast.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1305,7 +1305,8 @@ impl MacroDef {
}
}

#[derive(Clone, RustcEncodable, RustcDecodable, Debug, Copy)]
// Clippy uses Hash and PartialEq
#[derive(Clone, RustcEncodable, RustcDecodable, Debug, Copy, Hash, PartialEq)]
pub enum StrStyle {
/// A regular string, like `"foo"`.
Cooked,
Expand All @@ -1327,7 +1328,8 @@ pub struct Lit {
pub span: Span,
}

#[derive(Clone, RustcEncodable, RustcDecodable, Debug, Copy)]
// Clippy uses Hash and PartialEq
#[derive(Clone, RustcEncodable, RustcDecodable, Debug, Copy, Hash, PartialEq)]
pub enum LitIntType {
Signed(IntTy),
Unsigned(UintTy),
Expand All @@ -1337,7 +1339,8 @@ pub enum LitIntType {
/// Literal kind.
///
/// E.g., `"foo"`, `42`, `12.34`, or `bool`.
#[derive(Clone, RustcEncodable, RustcDecodable, Debug)]
// Clippy uses Hash and PartialEq
#[derive(Clone, RustcEncodable, RustcDecodable, Debug, Hash, PartialEq)]
pub enum LitKind {
/// A string literal (`"foo"`).
Str(Symbol, StrStyle),
Expand Down
2 changes: 1 addition & 1 deletion src/tools/clippy

0 comments on commit 68cfd58

Please sign in to comment.