#include <bindpp.h>
Public Member Functions | |
Ctx (int arg_cnt) | |
I32 | arg_len () |
length of arguments | |
Scalar * | arg (int n) |
get the argument indexed by n | |
template<class T> | |
void | ret (T n) |
return the one scalar value | |
template<class T> | |
void | ret (int n, T v) |
bool | wantarray () |
same as perl level wantarray() | |
void | ret (Array *ary) |
return multiple values | |
void | return_true () |
return true value | |
void | return_undef () |
return undef value | |
void | register_allocated (Value *v) |
register the allocated Value. | |
Protected Member Functions | |
SV * | fetch_stack (int n) |
fetch the top 'n' of stack | |
void | ret (int n, SV *s) |
void | initialize () |
Protected Attributes | |
I32 | ax |
SV ** | mark |
std::vector< Value * > | allocated |
void pl::Ctx::register_allocated | ( | Value * | v | ) | [inline] |
register the allocated Value.
these objects delete when leave this context. Note: 'Value' is delete, but Value->val is not delete!
SV* pl::Ctx::fetch_stack | ( | int | n | ) | [inline, protected] |
fetch the top 'n' of stack