@@ -342,25 +342,6 @@ impl<'a> PostExpansionVisitor<'a> {
342342 }
343343 }
344344
345- fn check_gat ( & self , generics : & ast:: Generics , span : Span ) {
346- if !generics. params . is_empty ( ) {
347- gate_feature_post ! (
348- & self ,
349- generic_associated_types,
350- span,
351- "generic associated types are unstable"
352- ) ;
353- }
354- if !generics. where_clause . predicates . is_empty ( ) {
355- gate_feature_post ! (
356- & self ,
357- generic_associated_types,
358- span,
359- "where clauses on associated types are unstable"
360- ) ;
361- }
362- }
363-
364345 /// Feature gate `impl Trait` inside `type Alias = $type_expr;`.
365346 fn check_impl_trait ( & self , ty : & ast:: Ty ) {
366347 struct ImplTraitVisitor < ' a > {
@@ -719,7 +700,7 @@ impl<'a> Visitor<'a> for PostExpansionVisitor<'a> {
719700 fn visit_assoc_item ( & mut self , i : & ' a ast:: AssocItem , ctxt : AssocCtxt ) {
720701 let is_fn = match i. kind {
721702 ast:: AssocItemKind :: Fn ( _) => true ,
722- ast:: AssocItemKind :: TyAlias ( box ast:: TyAlias { ref generics , ref ty, .. } ) => {
703+ ast:: AssocItemKind :: TyAlias ( box ast:: TyAlias { ref ty, .. } ) => {
723704 if let ( Some ( _) , AssocCtxt :: Trait ) = ( ty, ctxt) {
724705 gate_feature_post ! (
725706 & self ,
@@ -731,7 +712,6 @@ impl<'a> Visitor<'a> for PostExpansionVisitor<'a> {
731712 if let Some ( ty) = ty {
732713 self . check_impl_trait ( ty) ;
733714 }
734- self . check_gat ( generics, i. span ) ;
735715 false
736716 }
737717 _ => false ,
0 commit comments