Closed
Description
On this python code, overload
works fine and prints 3
as the result:
@overload
def add(a: i32) -> i32:
return a
@overload
def add(a: i32, b: i32) -> i32:
return a+b
print(add(1, 2))
But the following one fails:
@overload
def add(a: i32):
print(a)
@overload
def add(a: i32, b: i32):
print(a+b)
add(1, 2)
ASR:
throw LFortranException("ASR verify failed: " + error_msg);
LFortranException: ASR verify failed: 92:100: SubroutineCall::m_name cannot point outside of its symbol table
Metadata
Metadata
Assignees
Labels
No labels