]> git.lizzy.rs Git - rust.git/blob - src/test/ui/issues/issue-13167.rs
Rollup merge of #62257 - RalfJung:miri-c-str, r=estebank
[rust.git] / src / test / ui / issues / issue-13167.rs
1 // build-pass (FIXME(62277): could be check-pass?)
2 // pretty-expanded FIXME #23616
3
4 use std::slice;
5
6 pub struct PhfMapEntries<'a, T: 'a> {
7     iter: slice::Iter<'a, (&'static str, T)>,
8 }
9
10 impl<'a, T> Iterator for PhfMapEntries<'a, T> {
11     type Item = (&'static str, &'a T);
12
13     fn next(&mut self) -> Option<(&'static str, &'a T)> {
14         self.iter.by_ref().map(|&(key, ref value)| (key, value)).next()
15     }
16
17     fn size_hint(&self) -> (usize, Option<usize>) {
18         self.iter.size_hint()
19     }
20 }
21
22 fn main() {}