diff --git a/debug.c b/debug.c index f811ec6779..e4ad163ad1 100644 --- a/debug.c +++ b/debug.c @@ -11,6 +11,7 @@ #include "ruby/ruby.h" #include "ruby/encoding.h" +#include "ruby/io.h" #include "ruby/util.h" #include "vm_debug.h" #include "eval_intern.h" diff --git a/gc.c b/gc.c index b00dda8ffb..d0144f5266 100644 --- a/gc.c +++ b/gc.c @@ -14,13 +14,13 @@ #define rb_data_object_alloc rb_data_object_alloc #define rb_data_typed_object_alloc rb_data_typed_object_alloc -#include "internal.h" +#include "ruby/io.h" #include "ruby/st.h" #include "ruby/re.h" -#include "ruby/io.h" #include "ruby/thread.h" #include "ruby/util.h" #include "ruby/debug.h" +#include "internal.h" #include "eval_intern.h" #include "vm_core.h" #include "gc.h" diff --git a/internal.h b/internal.h index 119726b384..1a965991d3 100644 --- a/internal.h +++ b/internal.h @@ -14,7 +14,6 @@ #include "ruby.h" #include "ruby/encoding.h" -#include "ruby/io.h" #if defined(__cplusplus) extern "C" { @@ -1315,7 +1314,9 @@ void ruby_set_inplace_mode(const char *); ssize_t rb_io_bufread(VALUE io, void *buf, size_t size); void rb_stdio_set_default_encoding(void); VALUE rb_io_flush_raw(VALUE, int); +#ifdef RUBY_IO_H size_t rb_io_memsize(const rb_io_t *); +#endif int rb_stderr_tty_p(void); /* load.c */ diff --git a/string.c b/string.c index 75db0d22e8..390a9c3a58 100644 --- a/string.c +++ b/string.c @@ -24,6 +24,7 @@ #define BEG(no) (regs->beg[(no)]) #define END(no) (regs->end[(no)]) +#include #include #include diff --git a/win32/win32.c b/win32/win32.c index 5cb842ff76..025c4a3726 100644 --- a/win32/win32.c +++ b/win32/win32.c @@ -23,6 +23,7 @@ #include "ruby/ruby.h" #include "ruby/encoding.h" +#include "ruby/io.h" #include "ruby/util.h" #include #include