rust/tests/rustdoc/fn-bound.rs

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

22 lines
471 B
Rust
Raw Normal View History

2022-08-08 16:09:55 -05:00
// Regression test for #100143
2022-08-06 12:42:52 -05:00
use std::iter::Peekable;
pub struct Span<F: Fn(&i32)> {
inner: Peekable<ConditionalIterator<F>>,
}
pub struct ConditionalIterator<F> {
2022-08-06 12:42:52 -05:00
f: F,
}
// @has 'fn_bound/struct.ConditionalIterator.html' '//h3[@class="code-header"]' 'impl<F: Fn(&i32)> Iterator for ConditionalIterator<F>'
2022-08-06 12:42:52 -05:00
impl<F: Fn(&i32)> Iterator for ConditionalIterator<F> {
type Item = ();
fn next(&mut self) -> Option<Self::Item> {
todo!()
}
}