Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: jruby/jruby
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: fe5b4b40c38d
Choose a base ref
...
head repository: jruby/jruby
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: 66a1c8ede7c6
Choose a head ref
  • 2 commits
  • 1 file changed
  • 1 contributor

Commits on Mar 30, 2015

  1. Copy the full SHA
    0efdc52 View commit details
  2. Copy the full SHA
    66a1c8e View commit details
Showing with 2 additions and 6 deletions.
  1. +2 −6 truffle/src/main/java/org/jruby/truffle/nodes/core/StringNodes.java
Original file line number Diff line number Diff line change
@@ -873,6 +873,7 @@ private int countSlow(VirtualFrame frame, RubyString string, Object[] args) {
}
}

@RubiniusOnly
@CoreMethod(names = "data")
public abstract static class DataNode extends CoreMethodNode {

@@ -997,8 +998,6 @@ public RubyBasicObject downcase(RubyString string) {
@CoreMethod(names = "each_byte", needsBlock = true, returnsEnumeratorIfNoBlock = true)
public abstract static class EachByteNode extends YieldingCoreMethodNode {

@Child private CallDispatchHeadNode toEnumNode;

public EachByteNode(RubyContext context, SourceSection sourceSection) {
super(context, sourceSection);
}
@@ -1009,13 +1008,10 @@ public EachByteNode(EachByteNode prev) {

@Specialization
public RubyString eachByte(VirtualFrame frame, RubyString string, RubyProc block) {
notDesignedForCompilation();

final ByteList bytes = string.getBytes();
final int begin = bytes.getBegin();

for (int i = 0; i < bytes.getRealSize(); i++) {
yield(frame, block, bytes.get(begin + i));
yield(frame, block, bytes.get(i) & 0xff);
}

return string;