diff options
-rw-r--r-- | ChangeLog | 4 | ||||
-rw-r--r-- | parse.y | 4 |
2 files changed, 6 insertions, 2 deletions
@@ -1,3 +1,7 @@ +Thu Feb 14 17:38:35 2002 Nobuyoshi Nakada <nobu.nakada@nifty.ne.jp> + + * parse.y: avoid SEGV at OP_ASIGN to pseudo variable. + Thu Feb 14 14:13:16 2002 Yukihiro Matsumoto <matz@ruby-lang.org> * struct.c (Init_Struct): should undefine "allocate" for Struct @@ -427,8 +427,8 @@ stmt : kALIAS fitem {lex_state = EXPR_FNAME;} fitem } | var_lhs tOP_ASGN command_call { - ID vid = $1->nd_vid; if ($1) { + ID vid = $1->nd_vid; if ($2 == tOROP) { $1->nd_value = $3; $$ = NEW_OP_ASGN_OR(gettable(vid), $1); @@ -772,8 +772,8 @@ arg : lhs '=' arg } | var_lhs tOP_ASGN arg { - ID vid = $1->nd_vid; if ($1) { + ID vid = $1->nd_vid; if ($2 == tOROP) { $1->nd_value = $3; $$ = NEW_OP_ASGN_OR(gettable(vid), $1); |