Lifting Generics from MethodSig to TraitItem and ImplItem since we want to support generics in each variant of TraitItem and ImplItem

This commit is contained in:
Sunjay Varma
2017-09-21 22:18:47 -04:00
parent f6d7514545
commit f61394f0bd
11 changed files with 51 additions and 40 deletions

View File

@@ -1178,7 +1178,6 @@ pub struct MethodSig {
pub constness: Spanned<Constness>,
pub abi: Abi,
pub decl: P<FnDecl>,
pub generics: Generics,
}
/// Represents an item declaration within a trait declaration,
@@ -1190,6 +1189,7 @@ pub struct TraitItem {
pub id: NodeId,
pub ident: Ident,
pub attrs: Vec<Attribute>,
pub generics: Generics,
pub node: TraitItemKind,
pub span: Span,
/// See `Item::tokens` for what this is
@@ -1211,6 +1211,7 @@ pub struct ImplItem {
pub vis: Visibility,
pub defaultness: Defaultness,
pub attrs: Vec<Attribute>,
pub generics: Generics,
pub node: ImplItemKind,
pub span: Span,
/// See `Item::tokens` for what this is