Skip to content

Commit 92c71c4

Browse files
ronnurielcertik
authored andcommitted
Added test for & op
Signed-off-by: Ron Nuriel <[email protected]>
1 parent c356d4d commit 92c71c4

File tree

1 file changed

+11
-1
lines changed

1 file changed

+11
-1
lines changed

integration_tests/expr_01.py

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,13 +4,23 @@
44
def add(x: i32, y: i32) -> i32:
55
return x + y
66

7+
@inline
8+
def and_op(x: i32, y: i32) -> i32:
9+
return x & y
10+
711
def main0():
8-
x: i32; y: i32
12+
x: i32
13+
y: i32
14+
z: i32
915
x = (2+3)*5
1016
y = add(x, 2)*2
1117
assert x == 25
1218
assert y == 54
1319

20+
z = and_op(x, y)
21+
assert z == 16
22+
23+
1424
main0()
1525

1626
# Not implemented yet in LPython:

0 commit comments

Comments
 (0)