]> git.lizzy.rs Git - rust.git/blob - src/test/ui/generics/generic-no-mangle.fixed
Auto merge of #87284 - Aaron1011:remove-paren-special, r=petrochenkov
[rust.git] / src / test / ui / generics / generic-no-mangle.fixed
1 // run-rustfix
2
3 #![deny(no_mangle_generic_items)]
4
5
6 pub fn foo<T>() {} //~ ERROR functions generic over types or consts must be mangled
7
8
9 pub extern "C" fn bar<T>() {} //~ ERROR functions generic over types or consts must be mangled
10
11 #[no_mangle]
12 pub fn baz(x: &i32) -> &i32 { x }
13
14 #[no_mangle]
15 pub fn qux<'a>(x: &'a i32) -> &i32 { x }
16
17 fn main() {}