print OUTH "/* Generated by generate_treefuncs.pl from treefuncs.def!\n";
print OUTH " * Do not edit by hand! */\n\n";
-$typedefs = "typedef union _Node Node;\n";
+$typedefs = "typedef union Node Node;\n";
$typeenums = "enum {\n";
$typename = "";
$typeenums .= "\t$uct"."_NODE,\n";
- $typedefs .= "typedef struct _$typename $typename;\n";
+ $typedefs .= "typedef struct $typename $typename;\n";
- $typestruct{$typename} = "struct _$typename {\n\tNodeType type;\n";
+ $typestruct{$typename} = "struct $typename {\n\tNodeType type;\n";
$copyfunc_prot{$typename} = "static $typename *\ncopy_$lct ($typename * self)";
$setfunc_prot{$typename} = "static void\nsetv_$lct ($typename * self, va_list __ap)";
$freefunc_prot{$typename} = "void\nfree_$lct ($typename * self)";
print OUTH "$typestruct{$t}\n\n";
}
-print OUTH "union _Node {\n\tNodeType type;\n";
+print OUTH "union Node {\n\tNodeType type;\n";
foreach $t (sort keys %typestruct) {
$foo = lc $t;
<COMMENT>^(I(S.RI).E\(([1-9][0-9]+|[2-9]))/(\)) {
/* Thy evil easter egg */
#define QQ(x) long x
-#define KK(x) =atoi(__(&,,x,))
+#define KK(x) =atoi(oo(&,,x,))
#define MM(x,a) {QQ(i);for(i=2;i<x;i++){a}}
#define PP(Q) (P%Q)==0
-#define ___(x,y,z) if(x z y)
-#define __(a,x,y,z) a(yytext[y] x z)
-#define O__O(a,b) fprintf(stderr,"%s is %s!\n",a,b)
-QQ(m)=1;___(__(,==,2,'P'),__(,==,5,'M'),&&
-){QQ(P)KK(8);MM(P,___(PP(i),,)m=0;)}__(,=,
-7,0);___(,,m){O__O(__( &,,8,),__(&,,2,));}
+#define ooo(x,y,z) if(x z y)
+#define oo(a,x,y,z) a(yytext[y] x z)
+#define OooO(a,b) fprintf(stderr,"%s is %s!\n",a,b)
+QQ(m)=1;ooo(oo(,==,2,'P'),oo(,==,5,'M'),&&
+){QQ(P)KK(8);MM(P,ooo(PP(i),,)m=0;)}oo(,=,
+7,0);ooo(,,m){OooO(oo( &,,8,),oo(&,,2,));}
#undef QQ
#undef KK
#undef MM
#undef PP
-#undef ___
-#undef __
-#undef O__O
+#undef ooo
+#undef oo
+#undef OooO
REJECT;
}
#include <glib.h>
-struct _Class;
-struct _Type;
+struct Class;
+struct Type;
enum {
GOB_WARN,
/* get a name usable for a cast from a GObject (without G_TYPE_)*/
const char *get_cast(const char *type, gboolean simple_only);
-struct _Type *get_tree_type(const char *type, gboolean simple_only);
-char *get_type(const struct _Type *t, gboolean postfix_to_stars);
+struct Type *get_tree_type(const char *type, gboolean simple_only);
+char *get_type(const struct Type *t, gboolean postfix_to_stars);
enum {
SPECIAL_2POINTER,
};
/* returns TRUE if there are any special types at all */
-gboolean setup_special_array(struct _Class *c, gboolean *special_array);
+gboolean setup_special_array(struct Class *c, gboolean *special_array);
char * make_me_type (const char *type, const char *alt);