contrib/objcwrapper header_static: ignore struct declarations
authorAlexis Laferrière <alexis.laf@xymus.net>
Wed, 26 Aug 2015 20:12:37 +0000 (16:12 -0400)
committerAlexis Laferrière <alexis.laf@xymus.net>
Thu, 27 Aug 2015 19:26:49 +0000 (15:26 -0400)
Signed-off-by: Alexis Laferrière <alexis.laf@xymus.net>

contrib/objcwrapper/src/header_static.nit

index c43fe2a..19ffd72 100644 (file)
@@ -49,7 +49,10 @@ fun header_static(input: Reader, output: Writer) do
 
        while not input.eof do
                var line = input.read_line
-               if line.to_s.has("static") then static_target = true
+
+               if line.has("typedef struct") then continue
+
+               if line.has("static") then static_target = true
 
                if static_target then
                        if line.to_s.has("__attribute__") then static_attribute_target = true