add error for unsupported constant

This commit is contained in:
Pragyansh Chaturvedi
2025-09-11 01:33:56 +05:30
parent 393aaeaef5
commit ef502bcc9f
2 changed files with 3 additions and 0 deletions

View File

@ -43,6 +43,7 @@ def hello_again(ctx: c_void_p) -> c_int64:
key = 4
last().update(key, ts)
key = 5
st = "st"
last().update(key, ts)
return c_int64(0)

View File

@ -53,6 +53,8 @@ def handle_assign(func, module, builder, stmt, map_sym_tab, local_sym_tab):
local_sym_tab[var_name])
# local_sym_tab[var_name] = var
print(f"Assigned constant {rval.value} to {var_name}")
else:
print("Unsupported constant type")
elif isinstance(rval, ast.Call):
if isinstance(rval.func, ast.Name):
call_type = rval.func.id