From dd64078d4cd45a93201991e79b487bc4f92af758 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?J=C3=A9r=C3=A9my=20Zurcher?= <jeremy@asynk.ch>
Date: Thu, 18 Aug 2011 10:57:13 +0200
Subject: fix struct handling in genruby

---
 tools/genruby.rb | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/tools/genruby.rb b/tools/genruby.rb
index 4b9582f..c9ee5f1 100755
--- a/tools/genruby.rb
+++ b/tools/genruby.rb
@@ -109,7 +109,7 @@ TYPES_USAGE = {}
 #
 def set_type t, v, cb=false
     return 'bool' if t =~/Eina_Bool/
-    v = v.downcase.gsub(/(const|struct|enum|union)/,'').strip
+    v = v.downcase.sub(/(const|struct|enum|union) /,' ').strip
     if not TYPES[t].nil?
         puts "type already exists >#{t}< #{v}"
         exit 1
@@ -128,7 +128,7 @@ def set_type t, v, cb=false
 end
 #
 def get_type t
-    k = t.gsub(/(const|struct|enum|union)/, '').strip
+    k = t.gsub(/(const|enum|union)/, '').strip
     k.sub!(/\*/,' *') if k=~/\w+\*/
     r = TYPES[k]
     if r.nil?
-- 
cgit v1.1-2-g2b99