File tree Expand file tree Collapse file tree 2 files changed +9
-1
lines changed Expand file tree Collapse file tree 2 files changed +9
-1
lines changed Original file line number Diff line number Diff line change @@ -295,7 +295,7 @@ RUN(NAME test_dict_07 LABELS cpython llvm)
295
295
RUN (NAME test_dict_08 LABELS cpython llvm c )
296
296
RUN (NAME test_dict_09 LABELS cpython llvm c )
297
297
RUN (NAME test_dict_10 LABELS cpython llvm ) # TODO: Add support of dict with string in C backend
298
- RUN (NAME test_dict_11 LABELS cpython c ) # TODO: Add LLVM support
298
+ RUN (NAME test_dict_11 LABELS cpython llvm c )
299
299
RUN (NAME test_for_loop LABELS cpython llvm c )
300
300
RUN (NAME modules_01 LABELS cpython llvm c wasm wasm_x86 wasm_x64 )
301
301
RUN (NAME modules_02 LABELS cpython llvm c wasm wasm_x86 wasm_x64 )
Original file line number Diff line number Diff line change @@ -4,5 +4,13 @@ def test_dict_11():
4
4
num : dict [i32 , i32 ]
5
5
num = {11 : 22 , 33 : 44 , 55 : 66 }
6
6
assert num .get (7 , - 1 ) == - 1
7
+ assert num .get (11 , - 1 ) == 22
8
+ assert num .get (33 , - 1 ) == 44
9
+ assert num .get (55 , - 1 ) == 66
10
+ assert num .get (72 , - 110 ) == - 110
11
+ d : dict [i32 , str ]
12
+ d = {1 : "1" , 2 : "22" , 3 : "333" }
13
+ assert d .get (2 , "00" ) == "22"
14
+ assert d .get (21 , "nokey" ) == "nokey"
7
15
8
16
test_dict_11 ()
You can’t perform that action at this time.
0 commit comments