File tree 2 files changed +39
-1
lines changed
2 files changed +39
-1
lines changed Original file line number Diff line number Diff line change 35
35
- uses : dtolnay/rust-toolchain@master
36
36
with :
37
37
toolchain : ${{ matrix.rust }}
38
- - run : cargo check ${{ matrix.features }}
38
+ - run : cargo clippy ${{ matrix.features }}
39
39
40
40
test :
41
41
name : test
Original file line number Diff line number Diff line change
1
+ //! This module helps suppress two kinds of warnings: `deprecated` and `unstable_name_collisions`.
2
+ //! New items are created that are noop-wrappers of the original items.
3
+ //! The items' original paths are preserved.
4
+
5
+ use itertools:: Itertools ;
6
+
7
+ pub mod free {
8
+ // it seems the compiler is not able to discern that this is used
9
+ #[ allow( dead_code) ]
10
+ pub fn zip < I , J > ( i : I , j : J ) -> core:: iter:: Zip < I :: IntoIter , J :: IntoIter >
11
+ where I : IntoIterator ,
12
+ J : IntoIterator
13
+ {
14
+ #[ allow( deprecated) ]
15
+ itertools:: free:: zip ( i, j)
16
+ }
17
+ }
18
+
19
+ pub trait Ext : Itertools {
20
+ fn intersperse_wrap ( self , element : Self :: Item ) -> itertools:: Intersperse < Self >
21
+ where
22
+ Self : Sized ,
23
+ Self :: Item : Clone ,
24
+ {
25
+ <Self as Itertools >:: intersperse ( self , element)
26
+ }
27
+
28
+ fn fold1_wrap < F > ( self , f : F ) -> Option < Self :: Item >
29
+ where F : FnMut ( Self :: Item , Self :: Item ) -> Self :: Item ,
30
+ Self : Sized ,
31
+ {
32
+ #[ allow( deprecated) ]
33
+ <Self as Itertools >:: fold1 ( self , f)
34
+ }
35
+ }
36
+
37
+ impl < T : Itertools > Ext for T { }
38
+
You can’t perform that action at this time.
0 commit comments