diff options
author | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2009-04-06 01:47:15 +0000 |
---|---|---|
committer | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2009-04-06 01:47:15 +0000 |
commit | aaec30f96a67c43b89b8b5173734c77bd1a3411e (patch) | |
tree | 27b052f5891b6e491ff84111351778160a9c47c8 /ext/stringio/stringio.c | |
parent | 03dbd024ee994dde01597daa15389c7d0c6aec02 (diff) | |
download | ruby-aaec30f96a67c43b89b8b5173734c77bd1a3411e.tar.gz |
* ext/stringio/stringio.c (strio_path): removed. [ruby-dev:38254]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@23137 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'ext/stringio/stringio.c')
-rw-r--r-- | ext/stringio/stringio.c | 10 |
1 files changed, 3 insertions, 7 deletions
diff --git a/ext/stringio/stringio.c b/ext/stringio/stringio.c index ce1d55fd46..bc605da2a7 100644 --- a/ext/stringio/stringio.c +++ b/ext/stringio/stringio.c @@ -86,11 +86,11 @@ get_strio(VALUE self) } static VALUE -strio_substr(struct StringIO *ptr, int pos, int len) +strio_substr(struct StringIO *ptr, long pos, long len) { VALUE str = ptr->string; rb_encoding *enc = rb_enc_get(str); - int rlen = RSTRING_LEN(str) - pos; + long rlen = RSTRING_LEN(str) - pos; if (len > rlen) len = rlen; if (len < 0) len = 0; @@ -160,7 +160,7 @@ static void strio_init(int argc, VALUE *argv, struct StringIO *ptr) { VALUE string, mode; - int trunc = Qfalse; + int trunc = 0; switch (rb_scan_args(argc, argv, "02", &string, &mode)) { case 2: @@ -1185,9 +1185,6 @@ strio_sysread(int argc, VALUE *argv, VALUE self) #define strio_syswrite strio_write -/* call-seq: strio.path -> nil */ -#define strio_path strio_nil - /* * call-seq: * strio.isatty -> nil @@ -1325,7 +1322,6 @@ Init_stringio() rb_define_method(StringIO, "sync", strio_get_sync, 0); rb_define_method(StringIO, "sync=", strio_set_sync, 1); rb_define_method(StringIO, "tell", strio_tell, 0); - rb_define_method(StringIO, "path", strio_path, 0); rb_define_method(StringIO, "each", strio_each, -1); rb_define_method(StringIO, "each_line", strio_each, -1); |