File tree Expand file tree Collapse file tree 4 files changed +1157
-1109
lines changed
rust/ql/test/library-tests/type-inference Expand file tree Collapse file tree 4 files changed +1157
-1109
lines changed Original file line number Diff line number Diff line change 11multipleCallTargets
22| dereference.rs:61:15:61:24 | e1.deref() |
3- | main.rs:2213 :13:2213 :31 | ...::from(...) |
4- | main.rs:2214 :13:2214 :31 | ...::from(...) |
5- | main.rs:2215 :13:2215 :31 | ...::from(...) |
6- | main.rs:2221 :13:2221 :31 | ...::from(...) |
7- | main.rs:2222 :13:2222 :31 | ...::from(...) |
8- | main.rs:2223 :13:2223 :31 | ...::from(...) |
3+ | main.rs:2238 :13:2238 :31 | ...::from(...) |
4+ | main.rs:2239 :13:2239 :31 | ...::from(...) |
5+ | main.rs:2240 :13:2240 :31 | ...::from(...) |
6+ | main.rs:2246 :13:2246 :31 | ...::from(...) |
7+ | main.rs:2247 :13:2247 :31 | ...::from(...) |
8+ | main.rs:2248 :13:2248 :31 | ...::from(...) |
Original file line number Diff line number Diff line change 1+ nonInjectiveTypeParameterId
2+ | main.rs:1934:24:1934:31 | impl(T) | main.rs:1934:24:1934:31 | impl(T) |
3+ | main.rs:1934:24:1934:31 | impl(T) | main.rs:1934:24:1934:31 | impl(T) |
Original file line number Diff line number Diff line change @@ -1931,6 +1931,10 @@ mod impl_trait {
19311931 Some ( S3 ( x) )
19321932 }
19331933
1934+ fn get_a_my_trait4 < T : Clone > ( x : T ) -> ( impl MyTrait < T > , impl MyTrait < T > ) {
1935+ ( S3 ( x. clone ( ) ) , S3 ( x) ) // $ target=clone
1936+ }
1937+
19341938 fn uses_my_trait2 < A > ( t : impl MyTrait < A > ) -> A {
19351939 t. get_a ( ) // $ target=MyTrait::get_a
19361940 }
@@ -1947,6 +1951,7 @@ mod impl_trait {
19471951 let e = get_a_my_trait2 ( S1 ) . get_a ( ) ; // $ target=get_a_my_trait2 target=MyTrait::get_a type=e:S1
19481952 // For this function the `impl` type does not appear in the root of the return type
19491953 let f = get_a_my_trait3 ( S1 ) . unwrap ( ) . get_a ( ) ; // $ target=get_a_my_trait3 target=unwrap target=MyTrait::get_a type=f:S1
1954+ let g = get_a_my_trait4 ( S1 ) . 0 . get_a ( ) ; // $ target=get_a_my_trait4 target=MyTrait::get_a type=g:S1
19501955 }
19511956}
19521957
You can’t perform that action at this time.
0 commit comments