Skip to content

Commit

Permalink
Showing 1 changed file with 5 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -920,6 +920,11 @@ public MapNode(MapNode prev) {
super(prev);
}

@Specialization(guards = "isNull")
public RubyArray mapNull(VirtualFrame frame, RubyHash hash, RubyProc block) {
return new RubyArray(getContext().getCoreLibrary().getArrayClass(), null, 0);
}

@ExplodeLoop
@Specialization(guards = {"!isNull", "!isBuckets"})
public RubyArray mapPackedArray(VirtualFrame frame, RubyHash hash, RubyProc block) {

0 comments on commit 7fe3c36

Please sign in to comment.