summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJérémy Zurcher <jeremy@asynk.ch>2011-06-19 18:43:09 +0200
committerJérémy Zurcher <jeremy@asynk.ch>2011-06-19 18:43:09 +0200
commitaf02f35f827079a0258fb5bfb718294d29142d1e (patch)
tree667c47e9d730ab65cacf8b1e7d9b8462f4fa2c57
parent39eceb24663e22eeb8783d87dabbc62f21352194 (diff)
downloadffi-efl-af02f35f827079a0258fb5bfb718294d29142d1e.zip
ffi-efl-af02f35f827079a0258fb5bfb718294d29142d1e.tar.gz
genruby.rb: add unsigned short *, accept commented callbacks
-rwxr-xr-xtools/genruby.rb3
1 files changed, 2 insertions, 1 deletions
diff --git a/tools/genruby.rb b/tools/genruby.rb
index 5753b5a..e77ebf0 100755
--- a/tools/genruby.rb
+++ b/tools/genruby.rb
@@ -83,6 +83,7 @@ TYPES = {
'double *' => ':double_p',
'unsigned int *' => ':uint_p',
'unsigned char *' => ':uchar_p',
+ 'unsigned short *' => ':ushort_p',
'char *' => ':string', # FIXME ?!?!
'char **' => ':string_array', # FIXME ?!?!
'char ***' => ':string_array_p', # FIXME ?!?!
@@ -211,7 +212,7 @@ def gen_callbacks path, indent
r = []
open(path+'-callbacks','r').readlines.each do |l|
l.strip!
- if not l=~/^\s*typedef\s+(.*)((?:\(\*?\w+\)| \*?\w+))\s*\((.*)\);\s*$/
+ if not l=~/^\s*typedef\s+(.*)((?:\(\*?\w+\)| \*?\w+))\s*\((.*)\);/
r << indent+"# #{l}\n#{indent}# FIXME"
next
end