File tree Expand file tree Collapse file tree 3 files changed +376
-360
lines changed
rust/ql/test/library-tests/type-inference Expand file tree Collapse file tree 3 files changed +376
-360
lines changed Original file line number Diff line number Diff line change 11multipleResolvedTargets
22| main.rs:2223:9:2223:31 | ... .my_add(...) |
33| main.rs:2225:9:2225:29 | ... .my_add(...) |
4- | main.rs:2733 :13:2733 :17 | x.f() |
4+ | main.rs:2740 :13:2740 :17 | x.f() |
Original file line number Diff line number Diff line change @@ -2643,6 +2643,10 @@ mod context_typed {
26432643 fn f ( self ) { }
26442644 }
26452645
2646+ fn free_function < T : Default > ( ) -> T {
2647+ Default :: default ( ) // $ target=default
2648+ }
2649+
26462650 pub fn f ( ) {
26472651 let x = None ; // $ type=x:T.i32
26482652 let x: Option < i32 > = x;
@@ -2693,6 +2697,9 @@ mod context_typed {
26932697
26942698 let s = Default :: default ( ) ; // $ target=default type=s:S
26952699 S :: f ( s) ; // $ target=f
2700+
2701+ let z = free_function ( ) ; // $ target=free_function MISSING: type=z:i32
2702+ x. push ( z) ; // $ target=push
26962703 }
26972704}
26982705
You can’t perform that action at this time.
0 commit comments