ldmud/test/t-python/testob.c
Alexander Motzkau 0142ebbd27 Added abilities to Python integration to trace LPC program execution
Added BEFORE_INSTRUCTION hook to be called for every instruction.
Added call_stack property to query the current stack.
2025-07-07 22:14:05 +02:00

34 lines
531 B
C

#pragma save_types, rtt_checks, lightweight, clone, save_local_names
nosave protected int|float testvar = 42;
string var_testob = "v_testob";
string fun_testob()
{
return "f_testob";
}
int loaded()
{
return 1;
}
void create()
{
}
nomask protected int testfun(<int|float> value, varargs string* args)
{
return sizeof(args);
}
async string* testcoroutine(varargs string* args)
{
string local = "X";
return args + ({ yield(sizeof(args)), local });
}
mixed callback(closure fun)
{
return funcall(fun);
}