Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Bump NQP_REVISION to get bs fixes; a small tweak in Rakudo to account…
… for the change too.
  • Loading branch information
jnthn committed May 14, 2012
1 parent abb8f3a commit d1f5db2
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
6 changes: 6 additions & 0 deletions src/binder/types.c
Expand Up @@ -30,6 +30,7 @@ static PMC * PackageHOW = NULL;
static PMC * JunctionThreader = NULL;

static INTVAL ownedhash_id = 0;
static INTVAL ownedrpa_id = 0;

void Rakudo_types_mu_set(PMC * type) { Mu = type; }
PMC * Rakudo_types_mu_get(void) { return Mu; }
Expand Down Expand Up @@ -124,11 +125,16 @@ PMC * Rakudo_types_parrot_map(PARROT_INTERP, PMC * to_map) {
default:
if (ownedhash_id == 0)
ownedhash_id = Parrot_pmc_get_type_str(interp, Parrot_str_new(interp, "OwnedHash", 0));
if (ownedrpa_id == 0)
ownedrpa_id = Parrot_pmc_get_type_str(interp, Parrot_str_new(interp, "OwnedResizablePMCArray", 0));
if (to_map->vtable->base_type == ownedhash_id) {
result = REPR(_Hash)->allocate(interp, STABLE(_Hash));
REPR(result)->initialize(interp, STABLE(result), OBJECT_BODY(result));
VTABLE_set_attr_keyed(interp, result, EnumMap, Parrot_str_new_constant(interp, "$!storage"), to_map);
}
else if (to_map->vtable->base_type == ownedrpa_id) {
result = Rakudo_binding_parcel_from_rpa(interp, to_map, Mu);
}
else {
result = to_map;
}
Expand Down
2 changes: 1 addition & 1 deletion tools/build/NQP_REVISION
@@ -1 +1 @@
2012.04.1-19-g9ddfc35
2012.04.1-21-g5308279

0 comments on commit d1f5db2

Please sign in to comment.