Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Fixes #2258. Encoding issue with backticks
  • Loading branch information
enebo committed Dec 3, 2014
1 parent 5e0ee3c commit 2c6af6d
Show file tree
Hide file tree
Showing 6 changed files with 2,372 additions and 2,365 deletions.
9 changes: 8 additions & 1 deletion core/src/main/java/org/jruby/ast/DXStrNode.java
Expand Up @@ -31,6 +31,7 @@
***** END LICENSE BLOCK *****/
package org.jruby.ast;

import org.jcodings.Encoding;
import org.jruby.Ruby;
import org.jruby.ast.types.ILiteralNode;
import org.jruby.ast.visitor.NodeVisitor;
Expand All @@ -48,6 +49,10 @@ public DXStrNode(ISourcePosition position, DStrNode node) {
super(position);
addAll(node);
}

public DXStrNode(ISourcePosition position, Encoding encoding) {
super(position, encoding);
}

public DXStrNode(ISourcePosition position) {
super(position);
Expand All @@ -69,6 +74,8 @@ public Object accept(NodeVisitor iVisitor) {

@Override
public IRubyObject interpret(Ruby runtime, ThreadContext context, IRubyObject self, Block aBlock) {
return self.callMethod(context, "`", super.interpret(runtime, context, self, aBlock));
IRubyObject string = super.interpret(runtime, context, self, aBlock);

return self.callMethod(context, "`", string);
}
}
Empty file.

0 comments on commit 2c6af6d

Please sign in to comment.