summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJérémy Zurcher <jeremy@asynk.ch>2012-01-23 16:32:16 +0100
committerJérémy Zurcher <jeremy@asynk.ch>2012-01-23 16:32:16 +0100
commit6c2a551257b31c372d4e34644b9d511b8a6278c8 (patch)
tree204bada900515a70c0ce5c4fbb119678101fec22
parent41cb58308c9454f4e8ecbe73fc83addec9237d84 (diff)
downloadffi-efl-6c2a551257b31c372d4e34644b9d511b8a6278c8.zip
ffi-efl-6c2a551257b31c372d4e34644b9d511b8a6278c8.tar.gz
tools/genruby: use eval to compute enum item values
-rwxr-xr-xtools/genruby.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/tools/genruby.rb b/tools/genruby.rb
index 77a4fb1..2315da0 100755
--- a/tools/genruby.rb
+++ b/tools/genruby.rb
@@ -171,7 +171,7 @@ def gen_enums path, indent
i+=1
else
h[s]=v
- i=v.to_i+1
+ i=eval(v).to_i+1
end
end
args = syms.inject(''){|r,s| r+=":#{s.strip.downcase}, #{h[s]}, " }.sub(/, $/,'')