]> git.lizzy.rs Git - rust.git/blob - src/test/ui/issues/issue-17816.rs
Rollup merge of #86479 - exphp-forks:float-debug-exponential, r=yaahc
[rust.git] / src / test / ui / issues / issue-17816.rs
1 // run-pass
2 #![allow(unused_variables)]
3 use std::marker::PhantomData;
4
5 fn main() {
6     struct Symbol<'a, F: Fn(Vec<&'a str>) -> &'a str> { function: F, marker: PhantomData<&'a ()> }
7     let f = |x: Vec<&str>| -> &str { "foobar" };
8     let sym = Symbol { function: f, marker: PhantomData };
9     (sym.function)(vec![]);
10 }