parrotcode: Subroutines | |
Contents | C |
src/sub.c - Subroutines
Subroutines, continuations, co-routines and other fun stuff...
void mark_context(PARROT_INTERP, NOTNULL(parrot_context_t *ctx))
*ctx
.PARROT_MALLOC PARROT_CANNOT_RETURN_NULL Parrot_sub *new_sub(PARROT_INTERP)
Parrot_sub
.PARROT_MALLOC PARROT_CANNOT_RETURN_NULL Parrot_sub *new_closure(PARROT_INTERP)
Parrot_sub
with its own sctatchpad.PARROT_MALLOC PARROT_CANNOT_RETURN_NULL Parrot_cont *new_continuation(PARROT_INTERP, NULLOK(Parrot_cont *to))
Parrot_cont
to the context of to
with its own copy of the current interpreter context.
If to
is NULL
,
then the to_ctx
is set to the current context.PARROT_MALLOC PARROT_CANNOT_RETURN_NULL Parrot_cont *new_ret_continuation(PARROT_INTERP)
Parrot_cont
pointing to the current context.PARROT_MALLOC PARROT_CANNOT_RETURN_NULL Parrot_coro *new_coroutine(PARROT_INTERP)
Parrot_coro
.PARROT_API PARROT_MALLOC PARROT_CANNOT_RETURN_NULL PMC *new_ret_continuation_pmc(PARROT_INTERP, NULLOK(opcode_t *address))
RetContinuation
PMC.
Uses one from the cache,
if possible; otherwise,
creates a new one.void invalidate_retc_context(PARROT_INTERP, NOTNULL(PMC *cont))
PARROT_API PARROT_CAN_RETURN_NULL PARROT_WARN_UNUSED_RESULT STRING *Parrot_full_sub_name(PARROT_INTERP, NULLOK(PMC *sub))
PARROT_API int Parrot_Context_get_info(PARROT_INTERP, NOTNULL(parrot_context_t *ctx), NOTNULL(Parrot_Context_info *info))
PARROT_API PARROT_CAN_RETURN_NULL PARROT_WARN_UNUSED_RESULT STRING *Parrot_Context_infostr(PARROT_INTERP, NOTNULL(parrot_context_t *ctx))
PARROT_CANNOT_RETURN_NULL PARROT_WARN_UNUSED_RESULT PMC *Parrot_find_pad(PARROT_INTERP, NOTNULL(STRING *lex_name), NOTNULL(parrot_context_t *ctx))
PARROT_API PARROT_CANNOT_RETURN_NULL PARROT_WARN_UNUSED_RESULT PMC *parrot_new_closure(PARROT_INTERP, NOTNULL(PMC *sub_pmc))
include/parrot/sub.h.
Initial version by Melvin on 2002/06/6.
|