summaryrefslogtreecommitdiffstats
path: root/parse.y
diff options
context:
space:
mode:
authormatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2002-01-18 14:24:01 +0000
committermatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2002-01-18 14:24:01 +0000
commitaf9a0d1e981ee2ed4d145ba10070daabe5cd3f47 (patch)
tree99e97c4d2997df4e344a146d68847ec905fc5302 /parse.y
parentc98187c6f8504e2a52cc6d45bb8934029f523eeb (diff)
downloadruby-af9a0d1e981ee2ed4d145ba10070daabe5cd3f47.tar.gz
ruby-af9a0d1e981ee2ed4d145ba10070daabe5cd3f47.tar.xz
ruby-af9a0d1e981ee2ed4d145ba10070daabe5cd3f47.zip
* io.c (rb_io_s_new): block check moved from initialize to this
method. * io.c (rb_io_s_open): open should call initialize too. IO#for_fd also calls initialize. [new] * error.c (rb_sys_fail): replace INT2FIX() by INT2NUM() since errno value may not fit in Fixnum size on Hurd. * error.c (set_syserr): ditto. * dir.c (dir_s_glob): returns nil if block given. * io.c (rb_io_each_byte): should return self. * io.c (rb_io_close_m): close check added. * dir.c (dir_seek): should return pos. * parse.y (fixpos): orig may be (NODE*)1, which should not be dereferenced. git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@2004 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'parse.y')
-rw-r--r--parse.y1
1 files changed, 1 insertions, 0 deletions
diff --git a/parse.y b/parse.y
index 1b077cb15..00aa32f88 100644
--- a/parse.y
+++ b/parse.y
@@ -4126,6 +4126,7 @@ fixpos(node, orig)
{
if (!node) return;
if (!orig) return;
+ if (orig == (NODE*)1) return;
node->nd_file = orig->nd_file;
nd_set_line(node, nd_line(orig));
}