2000-05-01 05:42:38 -04:00
|
|
|
/**********************************************************************
|
1999-08-13 01:45:20 -04:00
|
|
|
|
|
|
|
rubyio.h -
|
|
|
|
|
|
|
|
$Author$
|
|
|
|
created at: Fri Nov 12 16:47:09 JST 1993
|
|
|
|
|
* encoding.c: provide basic features for M17N.
* parse.y: encoding aware parsing.
* parse.y (pragma_encoding): encoding specification pragma.
* parse.y (rb_intern3): encoding specified symbols.
* string.c (rb_str_length): length based on characters.
for older behavior, bytesize method added.
* string.c (rb_str_index_m): index based on characters. rindex as
well.
* string.c (succ_char): encoding aware succeeding string.
* string.c (rb_str_reverse): reverse based on characters.
* string.c (rb_str_inspect): encoding aware string description.
* string.c (rb_str_upcase_bang): encoding aware case conversion.
downcase, capitalize, swapcase as well.
* string.c (rb_str_tr_bang): tr based on characters. delete,
squeeze, tr_s, count as well.
* string.c (rb_str_split_m): split based on characters.
* string.c (rb_str_each_line): encoding aware each_line.
* string.c (rb_str_each_char): added. iteration based on
characters.
* string.c (rb_str_strip_bang): encoding aware whitespace
stripping. lstrip, rstrip as well.
* string.c (rb_str_justify): encoding aware justifying (ljust,
rjust, center).
* string.c (str_encoding): get encoding attribute from a string.
* re.c (rb_reg_initialize): encoding aware regular expression
* sprintf.c (rb_str_format): formatting (i.e. length count) based
on characters.
* io.c (rb_io_getc): getc to return one-character string.
for older behavior, getbyte method added.
* ext/stringio/stringio.c (strio_getc): ditto.
* io.c (rb_io_ungetc): allow pushing arbitrary string at the
current reading point.
* ext/stringio/stringio.c (strio_ungetc): ditto.
* ext/strscan/strscan.c: encoding support.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@13261 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-08-24 23:29:39 -04:00
|
|
|
Copyright (C) 1993-2007 Yukihiro Matsumoto
|
1999-08-13 01:45:20 -04:00
|
|
|
|
2000-05-01 05:42:38 -04:00
|
|
|
**********************************************************************/
|
1999-08-13 01:45:20 -04:00
|
|
|
|
2007-06-09 23:06:15 -04:00
|
|
|
#ifndef RUBY_IO_H
|
|
|
|
#define RUBY_IO_H 1
|
|
|
|
|
|
|
|
#if defined(__cplusplus)
|
|
|
|
extern "C" {
|
|
|
|
#if 0
|
|
|
|
} /* satisfy cc-mode */
|
|
|
|
#endif
|
|
|
|
#endif
|
1999-08-13 01:45:20 -04:00
|
|
|
|
|
|
|
#include <stdio.h>
|
|
|
|
#include <errno.h>
|
* encoding.c: provide basic features for M17N.
* parse.y: encoding aware parsing.
* parse.y (pragma_encoding): encoding specification pragma.
* parse.y (rb_intern3): encoding specified symbols.
* string.c (rb_str_length): length based on characters.
for older behavior, bytesize method added.
* string.c (rb_str_index_m): index based on characters. rindex as
well.
* string.c (succ_char): encoding aware succeeding string.
* string.c (rb_str_reverse): reverse based on characters.
* string.c (rb_str_inspect): encoding aware string description.
* string.c (rb_str_upcase_bang): encoding aware case conversion.
downcase, capitalize, swapcase as well.
* string.c (rb_str_tr_bang): tr based on characters. delete,
squeeze, tr_s, count as well.
* string.c (rb_str_split_m): split based on characters.
* string.c (rb_str_each_line): encoding aware each_line.
* string.c (rb_str_each_char): added. iteration based on
characters.
* string.c (rb_str_strip_bang): encoding aware whitespace
stripping. lstrip, rstrip as well.
* string.c (rb_str_justify): encoding aware justifying (ljust,
rjust, center).
* string.c (str_encoding): get encoding attribute from a string.
* re.c (rb_reg_initialize): encoding aware regular expression
* sprintf.c (rb_str_format): formatting (i.e. length count) based
on characters.
* io.c (rb_io_getc): getc to return one-character string.
for older behavior, getbyte method added.
* ext/stringio/stringio.c (strio_getc): ditto.
* io.c (rb_io_ungetc): allow pushing arbitrary string at the
current reading point.
* ext/stringio/stringio.c (strio_ungetc): ditto.
* ext/strscan/strscan.c: encoding support.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@13261 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-08-24 23:29:39 -04:00
|
|
|
#include "ruby/encoding.h"
|
1999-08-13 01:45:20 -04:00
|
|
|
|
2004-11-19 11:59:11 -05:00
|
|
|
#if defined(HAVE_STDIO_EXT_H)
|
|
|
|
#include <stdio_ext.h>
|
|
|
|
#endif
|
|
|
|
|
2011-05-03 21:07:03 -04:00
|
|
|
#include "ruby/config.h"
|
|
|
|
#if defined(HAVE_POLL)
|
2013-03-28 10:10:21 -04:00
|
|
|
# ifdef _AIX
|
|
|
|
# define reqevents events
|
|
|
|
# define rtnevents revents
|
|
|
|
# endif
|
2011-05-03 21:07:03 -04:00
|
|
|
# include <poll.h>
|
2013-03-28 10:10:21 -04:00
|
|
|
# ifdef _AIX
|
|
|
|
# undef reqevents
|
|
|
|
# undef rtnevents
|
2013-03-28 21:24:14 -04:00
|
|
|
# undef events
|
|
|
|
# undef revents
|
2013-03-28 10:10:21 -04:00
|
|
|
# endif
|
2011-05-03 21:07:03 -04:00
|
|
|
# define RB_WAITFD_IN POLLIN
|
|
|
|
# define RB_WAITFD_PRI POLLPRI
|
|
|
|
# define RB_WAITFD_OUT POLLOUT
|
|
|
|
#else
|
|
|
|
# define RB_WAITFD_IN 0x001
|
|
|
|
# define RB_WAITFD_PRI 0x002
|
|
|
|
# define RB_WAITFD_OUT 0x004
|
|
|
|
#endif
|
2011-05-03 20:59:57 -04:00
|
|
|
|
2013-04-05 06:29:38 -04:00
|
|
|
RUBY_SYMBOL_EXPORT_BEGIN
|
2010-07-21 17:38:25 -04:00
|
|
|
|
2010-11-18 08:58:47 -05:00
|
|
|
typedef struct {
|
|
|
|
char *ptr; /* off + len <= capa */
|
|
|
|
int off;
|
|
|
|
int len;
|
|
|
|
int capa;
|
|
|
|
} rb_io_buffer_t;
|
|
|
|
|
* file.c, gc.c, io.c, ruby.h, rubyio.h, win32/win32.h (rb_io_t):
renamed from OpenFile.
* ext/dl/cptr.c, ext/io/wait/wait.c, ext/openssl/ossl.h,
ext/openssl/ossl_bio.c, ext/openssl/ossl_ssl.c, ext/pty/pty.c,
ext/readline/readline.c, ext/socket/socket.c: ditto.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@11869 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-02-24 05:30:50 -05:00
|
|
|
typedef struct rb_io_t {
|
2004-12-08 08:26:27 -05:00
|
|
|
int fd; /* file descriptor */
|
|
|
|
FILE *stdio_file; /* stdio ptr for read/write if available */
|
2008-09-24 08:23:52 -04:00
|
|
|
int mode; /* mode flags: FMODE_XXXs */
|
* configure.in (pid_t, uid_t, gid_t): check if defined.
* intern.h, process.c, rubyio.h, ext/etc/etc.c, ext/pty/pty.c: use
rb_{pid,uid,gid}_t instead of plain int. [ruby-dev:30376]
* ext/etc/extconf.rb (PIDT2NUM, NUM2PIDT, UIDT2NUM, NUM2UIDT, GIDT2NUM,
NUM2GIDT): moved to configure.in.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@11769 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-02-17 23:11:57 -05:00
|
|
|
rb_pid_t pid; /* child's pid (for pipes) */
|
1999-08-13 01:45:20 -04:00
|
|
|
int lineno; /* number of lines read */
|
2008-09-24 08:23:52 -04:00
|
|
|
VALUE pathv; /* pathname for file */
|
* file.c, gc.c, io.c, ruby.h, rubyio.h, win32/win32.h (rb_io_t):
renamed from OpenFile.
* ext/dl/cptr.c, ext/io/wait/wait.c, ext/openssl/ossl.h,
ext/openssl/ossl_bio.c, ext/openssl/ossl_ssl.c, ext/pty/pty.c,
ext/readline/readline.c, ext/socket/socket.c: ditto.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@11869 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-02-24 05:30:50 -05:00
|
|
|
void (*finalize)(struct rb_io_t*,int); /* finalize proc */
|
2008-08-16 13:06:35 -04:00
|
|
|
|
2010-11-18 08:58:47 -05:00
|
|
|
rb_io_buffer_t wbuf, rbuf;
|
2008-08-16 13:06:35 -04:00
|
|
|
|
2007-11-19 22:16:53 -05:00
|
|
|
VALUE tied_io_for_writing;
|
2008-08-18 04:00:55 -04:00
|
|
|
|
|
|
|
/*
|
|
|
|
* enc enc2 read action write action
|
|
|
|
* NULL NULL force_encoding(default_external) write the byte sequence of str
|
|
|
|
* e1 NULL force_encoding(e1) convert str.encoding to e1
|
2008-08-18 09:35:55 -04:00
|
|
|
* e1 e2 convert from e2 to e1 convert str.encoding to e2
|
2008-08-18 04:00:55 -04:00
|
|
|
*/
|
2008-08-24 03:49:13 -04:00
|
|
|
struct rb_io_enc_t {
|
|
|
|
rb_encoding *enc;
|
|
|
|
rb_encoding *enc2;
|
2008-09-04 06:22:11 -04:00
|
|
|
int ecflags;
|
2008-09-03 14:18:10 -04:00
|
|
|
VALUE ecopts;
|
2008-08-24 03:49:13 -04:00
|
|
|
} encs;
|
2008-08-16 13:06:35 -04:00
|
|
|
|
|
|
|
rb_econv_t *readconv;
|
2010-11-18 08:58:47 -05:00
|
|
|
rb_io_buffer_t cbuf;
|
2008-08-18 08:06:42 -04:00
|
|
|
|
|
|
|
rb_econv_t *writeconv;
|
2008-09-09 11:02:42 -04:00
|
|
|
VALUE writeconv_asciicompat;
|
2008-09-04 06:22:11 -04:00
|
|
|
int writeconv_pre_ecflags;
|
2008-09-03 14:18:10 -04:00
|
|
|
VALUE writeconv_pre_ecopts;
|
2008-08-18 08:06:42 -04:00
|
|
|
int writeconv_initialized;
|
|
|
|
|
2008-11-07 15:47:02 -05:00
|
|
|
VALUE write_lock;
|
* file.c, gc.c, io.c, ruby.h, rubyio.h, win32/win32.h (rb_io_t):
renamed from OpenFile.
* ext/dl/cptr.c, ext/io/wait/wait.c, ext/openssl/ossl.h,
ext/openssl/ossl_bio.c, ext/openssl/ossl_ssl.c, ext/pty/pty.c,
ext/readline/readline.c, ext/socket/socket.c: ditto.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@11869 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-02-24 05:30:50 -05:00
|
|
|
} rb_io_t;
|
1999-08-13 01:45:20 -04:00
|
|
|
|
2007-02-24 20:16:58 -05:00
|
|
|
#define HAVE_RB_IO_T 1
|
|
|
|
|
2008-08-23 04:41:02 -04:00
|
|
|
#define FMODE_READABLE 0x00000001
|
|
|
|
#define FMODE_WRITABLE 0x00000002
|
|
|
|
#define FMODE_READWRITE (FMODE_READABLE|FMODE_WRITABLE)
|
|
|
|
#define FMODE_BINMODE 0x00000004
|
|
|
|
#define FMODE_SYNC 0x00000008
|
|
|
|
#define FMODE_TTY 0x00000010
|
|
|
|
#define FMODE_DUPLEX 0x00000020
|
|
|
|
#define FMODE_APPEND 0x00000040
|
|
|
|
#define FMODE_CREATE 0x00000080
|
|
|
|
/* #define FMODE_NOREVLOOKUP 0x00000100 */
|
|
|
|
#define FMODE_WSPLIT 0x00000200
|
|
|
|
#define FMODE_WSPLIT_INITIALIZED 0x00000400
|
|
|
|
#define FMODE_TRUNC 0x00000800
|
|
|
|
#define FMODE_TEXTMODE 0x00001000
|
|
|
|
/* #define FMODE_PREP 0x00010000 */
|
2009-08-21 02:17:06 -04:00
|
|
|
#define FMODE_SETENC_BY_BOM 0x00100000
|
1999-08-13 01:45:20 -04:00
|
|
|
|
2000-11-10 02:16:52 -05:00
|
|
|
#define GetOpenFile(obj,fp) rb_io_check_closed((fp) = RFILE(rb_io_taint_check(obj))->fptr)
|
1999-08-13 01:45:20 -04:00
|
|
|
|
2010-11-18 08:58:47 -05:00
|
|
|
#define RB_IO_BUFFER_INIT(buf) do {\
|
|
|
|
(buf).ptr = NULL;\
|
|
|
|
(buf).off = 0;\
|
|
|
|
(buf).len = 0;\
|
|
|
|
(buf).capa = 0;\
|
|
|
|
} while (0)
|
|
|
|
|
1999-08-13 01:45:20 -04:00
|
|
|
#define MakeOpenFile(obj, fp) do {\
|
2001-10-03 03:19:19 -04:00
|
|
|
if (RFILE(obj)->fptr) {\
|
|
|
|
rb_io_close(obj);\
|
2010-03-12 22:26:18 -05:00
|
|
|
rb_io_fptr_finalize(RFILE(obj)->fptr);\
|
2001-10-03 03:19:19 -04:00
|
|
|
RFILE(obj)->fptr = 0;\
|
|
|
|
}\
|
2011-04-07 07:04:18 -04:00
|
|
|
(fp) = 0;\
|
2010-11-18 08:58:47 -05:00
|
|
|
RB_IO_FPTR_NEW(fp);\
|
2011-04-07 07:04:18 -04:00
|
|
|
RFILE(obj)->fptr = (fp);\
|
2010-11-18 08:58:47 -05:00
|
|
|
} while (0)
|
|
|
|
|
|
|
|
#define RB_IO_FPTR_NEW(fp) do {\
|
2011-04-07 07:04:18 -04:00
|
|
|
(fp) = ALLOC(rb_io_t);\
|
|
|
|
(fp)->fd = -1;\
|
|
|
|
(fp)->stdio_file = NULL;\
|
|
|
|
(fp)->mode = 0;\
|
|
|
|
(fp)->pid = 0;\
|
|
|
|
(fp)->lineno = 0;\
|
|
|
|
(fp)->pathv = Qnil;\
|
|
|
|
(fp)->finalize = 0;\
|
|
|
|
RB_IO_BUFFER_INIT((fp)->wbuf);\
|
|
|
|
RB_IO_BUFFER_INIT((fp)->rbuf);\
|
|
|
|
RB_IO_BUFFER_INIT((fp)->cbuf);\
|
|
|
|
(fp)->readconv = NULL;\
|
|
|
|
(fp)->writeconv = NULL;\
|
|
|
|
(fp)->writeconv_asciicompat = Qnil;\
|
|
|
|
(fp)->writeconv_pre_ecflags = 0;\
|
|
|
|
(fp)->writeconv_pre_ecopts = Qnil;\
|
|
|
|
(fp)->writeconv_initialized = 0;\
|
|
|
|
(fp)->tied_io_for_writing = 0;\
|
|
|
|
(fp)->encs.enc = NULL;\
|
|
|
|
(fp)->encs.enc2 = NULL;\
|
|
|
|
(fp)->encs.ecflags = 0;\
|
|
|
|
(fp)->encs.ecopts = Qnil;\
|
|
|
|
(fp)->write_lock = 0;\
|
1999-08-13 01:45:20 -04:00
|
|
|
} while (0)
|
|
|
|
|
* file.c, gc.c, io.c, ruby.h, rubyio.h, win32/win32.h (rb_io_t):
renamed from OpenFile.
* ext/dl/cptr.c, ext/io/wait/wait.c, ext/openssl/ossl.h,
ext/openssl/ossl_bio.c, ext/openssl/ossl_ssl.c, ext/pty/pty.c,
ext/readline/readline.c, ext/socket/socket.c: ditto.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@11869 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-02-24 05:30:50 -05:00
|
|
|
FILE *rb_io_stdio_file(rb_io_t *fptr);
|
1999-08-13 01:45:20 -04:00
|
|
|
|
* bignum.c: changed `foo _((boo))' to `foo(boo)`. [ruby-dev:27056]
* defines.h, dir.c, dln.h, enumerator.c, env.h, error.c, eval.c, file.c,
gc.c, hash.c, inits.c, intern.h, io.c, lex.c, marshal.c, missing.h,
node.h, numeric.c, pack.c, process.c, re.h, ruby.c, ruby.h, rubyio.h,
rubysig.h, signal.c, sprintf.c, st.h, string.c, struct.c, time.c,
util.c, util.h, variable.c: ditto.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@9155 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2005-09-14 02:32:32 -04:00
|
|
|
FILE *rb_fdopen(int, const char*);
|
2008-09-05 07:30:35 -04:00
|
|
|
int rb_io_modestr_fmode(const char *modestr);
|
|
|
|
int rb_io_modestr_oflags(const char *modestr);
|
|
|
|
int rb_io_oflags_fmode(int oflags);
|
* file.c, gc.c, io.c, ruby.h, rubyio.h, win32/win32.h (rb_io_t):
renamed from OpenFile.
* ext/dl/cptr.c, ext/io/wait/wait.c, ext/openssl/ossl.h,
ext/openssl/ossl_bio.c, ext/openssl/ossl_ssl.c, ext/pty/pty.c,
ext/readline/readline.c, ext/socket/socket.c: ditto.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@11869 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-02-24 05:30:50 -05:00
|
|
|
void rb_io_check_writable(rb_io_t*);
|
|
|
|
void rb_io_check_readable(rb_io_t*);
|
2011-01-14 19:42:14 -05:00
|
|
|
void rb_io_check_char_readable(rb_io_t *fptr);
|
|
|
|
void rb_io_check_byte_readable(rb_io_t *fptr);
|
* file.c, gc.c, io.c, ruby.h, rubyio.h, win32/win32.h (rb_io_t):
renamed from OpenFile.
* ext/dl/cptr.c, ext/io/wait/wait.c, ext/openssl/ossl.h,
ext/openssl/ossl_bio.c, ext/openssl/ossl_ssl.c, ext/pty/pty.c,
ext/readline/readline.c, ext/socket/socket.c: ditto.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@11869 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-02-24 05:30:50 -05:00
|
|
|
int rb_io_fptr_finalize(rb_io_t*);
|
|
|
|
void rb_io_synchronized(rb_io_t*);
|
|
|
|
void rb_io_check_initialized(rb_io_t*);
|
|
|
|
void rb_io_check_closed(rb_io_t*);
|
2011-01-14 19:42:14 -05:00
|
|
|
VALUE rb_io_get_io(VALUE io);
|
2012-07-27 05:25:54 -04:00
|
|
|
VALUE rb_io_check_io(VALUE io);
|
2011-01-14 19:42:14 -05:00
|
|
|
VALUE rb_io_get_write_io(VALUE io);
|
|
|
|
VALUE rb_io_set_write_io(VALUE io, VALUE w);
|
* bignum.c: changed `foo _((boo))' to `foo(boo)`. [ruby-dev:27056]
* defines.h, dir.c, dln.h, enumerator.c, env.h, error.c, eval.c, file.c,
gc.c, hash.c, inits.c, intern.h, io.c, lex.c, marshal.c, missing.h,
node.h, numeric.c, pack.c, process.c, re.h, ruby.c, ruby.h, rubyio.h,
rubysig.h, signal.c, sprintf.c, st.h, string.c, struct.c, time.c,
util.c, util.h, variable.c: ditto.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@9155 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2005-09-14 02:32:32 -04:00
|
|
|
int rb_io_wait_readable(int);
|
|
|
|
int rb_io_wait_writable(int);
|
2011-05-03 20:59:57 -04:00
|
|
|
int rb_wait_for_single_fd(int fd, int events, struct timeval *tv);
|
* file.c, gc.c, io.c, ruby.h, rubyio.h, win32/win32.h (rb_io_t):
renamed from OpenFile.
* ext/dl/cptr.c, ext/io/wait/wait.c, ext/openssl/ossl.h,
ext/openssl/ossl_bio.c, ext/openssl/ossl_ssl.c, ext/pty/pty.c,
ext/readline/readline.c, ext/socket/socket.c: ditto.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@11869 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-02-24 05:30:50 -05:00
|
|
|
void rb_io_set_nonblock(rb_io_t *fptr);
|
2010-07-21 23:02:40 -04:00
|
|
|
int rb_io_extract_encoding_option(VALUE opt, rb_encoding **enc_p, rb_encoding **enc2_p, int *fmode_p);
|
2011-01-14 19:42:14 -05:00
|
|
|
ssize_t rb_io_bufwrite(VALUE io, const void *buf, size_t size);
|
* bignum.c: changed `foo _((boo))' to `foo(boo)`. [ruby-dev:27056]
* defines.h, dir.c, dln.h, enumerator.c, env.h, error.c, eval.c, file.c,
gc.c, hash.c, inits.c, intern.h, io.c, lex.c, marshal.c, missing.h,
node.h, numeric.c, pack.c, process.c, re.h, ruby.c, ruby.h, rubyio.h,
rubysig.h, signal.c, sprintf.c, st.h, string.c, struct.c, time.c,
util.c, util.h, variable.c: ditto.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@9155 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2005-09-14 02:32:32 -04:00
|
|
|
|
2008-09-05 07:30:35 -04:00
|
|
|
/* compatibility for ruby 1.8 and older */
|
|
|
|
#define rb_io_mode_flags(modestr) rb_io_modestr_fmode(modestr)
|
|
|
|
#define rb_io_modenum_flags(oflags) rb_io_oflags_fmode(oflags)
|
|
|
|
|
* bignum.c: changed `foo _((boo))' to `foo(boo)`. [ruby-dev:27056]
* defines.h, dir.c, dln.h, enumerator.c, env.h, error.c, eval.c, file.c,
gc.c, hash.c, inits.c, intern.h, io.c, lex.c, marshal.c, missing.h,
node.h, numeric.c, pack.c, process.c, re.h, ruby.c, ruby.h, rubyio.h,
rubysig.h, signal.c, sprintf.c, st.h, string.c, struct.c, time.c,
util.c, util.h, variable.c: ditto.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@9155 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2005-09-14 02:32:32 -04:00
|
|
|
VALUE rb_io_taint_check(VALUE);
|
|
|
|
NORETURN(void rb_eof_error(void));
|
|
|
|
|
* file.c, gc.c, io.c, ruby.h, rubyio.h, win32/win32.h (rb_io_t):
renamed from OpenFile.
* ext/dl/cptr.c, ext/io/wait/wait.c, ext/openssl/ossl.h,
ext/openssl/ossl_bio.c, ext/openssl/ossl_ssl.c, ext/pty/pty.c,
ext/readline/readline.c, ext/socket/socket.c: ditto.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@11869 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-02-24 05:30:50 -05:00
|
|
|
void rb_io_read_check(rb_io_t*);
|
|
|
|
int rb_io_read_pending(rb_io_t*);
|
2009-10-10 06:49:47 -04:00
|
|
|
DEPRECATED(void rb_read_check(FILE*));
|
* bignum.c: changed `foo _((boo))' to `foo(boo)`. [ruby-dev:27056]
* defines.h, dir.c, dln.h, enumerator.c, env.h, error.c, eval.c, file.c,
gc.c, hash.c, inits.c, intern.h, io.c, lex.c, marshal.c, missing.h,
node.h, numeric.c, pack.c, process.c, re.h, ruby.c, ruby.h, rubyio.h,
rubysig.h, signal.c, sprintf.c, st.h, string.c, struct.c, time.c,
util.c, util.h, variable.c: ditto.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@9155 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2005-09-14 02:32:32 -04:00
|
|
|
|
2013-10-01 07:54:53 -04:00
|
|
|
struct stat;
|
|
|
|
VALUE rb_stat_new(const struct stat *);
|
|
|
|
|
|
|
|
/* gc.c */
|
|
|
|
|
2013-04-05 06:29:38 -04:00
|
|
|
RUBY_SYMBOL_EXPORT_END
|
2010-07-21 17:38:25 -04:00
|
|
|
|
2007-06-09 23:06:15 -04:00
|
|
|
#if defined(__cplusplus)
|
|
|
|
#if 0
|
|
|
|
{ /* satisfy cc-mode */
|
|
|
|
#endif
|
|
|
|
} /* extern "C" { */
|
1999-08-13 01:45:20 -04:00
|
|
|
#endif
|
2007-06-09 23:06:15 -04:00
|
|
|
|
|
|
|
#endif /* RUBY_IO_H */
|