Open
Description
% cat examples/expr2.py
from lpython import i32
a: list[i32]
a = [2, 3]
b: list[i32]
b = list(a)
print(b)
% python examples/expr2.py
[2, 3]
% lpython examples/expr2.py
semantic error: Type mismatch in assignment, the types must be compatible
--> examples/expr2.py:6:1
|
6 | b = list(a)
| ^ ^^^^^^^ type mismatch ('list[i32]' and 'list[str]')
Note: Please report unclear or confusing messages as bugs at
https://github.com/lcompilers/lpython/issues.
Metadata
Metadata
Assignees
Labels
No labels