2 typedef long long int64;
3 typedef unsigned long long uint64;
7 #elif defined(__TINYC__)
9 #define __builtin_va_list va_list
10 #define __builtin_va_start va_start
11 #define __builtin_va_end va_end
13 #define strcasecmp stricmp
14 #define strncasecmp strnicmp
15 #define __declspec(x) __attribute__((x))
19 typedef long long int64;
20 typedef unsigned long long uint64;
22 typedef __int64 int64;
23 typedef unsigned __int64 uint64;
26 #define __ENDIAN_PAD(x) (8 - (x))
28 #define __ENDIAN_PAD(x) 0
32 typedef unsigned long long int uintptr_t;
33 typedef long long int intptr_t;
35 typedef unsigned int uintptr_t;
41 extern void * __ecereNameSpace__ecere__com__eSystem_New(unsigned int size);
43 extern void * __ecereNameSpace__ecere__com__eSystem_New0(unsigned int size);
45 extern void * __ecereNameSpace__ecere__com__eSystem_Renew(void * memory, unsigned int size);
47 extern void * __ecereNameSpace__ecere__com__eSystem_Renew0(void * memory, unsigned int size);
49 extern struct __ecereNameSpace__ecere__com__Class * __ecereClass___ecereNameSpace__ecere__sys__BTNode;
51 struct __ecereNameSpace__ecere__sys__BTNode;
53 extern struct __ecereNameSpace__ecere__com__Class * __ecereClass___ecereNameSpace__ecere__sys__BinaryTree;
55 struct __ecereNameSpace__ecere__sys__BinaryTree
57 struct __ecereNameSpace__ecere__sys__BTNode * root;
59 int (* CompareKey)(struct __ecereNameSpace__ecere__sys__BinaryTree * tree, uintptr_t a, uintptr_t b);
60 void (* FreeKey)(void * key);
61 } __attribute__ ((gcc_struct));
63 extern struct __ecereNameSpace__ecere__com__Class * __ecereClass___ecereNameSpace__ecere__sys__OldList;
65 struct __ecereNameSpace__ecere__sys__OldList
72 } __attribute__ ((gcc_struct));
74 extern struct __ecereNameSpace__ecere__com__Class * __ecereClass___ecereNameSpace__ecere__com__Method;
76 struct __ecereNameSpace__ecere__com__Method
79 struct __ecereNameSpace__ecere__com__Method * parent;
80 struct __ecereNameSpace__ecere__com__Method * left;
81 struct __ecereNameSpace__ecere__com__Method * right;
86 struct __ecereNameSpace__ecere__com__Class * _class;
88 char * dataTypeString;
89 struct Type * dataType;
91 } __attribute__ ((gcc_struct));
93 extern struct __ecereNameSpace__ecere__com__Class * __ecereClass___ecereNameSpace__ecere__com__Property;
95 struct __ecereNameSpace__ecere__com__Property
97 struct __ecereNameSpace__ecere__com__Property * prev;
98 struct __ecereNameSpace__ecere__com__Property * next;
100 unsigned int isProperty;
103 struct __ecereNameSpace__ecere__com__Class * _class;
104 char * dataTypeString;
105 struct __ecereNameSpace__ecere__com__Class * dataTypeClass;
106 struct Type * dataType;
109 unsigned int (* IsSet)();
113 unsigned int conversion;
114 unsigned int watcherOffset;
116 unsigned int compiled;
117 unsigned int selfWatchable;
118 unsigned int isWatchable;
119 } __attribute__ ((gcc_struct));
121 extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_CodePosition;
128 unsigned int included;
129 } __attribute__ ((gcc_struct));
131 extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_Location;
135 struct CodePosition start;
136 struct CodePosition end;
137 } __attribute__ ((gcc_struct));
139 extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_Attrib;
145 struct __ecereNameSpace__ecere__sys__OldList * attribs;
146 } __attribute__ ((gcc_struct));
148 extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_ExtDecl;
157 struct Attrib * attr;
158 } __attribute__ ((gcc_struct));
159 } __attribute__ ((gcc_struct));
161 extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_ClassDefinition;
163 struct ClassDefinition
165 struct ClassDefinition * prev;
166 struct ClassDefinition * next;
168 struct Specifier * _class;
169 struct __ecereNameSpace__ecere__sys__OldList * baseSpecs;
170 struct __ecereNameSpace__ecere__sys__OldList * definitions;
171 struct Symbol * symbol;
172 struct Location blockStart;
173 struct Location nameLoc;
176 unsigned int deleteWatchable;
177 } __attribute__ ((gcc_struct));
179 extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_Context;
183 extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_Instantiation;
187 struct Instantiation * prev;
188 struct Instantiation * next;
190 struct Specifier * _class;
191 struct Expression * exp;
192 struct __ecereNameSpace__ecere__sys__OldList * members;
193 struct Symbol * symbol;
194 unsigned int fullSet;
195 unsigned int isConstant;
196 unsigned char * data;
197 struct Location nameLoc;
198 struct Location insideLoc;
200 } __attribute__ ((gcc_struct));
202 extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_Declaration;
206 struct Declaration * prev;
207 struct Declaration * next;
214 struct __ecereNameSpace__ecere__sys__OldList * specifiers;
215 struct __ecereNameSpace__ecere__sys__OldList * declarators;
216 } __attribute__ ((gcc_struct));
217 struct Instantiation * inst;
220 struct Identifier * id;
221 struct Expression * exp;
222 } __attribute__ ((gcc_struct));
223 } __attribute__ ((gcc_struct));
224 struct Specifier * extStorage;
225 struct Symbol * symbol;
227 } __attribute__ ((gcc_struct));
229 extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_Statement;
233 struct Statement * prev;
234 struct Statement * next;
239 struct __ecereNameSpace__ecere__sys__OldList * expressions;
242 struct Identifier * id;
243 struct Statement * stmt;
244 } __attribute__ ((gcc_struct)) labeled;
247 struct Expression * exp;
248 struct Statement * stmt;
249 } __attribute__ ((gcc_struct)) caseStmt;
252 struct __ecereNameSpace__ecere__sys__OldList * declarations;
253 struct __ecereNameSpace__ecere__sys__OldList * statements;
254 struct Context * context;
255 unsigned int isSwitch;
256 } __attribute__ ((gcc_struct)) compound;
259 struct __ecereNameSpace__ecere__sys__OldList * exp;
260 struct Statement * stmt;
261 struct Statement * elseStmt;
262 } __attribute__ ((gcc_struct)) ifStmt;
265 struct __ecereNameSpace__ecere__sys__OldList * exp;
266 struct Statement * stmt;
267 } __attribute__ ((gcc_struct)) switchStmt;
270 struct __ecereNameSpace__ecere__sys__OldList * exp;
271 struct Statement * stmt;
272 } __attribute__ ((gcc_struct)) whileStmt;
275 struct __ecereNameSpace__ecere__sys__OldList * exp;
276 struct Statement * stmt;
277 } __attribute__ ((gcc_struct)) doWhile;
280 struct Statement * init;
281 struct Statement * check;
282 struct __ecereNameSpace__ecere__sys__OldList * increment;
283 struct Statement * stmt;
284 } __attribute__ ((gcc_struct)) forStmt;
287 struct Identifier * id;
288 } __attribute__ ((gcc_struct)) gotoStmt;
291 struct Specifier * spec;
293 struct __ecereNameSpace__ecere__sys__OldList * inputFields;
294 struct __ecereNameSpace__ecere__sys__OldList * outputFields;
295 struct __ecereNameSpace__ecere__sys__OldList * clobberedFields;
296 } __attribute__ ((gcc_struct)) asmStmt;
299 struct Expression * watcher;
300 struct Expression * object;
301 struct __ecereNameSpace__ecere__sys__OldList * watches;
302 } __attribute__ ((gcc_struct)) _watch;
305 struct Identifier * id;
306 struct __ecereNameSpace__ecere__sys__OldList * exp;
307 struct __ecereNameSpace__ecere__sys__OldList * filter;
308 struct Statement * stmt;
309 } __attribute__ ((gcc_struct)) forEachStmt;
310 struct Declaration * decl;
311 } __attribute__ ((gcc_struct));
312 } __attribute__ ((gcc_struct));
314 extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_TypeName;
318 struct TypeName * prev;
319 struct TypeName * next;
321 struct __ecereNameSpace__ecere__sys__OldList * qualifiers;
322 struct Declarator * declarator;
324 struct Expression * bitCount;
325 } __attribute__ ((gcc_struct));
327 extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_Initializer;
331 struct Initializer * prev;
332 struct Initializer * next;
337 struct Expression * exp;
338 struct __ecereNameSpace__ecere__sys__OldList * list;
339 } __attribute__ ((gcc_struct));
340 unsigned int isConstant;
341 } __attribute__ ((gcc_struct));
343 extern struct __ecereNameSpace__ecere__com__Class * __ecereClass___ecereNameSpace__ecere__com__DataValue;
345 struct __ecereNameSpace__ecere__com__DataValue
360 } __attribute__ ((gcc_struct));
361 } __attribute__ ((gcc_struct));
363 extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_Expression;
367 struct Expression * prev;
368 struct Expression * next;
376 struct Identifier * identifier;
377 } __attribute__ ((gcc_struct));
378 struct Statement * compound;
379 struct Instantiation * instance;
381 struct __ecereNameSpace__ecere__sys__OldList * list;
384 struct __ecereNameSpace__ecere__sys__OldList * specifiers;
385 struct Declarator * decl;
386 } __attribute__ ((gcc_struct)) _classExp;
389 struct Identifier * id;
390 } __attribute__ ((gcc_struct)) classData;
393 struct Expression * exp;
394 struct __ecereNameSpace__ecere__sys__OldList * arguments;
395 struct Location argLoc;
396 } __attribute__ ((gcc_struct)) call;
399 struct Expression * exp;
400 struct __ecereNameSpace__ecere__sys__OldList * index;
401 } __attribute__ ((gcc_struct)) index;
404 struct Expression * exp;
405 struct Identifier * member;
407 unsigned int thisPtr;
408 } __attribute__ ((gcc_struct)) member;
412 struct Expression * exp1;
413 struct Expression * exp2;
414 } __attribute__ ((gcc_struct)) op;
415 struct TypeName * typeName;
416 struct Specifier * _class;
419 struct TypeName * typeName;
420 struct Expression * exp;
421 } __attribute__ ((gcc_struct)) cast;
424 struct Expression * cond;
425 struct __ecereNameSpace__ecere__sys__OldList * exp;
426 struct Expression * elseExp;
427 } __attribute__ ((gcc_struct)) cond;
430 struct TypeName * typeName;
431 struct Expression * size;
432 } __attribute__ ((gcc_struct)) _new;
435 struct TypeName * typeName;
436 struct Expression * size;
437 struct Expression * exp;
438 } __attribute__ ((gcc_struct)) _renew;
442 struct Identifier * id;
443 } __attribute__ ((gcc_struct)) db;
446 struct Expression * ds;
447 struct Expression * name;
448 } __attribute__ ((gcc_struct)) dbopen;
451 struct TypeName * typeName;
452 struct Initializer * initializer;
453 } __attribute__ ((gcc_struct)) initializer;
456 struct Expression * exp;
457 struct TypeName * typeName;
458 } __attribute__ ((gcc_struct)) vaArg;
459 } __attribute__ ((gcc_struct));
460 unsigned int debugValue;
461 struct __ecereNameSpace__ecere__com__DataValue val;
462 unsigned int address;
463 unsigned int hasAddress;
464 struct Type * expType;
465 struct Type * destType;
468 unsigned int byReference;
469 unsigned int isConstant;
470 unsigned int addedThis;
471 unsigned int needCast;
472 unsigned int thisPtr;
473 } __attribute__ ((gcc_struct));
475 extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_TemplateDatatype;
477 struct TemplateDatatype
479 struct __ecereNameSpace__ecere__sys__OldList * specifiers;
480 struct Declarator * decl;
481 } __attribute__ ((gcc_struct));
483 extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_TemplateArgument;
485 struct TemplateArgument;
487 extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_TemplateParameter;
489 struct TemplateParameter
491 struct TemplateParameter * prev;
492 struct TemplateParameter * next;
495 struct Identifier * identifier;
498 struct TemplateDatatype * dataType;
500 } __attribute__ ((gcc_struct));
501 struct TemplateArgument * defaultArgument;
502 char * dataTypeString;
503 struct Type * baseType;
504 } __attribute__ ((gcc_struct));
506 extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_Specifier;
510 struct Specifier * prev;
511 struct Specifier * next;
519 struct ExtDecl * extDecl;
521 struct Symbol * symbol;
522 struct __ecereNameSpace__ecere__sys__OldList * templateArgs;
523 } __attribute__ ((gcc_struct));
526 struct Identifier * id;
527 struct __ecereNameSpace__ecere__sys__OldList * list;
528 struct __ecereNameSpace__ecere__sys__OldList * baseSpecs;
529 struct __ecereNameSpace__ecere__sys__OldList * definitions;
530 unsigned int addNameSpace;
531 struct Context * ctx;
532 struct ExtDecl * extDeclStruct;
533 } __attribute__ ((gcc_struct));
534 struct Expression * expression;
535 struct Specifier * _class;
536 struct TemplateParameter * templateParameter;
537 } __attribute__ ((gcc_struct));
538 } __attribute__ ((gcc_struct));
540 extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_Identifier;
544 struct Identifier * prev;
545 struct Identifier * next;
547 struct Symbol * classSym;
548 struct Specifier * _class;
550 struct Identifier * badID;
551 } __attribute__ ((gcc_struct));
553 extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_Pointer;
557 struct Pointer * prev;
558 struct Pointer * next;
560 struct __ecereNameSpace__ecere__sys__OldList * qualifiers;
561 struct Pointer * pointer;
562 } __attribute__ ((gcc_struct));
564 extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_Declarator;
568 struct Declarator * prev;
569 struct Declarator * next;
572 struct Symbol * symbol;
573 struct Declarator * declarator;
576 struct Identifier * identifier;
579 struct Expression * exp;
580 struct Expression * posExp;
581 struct Attrib * attrib;
582 } __attribute__ ((gcc_struct)) structDecl;
585 struct Expression * exp;
586 struct Specifier * enumClass;
587 } __attribute__ ((gcc_struct)) array;
590 struct __ecereNameSpace__ecere__sys__OldList * parameters;
591 } __attribute__ ((gcc_struct)) function;
594 struct Pointer * pointer;
595 } __attribute__ ((gcc_struct)) pointer;
598 struct ExtDecl * extended;
599 } __attribute__ ((gcc_struct)) extended;
600 } __attribute__ ((gcc_struct));
601 } __attribute__ ((gcc_struct));
603 extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_FunctionDefinition;
605 struct FunctionDefinition
607 struct FunctionDefinition * prev;
608 struct FunctionDefinition * next;
610 struct __ecereNameSpace__ecere__sys__OldList * specifiers;
611 struct Declarator * declarator;
612 struct __ecereNameSpace__ecere__sys__OldList * declarations;
613 struct Statement * body;
614 struct __ecereNameSpace__ecere__com__Class * _class;
615 struct __ecereNameSpace__ecere__sys__OldList attached;
618 struct Symbol * propSet;
620 unsigned int propertyNoThis;
621 } __attribute__ ((gcc_struct));
623 extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_DBTableDef;
627 extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_External;
631 struct External * prev;
632 struct External * next;
635 struct Symbol * symbol;
638 struct FunctionDefinition * function;
639 struct ClassDefinition * _class;
640 struct Declaration * declaration;
642 struct Identifier * id;
643 struct DBTableDef * table;
644 } __attribute__ ((gcc_struct));
646 } __attribute__ ((gcc_struct));
648 extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_ModuleImport;
652 extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_ClassImport;
656 extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_Symbol;
661 struct Symbol * parent;
662 struct Symbol * left;
663 struct Symbol * right;
668 struct __ecereNameSpace__ecere__com__Method * method;
669 struct __ecereNameSpace__ecere__com__Property * _property;
670 struct __ecereNameSpace__ecere__com__Class * registered;
671 } __attribute__ ((gcc_struct));
678 struct External * pointerExternal;
679 struct External * structExternal;
680 } __attribute__ ((gcc_struct));
683 struct External * externalGet;
684 struct External * externalSet;
685 struct External * externalPtr;
686 struct External * externalIsSet;
687 } __attribute__ ((gcc_struct));
690 struct External * methodExternal;
691 struct External * methodCodeExternal;
692 } __attribute__ ((gcc_struct));
693 } __attribute__ ((gcc_struct));
694 unsigned int imported;
695 unsigned int declaredStructSym;
696 struct __ecereNameSpace__ecere__com__Class * _class;
697 unsigned int declaredStruct;
698 unsigned int needConstructor;
699 unsigned int needDestructor;
700 char * constructorName;
703 char * destructorName;
704 struct ModuleImport * module;
705 struct ClassImport * _import;
706 struct Location nameLoc;
707 unsigned int isParam;
708 unsigned int isRemote;
709 unsigned int isStruct;
710 unsigned int fireWatchersDone;
712 unsigned int classData;
713 unsigned int isStatic;
715 struct __ecereNameSpace__ecere__sys__OldList * templateParams;
716 struct __ecereNameSpace__ecere__sys__OldList templatedClasses;
717 struct Context * ctx;
719 struct Expression * propCategory;
720 } __attribute__ ((gcc_struct));
722 extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_Type;
731 struct Symbol * _class;
734 struct __ecereNameSpace__ecere__sys__OldList members;
736 } __attribute__ ((gcc_struct));
739 struct Type * returnType;
740 struct __ecereNameSpace__ecere__sys__OldList params;
741 struct Symbol * thisClass;
742 unsigned int staticMethod;
743 struct TemplateParameter * thisClassTemplate;
744 } __attribute__ ((gcc_struct));
747 struct __ecereNameSpace__ecere__com__Method * method;
748 struct __ecereNameSpace__ecere__com__Class * methodClass;
749 struct __ecereNameSpace__ecere__com__Class * usedClass;
750 } __attribute__ ((gcc_struct));
753 struct Type * arrayType;
755 struct Expression * arraySizeExp;
756 unsigned int freeExp;
757 struct Symbol * enumClass;
758 } __attribute__ ((gcc_struct));
760 struct TemplateParameter * templateParameter;
761 } __attribute__ ((gcc_struct));
762 unsigned int isSigned;
764 unsigned int constant;
771 unsigned int byReference;
772 unsigned int extraParam;
774 unsigned int directClassAccess;
775 unsigned int computing;
776 unsigned int dllExport;
778 unsigned int keepCast;
779 unsigned int passAsTemplate;
781 } __attribute__ ((gcc_struct));
783 extern struct __ecereNameSpace__ecere__com__Class * __ecereClass___ecereNameSpace__ecere__com__Class;
785 struct __ecereNameSpace__ecere__com__Class
787 struct __ecereNameSpace__ecere__com__Class * prev;
788 struct __ecereNameSpace__ecere__com__Class * next;
794 int (* Constructor)(struct __ecereNameSpace__ecere__com__Instance *);
795 void (* Destructor)(struct __ecereNameSpace__ecere__com__Instance *);
798 struct __ecereNameSpace__ecere__com__Class * base;
799 struct __ecereNameSpace__ecere__sys__BinaryTree methods;
800 struct __ecereNameSpace__ecere__sys__BinaryTree members;
801 struct __ecereNameSpace__ecere__sys__BinaryTree prop;
802 struct __ecereNameSpace__ecere__sys__OldList membersAndProperties;
803 struct __ecereNameSpace__ecere__sys__BinaryTree classProperties;
804 struct __ecereNameSpace__ecere__sys__OldList derivatives;
808 struct __ecereNameSpace__ecere__com__Instance * module;
809 struct __ecereNameSpace__ecere__com__NameSpace * nameSpace;
810 char * dataTypeString;
811 struct Type * dataType;
813 int defaultAlignment;
814 void (* Initialize)();
816 struct __ecereNameSpace__ecere__sys__OldList selfWatchers;
817 char * designerClass;
818 unsigned int noExpansion;
819 char * defaultProperty;
820 unsigned int comRedefinition;
822 unsigned int isRemote;
823 unsigned int internalDecl;
825 unsigned int computeSize;
827 int destructionWatchOffset;
829 struct __ecereNameSpace__ecere__sys__OldList delayedCPValues;
830 int inheritanceAccess;
833 struct __ecereNameSpace__ecere__sys__OldList conversions;
834 struct __ecereNameSpace__ecere__sys__OldList templateParams;
835 struct __ecereNameSpace__ecere__com__ClassTemplateArgument * templateArgs;
836 struct __ecereNameSpace__ecere__com__Class * templateClass;
837 struct __ecereNameSpace__ecere__sys__OldList templatized;
839 } __attribute__ ((gcc_struct));
841 extern struct __ecereNameSpace__ecere__com__Class * __ecereClass___ecereNameSpace__ecere__com__Instance;
843 struct __ecereNameSpace__ecere__com__Instance
846 struct __ecereNameSpace__ecere__com__Class * _class;
848 } __attribute__ ((gcc_struct));
850 extern struct __ecereNameSpace__ecere__com__Class * __ecereClass___ecereNameSpace__ecere__com__DataMember;
852 struct __ecereNameSpace__ecere__com__DataMember
854 struct __ecereNameSpace__ecere__com__DataMember * prev;
855 struct __ecereNameSpace__ecere__com__DataMember * next;
857 unsigned int isProperty;
860 struct __ecereNameSpace__ecere__com__Class * _class;
861 char * dataTypeString;
862 struct __ecereNameSpace__ecere__com__Class * dataTypeClass;
863 struct Type * dataType;
867 struct __ecereNameSpace__ecere__sys__OldList members;
868 struct __ecereNameSpace__ecere__sys__BinaryTree membersAlpha;
871 } __attribute__ ((gcc_struct));
873 extern struct __ecereNameSpace__ecere__com__Class * __ecereClass___ecereNameSpace__ecere__com__SerialBuffer;
875 struct __ecereNameSpace__ecere__com__SerialBuffer
877 unsigned char * _buffer;
881 } __attribute__ ((gcc_struct));
883 extern struct __ecereNameSpace__ecere__com__Class * __ecereClass___ecereNameSpace__ecere__com__ClassTemplateArgument;
885 struct __ecereNameSpace__ecere__com__ClassTemplateArgument
891 char * dataTypeString;
892 struct __ecereNameSpace__ecere__com__Class * dataTypeClass;
893 } __attribute__ ((gcc_struct));
894 struct __ecereNameSpace__ecere__com__DataValue expression;
900 struct __ecereNameSpace__ecere__com__DataMember * member;
901 struct __ecereNameSpace__ecere__com__Property * prop;
902 struct __ecereNameSpace__ecere__com__Method * method;
903 } __attribute__ ((gcc_struct));
904 } __attribute__ ((gcc_struct));
905 } __attribute__ ((gcc_struct));
906 } __attribute__ ((gcc_struct));
910 IDENTIFIER = 258, CONSTANT = 259, STRING_LITERAL = 260, SIZEOF = 261, PTR_OP = 262, INC_OP = 263, DEC_OP = 264, LEFT_OP = 265, RIGHT_OP = 266, LE_OP = 267, GE_OP = 268, EQ_OP = 269, NE_OP = 270, AND_OP = 271, OR_OP = 272, MUL_ASSIGN = 273, DIV_ASSIGN = 274, MOD_ASSIGN = 275, ADD_ASSIGN = 276, SUB_ASSIGN = 277, LEFT_ASSIGN = 278, RIGHT_ASSIGN = 279, AND_ASSIGN = 280, XOR_ASSIGN = 281, OR_ASSIGN = 282, TYPE_NAME = 283, TYPEDEF = 284, EXTERN = 285, STATIC = 286, AUTO = 287, REGISTER = 288, CHAR = 289, SHORT = 290, INT = 291, UINT = 292, INT64 = 293, LONG = 294, SIGNED = 295, UNSIGNED = 296, FLOAT = 297, DOUBLE = 298, CONST = 299, VOLATILE = 300, VOID = 301, VALIST = 302, STRUCT = 303, UNION = 304, ENUM = 305, ELLIPSIS = 306, CASE = 307, DEFAULT = 308, IF = 309, SWITCH = 310, WHILE = 311, DO = 312, FOR = 313, GOTO = 314, CONTINUE = 315, BREAK = 316, RETURN = 317, IFX = 318, ELSE = 319, CLASS = 320, THISCLASS = 321, CLASS_NAME = 322, PROPERTY = 323, SETPROP = 324, GETPROP = 325, NEWOP = 326, RENEW = 327, DELETE = 328, EXT_DECL = 329, EXT_STORAGE = 330, IMPORT = 331, DEFINE = 332, VIRTUAL = 333, ATTRIB = 334, PUBLIC = 335, PRIVATE = 336, TYPED_OBJECT = 337, ANY_OBJECT = 338, _INCREF = 339, EXTENSION = 340, ASM = 341, TYPEOF = 342, WATCH = 343, STOPWATCHING = 344, FIREWATCHERS = 345, WATCHABLE = 346, CLASS_DESIGNER = 347, CLASS_NO_EXPANSION = 348, CLASS_FIXED = 349, ISPROPSET = 350, CLASS_DEFAULT_PROPERTY = 351, PROPERTY_CATEGORY = 352, CLASS_DATA = 353, CLASS_PROPERTY = 354, SUBCLASS = 355, NAMESPACE = 356, NEW0OP = 357, RENEW0 = 358, VAARG = 359, DBTABLE = 360, DBFIELD = 361, DBINDEX = 362, DATABASE_OPEN = 363, ALIGNOF = 364, ATTRIB_DEP = 365, __ATTRIB = 366
913 typedef union YYSTYPE
918 struct Identifier * id;
919 struct Expression * exp;
920 struct Specifier * specifier;
921 struct __ecereNameSpace__ecere__sys__OldList * list;
922 struct Enumerator * enumerator;
923 struct Declarator * declarator;
924 struct Pointer * pointer;
925 struct Initializer * initializer;
926 struct InitDeclarator * initDeclarator;
927 struct TypeName * typeName;
928 struct Declaration * declaration;
929 struct Statement * stmt;
930 struct FunctionDefinition * function;
931 struct External * external;
932 struct Context * context;
933 struct AsmField * asmField;
934 struct Attrib * attrib;
935 struct ExtDecl * extDecl;
936 struct Attribute * attribute;
937 struct Instantiation * instance;
938 struct MembersInit * membersInit;
939 struct MemberInit * memberInit;
940 struct ClassFunction * classFunction;
941 struct ClassDefinition * _class;
942 struct ClassDef * classDef;
943 struct PropertyDef * prop;
945 struct Symbol * symbol;
946 struct PropertyWatch * propertyWatch;
947 struct TemplateParameter * templateParameter;
948 struct TemplateArgument * templateArgument;
949 struct TemplateDatatype * templateDatatype;
950 struct DBTableEntry * dbtableEntry;
951 struct DBIndexItem * dbindexItem;
952 struct DBTableDef * dbtableDef;
953 } __attribute__ ((gcc_struct)) YYSTYPE;
955 extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_Enumerator;
959 struct Enumerator * prev;
960 struct Enumerator * next;
962 struct Identifier * id;
963 struct Expression * exp;
964 } __attribute__ ((gcc_struct));
966 extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_InitDeclarator;
968 struct InitDeclarator
970 struct InitDeclarator * prev;
971 struct InitDeclarator * next;
973 struct Declarator * declarator;
974 struct Initializer * initializer;
975 } __attribute__ ((gcc_struct));
977 extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_AsmField;
981 struct AsmField * prev;
982 struct AsmField * next;
985 struct Expression * expression;
986 } __attribute__ ((gcc_struct));
988 extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_Attribute;
992 struct Attribute * prev;
993 struct Attribute * next;
996 struct Expression * exp;
997 } __attribute__ ((gcc_struct));
999 extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_ClassFunction;
1001 struct ClassFunction
1003 struct ClassFunction * prev;
1004 struct ClassFunction * next;
1005 struct Location loc;
1006 struct __ecereNameSpace__ecere__sys__OldList * specifiers;
1007 struct Declarator * declarator;
1008 struct __ecereNameSpace__ecere__sys__OldList * declarations;
1009 struct Statement * body;
1010 struct __ecereNameSpace__ecere__com__Class * _class;
1011 struct __ecereNameSpace__ecere__sys__OldList attached;
1014 struct Symbol * propSet;
1015 unsigned int isVirtual;
1016 unsigned int isConstructor;
1017 unsigned int isDestructor;
1018 unsigned int dontMangle;
1021 } __attribute__ ((gcc_struct));
1023 extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_MembersInit;
1027 struct MembersInit * prev;
1028 struct MembersInit * next;
1029 struct Location loc;
1033 struct __ecereNameSpace__ecere__sys__OldList * dataMembers;
1034 struct ClassFunction * function;
1035 } __attribute__ ((gcc_struct));
1036 } __attribute__ ((gcc_struct));
1038 extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_MemberInit;
1042 struct MemberInit * prev;
1043 struct MemberInit * next;
1044 struct Location loc;
1045 struct Location realLoc;
1046 struct __ecereNameSpace__ecere__sys__OldList * identifiers;
1047 struct Initializer * initializer;
1049 unsigned int variable;
1050 unsigned int takeOutExp;
1051 } __attribute__ ((gcc_struct));
1053 extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_PropertyDef;
1057 extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_PropertyWatch;
1059 struct PropertyWatch;
1061 extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_ClassDef;
1065 struct ClassDef * prev;
1066 struct ClassDef * next;
1067 struct Location loc;
1071 struct Declaration * decl;
1072 struct ClassFunction * function;
1073 struct __ecereNameSpace__ecere__sys__OldList * defProperties;
1074 struct PropertyDef * propertyDef;
1075 struct PropertyWatch * propertyWatch;
1077 struct Identifier * defaultProperty;
1080 struct Identifier * id;
1081 struct Initializer * initializer;
1082 } __attribute__ ((gcc_struct));
1083 } __attribute__ ((gcc_struct));
1086 } __attribute__ ((gcc_struct));
1088 extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_DBTableEntry;
1090 struct DBTableEntry;
1092 extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_DBIndexItem;
1096 extern YYSTYPE yylval;
1098 extern struct Location yylloc;
1102 unsigned int memoryGuard = 0x0;
1104 void SetMemoryGuard(unsigned int b)
1109 unsigned int GetMemoryGuard()
1114 extern int strcmp(const char * , const char * );
1116 int __ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts;
1118 static void OutputIdentifier(struct Identifier * id, struct __ecereNameSpace__ecere__com__Instance * f)
1124 if(id->_class->type == 8)
1126 if(id->_class->templateParameter && id->_class->templateParameter->identifier && id->_class->templateParameter->identifier->string)
1127 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, id->_class->templateParameter->identifier->string);
1131 if(id->_class->name)
1133 if(!strcmp(id->_class->name, "class"))
1134 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "typed_object");
1136 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, id->_class->name);
1139 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "::");
1142 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, (id && id->string) ? id->string : "(null identifier)");
1145 int __ecereVMethodID___ecereNameSpace__ecere__sys__File_Putc;
1147 static void OutputOperator(int op, struct __ecereNameSpace__ecere__com__Instance * f)
1152 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "++");
1155 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "--");
1158 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "sizeof ");
1161 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "<<");
1164 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, ">>");
1167 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "<=");
1170 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, ">=");
1173 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "==");
1176 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "!=");
1179 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "&&");
1182 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "||");
1185 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "*=");
1188 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "/=");
1191 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "%=");
1194 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "+=");
1197 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "-=");
1200 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "<<=");
1203 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, ">>=");
1206 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "&=");
1209 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "^=");
1212 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "|=");
1227 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, char ch))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Putc])(f, (char)op);
1230 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "delete ");
1235 static void OutputSpecifier(struct Specifier * spec, struct __ecereNameSpace__ecere__com__Instance * f);
1237 static void OutputDeclarator(struct Declarator * decl, struct __ecereNameSpace__ecere__com__Instance * f);
1239 void OutputTypeName(struct TypeName * type, struct __ecereNameSpace__ecere__com__Instance * f)
1241 if(type->qualifiers)
1243 struct Specifier * spec;
1245 for(spec = (*type->qualifiers).first; spec; spec = spec->next)
1247 OutputSpecifier(spec, f);
1249 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, " ");
1252 if(type->declarator)
1254 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, " ");
1255 OutputDeclarator(type->declarator, f);
1257 if(!type->qualifiers && !type->declarator)
1258 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "...");
1261 static void OutputStatement(struct Statement * stmt, struct __ecereNameSpace__ecere__com__Instance * f);
1263 static void OutputInstance(struct Instantiation * inst, struct __ecereNameSpace__ecere__com__Instance * f);
1265 extern int printf(char * , ...);
1267 static void OutputInitializer(struct Initializer * initializer, struct __ecereNameSpace__ecere__com__Instance * f);
1269 void OutputExpression(struct Expression * exp, struct __ecereNameSpace__ecere__com__Instance * f)
1274 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "class(");
1275 if(exp->_classExp.specifiers)
1277 struct Specifier * spec;
1279 for(spec = (*exp->_classExp.specifiers).first; spec; spec = spec->next)
1281 OutputSpecifier(spec, f);
1283 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, " ");
1285 if(exp->_classExp.decl)
1287 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, " ");
1288 OutputDeclarator(exp->_classExp.decl, f);
1290 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, ")");
1294 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "__extension__ (");
1295 OutputStatement(exp->compound, f);
1296 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, ")");
1299 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "new ");
1300 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, " ");
1301 OutputTypeName(exp->_renew.typeName, f);
1302 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "[");
1303 OutputExpression(exp->_renew.size, f);
1304 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "]");
1307 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "new0 ");
1308 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, " ");
1309 OutputTypeName(exp->_renew.typeName, f);
1310 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "[");
1311 OutputExpression(exp->_renew.size, f);
1312 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "]");
1315 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "renew ");
1316 OutputExpression(exp->_renew.exp, f);
1317 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, " ");
1318 OutputTypeName(exp->_renew.typeName, f);
1319 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "[");
1320 OutputExpression(exp->_renew.size, f);
1321 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "]");
1324 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "renew0 ");
1325 OutputExpression(exp->_renew.exp, f);
1326 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, " ");
1327 OutputTypeName(exp->_renew.typeName, f);
1328 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "[");
1329 OutputExpression(exp->_renew.size, f);
1330 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "]");
1334 OutputIdentifier(exp->identifier, f);
1338 OutputInstance(exp->instance, f);
1342 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, exp->constant);
1348 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, exp->string);
1353 OutputExpression(exp->op.exp1, f);
1355 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, " ");
1357 OutputOperator(exp->op.op, f);
1360 if(exp->op.exp1 || (exp->op.exp2->type == 4 && !exp->op.exp2->op.exp1 && exp->op.exp2->op.op == exp->op.op))
1361 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, " ");
1362 OutputExpression(exp->op.exp2, f);
1368 struct Expression * expression;
1371 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "__extension__ (");
1372 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "(");
1375 for(expression = (*exp->list).first; expression; expression = expression->next)
1377 OutputExpression(expression, f);
1378 if(expression->next)
1379 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, ", ");
1382 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, ")");
1387 struct Expression * expression;
1390 OutputExpression(exp->index.exp, f);
1391 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "[");
1392 if(exp->index.index)
1393 for(expression = (*exp->index.index).first; expression; expression = expression->next)
1395 OutputExpression(expression, f);
1396 if(expression->next)
1397 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, ", ");
1399 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "]");
1404 OutputExpression(exp->call.exp, f);
1405 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "(");
1406 if(exp->call.arguments)
1408 struct Expression * expression;
1410 for(expression = (*exp->call.arguments).first; expression; expression = expression->next)
1412 OutputExpression(expression, f);
1413 if(expression->next)
1414 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, ", ");
1417 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, ")");
1422 OutputExpression(exp->member.exp, f);
1423 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, ".");
1424 if(exp->member.member)
1425 OutputIdentifier(exp->member.member, f);
1428 OutputExpression(exp->member.exp, f);
1429 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "->");
1430 OutputIdentifier(exp->member.member, f);
1433 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "sizeof(");
1434 OutputTypeName(exp->typeName, f);
1435 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, ")");
1438 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "__alignof__(");
1439 OutputTypeName(exp->typeName, f);
1440 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, ")");
1443 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "__extension__ (");
1444 if(exp->initializer.typeName)
1445 OutputTypeName(exp->initializer.typeName, f);
1446 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, ")");
1447 if(exp->initializer.initializer)
1448 OutputInitializer(exp->initializer.initializer, f);
1451 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "(");
1452 OutputTypeName(exp->cast.typeName, f);
1453 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, ")");
1455 OutputExpression(exp->cast.exp, f);
1458 OutputExpression(exp->cond.cond, f);
1459 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, " ? ");
1461 struct Expression * expression;
1463 for(expression = (*exp->cond.exp).first; expression; expression = expression->next)
1465 OutputExpression(expression, f);
1466 if(expression->next)
1467 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, ", ");
1470 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, " : ");
1471 OutputExpression(exp->cond.elseExp, f);
1474 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "__builtin_va_arg(");
1475 OutputExpression(exp->vaArg.exp, f);
1476 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, ", ");
1477 OutputTypeName(exp->vaArg.typeName, f);
1478 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, ")");
1481 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "[");
1484 struct Expression * expression;
1486 for(expression = (*exp->list).first; expression; expression = expression->next)
1488 OutputExpression(expression, f);
1489 if(expression->next)
1490 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, ", ");
1493 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "]");
1498 static void OutputAsmField(struct AsmField * field, struct __ecereNameSpace__ecere__com__Instance * f)
1500 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, field->command);
1501 if(field->expression)
1503 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "(");
1504 OutputExpression(field->expression, f);
1505 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, ")");
1509 extern unsigned int inCompiler;
1511 extern char * __ecereNameSpace__ecere__sys__PathCat(char * string, char * addedPath);
1513 extern char * GetIncludeFileFromID(int id);
1515 extern char * sourceFile;
1517 extern void __ecereNameSpace__ecere__sys__ChangeCh(char * string, char ch1, char ch2);
1519 extern char * outputFile;
1521 extern unsigned int outputLineNumbers;
1523 static void OutputDeclaration(struct Declaration * decl, struct __ecereNameSpace__ecere__com__Instance * f);
1525 extern struct __ecereNameSpace__ecere__sys__OldList * MkList(void);
1527 extern struct Declarator * SpecDeclFromString(char * string, struct __ecereNameSpace__ecere__sys__OldList * specs, struct Declarator * baseDecl);
1529 extern struct Declarator * MkDeclaratorIdentifier(struct Identifier * id);
1531 extern struct Identifier * MkIdentifier(char * string);
1533 extern struct __ecereNameSpace__ecere__sys__OldList * CopyList(struct __ecereNameSpace__ecere__sys__OldList * source, void * (* )(void * ));
1535 extern struct Specifier * CopySpecifier(struct Specifier * spec);
1537 extern struct Declarator * PlugDeclarator(struct Declarator * decl, struct Declarator * baseDecl);
1539 extern void ListAdd(struct __ecereNameSpace__ecere__sys__OldList * list, void * item);
1541 extern struct Specifier * MkSpecifierName(char * name);
1543 extern void PrintType(struct Type * type, char * string, unsigned int printName, unsigned int fullName);
1545 extern struct TypeName * MkTypeName(struct __ecereNameSpace__ecere__sys__OldList * qualifiers, struct Declarator * declarator);
1547 extern void InstDeclPassTypeName(struct TypeName * type, unsigned int param);
1549 extern void FreeTypeName(struct TypeName * typeName);
1551 int __ecereMethod___ecereNameSpace__ecere__sys__File_Printf(struct __ecereNameSpace__ecere__com__Instance * this, char * format, ...);
1553 static void OutputStatement(struct Statement * stmt, struct __ecereNameSpace__ecere__com__Instance * f)
1555 char name[274] = "";
1556 char origName[274] = "";
1560 if(yylloc.start.included)
1562 __ecereNameSpace__ecere__sys__PathCat(name, GetIncludeFileFromID((unsigned int)yylloc.start.included));
1566 __ecereNameSpace__ecere__sys__PathCat(name, sourceFile);
1568 __ecereNameSpace__ecere__sys__ChangeCh(name, '\\', '/');
1569 __ecereNameSpace__ecere__sys__PathCat(origName, outputFile);
1570 __ecereNameSpace__ecere__sys__ChangeCh(origName, '\\', '/');
1572 if(inCompiler && outputLineNumbers && stmt->loc.start.line)
1574 __ecereMethod___ecereNameSpace__ecere__sys__File_Printf(f, "\n#line %d \"%s\"\n", stmt->loc.start.line, name);
1580 OutputIdentifier(stmt->labeled.id, f);
1581 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, ":\n");
1583 OutputStatement(stmt->labeled.stmt, f);
1586 if(stmt->caseStmt.exp)
1588 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "case ");
1589 OutputExpression(stmt->caseStmt.exp, f);
1590 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, ":\n");
1595 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "default:\n");
1598 if(stmt->caseStmt.stmt)
1599 OutputStatement(stmt->caseStmt.stmt, f);
1603 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "{\n");
1605 if(stmt->compound.declarations)
1607 struct Declaration * decl;
1609 for(decl = (*stmt->compound.declarations).first; decl; decl = decl->next)
1611 OutputDeclaration(decl, f);
1614 if(stmt->compound.statements)
1616 struct Statement * statement;
1618 if(stmt->compound.declarations)
1620 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "\n");
1623 for(statement = (*stmt->compound.statements).first; statement; statement = statement->next)
1625 OutputStatement(statement, f);
1626 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "\n");
1630 if(inCompiler && outputLineNumbers && stmt->loc.end.line)
1632 __ecereMethod___ecereNameSpace__ecere__sys__File_Printf(f, "\n#line %d \"%s\"\n", stmt->loc.end.line, name);
1635 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "}");
1640 if(stmt->expressions)
1642 struct Expression * exp;
1644 for(exp = (*stmt->expressions).first; exp; exp = exp->next)
1646 OutputExpression(exp, f);
1648 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, ", ");
1651 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, ";");
1656 struct Expression * exp;
1658 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "if(");
1659 for(exp = (*stmt->ifStmt.exp).first; exp; exp = exp->next)
1661 OutputExpression(exp, f);
1663 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, ", ");
1665 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, ")\n");
1667 if(stmt->ifStmt.stmt)
1668 OutputStatement(stmt->ifStmt.stmt, f);
1669 if(stmt->ifStmt.elseStmt)
1671 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "\n");
1673 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "else");
1674 if(stmt->ifStmt.elseStmt->type != 4)
1676 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "\n");
1680 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, " ");
1681 OutputStatement(stmt->ifStmt.elseStmt, f);
1687 struct Expression * exp;
1689 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "switch(");
1690 for(exp = (*stmt->switchStmt.exp).first; exp; exp = exp->next)
1692 OutputExpression(exp, f);
1694 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, ", ");
1696 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, ")\n");
1698 OutputStatement(stmt->switchStmt.stmt, f);
1703 struct Expression * exp;
1705 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "while(");
1706 for(exp = (*stmt->switchStmt.exp).first; exp; exp = exp->next)
1708 OutputExpression(exp, f);
1710 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, ", ");
1712 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, ")\n");
1714 OutputStatement(stmt->whileStmt.stmt, f);
1719 struct Expression * exp;
1721 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "do\n");
1723 OutputStatement(stmt->whileStmt.stmt, f);
1724 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "while(");
1725 for(exp = (*stmt->switchStmt.exp).first; exp; exp = exp->next)
1727 OutputExpression(exp, f);
1729 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, ", ");
1731 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, ");");
1736 struct Expression * exp;
1738 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "for(");
1739 OutputStatement(stmt->forStmt.init, f);
1740 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, " ");
1741 OutputStatement(stmt->forStmt.check, f);
1742 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, " ");
1743 if(stmt->forStmt.increment)
1745 if(inCompiler && outputLineNumbers && stmt->loc.end.line)
1747 __ecereMethod___ecereNameSpace__ecere__sys__File_Printf(f, "\n#line %d \"%s\"\n", stmt->loc.end.line, name);
1750 for(exp = (*stmt->forStmt.increment).first; exp; exp = exp->next)
1752 OutputExpression(exp, f);
1754 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, ", ");
1757 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, ")\n");
1759 OutputStatement(stmt->forStmt.stmt, f);
1764 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "goto ");
1765 OutputIdentifier(stmt->gotoStmt.id, f);
1766 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, ";");
1770 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "continue;");
1773 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "break;");
1777 struct Expression * exp;
1779 if(inCompiler && memoryGuard)
1781 struct Expression * exp = stmt->expressions ? (*stmt->expressions).last : (((void *)0));
1783 __ecereMethod___ecereNameSpace__ecere__sys__File_Printf(f, "{ ");
1784 if(exp && exp->expType)
1786 char string[1024] = "";
1787 struct __ecereNameSpace__ecere__sys__OldList * specs = MkList();
1788 struct Declarator * decl;
1789 struct TypeName * typeName;
1791 if(exp->expType->kind == 20)
1793 if(exp->expType->templateParameter->dataTypeString)
1794 decl = SpecDeclFromString(exp->expType->templateParameter->dataTypeString, specs, MkDeclaratorIdentifier(MkIdentifier("__ecereReturnVal")));
1795 else if(exp->expType->templateParameter->dataType)
1797 (__ecereNameSpace__ecere__com__eSystem_Delete(specs), specs = 0);
1798 specs = CopyList(exp->expType->templateParameter->dataType->specifiers, CopySpecifier);
1799 decl = PlugDeclarator(exp->expType->templateParameter->dataType->decl, MkDeclaratorIdentifier(MkIdentifier("__ecereReturnVal")));
1803 ListAdd(specs, MkSpecifierName("uint64"));
1804 decl = MkDeclaratorIdentifier(MkIdentifier("__ecereReturnVal"));
1809 PrintType(exp->expType, string, 0x1, 0x1);
1810 decl = SpecDeclFromString(string, specs, MkDeclaratorIdentifier(MkIdentifier("__ecereReturnVal")));
1812 typeName = MkTypeName(specs, decl);
1813 InstDeclPassTypeName(typeName, 0x0);
1814 OutputTypeName(typeName, f);
1815 __ecereMethod___ecereNameSpace__ecere__sys__File_Printf(f, ";");
1816 FreeTypeName(typeName);
1820 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "return ");
1823 struct Expression * exp = stmt->expressions ? (*stmt->expressions).last : (((void *)0));
1825 if(exp && exp->expType)
1826 __ecereMethod___ecereNameSpace__ecere__sys__File_Printf(f, "__ecereReturnVal = ");
1828 if(stmt->expressions)
1830 for(exp = (*stmt->expressions).first; exp; exp = exp->next)
1832 OutputExpression(exp, f);
1834 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, ", ");
1837 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, ";");
1838 if(inCompiler && memoryGuard)
1840 struct Expression * exp = stmt->expressions ? (struct Expression *)(*stmt->expressions).last : (((void *)0));
1842 __ecereMethod___ecereNameSpace__ecere__sys__File_Printf(f, " __ecereNameSpace__ecere__com__MemoryGuard_PopLoc();");
1843 if(exp && exp->expType)
1844 __ecereMethod___ecereNameSpace__ecere__sys__File_Printf(f, "return __ecereReturnVal;");
1846 __ecereMethod___ecereNameSpace__ecere__sys__File_Printf(f, "return;");
1847 __ecereMethod___ecereNameSpace__ecere__sys__File_Printf(f, "}");
1853 struct AsmField * field;
1855 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "__asm__ ");
1856 if(stmt->asmStmt.spec)
1857 OutputSpecifier(stmt->asmStmt.spec, f);
1858 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "(");
1859 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, stmt->asmStmt.statements);
1860 if(stmt->asmStmt.inputFields || stmt->asmStmt.outputFields || stmt->asmStmt.clobberedFields)
1862 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, ":");
1863 if(stmt->asmStmt.inputFields)
1865 for(field = (*stmt->asmStmt.inputFields).first; field; field = field->next)
1868 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, ",");
1869 OutputAsmField(field, f);
1873 if(stmt->asmStmt.outputFields || stmt->asmStmt.clobberedFields)
1875 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, ":");
1876 if(stmt->asmStmt.outputFields)
1878 for(field = (*stmt->asmStmt.outputFields).first; field; field = field->next)
1881 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, ",");
1882 OutputAsmField(field, f);
1886 if(stmt->asmStmt.clobberedFields)
1888 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, ":");
1889 for(field = (*stmt->asmStmt.clobberedFields).first; field; field = field->next)
1892 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, ",");
1893 OutputAsmField(field, f);
1896 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, ");\n");
1900 if(inCompiler && outputLineNumbers && stmt->loc.start.line)
1902 __ecereMethod___ecereNameSpace__ecere__sys__File_Printf(f, "\n#line %d \"%s\"\n", outputLine + 2, origName);
1907 static void OutputPointer(struct Pointer * ptr, struct __ecereNameSpace__ecere__com__Instance * f)
1909 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "*");
1912 struct Specifier * spec;
1914 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, " ");
1915 for(spec = (*ptr->qualifiers).first; spec; spec = spec->next)
1917 OutputSpecifier(spec, f);
1919 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, " ");
1924 OutputPointer(ptr->pointer, f);
1928 static void OutputAttrib(struct Attrib * attr, struct __ecereNameSpace__ecere__com__Instance * f);
1930 static void OutputExtDecl(struct ExtDecl * extDecl, struct __ecereNameSpace__ecere__com__Instance * f);
1932 extern void ProcessExpressionType(struct Expression * exp);
1934 extern void ComputeExpression(struct Expression * exp);
1936 extern int __ecereNameSpace__ecere__com__eClass_GetProperty(struct __ecereNameSpace__ecere__com__Class * _class, char * name);
1938 static void OutputDeclarator(struct Declarator * decl, struct __ecereNameSpace__ecere__com__Instance * f)
1943 if(decl->declarator)
1945 OutputDeclarator(decl->declarator, f);
1947 if(decl->structDecl.exp)
1949 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, " : ");
1950 OutputExpression(decl->structDecl.exp, f);
1952 if(decl->structDecl.posExp)
1954 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, " : ");
1955 OutputExpression(decl->structDecl.posExp, f);
1957 if(decl->structDecl.attrib)
1959 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, " ");
1960 OutputAttrib(decl->structDecl.attrib, f);
1964 OutputIdentifier(decl->identifier, f);
1967 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "(");
1968 OutputDeclarator(decl->declarator, f);
1969 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, ")");
1972 if(decl->extended.extended)
1973 OutputExtDecl(decl->extended.extended, f);
1974 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, " ");
1975 OutputDeclarator(decl->declarator, f);
1978 OutputDeclarator(decl->declarator, f);
1979 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, " ");
1980 if(decl->extended.extended)
1981 OutputExtDecl(decl->extended.extended, f);
1984 if(decl->declarator)
1986 OutputDeclarator(decl->declarator, f);
1988 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "[");
1991 ProcessExpressionType(decl->array.exp);
1992 ComputeExpression(decl->array.exp);
1993 OutputExpression(decl->array.exp, f);
1995 else if(decl->array.enumClass)
1997 struct Symbol * _class = decl->array.enumClass->symbol;
1999 if(_class && _class->registered)
2001 __ecereMethod___ecereNameSpace__ecere__sys__File_Printf(f, "%d", __ecereNameSpace__ecere__com__eClass_GetProperty(_class->registered, "enumSize"));
2004 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "]");
2008 struct TypeName * param;
2010 if(decl->declarator)
2011 OutputDeclarator(decl->declarator, f);
2012 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "(");
2013 if(decl->function.parameters && (*decl->function.parameters).first)
2015 for(param = (*decl->function.parameters).first; param; param = param->next)
2017 OutputTypeName(param, f);
2019 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, ", ");
2022 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, ")");
2026 if(decl->pointer.pointer)
2027 OutputPointer(decl->pointer.pointer, f);
2028 if(decl->declarator)
2030 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, " ");
2031 OutputDeclarator(decl->declarator, f);
2037 static void OutputEnumerator(struct Enumerator * enumerator, struct __ecereNameSpace__ecere__com__Instance * f)
2039 OutputIdentifier(enumerator->id, f);
2042 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, " = ");
2043 OutputExpression(enumerator->exp, f);
2047 static void OutputAttribute(struct Attribute * attr, struct __ecereNameSpace__ecere__com__Instance * f)
2050 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, attr->attr);
2053 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, " ");
2054 OutputExpression(attr->exp, f);
2058 static void OutputAttrib(struct Attrib * attr, struct __ecereNameSpace__ecere__com__Instance * f)
2063 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "__attribute__((");
2066 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "__attribute((");
2069 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "__attribute_deprecated__((");
2074 struct Attribute * attrib;
2076 for(attrib = (*attr->attribs).first; attrib; attrib = attrib->next)
2079 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, " ");
2080 OutputAttribute(attrib, f);
2083 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "))");
2086 static void OutputExtDecl(struct ExtDecl * extDecl, struct __ecereNameSpace__ecere__com__Instance * f)
2088 if(extDecl->type == 0 && extDecl->s)
2089 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, extDecl->s);
2090 else if(extDecl->type == 1)
2091 OutputAttrib(extDecl->attr, f);
2094 extern struct Symbol * FindClass(char * name);
2096 static void OutputClassDef(struct ClassDef * def, struct __ecereNameSpace__ecere__com__Instance * f);
2098 static void OutputSpecifier(struct Specifier * spec, struct __ecereNameSpace__ecere__com__Instance * f)
2103 switch(spec->specifier)
2106 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "typedef");
2109 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "extern");
2112 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "static");
2115 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "auto");
2118 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "register");
2121 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "const");
2124 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "volatile");
2127 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "void");
2130 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "char");
2133 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "short");
2136 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "int");
2139 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "unsigned int");
2142 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "long long");
2145 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "__builtin_va_list");
2148 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "long");
2151 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "float");
2154 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "double");
2157 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "signed");
2160 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "unsigned");
2163 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "typed_object");
2166 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "any_object");
2169 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "class");
2172 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "thisclass");
2178 OutputExtDecl(spec->extDecl, f);
2181 if(spec->name && !strcmp(spec->name, "class"))
2183 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "typed_object");
2187 struct Symbol * symbol = spec->symbol;
2189 if(!symbol && spec->name)
2190 symbol = FindClass(spec->name);
2193 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, symbol->string ? symbol->string : "(null)");
2196 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, spec->name);
2201 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "enum");
2204 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, " ");
2205 OutputIdentifier(spec->id, f);
2209 struct Enumerator * enumerator;
2211 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "\n{\n");
2213 for(enumerator = (*spec->list).first; enumerator; enumerator = enumerator->next)
2215 OutputEnumerator(enumerator, f);
2216 if(enumerator->next)
2217 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, ", ");
2219 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "\n}");
2227 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, (spec->type == 3) ? "struct" : "union");
2228 if(spec->extDeclStruct)
2230 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, " ");
2231 OutputExtDecl(spec->extDeclStruct, f);
2235 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, " ");
2236 OutputIdentifier(spec->id, f);
2238 if(spec->definitions)
2240 struct ClassDef * def;
2242 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "\n{\n");
2244 for(def = (*spec->definitions).first; def; def = def->next)
2246 OutputClassDef(def, f);
2248 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "} __attribute__ ((gcc_struct))");
2253 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "__typeof(");
2254 OutputExpression(spec->expression, f);
2255 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, ")");
2258 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "subclass(");
2259 OutputSpecifier(spec->_class, f);
2260 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, ")");
2263 OutputIdentifier(spec->templateParameter->identifier, f);
2268 static void OutputInitializer(struct Initializer * initializer, struct __ecereNameSpace__ecere__com__Instance * f)
2270 char name[274] = "";
2271 char origName[274] = "";
2275 if(yylloc.start.included)
2277 __ecereNameSpace__ecere__sys__PathCat(name, GetIncludeFileFromID((unsigned int)yylloc.start.included));
2281 __ecereNameSpace__ecere__sys__PathCat(name, sourceFile);
2283 __ecereNameSpace__ecere__sys__ChangeCh(name, '\\', '/');
2284 __ecereNameSpace__ecere__sys__PathCat(origName, outputFile);
2285 __ecereNameSpace__ecere__sys__ChangeCh(origName, '\\', '/');
2287 switch(initializer->type)
2291 struct Initializer * init;
2293 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "\n{\n");
2295 if(inCompiler && outputLineNumbers && initializer->loc.start.line)
2297 __ecereMethod___ecereNameSpace__ecere__sys__File_Printf(f, "\n#line %d \"%s\"\n", initializer->loc.start.line, name);
2300 for(init = (*initializer->list).first; init; init = init->next)
2302 OutputInitializer(init, f);
2304 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, ", ");
2306 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "\n}");
2307 if(inCompiler && outputLineNumbers && initializer->loc.start.line)
2309 __ecereMethod___ecereNameSpace__ecere__sys__File_Printf(f, "\n#line %d \"%s\"\n", initializer->loc.start.line, name);
2316 if(initializer->exp)
2317 OutputExpression(initializer->exp, f);
2322 static void OutputInitDeclarator(struct InitDeclarator * decl, struct __ecereNameSpace__ecere__com__Instance * f)
2324 OutputDeclarator(decl->declarator, f);
2325 if(decl->initializer)
2327 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, " = ");
2328 OutputInitializer(decl->initializer, f);
2332 static void OutputDeclaration(struct Declaration * decl, struct __ecereNameSpace__ecere__com__Instance * f)
2334 struct Specifier * spec;
2335 char origName[274] = "";
2341 struct InitDeclarator * d;
2345 __ecereNameSpace__ecere__sys__PathCat(origName, outputFile);
2346 __ecereNameSpace__ecere__sys__ChangeCh(origName, '\\', '/');
2348 if(decl->declarators && (*decl->declarators).first)
2350 for(d = (*decl->declarators).first; d; d = d->next)
2353 char name[274] = "";
2355 if(yylloc.start.included)
2357 __ecereNameSpace__ecere__sys__PathCat(name, GetIncludeFileFromID((unsigned int)yylloc.start.included));
2361 __ecereNameSpace__ecere__sys__PathCat(name, sourceFile);
2363 __ecereNameSpace__ecere__sys__ChangeCh(name, '\\', '/');
2364 if(inCompiler && outputLineNumbers && decl->loc.start.line)
2366 __ecereMethod___ecereNameSpace__ecere__sys__File_Printf(f, "\n#line %d \"%s\"\n", decl->loc.start.line, name);
2372 if(decl->specifiers)
2374 for(spec = (*decl->specifiers).first; spec; spec = spec->next)
2376 OutputSpecifier(spec, f);
2378 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, " ");
2381 if(decl->declarators && (*decl->declarators).first)
2383 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, " ");
2384 for(d = (*decl->declarators).first; d; d = d->next)
2386 OutputInitDeclarator(d, f);
2388 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, ", ");
2395 if(decl->specifiers)
2397 for(spec = (*decl->specifiers).first; spec; spec = spec->next)
2399 OutputSpecifier(spec, f);
2401 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, " ");
2404 if(decl->declarators)
2406 struct Declarator * d;
2408 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, " ");
2409 for(d = (*decl->declarators).first; d; d = d->next)
2411 OutputDeclarator(d, f);
2413 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, ", ");
2416 if(decl->extStorage)
2418 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, " ");
2419 OutputSpecifier(decl->extStorage, f);
2426 OutputInstance(decl->inst, f);
2432 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, ";\n");
2434 if(inCompiler && outputLineNumbers && decl->loc.start.line && decl->type == 1)
2436 __ecereMethod___ecereNameSpace__ecere__sys__File_Printf(f, "\n#line %d \"%s\"\n", outputLine + 2, origName);
2441 static struct FunctionDefinition * curFunction;
2443 extern struct Identifier * GetDeclId(struct Declarator * decl);
2445 static void OutputFunction(struct FunctionDefinition * func, struct __ecereNameSpace__ecere__com__Instance * f)
2447 struct FunctionDefinition * oldFunc = curFunction;
2450 if(func->specifiers)
2452 struct Specifier * spec;
2454 for(spec = (*func->specifiers).first; spec; spec = spec->next)
2456 OutputSpecifier(spec, f);
2458 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, " ");
2460 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, " ");
2462 if(func->declarator)
2463 OutputDeclarator(func->declarator, f);
2464 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "\n");
2466 if(func->declarations)
2468 struct Declaration * decl;
2470 for(decl = (*func->declarations).first; decl; decl = decl->next)
2472 OutputDeclaration(decl, f);
2474 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "\n");
2479 if(inCompiler && memoryGuard)
2481 char name[1024] = "";
2482 struct Identifier * id = GetDeclId(func->declarator);
2484 if(yylloc.start.included)
2486 __ecereNameSpace__ecere__sys__PathCat(name, GetIncludeFileFromID((unsigned int)yylloc.start.included));
2490 __ecereNameSpace__ecere__sys__PathCat(name, sourceFile);
2492 __ecereNameSpace__ecere__sys__ChangeCh(name, '\\', '/');
2493 __ecereMethod___ecereNameSpace__ecere__sys__File_Printf(f, "{\n");
2494 __ecereMethod___ecereNameSpace__ecere__sys__File_Printf(f, " __ecereNameSpace__ecere__com__MemoryGuard_PushLoc(\"%s:%s\");\n", name, id->string);
2497 OutputStatement(func->body, f);
2498 if(inCompiler && memoryGuard)
2500 __ecereMethod___ecereNameSpace__ecere__sys__File_Printf(f, " __ecereNameSpace__ecere__com__MemoryGuard_PopLoc();\n");
2501 __ecereMethod___ecereNameSpace__ecere__sys__File_Printf(f, "}\n");
2504 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "\n");
2507 curFunction = oldFunc;
2510 static void OutputMemberInit(struct MemberInit * init, struct __ecereNameSpace__ecere__com__Instance * f)
2512 if(init->identifiers)
2514 if((*init->identifiers).count > 1)
2516 struct Identifier * id;
2518 for(id = (*init->identifiers).first; id; id = id->next)
2520 OutputIdentifier(id, f);
2522 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, ".");
2525 else if((*init->identifiers).first)
2526 OutputIdentifier((*init->identifiers).first, f);
2527 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, " = ");
2529 if(init->initializer)
2530 OutputInitializer(init->initializer, f);
2533 static void OutputClassFunction(struct ClassFunction * func, struct __ecereNameSpace__ecere__com__Instance * f);
2535 static void OutputMembersInit(struct MembersInit * init, struct __ecereNameSpace__ecere__com__Instance * f)
2541 struct MemberInit * member;
2543 if(init->dataMembers)
2545 for(member = (*init->dataMembers).first; member; member = member->next)
2547 OutputMemberInit(member, f);
2549 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, ", ");
2555 OutputClassFunction(init->function, f);
2560 static void OutputInstance(struct Instantiation * inst, struct __ecereNameSpace__ecere__com__Instance * f)
2563 OutputSpecifier(inst->_class, f);
2566 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, " ");
2567 OutputExpression(inst->exp, f);
2569 if(inst->members && (*inst->members).count > 1)
2571 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "\n{\n");
2574 else if(inst->members)
2575 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, " { ");
2577 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "{");
2580 struct MembersInit * init;
2582 for(init = (*inst->members).first; init; init = init->next)
2584 OutputMembersInit(init, f);
2585 if(init->type == 0 && init->next)
2587 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, ";\n");
2593 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, " }");
2595 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "}");
2598 static void OutputClassFunction(struct ClassFunction * func, struct __ecereNameSpace__ecere__com__Instance * f)
2600 if(func->specifiers)
2602 struct Specifier * spec;
2604 for(spec = (*func->specifiers).first; spec; spec = spec->next)
2606 OutputSpecifier(spec, f);
2608 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, " ");
2610 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, " ");
2612 if(func->declarator)
2613 OutputDeclarator(func->declarator, f);
2614 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "\n");
2616 if(func->declarations)
2618 struct Declaration * decl;
2620 for(decl = (*func->declarations).first; decl; decl = decl->next)
2622 OutputDeclaration(decl, f);
2624 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "\n");
2629 OutputStatement(func->body, f);
2630 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "\n");
2634 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, ";");
2637 static void OutputClassDef(struct ClassDef * def, struct __ecereNameSpace__ecere__com__Instance * f)
2644 OutputDeclaration(def->decl, f);
2645 if(def->next && def->next->type != 2)
2647 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "\n");
2654 struct MemberInit * init;
2656 for(init = (*def->defProperties).first; init; init = init->next)
2658 OutputMemberInit(init, f);
2660 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, ", ");
2662 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, ";\n\n");
2667 OutputClassFunction(def->function, f);
2668 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "\n");
2674 static void OutputClass(struct ClassDefinition * _class, struct __ecereNameSpace__ecere__com__Instance * f)
2676 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "class ");
2677 OutputSpecifier(_class->_class, f);
2678 if(_class->baseSpecs)
2680 struct Specifier * spec;
2682 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, " : ");
2683 for(spec = (*_class->baseSpecs).first; spec; spec = spec->next)
2685 OutputSpecifier(spec, f);
2688 if(_class->definitions)
2690 struct ClassDef * def;
2692 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "\n{\n");
2694 for(def = (*_class->definitions).first; def; def = def->next)
2696 OutputClassDef(def, f);
2698 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "}\n");
2702 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, ";");
2705 void OutputTree(struct __ecereNameSpace__ecere__sys__OldList * ast, struct __ecereNameSpace__ecere__com__Instance * f)
2707 struct External * external;
2710 for(external = ast->first; external; external = external->next)
2712 switch(external->type)
2715 OutputFunction(external->function, f);
2716 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "\n");
2720 OutputDeclaration(external->declaration, f);
2721 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "\n");
2725 OutputClass(external->_class, f);
2726 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, const char * string))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Puts])(f, "\n");
2733 extern struct __ecereNameSpace__ecere__com__Class * __ecereClass___ecereNameSpace__ecere__sys__TempFile;
2735 struct __ecereNameSpace__ecere__sys__TempFile
2737 char __ecere_padding[24];
2738 } __attribute__ ((gcc_struct));
2740 extern char * __ecereNameSpace__ecere__sys__TrimRSpaces(char * string, char * output);
2742 extern void * __ecereNameSpace__ecere__com__eInstance_New(struct __ecereNameSpace__ecere__com__Class * _class);
2744 int __ecereVMethodID___ecereNameSpace__ecere__sys__File_GetSize;
2746 int __ecereVMethodID___ecereNameSpace__ecere__sys__File_Seek;
2748 int __ecereVMethodID___ecereNameSpace__ecere__sys__File_Read;
2750 extern void __ecereNameSpace__ecere__com__eInstance_DecRef(struct __ecereNameSpace__ecere__com__Instance * instance);
2752 char * StringFromSpecDecl(struct __ecereNameSpace__ecere__sys__OldList * specs, struct Declarator * decl)
2755 struct TypeName * typeName = __ecereNameSpace__ecere__com__eInstance_New(__ecereClass_TypeName);
2756 struct __ecereNameSpace__ecere__com__Instance * f = __ecereNameSpace__ecere__com__eInstance_New(__ecereClass___ecereNameSpace__ecere__sys__TempFile);
2759 typeName->qualifiers = specs;
2760 typeName->declarator = decl;
2761 OutputTypeName(typeName, f);
2762 ((typeName ? (__ecereClass_TypeName->Destructor ? __ecereClass_TypeName->Destructor(typeName) : 0, __ecereNameSpace__ecere__com__eSystem_Delete(typeName)) : 0), typeName = 0);
2763 size = ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_GetSize])(f);
2764 string = __ecereNameSpace__ecere__com__eSystem_New(sizeof(char) * (size + 1));
2765 ((unsigned int (*)(struct __ecereNameSpace__ecere__com__Instance *, int pos, int mode))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Seek])(f, 0, 0);
2766 ((int (*)(struct __ecereNameSpace__ecere__com__Instance *, void * buffer, unsigned int size, unsigned int count))f->_vTbl[__ecereVMethodID___ecereNameSpace__ecere__sys__File_Read])(f, string, 1, (unsigned int)size);
2767 string[size] = '\0';
2768 __ecereNameSpace__ecere__sys__TrimRSpaces(string, string);
2769 (__ecereNameSpace__ecere__com__eInstance_DecRef(f), f = 0);
2773 extern struct __ecereNameSpace__ecere__com__Class * __ecereClass___ecereNameSpace__ecere__com__GlobalFunction;
2775 struct __ecereNameSpace__ecere__com__GlobalFunction;
2777 extern struct __ecereNameSpace__ecere__com__GlobalFunction * __ecereNameSpace__ecere__com__eSystem_RegisterFunction(char * name, char * type, void * func, struct __ecereNameSpace__ecere__com__Instance * module, int declMode);
2779 void __ecereRegisterModule_output(struct __ecereNameSpace__ecere__com__Instance * module)
2781 struct __ecereNameSpace__ecere__com__Class * class;
2783 __ecereNameSpace__ecere__com__eSystem_RegisterFunction("SetMemoryGuard", "void SetMemoryGuard(bool b)", SetMemoryGuard, module, 1);
2784 __ecereNameSpace__ecere__com__eSystem_RegisterFunction("GetMemoryGuard", "bool GetMemoryGuard(void)", GetMemoryGuard, module, 1);
2785 __ecereNameSpace__ecere__com__eSystem_RegisterFunction("OutputTypeName", "void OutputTypeName(TypeName type, ecere::sys::File f)", OutputTypeName, module, 1);
2786 __ecereNameSpace__ecere__com__eSystem_RegisterFunction("OutputExpression", "void OutputExpression(Expression exp, ecere::sys::File f)", OutputExpression, module, 1);
2787 __ecereNameSpace__ecere__com__eSystem_RegisterFunction("OutputTree", "void OutputTree(ecere::sys::OldList ast, ecere::sys::File f)", OutputTree, module, 1);
2788 __ecereNameSpace__ecere__com__eSystem_RegisterFunction("StringFromSpecDecl", "char * StringFromSpecDecl(ecere::sys::OldList specs, Declarator decl)", StringFromSpecDecl, module, 1);
2791 void __ecereUnregisterModule_output(struct __ecereNameSpace__ecere__com__Instance * module)