diff options
Diffstat (limited to 'bootstrap/test2.cff')
| -rw-r--r-- | bootstrap/test2.cff | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/bootstrap/test2.cff b/bootstrap/test2.cff index 66603ba..6fbb8fa 100644 --- a/bootstrap/test2.cff +++ b/bootstrap/test2.cff @@ -8,6 +8,10 @@ struct Node<T> { } } +struct Bit<T> { + fn neg(x T) T { return ~x; } +} + extern fn main() void { let n Node<int> = {#null, 0}; let n Node<int> = {&n, 1}; @@ -18,4 +22,7 @@ extern fn main() void { let x Node<f32> = {}; n->ok(); x->ok(); + + Bit<i32>:neg(3); + Bit<i64>:neg(3); } |