File tree Expand file tree Collapse file tree 2 files changed +37
-31
lines changed Expand file tree Collapse file tree 2 files changed +37
-31
lines changed Original file line number Diff line number Diff line change @@ -570,9 +570,11 @@ RUN(NAME test_unary_op_01 LABELS cpython llvm c) # unary minus
570570RUN(NAME test_unary_op_02 LABELS cpython llvm c) # unary plus
571571RUN(NAME test_unary_op_03 LABELS cpython llvm c wasm) # unary bitinvert
572572RUN(NAME test_unary_op_04 LABELS cpython llvm c) # unary bitinvert
573- RUN(NAME test_unary_op_05 LABELS cpython llvm c) # unsigned unary minus, plus
573+ # Unsigned unary minus is not supported in CPython
574+ # RUN(NAME test_unary_op_05 LABELS cpython llvm c) # unsigned unary minus, plus
574575RUN(NAME test_unary_op_06 LABELS cpython llvm c) # unsigned unary bitnot
575- RUN(NAME test_unsigned_01 LABELS cpython llvm c) # unsigned bitshift left, right
576+ # The value after shift overflows in CPython
577+ # RUN(NAME test_unsigned_01 LABELS cpython llvm c) # unsigned bitshift left, right
576578RUN(NAME test_unsigned_02 LABELS cpython llvm c)
577579RUN(NAME test_unsigned_03 LABELS cpython llvm c)
578580RUN(NAME test_bool_binop LABELS cpython llvm c)
Original file line number Diff line number Diff line change @@ -34,46 +34,50 @@ def test_02():
3434 print (w )
3535 assert w == u32 (11 )
3636
37- def test_03 ():
38- x : u32 = u32 (- 10 )
39- print (x )
40- assert x == u32 (4294967286 )
37+ # Disable following tests
38+ # Negative numbers in unsigned should throw errors
39+ # TODO: Add these tests as error reference tests
4140
42- y : u16 = u16 (x )
43- print (y )
44- assert y == u16 (65526 )
41+ # def test_03():
42+ # x : u32 = u32(-10)
43+ # print(x)
44+ # assert x == u32(4294967286)
4545
46- z : u64 = u64 ( y )
47- print (z )
48- assert z == u64 (65526 )
46+ # y: u16 = u16(x )
47+ # print(y )
48+ # assert y == u16 (65526)
4949
50- w : u8 = u8 ( z )
51- print (w )
52- assert w == u8 ( 246 )
50+ # z: u64 = u64(y )
51+ # print(z )
52+ # assert z == u64(65526 )
5353
54- def test_04 ():
55- x : u64 = u64 (- 11 )
56- print (x )
57- # TODO: We are unable to store the following u64 in AST/R
58- # assert x == u64(18446744073709551605)
54+ # w: u8 = u8(z)
55+ # print(w)
56+ # assert w == u8(246)
5957
60- y : u8 = u8 (x )
61- print (y )
62- assert y == u8 (245 )
58+ # def test_04():
59+ # x : u64 = u64(-11)
60+ # print(x)
61+ # # TODO: We are unable to store the following u64 in AST/R
62+ # # assert x == u64(18446744073709551605)
6363
64- z : u16 = u16 ( y )
65- print (z )
66- assert z == u16 (245 )
64+ # y: u8 = u8(x )
65+ # print(y )
66+ # assert y == u8 (245)
6767
68- w : u32 = u32 (z )
69- print (w )
70- assert w == u32 (245 )
68+ # z: u16 = u16(y)
69+ # print(z)
70+ # assert z == u16(245)
71+
72+ # w: u32 = u32(z)
73+ # print(w)
74+ # assert w == u32(245)
7175
7276
7377def main0 ():
7478 test_01 ()
7579 test_02 ()
76- test_03 ()
77- test_04 ()
80+ # test_03()
81+ # test_04()
7882
7983main0 ()
You can’t perform that action at this time.
0 commit comments