]> git.lizzy.rs Git - rust.git/blob - src/test/codegen/fn-impl-trait-self.rs
Do not suggest using a const parameter when there are bounds on an unused type parameter
[rust.git] / src / test / codegen / fn-impl-trait-self.rs
1 // compile-flags: -g
2 //
3 // CHECK-LABEL: @main
4 // MSVC: {{.*}}DIDerivedType(tag: DW_TAG_pointer_type, name: "recursive_type$ (*)()",{{.*}}
5 // NONMSVC: {{.*}}DIDerivedType(tag: DW_TAG_pointer_type, name: "fn() -> <recursive_type>",{{.*}}
6 //
7 // CHECK: {{.*}}DISubroutineType{{.*}}
8 // CHECK: {{.*}}DIBasicType(name: "<recur_type>", encoding: DW_ATE_unsigned)
9
10 pub fn foo() -> impl Copy {
11     foo
12 }
13
14 fn main() {
15     let my_res = foo();
16 }