Skip to content
Snippets Groups Projects
Commit 321b436e authored by stepan's avatar stepan
Browse files

Add missing Truffle Boundary

parent 912cc6f5
Branches
No related tags found
No related merge requests found
...@@ -69,6 +69,7 @@ public final class NativeCharArray extends NativeUInt8Array { ...@@ -69,6 +69,7 @@ public final class NativeCharArray extends NativeUInt8Array {
return new String(mbuf, 0, i); return new String(mbuf, 0, i);
} }
@TruffleBoundary
public String getString() { public String getString() {
byte[] val = getValue(); byte[] val = getValue();
return new String(val, 0, fakesNullTermination() ? val.length : val.length - 1); return new String(val, 0, fakesNullTermination() ? val.length : val.length - 1);
......
...@@ -22,6 +22,7 @@ ...@@ -22,6 +22,7 @@
*/ */
package com.oracle.truffle.r.runtime.ffi.interop; package com.oracle.truffle.r.runtime.ffi.interop;
import com.oracle.truffle.api.CompilerDirectives.TruffleBoundary;
import com.oracle.truffle.api.interop.CanResolve; import com.oracle.truffle.api.interop.CanResolve;
import com.oracle.truffle.api.interop.MessageResolution; import com.oracle.truffle.api.interop.MessageResolution;
import com.oracle.truffle.api.interop.Resolve; import com.oracle.truffle.api.interop.Resolve;
...@@ -78,6 +79,7 @@ public class NativeCharArrayMR { ...@@ -78,6 +79,7 @@ public class NativeCharArrayMR {
@Resolve(message = "EXECUTE") @Resolve(message = "EXECUTE")
public abstract static class NCAToStringNode extends Node { public abstract static class NCAToStringNode extends Node {
@TruffleBoundary
protected java.lang.Object access(NativeCharArray receiver, @SuppressWarnings("unused") Object[] arguments) { protected java.lang.Object access(NativeCharArray receiver, @SuppressWarnings("unused") Object[] arguments) {
return new String(receiver.getValue()); return new String(receiver.getValue());
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment