From 6ff6dcedda7458d5f429f906cb2909f0aca1650f Mon Sep 17 00:00:00 2001 From: Charles Oliver Nutter Date: Wed, 6 Mar 2024 14:51:12 -0600 Subject: [PATCH] Missed a few functions from MRI intern.h These functions are not internal; they are functions for working with internal types. --- core/src/main/java/org/jruby/api/MRI.java | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/core/src/main/java/org/jruby/api/MRI.java b/core/src/main/java/org/jruby/api/MRI.java index d1d2c93600c..298ec484494 100644 --- a/core/src/main/java/org/jruby/api/MRI.java +++ b/core/src/main/java/org/jruby/api/MRI.java @@ -11,6 +11,7 @@ import org.jruby.runtime.ThreadContext; import org.jruby.runtime.builtin.IRubyObject; import org.jruby.util.ByteList; +import org.jruby.util.ByteListHolder; import org.jruby.util.io.EncodingUtils; import org.jruby.util.io.IOEncodable; import org.jruby.util.io.OpenFile; @@ -173,6 +174,18 @@ public static Encoding rb_default_external_encoding(ThreadContext context) { return EncodingUtils.defaultExternalEncoding(context.runtime); } + public static void rb_str_buf_cat(Ruby runtime, RubyString str, ByteList ptr) { + EncodingUtils.rbStrBufCat(runtime, str, ptr); + } + + public static void rb_str_buf_cat(Ruby runtime, ByteListHolder str, byte[] ptrBytes, int ptr, int len) { + EncodingUtils.rbStrBufCat(runtime, str, ptrBytes, ptr, len); + } + + public static void rb_str_buf_cat(Ruby runtime, ByteList str, byte[] ptrBytes, int ptr, int len) { + EncodingUtils.rbStrBufCat(runtime, str, ptrBytes, ptr, len); + } + public static void rb_enc_str_buf_cat(ThreadContext context, RubyString str, ByteList ptr, Encoding enc) { EncodingUtils.encStrBufCat(context.runtime, str, ptr, enc); }