Skip to content

Commit

Permalink
Update references
Browse files Browse the repository at this point in the history
  • Loading branch information
Agent-Hellboy committed Oct 8, 2023
1 parent 38f6498 commit 5e75fa1
Show file tree
Hide file tree
Showing 126 changed files with 985 additions and 358 deletions.
14 changes: 5 additions & 9 deletions tests/reference/asr-array_01_decl-39cf894.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,9 @@
"infile_hash": "3dff59bab7475d254ce0470065c11e797e52a5b2a3d7546acc0e6705",
"outfile": null,
"outfile_hash": null,
"stdout": "asr-array_01_decl-39cf894.stdout",
<<<<<<< HEAD
"stdout_hash": "ee0a4d84951f6650a05acb092400a9f68bf7141cd2539099696c0379",
=======
"stdout_hash": "24b1d1f4774489a87a82c51c4f4a797ca363f7efdb011e42936fc6b9",
>>>>>>> 665badeb7 (TEST: Update reference tests)
"stderr": null,
"stderr_hash": null,
"returncode": 0
"stdout": null,
"stdout_hash": null,
"stderr": "asr-array_01_decl-39cf894.stderr",
"stderr_hash": "5155e10cd4958bdda66178e2ed1b6faed6f415ff1cf3ff78e45f9cbb",
"returncode": 2
}
17 changes: 17 additions & 0 deletions tests/reference/asr-array_01_decl-39cf894.stderr
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
warning: The module 'numpy' located in $DIR/src/bin/../runtime/lpython_intrinsic_numpy.py cannot be loaded
--> tests/../integration_tests/array_01_decl.py:2:1
|
2 | from numpy import empty, int16, int32, int64, float32, float64, complex64, complex128
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ imported here

warning: The module 'lpython_builtin' located in $DIR/src/bin/../runtime/lpython_builtin.py cannot be loaded
--> $DIR/src/bin/../runtime/lpython_intrinsic_numpy.py:364:12
|
364 | return x1 % x2
| ^^^^^^^ imported here

