summaryrefslogtreecommitdiff
path: root/defs/id.def
diff options
context:
space:
mode:
authornobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2013-05-01 02:38:44 +0000
committernobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2013-05-01 02:38:44 +0000
commit9644f9b57217c606d6ba845d8f789a0799c2e5a5 (patch)
treec15e1236d7e1e199253f1bfdd217d57a678ceabc /defs/id.def
parentc322f10ad99f9cc964dca4e42179f52450516b74 (diff)
proc.c: use predefined IDs
* defs/id.def (predefined): add "idProc". * proc.c (mnew, mproc, mlambda): use predefined IDs. * vm.c (Init_VM): ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@40530 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'defs/id.def')
-rw-r--r--defs/id.def6
1 files changed, 5 insertions, 1 deletions
diff --git a/defs/id.def b/defs/id.def
index ea0746e4d6..91c4110d24 100644
--- a/defs/id.def
+++ b/defs/id.def
@@ -7,6 +7,7 @@ firstline, predefined = __LINE__+1, %[\
gets
succ
each
+ proc
lambda
send
__send__
@@ -48,7 +49,10 @@ const_ids = []
class_ids = []
names = {}
predefined.split(/^/).each_with_index do |line, num|
- next if /^#/ =~ line or (name, token = line.split; !name)
+ next if /^#/ =~ line
+ line.sub!(/\s+#.*/, '')
+ name, token = line.split
+ next unless name
token ||= name
if /#/ =~ token
token = "_#{token.gsub(/\W+/, '_')}"