File tree Expand file tree Collapse file tree 1 file changed +1
-6
lines changed
library/core/src/iter/sources Expand file tree Collapse file tree 1 file changed +1
-6
lines changed Original file line number Diff line number Diff line change @@ -22,17 +22,12 @@ pub const fn empty<T>() -> Empty<T> {
2222 Empty ( marker:: PhantomData )
2323}
2424
25- // Newtype for use in `PhantomData` to avoid
26- // > error: const-stable function cannot use `#[feature(const_fn_fn_ptr_basics)]`
27- // in `const fn empty<T>()` above.
28- struct FnReturning < T > ( fn ( ) -> T ) ;
29-
3025/// An iterator that yields nothing.
3126///
3227/// This `struct` is created by the [`empty()`] function. See its documentation for more.
3328#[ must_use = "iterators are lazy and do nothing unless consumed" ]
3429#[ stable( feature = "iter_empty" , since = "1.2.0" ) ]
35- pub struct Empty < T > ( marker:: PhantomData < FnReturning < T > > ) ;
30+ pub struct Empty < T > ( marker:: PhantomData < fn ( ) -> T > ) ;
3631
3732#[ stable( feature = "core_impl_debug" , since = "1.9.0" ) ]
3833impl < T > fmt:: Debug for Empty < T > {
You can’t perform that action at this time.
0 commit comments