Skip to content

Commit df4b8d0

Browse files
committed
Added test for setupCalleeClosure
1 parent 431a484 commit df4b8d0

3 files changed

Lines changed: 23 additions & 0 deletions

File tree

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
fn apply<F: FnOnce(u8, u8) -> u8>(f: F, a: u8, b: u8) -> u8 {
2+
f(a, b)
3+
}
4+
5+
fn main() {
6+
let result = apply(|x, y| x + y, 10, 32);
7+
assert_eq!(result, 42);
8+
}
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
2+
┌─ 1 (root, init)
3+
│ #execTerminator ( terminator ( ... kind: terminatorKindCall ( ... func: operandC
4+
│ span: 0
5+
6+
│ (79 steps)
7+
└─ 3 (stuck, leaf)
8+
#traverseProjection ( toLocal ( 4 ) , thunk ( #applyBinOp ( binOpAdd , Aggregate
9+
10+
11+
┌─ 2 (root, leaf, target, terminal)
12+
│ #EndProgram ~> .K
13+
14+

kmir/src/tests/integration/test_integration.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,7 @@
6363
'ref-ptr-cast-elem-fail',
6464
'ref-ptr-cast-elem-offset-fail',
6565
'and_then_closure-fail',
66+
'closure_fnonce_tuple_arg-fail',
6667
]
6768

6869

0 commit comments

Comments
 (0)