Commit dc9cf16 1 parent 7dcfac7 commit dc9cf16 Copy full SHA for dc9cf16
File tree 1 file changed +6
-0
lines changed
1 file changed +6
-0
lines changed Original file line number Diff line number Diff line change 1
1
use super :: * ;
2
2
use proc_macro2:: TokenStream ;
3
+ #[ cfg( feature = "printing" ) ]
3
4
use std:: iter;
5
+ #[ cfg( feature = "printing" ) ]
4
6
use std:: slice;
5
7
6
8
#[ cfg( feature = "parsing" ) ]
@@ -582,13 +584,16 @@ impl MetaList {
582
584
}
583
585
}
584
586
587
+ #[ cfg( feature = "printing" ) ]
585
588
pub ( crate ) trait FilterAttrs < ' a > {
586
589
type Ret : Iterator < Item = & ' a Attribute > ;
587
590
588
591
fn outer ( self ) -> Self :: Ret ;
592
+ #[ cfg( feature = "full" ) ]
589
593
fn inner ( self ) -> Self :: Ret ;
590
594
}
591
595
596
+ #[ cfg( feature = "printing" ) ]
592
597
impl < ' a > FilterAttrs < ' a > for & ' a [ Attribute ] {
593
598
type Ret = iter:: Filter < slice:: Iter < ' a , Attribute > , fn ( & & Attribute ) -> bool > ;
594
599
@@ -602,6 +607,7 @@ impl<'a> FilterAttrs<'a> for &'a [Attribute] {
602
607
self . iter ( ) . filter ( is_outer)
603
608
}
604
609
610
+ #[ cfg( feature = "full" ) ]
605
611
fn inner ( self ) -> Self :: Ret {
606
612
fn is_inner ( attr : & & Attribute ) -> bool {
607
613
match attr. style {
You can’t perform that action at this time.
0 commit comments