Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

some refresh due to parrot changes

  • Loading branch information...
commit b39e81ed9d5ec761479cb2896f1fc6068809fc84 1 parent bca8b6c
@cognominal cognominal authored
View
10 src/pmc/bkmarshal.c
@@ -124,8 +124,8 @@ PARROT_CANNOT_RETURN_NULL
PMC *
blizkost_wrap_sv(BLIZKOST_NEXUS, SV *sv) {
dBNPERL; dBNINTERP;
- PMC *wrapper = Parrot_pmc_new_noinit(interp, pmc_type(interp,
- string_from_literal(interp, "P5Scalar")));
+ PMC *wrapper = Parrot_pmc_new_noinit(interp, Parrot_pmc_get_type_str(interp,
+ Parrot_str_new_constant(interp, "P5Scalar")));
PObj_custom_mark_SET(wrapper);
PObj_custom_destroy_SET(wrapper);
@@ -158,7 +158,7 @@ blizkost_return_from_invoke(PARROT_INTERP, void *next) {
* return continuation here, which gets rid of this frame
* and returns the real return address
*/
- if (cont && cont != NEED_CONTINUATION
+ if (!PMC_IS_NULL(cont)
&& (PObj_get_FLAGS(cont) & SUB_FLAG_TAILCALL)) {
cont = Parrot_pcc_get_continuation(interp, CURRENT_CONTEXT(interp));
next = VTABLE_invoke(interp, cont, next);
@@ -219,7 +219,7 @@ blizkost_call_in(BLIZKOST_NEXUS, SV *what, U32 mode, PMC *positp, PMC *namedp,
SPAGAIN;
/* Build the results PMC array. */
- *retp = pmc_new(interp, enum_class_ResizablePMCArray);
+ *retp = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
for (i = 0; i < num_returns; i++) {
SV *result_sv = POPs;
PMC *result_pmc = blizkost_wrap_sv(nexus, result_sv);
@@ -253,9 +253,7 @@ blizkost_delete_binding(PerlInterpreter *my_perl, SV *handle, MAGIC *mg)
dBNINTERP;
PMC *targ = (PMC *)(mg->mg_obj);
- PARROT_CALLIN_START(interp);
Parrot_pmc_gc_unregister(interp, targ);
- PARROT_CALLIN_END(interp);
return 0;
}
View
4 src/pmc/p5hashiter.pmc
@@ -93,8 +93,8 @@ Mark GC-ables.
GET_ATTR_backing_hash(INTERP, SELF, hash);
GETATTR_P5SV_sv(INTERP, hash, hashsv);
- retpmc = Parrot_pmc_new_noinit(interp, pmc_type(interp,
- string_from_literal(interp, "P5HashIterResult")));
+ retpmc = Parrot_pmc_new_noinit(interp, Parrot_pmc_get_type_str(interp,
+ Parrot_str_new_constant(interp, "P5HashIterResult")));
PObj_custom_mark_SET(retpmc);
SETATTR_P5HashIterResult_hekey(INTERP, retpmc,
View
4 src/pmc/p5interpreter.pmc
@@ -164,8 +164,8 @@ Acquire a namespace handle.
METHOD PMC *get_namespace(STRING *name) {
struct blizkost_nexus *nexus = PARROT_P5INTERPRETER(SELF)->nexus;
- PMC *ns = Parrot_pmc_new_noinit(interp, pmc_type(interp,
- string_from_literal(interp, "P5Namespace")));
+ PMC *ns = Parrot_pmc_new_noinit(interp, Parrot_pmc_get_type_str(interp,
+ Parrot_str_new_constant(interp, "P5Namespace")));
/* Set up the underlying structure. */
PObj_custom_mark_SET(ns);
SETATTR_P5Namespace_nexus(interp, ns, nexus);
View
2  src/pmc/p5namespace.pmc
@@ -58,7 +58,7 @@ Hands back a P5Invocation so we can call a method on the package.
PMC *result;
/* Make and return a P5Invocation object. */
- result = pmc_new(interp, pmc_type(interp, CONST_STRING(interp, "P5Invocation")));
+ result = Parrot_pmc_new(interp, Parrot_pmc_get_type_str(interp, CONST_STRING(interp, "P5Invocation")));
SETATTR_P5Invocation_nexus(interp, result, nexus);
SETATTR_P5Invocation_name(interp, result, name);
return result;
View
6 src/pmc/p5scalar.pmc
@@ -175,8 +175,8 @@ Returns the string value of the SV.
type = SvTYPE(rsv);
if (type == SVt_PVHV) {
- PMC *iter = Parrot_pmc_new_noinit(interp, pmc_type(interp,
- string_from_literal(interp, "P5HashIter")));
+ PMC *iter = Parrot_pmc_new_noinit(interp, Parrot_pmc_get_type_str(interp,
+ Parrot_str_new_constant(interp, "P5HashIter")));
hv_iterinit((HV*) rsv);
@@ -215,7 +215,7 @@ the given name on the given Perl 5 Scalar invocant.
PMC *result;
- result = pmc_new(interp, pmc_type(interp, string_from_literal(interp, "P5Invocation")));
+ result = Parrot_pmc_new(interp, Parrot_pmc_get_type_str(interp, Parrot_str_new_constant(interp, "P5Invocation")));
SETATTR_P5Invocation_nexus(interp, result, nexus);
SETATTR_P5Invocation_name(interp, result, name);
Please sign in to comment.
Something went wrong with that request. Please try again.