summaryrefslogtreecommitdiff
path: root/parse.y
diff options
context:
space:
mode:
authornobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2006-06-20 16:41:08 +0000
committernobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2006-06-20 16:41:08 +0000
commitdd69e5b006aaa75f7ef715979c36f2a98d4e77e4 (patch)
tree6057bed57d840786b01cc3ad2a339901886bb60b /parse.y
parent1e5a8a56f0e6b4ad194fdaddcc312afa329884be (diff)
* parse.y (yylex, reswords): modifier token is no longer returned in
fname state. [ruby-dev:28775] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@10349 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'parse.y')
-rw-r--r--parse.y5
1 files changed, 3 insertions, 2 deletions
diff --git a/parse.y b/parse.y
index 651c798..af81a89 100644
--- a/parse.y
+++ b/parse.y
@@ -964,11 +964,11 @@ op : '|' { $$ = '|'; }
reswords : k__LINE__ | k__FILE__ | klBEGIN | klEND
| kALIAS | kAND | kBEGIN | kBREAK | kCASE | kCLASS | kDEF
- | kDEFINED | kDO | kDO_BLOCK | kELSE | kELSIF | kEND | kENSURE | kFALSE
+ | kDEFINED | kDO | kELSE | kELSIF | kEND | kENSURE | kFALSE
| kFOR | kIN | kMODULE | kNEXT | kNIL | kNOT
| kOR | kREDO | kRESCUE | kRETRY | kRETURN | kSELF | kSUPER
| kTHEN | kTRUE | kUNDEF | kWHEN | kYIELD
- | kIF_MOD | kUNLESS_MOD | kWHILE_MOD | kUNTIL_MOD | kRESCUE_MOD
+ | kIF | kUNLESS | kWHILE | kUNTIL
;
arg : lhs '=' arg
@@ -4448,6 +4448,7 @@ yylex()
lex_state = kw->state;
if (state == EXPR_FNAME) {
yylval.id = rb_intern(kw->name);
+ return kw->id[0];
}
if (kw->id[0] == kDO) {
if (COND_P()) return kDO_COND;