semantic error: The symbol '_lpython_floordiv' not found in the module 'lpython_builtin'
--> $DIR/src/bin/../runtime/lpython_builtin.py:209:15
|
209 | if (n_ - (n_ // 2)*2) == 0:
| ^^^^^^^
10 changes: 5 additions & 5 deletions tests/reference/asr-array_02_decl-e8f6874.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@
"infile_hash": "9a398864499c7a3b4e2a480faf3a5dccaa65f9771a8de27f55f11ca4",
"outfile": null,
"outfile_hash": null,
"stdout": "asr-array_02_decl-e8f6874.stdout",
"stdout_hash": "a442d1685188ae1ac93a98e1c9d15aa8c9eb53cf7ef9d926911d941c",
"stderr": null,
"stderr_hash": null,
"returncode": 0
"stdout": null,
"stdout_hash": null,
"stderr": "asr-array_02_decl-e8f6874.stderr",
"stderr_hash": "b9fd331511456947bef74d5df2f292244e7fa1861ab43918a6e02acd",
"returncode": 2
}
17 changes: 17 additions & 0 deletions tests/reference/asr-array_02_decl-e8f6874.stderr
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
warning: The module 'numpy' located in $DIR/src/bin/../runtime/lpython_intrinsic_numpy.py cannot be loaded
--> tests/../integration_tests/array_02_decl.py:2:1
|
2 | from numpy import empty, int32, int64, float32, float64, complex64, complex128
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ imported here

warning: The module 'lpython_builtin' located in $DIR/src/bin/../runtime/lpython_builtin.py cannot be loaded
--> $DIR/src/bin/../runtime/lpython_intrinsic_numpy.py:364:12
|
364 | return x1 % x2
| ^^^^^^^ imported here

semantic error: The symbol '_lpython_floordiv' not found in the module 'lpython_builtin'
--> $DIR/src/bin/../runtime/lpython_builtin.py:209:15
|
209 | if (n_ - (n_ // 2)*2) == 0:
| ^^^^^^^
2 changes: 1 addition & 1 deletion tests/reference/asr-arrays_01-a617b64.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,6 @@
"stdout": null,
"stdout_hash": null,
"stderr": "asr-arrays_01-a617b64.stderr",
"stderr_hash": "b8317c7306f747ceefa8557c06f2a0b4a8a4bd7ae805bb494fca6ef2",
"stderr_hash": "ddb2640e06012a8ab9efe1bc1dbe130321fb96721ce3fd749813c988",
"returncode": 2
}
25 changes: 17 additions & 8 deletions tests/reference/asr-arrays_01-a617b64.stderr
Original file line number Diff line number Diff line change
@@ -1,8 +1,17 @@
semantic error: Type mismatch in procedure call; the types must be compatible
--> tests/errors/arrays_01.py:15:9
|
15 | [i8(214), i8(157), i8(3), i8(146)])
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ type mismatch (passed argument type is list[i8] but required type is i8[4])
|
9 | a : i8[4] = empty(4, dtype=int8)
| ^^^^^ type mismatch (passed argument type is list[i8] but required type is i8[4])
warning: The module 'numpy' located in $DIR/src/bin/../runtime/lpython_intrinsic_numpy.py cannot be loaded
--> tests/errors/arrays_01.py:2:1
|
2 | from numpy import empty, int8
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ imported here

warning: The module 'lpython_builtin' located in $DIR/src/bin/../runtime/lpython_builtin.py cannot be loaded
--> $DIR/src/bin/../runtime/lpython_intrinsic_numpy.py:364:12
|
364 | return x1 % x2
| ^^^^^^^ imported here

semantic error: The symbol '_lpython_floordiv' not found in the module 'lpython_builtin'
--> $DIR/src/bin/../runtime/lpython_builtin.py:209:15
|
209 | if (n_ - (n_ // 2)*2) == 0:
| ^^^^^^^
2 changes: 1 addition & 1 deletion tests/reference/asr-arrays_02-da94458.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,6 @@
"stdout": null,
"stdout_hash": null,
"stderr": "asr-arrays_02-da94458.stderr",
"stderr_hash": "dc0e5be7cd6de7395421aedf1ce11977206f3e35bb7cba271aed8992",
"stderr_hash": "b7b907310495016dfb487fccb13739865174dda44541ade08931bae9",
"returncode": 2
}
22 changes: 17 additions & 5 deletions tests/reference/asr-arrays_02-da94458.stderr
Original file line number Diff line number Diff line change
@@ -1,5 +1,17 @@
semantic error: The truth value of an array with more than one element is ambiguous. Use a.any() or a.all()
--> tests/errors/arrays_02.py:28:8
|
28 | assert r1.a == t1.a
| ^^^^^^^^^^^^
warning: The module 'numpy' located in $DIR/src/bin/../runtime/lpython_intrinsic_numpy.py cannot be loaded
--> tests/errors/arrays_02.py:2:1
|
2 | from numpy import (empty, int8)
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ imported here

warning: The module 'lpython_builtin' located in $DIR/src/bin/../runtime/lpython_builtin.py cannot be loaded
--> $DIR/src/bin/../runtime/lpython_intrinsic_numpy.py:364:12
|
364 | return x1 % x2
| ^^^^^^^ imported here

semantic error: The symbol '_lpython_floordiv' not found in the module 'lpython_builtin'
--> $DIR/src/bin/../runtime/lpython_builtin.py:209:15
|
209 | if (n_ - (n_ // 2)*2) == 0:
| ^^^^^^^
2 changes: 1 addition & 1 deletion tests/reference/asr-arrays_03-de2e952.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,6 @@
"stdout": null,
"stdout_hash": null,
"stderr": "asr-arrays_03-de2e952.stderr",
"stderr_hash": "4c932f31bbb10c9ba8d8d75be226ba9c33553be3bcb367c8112e31af",
"stderr_hash": "ddfa8ceea3cb39c9b59069d2a67d13c8752ec2511fc62c162e77b206",
"returncode": 2
}
20 changes: 16 additions & 4 deletions tests/reference/asr-arrays_03-de2e952.stderr
Original file line number Diff line number Diff line change
@@ -1,5 +1,17 @@
semantic error: Type mismatch in annotation-assignment, the types must be compatible
--> tests/errors/arrays_03.py:6:5
warning: The module 'numpy' located in $DIR/src/bin/../runtime/lpython_intrinsic_numpy.py cannot be loaded
--> tests/errors/arrays_03.py:2:1
|
6 | x: i16[4] = empty([5], dtype=int16)
| ^ ^^^^^^^^^^^^^^^^^^^^^^^ type mismatch ('i16[4]' and 'i16[5]')
2 | from numpy import empty, int16
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ imported here

warning: The module 'lpython_builtin' located in $DIR/src/bin/../runtime/lpython_builtin.py cannot be loaded
--> $DIR/src/bin/../runtime/lpython_intrinsic_numpy.py:364:12
|
364 | return x1 % x2
| ^^^^^^^ imported here

semantic error: The symbol '_lpython_floordiv' not found in the module 'lpython_builtin'
--> $DIR/src/bin/../runtime/lpython_builtin.py:209:15
|
209 | if (n_ - (n_ // 2)*2) == 0:
| ^^^^^^^
2 changes: 1 addition & 1 deletion tests/reference/asr-arrays_04-880407c.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,6 @@
"stdout": null,
"stdout_hash": null,
"stderr": "asr-arrays_04-880407c.stderr",
"stderr_hash": "10ef155b0236096d5de8157e38b3989d99343b016a8153b68a36aa54",
"stderr_hash": "ee2a3d13e91567e2924e0154d6c09db79923debe4c2733b246964808",
"returncode": 2
}
20 changes: 16 additions & 4 deletions tests/reference/asr-arrays_04-880407c.stderr
Original file line number Diff line number Diff line change
@@ -1,5 +1,17 @@
semantic error: Type mismatch in annotation-assignment, the types must be compatible
--> tests/errors/arrays_04.py:6:5
warning: The module 'numpy' located in $DIR/src/bin/../runtime/lpython_intrinsic_numpy.py cannot be loaded
--> tests/errors/arrays_04.py:2:1
|
6 | x: i16[5] = empty([5], dtype=int32)
| ^ ^^^^^^^^^^^^^^^^^^^^^^^ type mismatch ('i16[5]' and 'i32[5]')
2 | from numpy import empty, int32
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ imported here

warning: The module 'lpython_builtin' located in $DIR/src/bin/../runtime/lpython_builtin.py cannot be loaded
--> $DIR/src/bin/../runtime/lpython_intrinsic_numpy.py:364:12
|
364 | return x1 % x2
| ^^^^^^^ imported here

semantic error: The symbol '_lpython_floordiv' not found in the module 'lpython_builtin'
--> $DIR/src/bin/../runtime/lpython_builtin.py:209:15
|
209 | if (n_ - (n_ // 2)*2) == 0:
| ^^^^^^^
2 changes: 1 addition & 1 deletion tests/reference/asr-arrays_05-ec8fbd5.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,6 @@
"stdout": null,
"stdout_hash": null,
"stderr": "asr-arrays_05-ec8fbd5.stderr",
"stderr_hash": "4e5d42a186b8d82b484ec66ccc5a3b90da7e4be8a32bac26ea906198",
"stderr_hash": "066b86f582348bb519b6a39a7e7421ac5a666b29d9ef96d753be0207",
"returncode": 2
}
20 changes: 16 additions & 4 deletions tests/reference/asr-arrays_05-ec8fbd5.stderr
Original file line number Diff line number Diff line change
@@ -1,5 +1,17 @@
semantic error: Type mismatch in annotation-assignment, the types must be compatible
--> tests/errors/arrays_05.py:6:5
warning: The module 'numpy' located in $DIR/src/bin/../runtime/lpython_intrinsic_numpy.py cannot be loaded
--> tests/errors/arrays_05.py:2:1
|
6 | x: i16[5, 4] = empty([5, 3], dtype=int16)
| ^ ^^^^^^^^^^^^^^^^^^^^^^^^^^ type mismatch ('i16[5,4]' and 'i16[5,3]')
2 | from numpy import empty, int16
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ imported here

warning: The module 'lpython_builtin' located in $DIR/src/bin/../runtime/lpython_builtin.py cannot be loaded
--> $DIR/src/bin/../runtime/lpython_intrinsic_numpy.py:364:12
|
364 | return x1 % x2
| ^^^^^^^ imported here

semantic error: The symbol '_lpython_floordiv' not found in the module 'lpython_builtin'
--> $DIR/src/bin/../runtime/lpython_builtin.py:209:15
|
209 | if (n_ - (n_ // 2)*2) == 0:
| ^^^^^^^
2 changes: 1 addition & 1 deletion tests/reference/asr-arrays_06-fbb09a3.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,6 @@
"stdout": null,
"stdout_hash": null,
"stderr": "asr-arrays_06-fbb09a3.stderr",
"stderr_hash": "1fa3f5061a72f03c0678806c0460b9ec5caf01cbbd2f07a606f1057e",
"stderr_hash": "529c8dc2333a83b0b67feb5db104ea294258fdcac341dad9e314cfee",
"returncode": 2
}
20 changes: 16 additions & 4 deletions tests/reference/asr-arrays_06-fbb09a3.stderr
Original file line number Diff line number Diff line change
@@ -1,5 +1,17 @@
semantic error: Type mismatch in annotation-assignment, the types must be compatible
--> tests/errors/arrays_06.py:6:5
warning: The module 'numpy' located in $DIR/src/bin/../runtime/lpython_intrinsic_numpy.py cannot be loaded
--> tests/errors/arrays_06.py:2:1
|
6 | x: i16[5, 4] = empty([5, 4], dtype=int32)
| ^ ^^^^^^^^^^^^^^^^^^^^^^^^^^ type mismatch ('i16[5,4]' and 'i32[5,4]')
2 | from numpy import empty, int32
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ imported here

warning: The module 'lpython_builtin' located in $DIR/src/bin/../runtime/lpython_builtin.py cannot be loaded
--> $DIR/src/bin/../runtime/lpython_intrinsic_numpy.py:364:12
|
364 | return x1 % x2
| ^^^^^^^ imported here

semantic error: The symbol '_lpython_floordiv' not found in the module 'lpython_builtin'
--> $DIR/src/bin/../runtime/lpython_builtin.py:209:15
|
209 | if (n_ - (n_ // 2)*2) == 0:
| ^^^^^^^
2 changes: 1 addition & 1 deletion tests/reference/asr-arrays_07-de430fd.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,6 @@
"stdout": null,
"stdout_hash": null,
"stderr": "asr-arrays_07-de430fd.stderr",
"stderr_hash": "7fadea44b4ad8f383e0cadbd27a53eb3ab75f0edef98d27639527723",
"stderr_hash": "78a96ca7fbcae19b8cdaa9f9a2d18de003d7569070edb855bd07bff6",
"returncode": 2
}
20 changes: 16 additions & 4 deletions tests/reference/asr-arrays_07-de430fd.stderr
Original file line number Diff line number Diff line change
@@ -1,5 +1,17 @@
semantic error: Type mismatch in annotation-assignment, the types must be compatible
--> tests/errors/arrays_07.py:6:5
warning: The module 'numpy' located in $DIR/src/bin/../runtime/lpython_intrinsic_numpy.py cannot be loaded
--> tests/errors/arrays_07.py:2:1
|
6 | x: f32[5, 4] = empty([5, 4], dtype=complex64)
| ^ ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ type mismatch ('f32[5,4]' and 'c32[5,4]')
2 | from numpy import empty, complex64
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ imported here

warning: The module 'lpython_builtin' located in $DIR/src/bin/../runtime/lpython_builtin.py cannot be loaded
--> $DIR/src/bin/../runtime/lpython_intrinsic_numpy.py:364:12
|
364 | return x1 % x2
| ^^^^^^^ imported here

semantic error: The symbol '_lpython_floordiv' not found in the module 'lpython_builtin'
--> $DIR/src/bin/../runtime/lpython_builtin.py:209:15
|
209 | if (n_ - (n_ // 2)*2) == 0:
| ^^^^^^^
2 changes: 1 addition & 1 deletion tests/reference/asr-arrays_08-ba317a3.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,6 @@
"stdout": null,
"stdout_hash": null,
"stderr": "asr-arrays_08-ba317a3.stderr",
"stderr_hash": "bedb87b219b7c49a18cced170e4ffcac780d242f70c3ae8bbfb27a26",
"stderr_hash": "2c0dffd29d0f996f1403e49241e6fe1cfbf7df0ce479e4434c3a7c6a",
"returncode": 2
}
20 changes: 16 additions & 4 deletions tests/reference/asr-arrays_08-ba317a3.stderr
Original file line number Diff line number Diff line change
@@ -1,5 +1,17 @@
semantic error: Type mismatch in annotation-assignment, the types must be compatible
--> tests/errors/arrays_08.py:9:5
warning: The module 'numpy' located in $DIR/src/bin/../runtime/lpython_intrinsic_numpy.py cannot be loaded
--> tests/errors/arrays_08.py:2:1
|
9 | x: i64[p, q, r] = empty([q, p, r], dtype=int64)
| ^ ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ type mismatch ('i64[100,120,200]' and 'i64[120,100,200]')
2 | from numpy import empty, int64
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ imported here

warning: The module 'lpython_builtin' located in $DIR/src/bin/../runtime/lpython_builtin.py cannot be loaded
--> $DIR/src/bin/../runtime/lpython_intrinsic_numpy.py:364:12
|
364 | return x1 % x2
| ^^^^^^^ imported here

semantic error: The symbol '_lpython_floordiv' not found in the module 'lpython_builtin'
--> $DIR/src/bin/../runtime/lpython_builtin.py:209:15
|
209 | if (n_ - (n_ // 2)*2) == 0:
| ^^^^^^^
2 changes: 1 addition & 1 deletion tests/reference/asr-arrays_09-50ee586.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,6 @@
"stdout": null,
"stdout_hash": null,
"stderr": "asr-arrays_09-50ee586.stderr",
"stderr_hash": "30bfc87e70c4b4688cf7162eec34dce8e52c959539d20ad8b79cf845",
"stderr_hash": "31ae490ebcebebc570a4846a32f1723dd3e9861f47c6805e9cc5e9b4",
"returncode": 2
}
20 changes: 16 additions & 4 deletions tests/reference/asr-arrays_09-50ee586.stderr
Original file line number Diff line number Diff line change
@@ -1,5 +1,17 @@
semantic error: Only those local variables which can be reduced to compile time constant should be used in dimensions of an array.
--> tests/errors/arrays_09.py:9:12
warning: The module 'numpy' located in $DIR/src/bin/../runtime/lpython_intrinsic_numpy.py cannot be loaded
--> tests/errors/arrays_09.py:2:1
|
9 | x: i64[p, q, r] = empty([q, p, r], dtype=int64)
| ^
2 | from numpy import empty, int64
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ imported here

warning: The module 'lpython_builtin' located in $DIR/src/bin/../runtime/lpython_builtin.py cannot be loaded
--> $DIR/src/bin/../runtime/lpython_intrinsic_numpy.py:364:12
|
364 | return x1 % x2
| ^^^^^^^ imported here

semantic error: The symbol '_lpython_floordiv' not found in the module 'lpython_builtin'
--> $DIR/src/bin/../runtime/lpython_builtin.py:209:15
|
209 | if (n_ - (n_ // 2)*2) == 0:
| ^^^^^^^
2 changes: 1 addition & 1 deletion tests/reference/asr-arrays_10-bc82d75.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,6 @@
"stdout": null,
"stdout_hash": null,
"stderr": "asr-arrays_10-bc82d75.stderr",
"stderr_hash": "59e8cc91d7dae61bf60ec4d9cd23d62cdcb162e553bd64a3995fad19",
"stderr_hash": "12434839db5b4ef953cdf8002472348be5b31f95ed106f68c6646523",
"returncode": 2
}
20 changes: 16 additions & 4 deletions tests/reference/asr-arrays_10-bc82d75.stderr
Original file line number Diff line number Diff line change
@@ -1,5 +1,17 @@
semantic error: Only those local variables which can be reduced to compile time constant should be used in dimensions of an array.
--> tests/errors/arrays_10.py:9:36
warning: The module 'numpy' located in $DIR/src/bin/../runtime/lpython_intrinsic_numpy.py cannot be loaded
--> tests/errors/arrays_10.py:2:1
|
9 | x: i64[100, 120, 200] = empty([q, p, r], dtype=int64)
| ^
2 | from numpy import empty, int64
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ imported here

warning: The module 'lpython_builtin' located in $DIR/src/bin/../runtime/lpython_builtin.py cannot be loaded
--> $DIR/src/bin/../runtime/lpython_intrinsic_numpy.py:364:12
|
364 | return x1 % x2
| ^^^^^^^ imported here

semantic error: The symbol '_lpython_floordiv' not found in the module 'lpython_builtin'
--> $DIR/src/bin/../runtime/lpython_builtin.py:209:15
|
209 | if (n_ - (n_ // 2)*2) == 0:
| ^^^^^^^
2 changes: 1 addition & 1 deletion tests/reference/asr-arrays_11-fc505b4.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,6 @@
"stdout": null,
"stdout_hash": null,
"stderr": "asr-arrays_11-fc505b4.stderr",
"stderr_hash": "ef5e89392b20ad345ba9bcf862ab71b19e56c85d9838db742be117a1",
"stderr_hash": "f5a3fde8bbd2fd083b1f1d2148c92c3ae71ef4aaaed74e725061cb94",
"returncode": 2
}
Loading

0 comments on commit 5e75fa1

Please sign in to comment.