mirror of
https://github.com/varun-r-mallya/Python-BPF.git
synced 2025-12-31 21:06:25 +00:00
add map update function support
This commit is contained in:
@ -106,6 +106,18 @@ def handle_expr(func, module, builder, expr, local_sym_tab, map_sym_tab):
|
||||
handle_helper_call(
|
||||
call, module, builder, func, local_sym_tab, map_sym_tab)
|
||||
return
|
||||
elif isinstance(call.func, ast.Attribute):
|
||||
if isinstance(call.func.value, ast.Call) and isinstance(call.func.value.func, ast.Name):
|
||||
method_name = call.func.attr
|
||||
if method_name in helper_func_list:
|
||||
handle_helper_call(
|
||||
call, module, builder, func, local_sym_tab, map_sym_tab)
|
||||
return
|
||||
# I VIBED THIS WITHOUT UNDERSTANDING THIS PART>>>> TODO: check this later
|
||||
if call.func.id in helper_func_list:
|
||||
handle_helper_call(
|
||||
call, module, builder, func, local_sym_tab, map_sym_tab)
|
||||
return
|
||||
elif isinstance(call, ast.Name):
|
||||
if call.id in local_sym_tab:
|
||||
var = local_sym_tab[call.id]
|
||||
|
||||
Reference in New Issue
Block a user