mirror of
https://github.com/varun-r-mallya/Python-BPF.git
synced 2025-12-31 21:06:25 +00:00
add error for unsupported constant
This commit is contained in:
@ -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)
|
||||
|
||||
|
||||
@ -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
|
||||
|
||||
Reference in New Issue
Block a user