[前][次][番号順一覧][スレッド一覧]

ruby-changes:57025

From: Nobuyoshi <ko1@a...>
Date: Wed, 14 Aug 2019 11:37:04 +0900 (JST)
Subject: [ruby-changes:57025] Nobuyoshi Nakada: c744b62698 (master): io.c: export rb_io_extract_modeenc

https://git.ruby-lang.org/ruby.git/commit/?id=c744b62698

From c744b626985f5d78c6d8d8830b9aee2898412d7c Mon Sep 17 00:00:00 2001
From: Nobuyoshi Nakada <nobu@r...>
Date: Fri, 10 Jun 2016 08:01:39 +0900
Subject: io.c: export rb_io_extract_modeenc

* include/ruby/io.h (rb_io_enc_t): add typedef.

* io.c (rb_io_extract_modeenc): export.

diff --git a/include/ruby/io.h b/include/ruby/io.h
index 7caca17..152f4ef 100644
--- a/include/ruby/io.h
+++ b/include/ruby/io.h
@@ -101,6 +101,8 @@ typedef struct rb_io_t { https://github.com/ruby/ruby/blob/trunk/include/ruby/io.h#L101
     VALUE write_lock;
 } rb_io_t;
 
+typedef struct rb_io_enc_t rb_io_enc_t;
+
 #define HAVE_RB_IO_T 1
 
 #define FMODE_READABLE              0x00000001
@@ -153,6 +155,7 @@ int rb_io_wait_writable(int); https://github.com/ruby/ruby/blob/trunk/include/ruby/io.h#L155
 int rb_wait_for_single_fd(int fd, int events, struct timeval *tv);
 void rb_io_set_nonblock(rb_io_t *fptr);
 int rb_io_extract_encoding_option(VALUE opt, rb_encoding **enc_p, rb_encoding **enc2_p, int *fmode_p);
+void rb_io_extract_modeenc(VALUE *vmode_p, VALUE *vperm_p, VALUE opthash, int *oflags_p, int *fmode_p, rb_io_enc_t *convconfig_p);
 ssize_t rb_io_bufwrite(VALUE io, const void *buf, size_t size);
 
 /* compatibility for ruby 1.8 and older */
diff --git a/io.c b/io.c
index 6a4c5b9..19ce45c 100644
--- a/io.c
+++ b/io.c
@@ -5864,7 +5864,7 @@ extract_binmode(VALUE opthash, int *fmode) https://github.com/ruby/ruby/blob/trunk/io.c#L5864
     }
 }
 
-static void
+void
 rb_io_extract_modeenc(VALUE *vmode_p, VALUE *vperm_p, VALUE opthash,
         int *oflags_p, int *fmode_p, convconfig_t *convconfig_p)
 {
-- 
cgit v0.10.2


--
ML: ruby-changes@q...
Info: http://www.atdot.net/~ko1/quickml/

[前][次][番号順一覧][スレッド一覧]