ldmud/test/t-python/testob.c
Alexander Motzkau bf44f19753 Save local variable names for inspection in coroutines
With the new pragma save_local_names the names of local variables are
stored in the program so they can be inspected (with Python) later on.
2022-01-09 21:22:34 +01:00

29 lines
473 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 });
}