compiler/libec: (#205) Fixed integer promotions to follow the C standard (6.3.1.1)
[sdk] / compiler / bootstrap / libec / bootstrap / pass0.c
index 64d22e3..0d2a069 100644 (file)
@@ -35,20 +35,71 @@ typedef unsigned __int64 uint64;
 #else
 #define __ENDIAN_PAD(x) 0
 #endif
+#if defined(_WIN32)
+#   if defined(__GNUC__) || defined(__TINYC__)
+#      define ecere_stdcall __attribute__((__stdcall__))
+#      define ecere_gcc_struct __attribute__((gcc_struct))
+#   else
+#      define ecere_stdcall __stdcall
+#      define ecere_gcc_struct
+#   endif
+#else
+#   define ecere_stdcall
+#   define ecere_gcc_struct
+#endif
 #include <stdint.h>
 #include <sys/types.h>
+enum yytokentype
+{
+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, BOOL = 367, _BOOL = 368, _COMPLEX = 369, _IMAGINARY = 370, RESTRICT = 371, THREAD = 372, WIDE_STRING_LITERAL = 373
+};
 
-#if /*defined(_W64) || */(defined(__WORDSIZE) && __WORDSIZE == 8) || defined(__x86_64__)
-#define _64BIT 1
-#else
-#define _64BIT 0
-#endif
+extern unsigned int inCompiler;
+
+extern int declMode;
+
+extern int structDeclMode;
+
+extern const char *  sourceFile;
+
+extern struct __ecereNameSpace__ecere__com__Property * __ecereProp_Type_isPointerType;
 
-#define arch_PointerSize                  sizeof(void *)
-#define structSize_Instance               (_64BIT ? 24 : 12)
-#define structSize_Module                 (_64BIT ? 560 : 300)
+struct __ecereNameSpace__ecere__sys__OldList
+{
+void *  first;
+void *  last;
+int count;
+unsigned int offset;
+unsigned int circ;
+} ecere_gcc_struct;
+
+struct __ecereNameSpace__ecere__sys__BTNode;
+
+struct __ecereNameSpace__ecere__com__DataValue
+{
+union
+{
+char c;
+unsigned char uc;
+short s;
+unsigned short us;
+int i;
+unsigned int ui;
+void *  p;
+float f;
+double d;
+long long i64;
+uint64 ui64;
+} ecere_gcc_struct __anon1;
+} ecere_gcc_struct;
 
-struct __ecereNameSpace__ecere__com__Instance;
+struct __ecereNameSpace__ecere__com__SerialBuffer
+{
+unsigned char *  _buffer;
+unsigned int count;
+unsigned int _size;
+unsigned int pos;
+} ecere_gcc_struct;
 
 extern void *  __ecereNameSpace__ecere__com__eSystem_New(unsigned int size);
 
@@ -60,79 +111,33 @@ extern void *  __ecereNameSpace__ecere__com__eSystem_Renew0(void *  memory, unsi
 
 extern void __ecereNameSpace__ecere__com__eSystem_Delete(void *  memory);
 
-extern struct __ecereNameSpace__ecere__com__Class * __ecereClass___ecereNameSpace__ecere__sys__BTNode;
+struct Enumerator;
 
-struct __ecereNameSpace__ecere__sys__BTNode;
+struct Pointer;
 
-extern struct __ecereNameSpace__ecere__com__Class * __ecereClass___ecereNameSpace__ecere__sys__BinaryTree;
+struct InitDeclarator;
 
-struct __ecereNameSpace__ecere__sys__BinaryTree
-{
-struct __ecereNameSpace__ecere__sys__BTNode * root;
-int count;
-int (*  CompareKey)(struct __ecereNameSpace__ecere__sys__BinaryTree * tree, uintptr_t a, uintptr_t b);
-void (*  FreeKey)(void *  key);
-} __attribute__ ((gcc_struct));
+struct AsmField;
 
-extern struct __ecereNameSpace__ecere__com__Class * __ecereClass___ecereNameSpace__ecere__sys__OldList;
+struct Attrib;
 
-struct __ecereNameSpace__ecere__sys__OldList
-{
-void *  first;
-void *  last;
-int count;
-unsigned int offset;
-unsigned int circ;
-} __attribute__ ((gcc_struct));
+struct ExtDecl;
 
-extern struct __ecereNameSpace__ecere__com__Class * __ecereClass___ecereNameSpace__ecere__com__Method;
+struct Attribute;
 
-struct __ecereNameSpace__ecere__com__Method
-{
-const char *  name;
-struct __ecereNameSpace__ecere__com__Method * parent;
-struct __ecereNameSpace__ecere__com__Method * left;
-struct __ecereNameSpace__ecere__com__Method * right;
-int depth;
-int (*  function)();
-int vid;
-int type;
-struct __ecereNameSpace__ecere__com__Class * _class;
-void *  symbol;
-const char *  dataTypeString;
-struct Type * dataType;
-int memberAccess;
-} __attribute__ ((gcc_struct));
+struct PropertyWatch;
 
-extern struct __ecereNameSpace__ecere__com__Class * __ecereClass___ecereNameSpace__ecere__com__Property;
+struct TemplateParameter;
 
-struct __ecereNameSpace__ecere__com__Property
-{
-struct __ecereNameSpace__ecere__com__Property * prev;
-struct __ecereNameSpace__ecere__com__Property * next;
-const char *  name;
-unsigned int isProperty;
-int memberAccess;
-int id;
-struct __ecereNameSpace__ecere__com__Class * _class;
-const char *  dataTypeString;
-struct __ecereNameSpace__ecere__com__Class * dataTypeClass;
-struct Type * dataType;
-void (*  Set)(void * , int);
-int (*  Get)(void * );
-unsigned int (*  IsSet)(void * );
-void *  data;
-void *  symbol;
-int vid;
-unsigned int conversion;
-unsigned int watcherOffset;
-const char *  category;
-unsigned int compiled;
-unsigned int selfWatchable;
-unsigned int isWatchable;
-} __attribute__ ((gcc_struct));
+struct TemplateArgument;
+
+struct TemplateDatatype;
 
-extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_CodePosition;
+struct DBTableEntry;
+
+struct DBIndexItem;
+
+struct DBTableDef;
 
 struct CodePosition
 {
@@ -140,371 +145,287 @@ int line;
 int charPos;
 int pos;
 int included;
-} __attribute__ ((gcc_struct));
+} ecere_gcc_struct;
 
-extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_Location;
+extern char *  strcat(char * , const char * );
 
-struct Location
-{
-struct CodePosition start;
-struct CodePosition end;
-} __attribute__ ((gcc_struct));
+extern size_t strlen(const char * );
 
-extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_Attrib;
+extern int strncmp(const char * , const char * , size_t n);
 
-struct Attrib;
+struct ModuleImport;
 
-extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_ExtDecl;
+struct ClassImport;
 
-struct ExtDecl;
+extern void Compiler_Error(const char *  format, ...);
 
-extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_ClassDefinition;
+extern const char *  __ecereNameSpace__ecere__GetTranslatedString(const char * name, const char *  string, const char *  stringAndContext);
 
-struct ClassDefinition
+struct __ecereNameSpace__ecere__com__LinkList
 {
-struct ClassDefinition * prev;
-struct ClassDefinition * next;
-struct Location loc;
-struct Specifier * _class;
-struct __ecereNameSpace__ecere__sys__OldList *  baseSpecs;
-struct __ecereNameSpace__ecere__sys__OldList *  definitions;
-struct Symbol * symbol;
-struct Location blockStart;
-struct Location nameLoc;
-int endid;
-int declMode;
-unsigned int deleteWatchable;
-} __attribute__ ((gcc_struct));
+void * first;
+void * last;
+int count;
+} ecere_gcc_struct;
+
+extern char *  __ecereNameSpace__ecere__sys__CopyString(const char *  string);
 
-extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_Context;
+extern char *  strcpy(char * , const char * );
 
-struct Context
+struct __ecereNameSpace__ecere__com__LinkElement
 {
-struct Context * parent;
-struct __ecereNameSpace__ecere__sys__BinaryTree types;
-struct __ecereNameSpace__ecere__sys__BinaryTree classes;
-struct __ecereNameSpace__ecere__sys__BinaryTree symbols;
-struct __ecereNameSpace__ecere__sys__BinaryTree structSymbols;
-int nextID;
-int simpleID;
-struct __ecereNameSpace__ecere__sys__BinaryTree templateTypes;
-struct ClassDefinition * classDef;
-unsigned int templateTypesOnly;
-unsigned int hasNameSpace;
-} __attribute__ ((gcc_struct));
+void * prev;
+void * next;
+} ecere_gcc_struct;
 
-extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_Instantiation;
+extern char *  strstr(const char * , const char * );
 
-struct Instantiation
-{
-struct Instantiation * prev;
-struct Instantiation * next;
-struct Location loc;
-struct Specifier * _class;
-struct Expression * exp;
-struct __ecereNameSpace__ecere__sys__OldList *  members;
-struct Symbol * symbol;
-unsigned int fullSet;
-unsigned int isConstant;
-unsigned char *  data;
-struct Location nameLoc;
-struct Location insideLoc;
-unsigned int built;
-} __attribute__ ((gcc_struct));
+extern void Compiler_Warning(const char *  format, ...);
 
-extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_Declaration;
+extern int sprintf(char * , const char * , ...);
 
-struct Declaration
-{
-struct Declaration * prev;
-struct Declaration * next;
-struct Location loc;
-int type;
-union
-{
-struct
-{
-struct __ecereNameSpace__ecere__sys__OldList *  specifiers;
-struct __ecereNameSpace__ecere__sys__OldList *  declarators;
-} __attribute__ ((gcc_struct)) __anon1;
-struct Instantiation * inst;
-struct
-{
-struct Identifier * id;
-struct Expression * exp;
-} __attribute__ ((gcc_struct)) __anon2;
-} __attribute__ ((gcc_struct)) __anon1;
-struct Specifier * extStorage;
-struct Symbol * symbol;
-int declMode;
-} __attribute__ ((gcc_struct));
+struct __ecereNameSpace__ecere__com__GlobalFunction;
 
-extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_Statement;
+struct __ecereNameSpace__ecere__com__IteratorPointer;
 
-struct Statement
-{
-struct Statement * prev;
-struct Statement * next;
-struct Location loc;
-int type;
-union
+extern struct __ecereNameSpace__ecere__sys__OldList *  MkList(void);
+
+extern void ListAdd(struct __ecereNameSpace__ecere__sys__OldList * list, void *  item);
+
+extern void FreeList(struct __ecereNameSpace__ecere__sys__OldList * list, void (*  FreeFunction)(void * ));
+
+extern struct __ecereNameSpace__ecere__sys__OldList *  MkListOne(void *  item);
+
+extern struct __ecereNameSpace__ecere__sys__OldList *  ast;
+
+extern struct __ecereNameSpace__ecere__sys__OldList *  excludedSymbols;
+
+extern struct __ecereNameSpace__ecere__sys__OldList *  CopyList(struct __ecereNameSpace__ecere__sys__OldList *  source, void *  (*  CopyFunction)(void * ));
+
+unsigned int __ecereMethod___ecereNameSpace__ecere__sys__OldList_Insert(struct __ecereNameSpace__ecere__sys__OldList * this, void *  prevItem, void *  item);
+
+void __ecereMethod___ecereNameSpace__ecere__sys__OldList_Remove(struct __ecereNameSpace__ecere__sys__OldList * this, void *  item);
+
+void __ecereMethod___ecereNameSpace__ecere__sys__OldList_Add(struct __ecereNameSpace__ecere__sys__OldList * this, void *  item);
+
+void __ecereMethod___ecereNameSpace__ecere__sys__OldList_Clear(struct __ecereNameSpace__ecere__sys__OldList * this);
+
+extern struct Pointer * MkPointer(struct __ecereNameSpace__ecere__sys__OldList * qualifiers, struct Pointer * pointer);
+
+extern void FreeInitDeclarator(struct InitDeclarator * decl);
+
+extern struct Attrib * MkAttrib(int type, struct __ecereNameSpace__ecere__sys__OldList *  attribs);
+
+extern struct ExtDecl * MkExtDeclAttrib(struct Attrib * attr);
+
+struct Location
 {
-struct __ecereNameSpace__ecere__sys__OldList *  expressions;
-struct
+struct CodePosition start;
+struct CodePosition end;
+} ecere_gcc_struct;
+
+void FullClassNameCat(char * output, const char * className, unsigned int includeTemplateParams)
 {
-struct Identifier * id;
-struct Statement * stmt;
-} __attribute__ ((gcc_struct)) labeled;
-struct
+int c;
+char ch;
+int len;
+
+for(c = 0; (ch = className[c]) && ch != '<'; c++)
 {
-struct Expression * exp;
-struct Statement * stmt;
-} __attribute__ ((gcc_struct)) caseStmt;
-struct
+if(ch == ':')
 {
-struct __ecereNameSpace__ecere__sys__OldList * declarations;
-struct __ecereNameSpace__ecere__sys__OldList * statements;
-struct Context * context;
-unsigned int isSwitch;
-} __attribute__ ((gcc_struct)) compound;
-struct
-{
-struct __ecereNameSpace__ecere__sys__OldList * exp;
-struct Statement * stmt;
-struct Statement * elseStmt;
-} __attribute__ ((gcc_struct)) ifStmt;
-struct
-{
-struct __ecereNameSpace__ecere__sys__OldList * exp;
-struct Statement * stmt;
-} __attribute__ ((gcc_struct)) switchStmt;
-struct
-{
-struct __ecereNameSpace__ecere__sys__OldList * exp;
-struct Statement * stmt;
-} __attribute__ ((gcc_struct)) whileStmt;
-struct
+strcat(output, "__ecereNameSpace__");
+break;
+}
+}
+len = strlen(output);
+c = 0;
+if(!strncmp(className, "const ", 6))
+c += 6;
+for(; (ch = className[c]); c++)
 {
-struct __ecereNameSpace__ecere__sys__OldList * exp;
-struct Statement * stmt;
-} __attribute__ ((gcc_struct)) doWhile;
-struct
+if(ch == ':')
+output[len++] = '_';
+else if(ch == ' ')
+output[len++] = '_';
+else if(ch == '*')
 {
-struct Statement * init;
-struct Statement * check;
-struct __ecereNameSpace__ecere__sys__OldList * increment;
-struct Statement * stmt;
-} __attribute__ ((gcc_struct)) forStmt;
-struct
+output[len++] = '_';
+output[len++] = 'P';
+output[len++] = 'T';
+output[len++] = 'R';
+output[len++] = '_';
+}
+else if(ch == '=')
 {
-struct Identifier * id;
-} __attribute__ ((gcc_struct)) gotoStmt;
-struct
+output[len++] = '_';
+output[len++] = 'E';
+output[len++] = 'Q';
+output[len++] = 'U';
+output[len++] = '_';
+}
+else if(ch == '<')
 {
-struct Specifier * spec;
-char * statements;
-struct __ecereNameSpace__ecere__sys__OldList * inputFields;
-struct __ecereNameSpace__ecere__sys__OldList * outputFields;
-struct __ecereNameSpace__ecere__sys__OldList * clobberedFields;
-} __attribute__ ((gcc_struct)) asmStmt;
-struct
+if(!includeTemplateParams)
+break;
+if(!strncmp(className + c + 1, "const ", 6))
+c += 6;
+output[len++] = '_';
+output[len++] = 'T';
+output[len++] = 'P';
+output[len++] = 'L';
+output[len++] = '_';
+}
+else if(ch == '>')
 {
-struct Expression * watcher;
-struct Expression * object;
-struct __ecereNameSpace__ecere__sys__OldList * watches;
-} __attribute__ ((gcc_struct)) _watch;
-struct
+output[len++] = '_';
+}
+else if(ch == ',')
 {
-struct Identifier * id;
-struct __ecereNameSpace__ecere__sys__OldList * exp;
-struct __ecereNameSpace__ecere__sys__OldList * filter;
-struct Statement * stmt;
-} __attribute__ ((gcc_struct)) forEachStmt;
-struct Declaration * decl;
-} __attribute__ ((gcc_struct)) __anon1;
-} __attribute__ ((gcc_struct));
+if(!strncmp(className + c + 1, "const ", 6))
+c += 6;
+output[len++] = '_';
+}
+else
+output[len++] = ch;
+}
+output[len++] = 0;
+}
 
-extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_TypeName;
+extern struct Location yylloc;
 
-struct TypeName
-{
-struct TypeName * prev;
-struct TypeName * next;
-struct Location loc;
-struct __ecereNameSpace__ecere__sys__OldList *  qualifiers;
-struct Declarator * declarator;
-int classObjectType;
-struct Expression * bitCount;
-} __attribute__ ((gcc_struct));
+struct External;
 
-extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_Initializer;
+extern struct External * curExternal;
 
-struct Initializer
+struct TopoEdge
 {
-struct Initializer * prev;
-struct Initializer * next;
-struct Location loc;
-int type;
-union
-{
-struct Expression * exp;
-struct __ecereNameSpace__ecere__sys__OldList *  list;
-} __attribute__ ((gcc_struct)) __anon1;
-unsigned int isConstant;
-struct Identifier * id;
-} __attribute__ ((gcc_struct));
+struct __ecereNameSpace__ecere__com__LinkElement in;
+struct __ecereNameSpace__ecere__com__LinkElement out;
+struct External * from;
+struct External * to;
+unsigned int breakable;
+} ecere_gcc_struct;
 
-extern struct __ecereNameSpace__ecere__com__Class * __ecereClass___ecereNameSpace__ecere__com__DataValue;
+extern void FreeExternal(struct External * external);
 
-struct __ecereNameSpace__ecere__com__DataValue
-{
-union
-{
-char c;
-unsigned char uc;
-short s;
-unsigned short us;
-int i;
-unsigned int ui;
-void *  p;
-float f;
-double d;
-long long i64;
-uint64 ui64;
-} __attribute__ ((gcc_struct)) __anon1;
-} __attribute__ ((gcc_struct));
+extern struct External * DeclareStruct(struct External * neededBy, const char *  name, unsigned int skipNoHead, unsigned int needDereference);
 
-extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_Expression;
+struct Context;
 
-struct Expression
-{
-struct Expression * prev;
-struct Expression * next;
-struct Location loc;
-int type;
-union
-{
-struct
-{
-char *  constant;
-struct Identifier * identifier;
-} __attribute__ ((gcc_struct)) __anon1;
-struct Statement * compound;
-struct Instantiation * instance;
-struct
-{
-char *  string;
-unsigned int intlString;
-} __attribute__ ((gcc_struct)) __anon2;
-struct __ecereNameSpace__ecere__sys__OldList *  list;
-struct
-{
-struct __ecereNameSpace__ecere__sys__OldList * specifiers;
-struct Declarator * decl;
-} __attribute__ ((gcc_struct)) _classExp;
-struct
-{
-struct Identifier * id;
-} __attribute__ ((gcc_struct)) classData;
-struct
-{
-struct Expression * exp;
-struct __ecereNameSpace__ecere__sys__OldList * arguments;
-struct Location argLoc;
-} __attribute__ ((gcc_struct)) call;
-struct
-{
-struct Expression * exp;
-struct __ecereNameSpace__ecere__sys__OldList * index;
-} __attribute__ ((gcc_struct)) index;
-struct
-{
-struct Expression * exp;
-struct Identifier * member;
-int memberType;
-unsigned int thisPtr;
-} __attribute__ ((gcc_struct)) member;
-struct
-{
-int op;
-struct Expression * exp1;
-struct Expression * exp2;
-} __attribute__ ((gcc_struct)) op;
-struct TypeName * typeName;
-struct Specifier * _class;
-struct
-{
-struct TypeName * typeName;
-struct Expression * exp;
-} __attribute__ ((gcc_struct)) cast;
-struct
-{
-struct Expression * cond;
-struct __ecereNameSpace__ecere__sys__OldList * exp;
-struct Expression * elseExp;
-} __attribute__ ((gcc_struct)) cond;
-struct
-{
-struct TypeName * typeName;
-struct Expression * size;
-} __attribute__ ((gcc_struct)) _new;
-struct
-{
-struct TypeName * typeName;
-struct Expression * size;
-struct Expression * exp;
-} __attribute__ ((gcc_struct)) _renew;
-struct
-{
-char * table;
-struct Identifier * id;
-} __attribute__ ((gcc_struct)) db;
-struct
-{
-struct Expression * ds;
-struct Expression * name;
-} __attribute__ ((gcc_struct)) dbopen;
-struct
+extern struct Context * PushContext(void);
+
+extern void PopContext(struct Context * ctx);
+
+extern struct Context * curContext;
+
+struct __ecereNameSpace__ecere__com__Class;
+
+struct __ecereNameSpace__ecere__com__Instance
 {
-struct TypeName * typeName;
-struct Initializer * initializer;
-} __attribute__ ((gcc_struct)) initializer;
-struct
+void * *  _vTbl;
+struct __ecereNameSpace__ecere__com__Class * _class;
+int _refCount;
+} ecere_gcc_struct;
+
+extern long long __ecereNameSpace__ecere__com__eClass_GetProperty(struct __ecereNameSpace__ecere__com__Class * _class, const char *  name);
+
+extern void __ecereNameSpace__ecere__com__eClass_SetProperty(struct __ecereNameSpace__ecere__com__Class * _class, const char *  name, long long value);
+
+extern int AddMembers(struct External * neededBy, struct __ecereNameSpace__ecere__sys__OldList *  declarations, struct __ecereNameSpace__ecere__com__Class * _class, unsigned int isMember, unsigned int *  retSize, struct __ecereNameSpace__ecere__com__Class * topClass, unsigned int *  addedPadding);
+
+extern void *  __ecereNameSpace__ecere__com__eInstance_New(struct __ecereNameSpace__ecere__com__Class * _class);
+
+extern void __ecereNameSpace__ecere__com__eInstance_SetMethod(struct __ecereNameSpace__ecere__com__Instance * instance, const char *  name, void *  function);
+
+extern void __ecereNameSpace__ecere__com__eInstance_IncRef(struct __ecereNameSpace__ecere__com__Instance * instance);
+
+int __ecereVMethodID___ecereNameSpace__ecere__com__Container_GetNext;
+
+struct __ecereNameSpace__ecere__com__Property;
+
+extern void __ecereNameSpace__ecere__com__eInstance_FireSelfWatchers(struct __ecereNameSpace__ecere__com__Instance * instance, struct __ecereNameSpace__ecere__com__Property * _property);
+
+extern void __ecereNameSpace__ecere__com__eInstance_StopWatching(struct __ecereNameSpace__ecere__com__Instance * instance, struct __ecereNameSpace__ecere__com__Property * _property, struct __ecereNameSpace__ecere__com__Instance * object);
+
+extern void __ecereNameSpace__ecere__com__eInstance_Watch(void *  instance, struct __ecereNameSpace__ecere__com__Property * _property, void *  object, void (*  callback)(void * , void * ));
+
+extern void __ecereNameSpace__ecere__com__eInstance_FireWatchers(struct __ecereNameSpace__ecere__com__Instance * instance, struct __ecereNameSpace__ecere__com__Property * _property);
+
+extern struct __ecereNameSpace__ecere__com__Property * __ecereNameSpace__ecere__com__eClass_AddProperty(struct __ecereNameSpace__ecere__com__Class * _class, const char *  name, const char *  dataType, void *  setStmt, void *  getStmt, int declMode);
+
+struct Declarator;
+
+extern void FreeDeclarator(struct Declarator * decl);
+
+extern struct Declarator * MkDeclaratorPointer(struct Pointer * pointer, struct Declarator * declarator);
+
+extern struct Declarator * MkDeclaratorFunction(struct Declarator * declarator, struct __ecereNameSpace__ecere__sys__OldList * parameters);
+
+extern struct Declarator * PlugDeclarator(struct Declarator * decl, struct Declarator * baseDecl);
+
+extern struct Declarator * CopyDeclarator(struct Declarator * declarator);
+
+extern struct Declarator * GetFuncDecl(struct Declarator * decl);
+
+struct __ecereNameSpace__ecere__com__BTNamedLink;
+
+struct __ecereNameSpace__ecere__com__BTNamedLink
 {
-struct Expression * exp;
-struct TypeName * typeName;
-} __attribute__ ((gcc_struct)) vaArg;
-} __attribute__ ((gcc_struct)) __anon1;
-unsigned int debugValue;
-struct __ecereNameSpace__ecere__com__DataValue val;
-uint64 address;
-unsigned int hasAddress;
-struct Type * expType;
-struct Type * destType;
-unsigned int usage;
-int tempCount;
-unsigned int byReference;
-unsigned int isConstant;
-unsigned int addedThis;
-unsigned int needCast;
-unsigned int thisPtr;
-unsigned int opDestType;
-unsigned int needTemplateCast;
-} __attribute__ ((gcc_struct));
+const char *  name;
+struct __ecereNameSpace__ecere__com__BTNamedLink * parent;
+struct __ecereNameSpace__ecere__com__BTNamedLink * left;
+struct __ecereNameSpace__ecere__com__BTNamedLink * right;
+int depth;
+void *  data;
+} ecere_gcc_struct;
 
-extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_TemplateDatatype;
+struct Symbol;
 
-struct TemplateDatatype;
+extern struct Symbol * FindClass(const char *  name);
 
-extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_TemplateArgument;
+struct Declaration;
 
-struct TemplateArgument;
+extern struct External * MkExternalDeclaration(struct Declaration * declaration);
 
-extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_TemplateParameter;
+extern struct Declaration * MkDeclaration(struct __ecereNameSpace__ecere__sys__OldList * specifiers, struct __ecereNameSpace__ecere__sys__OldList * initDeclarators);
 
-struct TemplateParameter;
+struct Specifier;
+
+extern struct Specifier * MkSpecifierName(const char *  name);
+
+extern struct Declaration * MkStructDeclaration(struct __ecereNameSpace__ecere__sys__OldList * specifiers, struct __ecereNameSpace__ecere__sys__OldList * declarators, struct Specifier * extStorage);
+
+extern void FreeSpecifier(struct Specifier * spec);
+
+extern struct Specifier * MkSpecifier(int specifier);
+
+extern struct Specifier * CopySpecifier(struct Specifier * spec);
+
+extern struct Specifier * MkSpecifierExtended(struct ExtDecl * extDecl);
 
-extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_Specifier;
+struct Identifier;
+
+extern struct Identifier * GetDeclId(struct Declarator * decl);
+
+struct Identifier
+{
+struct Identifier * prev;
+struct Identifier * next;
+struct Location loc;
+struct Symbol * classSym;
+struct Specifier * _class;
+char *  string;
+struct Identifier * badID;
+} ecere_gcc_struct;
+
+extern struct Declarator * MkDeclaratorIdentifier(struct Identifier * id);
+
+extern struct Identifier * MkIdentifier(const char *  string);
+
+extern struct Specifier * MkStructOrUnion(int type, struct Identifier * id, struct __ecereNameSpace__ecere__sys__OldList * definitions);
+
+struct Expression;
 
 struct Specifier
 {
@@ -521,7 +442,8 @@ struct ExtDecl * extDecl;
 char *  name;
 struct Symbol * symbol;
 struct __ecereNameSpace__ecere__sys__OldList *  templateArgs;
-} __attribute__ ((gcc_struct)) __anon1;
+struct Specifier * nsSpec;
+} ecere_gcc_struct __anon1;
 struct
 {
 struct Identifier * id;
@@ -531,31 +453,12 @@ struct __ecereNameSpace__ecere__sys__OldList *  definitions;
 unsigned int addNameSpace;
 struct Context * ctx;
 struct ExtDecl * extDeclStruct;
-} __attribute__ ((gcc_struct)) __anon2;
+} ecere_gcc_struct __anon2;
 struct Expression * expression;
 struct Specifier * _class;
 struct TemplateParameter * templateParameter;
-} __attribute__ ((gcc_struct)) __anon1;
-} __attribute__ ((gcc_struct));
-
-extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_Identifier;
-
-struct Identifier
-{
-struct Identifier * prev;
-struct Identifier * next;
-struct Location loc;
-struct Symbol * classSym;
-struct Specifier * _class;
-char *  string;
-struct Identifier * badID;
-} __attribute__ ((gcc_struct));
-
-extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_Pointer;
-
-struct Pointer;
-
-extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_Declarator;
+} ecere_gcc_struct __anon1;
+} ecere_gcc_struct;
 
 struct Declarator
 {
@@ -573,81 +476,120 @@ struct
 struct Expression * exp;
 struct Expression * posExp;
 struct Attrib * attrib;
-} __attribute__ ((gcc_struct)) structDecl;
+} ecere_gcc_struct structDecl;
 struct
 {
 struct Expression * exp;
 struct Specifier * enumClass;
-} __attribute__ ((gcc_struct)) array;
+} ecere_gcc_struct array;
 struct
 {
 struct __ecereNameSpace__ecere__sys__OldList * parameters;
-} __attribute__ ((gcc_struct)) function;
+} ecere_gcc_struct function;
 struct
 {
 struct Pointer * pointer;
-} __attribute__ ((gcc_struct)) pointer;
+} ecere_gcc_struct pointer;
 struct
 {
 struct ExtDecl * extended;
-} __attribute__ ((gcc_struct)) extended;
-} __attribute__ ((gcc_struct)) __anon1;
-} __attribute__ ((gcc_struct));
+} ecere_gcc_struct extended;
+} ecere_gcc_struct __anon1;
+} ecere_gcc_struct;
+
+extern struct Expression * QMkExpId(const char *  id);
+
+extern struct Expression * MkExpOp(struct Expression * exp1, int op, struct Expression * exp2);
+
+extern struct Expression * CopyExpression(struct Expression * exp);
+
+extern struct Expression * MkExpCall(struct Expression * expression, struct __ecereNameSpace__ecere__sys__OldList * arguments);
 
-extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_FunctionDefinition;
+extern struct Expression * MkExpIdentifier(struct Identifier * id);
 
-struct FunctionDefinition
+extern struct Expression * MkExpMember(struct Expression * expression, struct Identifier * member);
+
+extern struct Attribute * MkAttribute(char * attr, struct Expression * exp);
+
+struct Type;
+
+struct __ecereNameSpace__ecere__com__Property
 {
-struct FunctionDefinition * prev;
-struct FunctionDefinition * next;
-struct Location loc;
-struct __ecereNameSpace__ecere__sys__OldList *  specifiers;
-struct Declarator * declarator;
-struct __ecereNameSpace__ecere__sys__OldList *  declarations;
-struct Statement * body;
+struct __ecereNameSpace__ecere__com__Property * prev;
+struct __ecereNameSpace__ecere__com__Property * next;
+const char *  name;
+unsigned int isProperty;
+int memberAccess;
+int id;
 struct __ecereNameSpace__ecere__com__Class * _class;
-struct __ecereNameSpace__ecere__sys__OldList attached;
-int declMode;
-struct Type * type;
-struct Symbol * propSet;
-int tempCount;
-unsigned int propertyNoThis;
-} __attribute__ ((gcc_struct));
+const char *  dataTypeString;
+struct __ecereNameSpace__ecere__com__Class * dataTypeClass;
+struct Type * dataType;
+void (*  Set)(void * , int);
+int (*  Get)(void * );
+unsigned int (*  IsSet)(void * );
+void *  data;
+void *  symbol;
+int vid;
+unsigned int conversion;
+unsigned int watcherOffset;
+const char *  category;
+unsigned int compiled;
+unsigned int selfWatchable;
+unsigned int isWatchable;
+} ecere_gcc_struct;
 
-extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_DBTableDef;
+extern struct Type * MkClassType(const char *  name);
 
-struct DBTableDef;
+extern struct Type * ProcessType(struct __ecereNameSpace__ecere__sys__OldList * specs, struct Declarator * decl);
+
+extern void FreeType(struct Type * type);
 
-extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_External;
+struct ClassFunction;
 
-struct External
+extern struct ClassFunction * MkClassFunction(struct __ecereNameSpace__ecere__sys__OldList * specifiers, struct Specifier * _class, struct Declarator * decl, struct __ecereNameSpace__ecere__sys__OldList * declList);
+
+struct Initializer;
+
+struct Initializer
 {
-struct External * prev;
-struct External * next;
+struct Initializer * prev;
+struct Initializer * next;
 struct Location loc;
 int type;
-struct Symbol * symbol;
 union
 {
-struct FunctionDefinition * function;
-struct ClassDefinition * _class;
-struct Declaration * declaration;
-char *  importString;
+struct Expression * exp;
+struct __ecereNameSpace__ecere__sys__OldList *  list;
+} ecere_gcc_struct __anon1;
+unsigned int isConstant;
 struct Identifier * id;
-struct DBTableDef * table;
-} __attribute__ ((gcc_struct)) __anon1;
-int importType;
-} __attribute__ ((gcc_struct));
+} ecere_gcc_struct;
 
-extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_ModuleImport;
+extern struct InitDeclarator * MkInitDeclarator(struct Declarator * declarator, struct Initializer * initializer);
 
-struct ModuleImport;
+extern void FreeInitializer(struct Initializer * initializer);
 
-extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_ClassImport;
+extern struct Initializer * MkInitializerAssignment(struct Expression * exp);
 
-struct ClassImport;
+struct __ecereNameSpace__ecere__com__Method;
 
-extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_Symbol;
+struct __ecereNameSpace__ecere__com__Method
+{
+const char *  name;
+struct __ecereNameSpace__ecere__com__Method * parent;
+struct __ecereNameSpace__ecere__com__Method * left;
+struct __ecereNameSpace__ecere__com__Method * right;
+int depth;
+int (*  function)();
+int vid;
+int type;
+struct __ecereNameSpace__ecere__com__Class * _class;
+void *  symbol;
+const char *  dataTypeString;
+struct Type * dataType;
+int memberAccess;
+} ecere_gcc_struct;
 
 struct Symbol
 {
@@ -662,29 +604,28 @@ union
 struct __ecereNameSpace__ecere__com__Method * method;
 struct __ecereNameSpace__ecere__com__Property * _property;
 struct __ecereNameSpace__ecere__com__Class * registered;
-} __attribute__ ((gcc_struct)) __anon1;
-int id;
-int idCode;
+} ecere_gcc_struct __anon1;
+unsigned int notYetDeclared;
 union
 {
 struct
 {
 struct External * pointerExternal;
 struct External * structExternal;
-} __attribute__ ((gcc_struct)) __anon1;
+} ecere_gcc_struct __anon1;
 struct
 {
 struct External * externalGet;
 struct External * externalSet;
 struct External * externalPtr;
 struct External * externalIsSet;
-} __attribute__ ((gcc_struct)) __anon2;
+} ecere_gcc_struct __anon2;
 struct
 {
 struct External * methodExternal;
 struct External * methodCodeExternal;
-} __attribute__ ((gcc_struct)) __anon3;
-} __attribute__ ((gcc_struct)) __anon2;
+} ecere_gcc_struct __anon3;
+} ecere_gcc_struct __anon2;
 unsigned int imported;
 unsigned int declaredStructSym;
 struct __ecereNameSpace__ecere__com__Class * _class;
@@ -711,9 +652,8 @@ struct __ecereNameSpace__ecere__sys__OldList templatedClasses;
 struct Context * ctx;
 int isIterator;
 struct Expression * propCategory;
-} __attribute__ ((gcc_struct));
-
-extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_Type;
+unsigned int mustRegister;
+} ecere_gcc_struct;
 
 struct Type
 {
@@ -727,7 +667,7 @@ struct
 {
 struct __ecereNameSpace__ecere__sys__OldList members;
 char *  enumName;
-} __attribute__ ((gcc_struct)) __anon1;
+} ecere_gcc_struct __anon1;
 struct
 {
 struct Type * returnType;
@@ -735,13 +675,13 @@ struct __ecereNameSpace__ecere__sys__OldList params;
 struct Symbol * thisClass;
 unsigned int staticMethod;
 struct TemplateParameter * thisClassTemplate;
-} __attribute__ ((gcc_struct)) __anon2;
+} ecere_gcc_struct __anon2;
 struct
 {
 struct __ecereNameSpace__ecere__com__Method * method;
 struct __ecereNameSpace__ecere__com__Class * methodClass;
 struct __ecereNameSpace__ecere__com__Class * usedClass;
-} __attribute__ ((gcc_struct)) __anon3;
+} ecere_gcc_struct __anon3;
 struct
 {
 struct Type * arrayType;
@@ -749,19 +689,22 @@ int arraySize;
 struct Expression * arraySizeExp;
 unsigned int freeExp;
 struct Symbol * enumClass;
-} __attribute__ ((gcc_struct)) __anon4;
+} ecere_gcc_struct __anon4;
 struct Type * type;
 struct TemplateParameter * templateParameter;
-} __attribute__ ((gcc_struct)) __anon1;
+} ecere_gcc_struct __anon1;
 int kind;
 unsigned int size;
 char *  name;
 char *  typeName;
+struct __ecereNameSpace__ecere__com__Class * thisClassFrom;
+int promotedFrom;
 int classObjectType;
 int alignment;
 unsigned int offset;
 int bitFieldCount;
 int count;
+int bitMemberSize;
 unsigned int isSigned : 1;
 unsigned int constant : 1;
 unsigned int truth : 1;
@@ -776,94 +719,170 @@ unsigned int attrStdcall : 1;
 unsigned int declaredWithStruct : 1;
 unsigned int typedByReference : 1;
 unsigned int casted : 1;
-} __attribute__ ((gcc_struct));
+unsigned int pointerAlignment : 1;
+unsigned int isLong : 1;
+unsigned int signedBeforePromotion : 1;
+} ecere_gcc_struct;
 
-extern struct __ecereNameSpace__ecere__com__Class * __ecereClass___ecereNameSpace__ecere__com__Class;
+extern struct __ecereNameSpace__ecere__com__Method * __ecereNameSpace__ecere__com__eClass_AddMethod(struct __ecereNameSpace__ecere__com__Class * _class, const char *  name, const char *  type, void *  function, int declMode);
 
-struct __ecereNameSpace__ecere__com__Class
-{
-struct __ecereNameSpace__ecere__com__Class * prev;
-struct __ecereNameSpace__ecere__com__Class * next;
-const char *  name;
-int offset;
-int structSize;
-int (* *  _vTbl)();
-int vTblSize;
-int (*  Constructor)(struct __ecereNameSpace__ecere__com__Instance *);
-void (*  Destructor)(struct __ecereNameSpace__ecere__com__Instance *);
-int offsetClass;
-int sizeClass;
-struct __ecereNameSpace__ecere__com__Class * base;
-struct __ecereNameSpace__ecere__sys__BinaryTree methods;
-struct __ecereNameSpace__ecere__sys__BinaryTree members;
-struct __ecereNameSpace__ecere__sys__BinaryTree prop;
-struct __ecereNameSpace__ecere__sys__OldList membersAndProperties;
-struct __ecereNameSpace__ecere__sys__BinaryTree classProperties;
-struct __ecereNameSpace__ecere__sys__OldList derivatives;
-int memberID;
-int startMemberID;
-int type;
-struct __ecereNameSpace__ecere__com__Instance * module;
-struct __ecereNameSpace__ecere__com__NameSpace *  nameSpace;
-const char *  dataTypeString;
-struct Type * dataType;
-int typeSize;
-int defaultAlignment;
-void (*  Initialize)();
-int memberOffset;
-struct __ecereNameSpace__ecere__sys__OldList selfWatchers;
-const char *  designerClass;
-unsigned int noExpansion;
-const char *  defaultProperty;
-unsigned int comRedefinition;
-int count;
-int isRemote;
-unsigned int internalDecl;
-void *  data;
-unsigned int computeSize;
-int structAlignment;
-int destructionWatchOffset;
-unsigned int fixed;
-struct __ecereNameSpace__ecere__sys__OldList delayedCPValues;
-int inheritanceAccess;
-const char *  fullName;
-void *  symbol;
-struct __ecereNameSpace__ecere__sys__OldList conversions;
-struct __ecereNameSpace__ecere__sys__OldList templateParams;
-struct __ecereNameSpace__ecere__com__ClassTemplateArgument *  templateArgs;
-struct __ecereNameSpace__ecere__com__Class * templateClass;
-struct __ecereNameSpace__ecere__sys__OldList templatized;
-int numParams;
-unsigned int isInstanceClass;
-unsigned int byValueSystemClass;
-} __attribute__ ((gcc_struct));
+extern void ProcessMethodType(struct __ecereNameSpace__ecere__com__Method * method);
 
-extern long long __ecereNameSpace__ecere__com__eClass_GetProperty(struct __ecereNameSpace__ecere__com__Class * _class, const char *  name);
+unsigned int __ecereProp_Type_Get_isPointerType(struct Type * this);
 
-extern void __ecereNameSpace__ecere__com__eClass_SetProperty(struct __ecereNameSpace__ecere__com__Class * _class, const char *  name, long long value);
+struct Statement;
 
-extern void __ecereNameSpace__ecere__com__eInstance_FireSelfWatchers(struct __ecereNameSpace__ecere__com__Instance * instance, struct __ecereNameSpace__ecere__com__Property * _property);
+struct ClassFunction
+{
+struct ClassFunction * prev;
+struct ClassFunction * next;
+struct Location loc;
+struct __ecereNameSpace__ecere__sys__OldList *  specifiers;
+struct Declarator * declarator;
+struct __ecereNameSpace__ecere__sys__OldList *  declarations;
+struct Statement * body;
+struct __ecereNameSpace__ecere__com__Class * _class;
+struct __ecereNameSpace__ecere__sys__OldList attached;
+int declMode;
+struct Type * type;
+struct Symbol * propSet;
+unsigned int isVirtual;
+unsigned int isConstructor;
+unsigned int isDestructor;
+unsigned int dontMangle;
+int id;
+int idCode;
+} ecere_gcc_struct;
 
-extern void __ecereNameSpace__ecere__com__eInstance_SetMethod(struct __ecereNameSpace__ecere__com__Instance * instance, const char *  name, void *  function);
+struct Statement
+{
+struct Statement * prev;
+struct Statement * next;
+struct Location loc;
+int type;
+union
+{
+struct __ecereNameSpace__ecere__sys__OldList *  expressions;
+struct
+{
+struct Identifier * id;
+struct Statement * stmt;
+} ecere_gcc_struct labeled;
+struct
+{
+struct Expression * exp;
+struct Statement * stmt;
+} ecere_gcc_struct caseStmt;
+struct
+{
+struct __ecereNameSpace__ecere__sys__OldList * declarations;
+struct __ecereNameSpace__ecere__sys__OldList * statements;
+struct Context * context;
+unsigned int isSwitch;
+} ecere_gcc_struct compound;
+struct
+{
+struct __ecereNameSpace__ecere__sys__OldList * exp;
+struct Statement * stmt;
+struct Statement * elseStmt;
+} ecere_gcc_struct ifStmt;
+struct
+{
+struct __ecereNameSpace__ecere__sys__OldList * exp;
+struct Statement * stmt;
+} ecere_gcc_struct switchStmt;
+struct
+{
+struct __ecereNameSpace__ecere__sys__OldList * exp;
+struct Statement * stmt;
+} ecere_gcc_struct whileStmt;
+struct
+{
+struct __ecereNameSpace__ecere__sys__OldList * exp;
+struct Statement * stmt;
+} ecere_gcc_struct doWhile;
+struct
+{
+struct Statement * init;
+struct Statement * check;
+struct __ecereNameSpace__ecere__sys__OldList * increment;
+struct Statement * stmt;
+} ecere_gcc_struct forStmt;
+struct
+{
+struct Identifier * id;
+} ecere_gcc_struct gotoStmt;
+struct
+{
+struct Specifier * spec;
+char * statements;
+struct __ecereNameSpace__ecere__sys__OldList * inputFields;
+struct __ecereNameSpace__ecere__sys__OldList * outputFields;
+struct __ecereNameSpace__ecere__sys__OldList * clobberedFields;
+} ecere_gcc_struct asmStmt;
+struct
+{
+struct Expression * watcher;
+struct Expression * object;
+struct __ecereNameSpace__ecere__sys__OldList * watches;
+} ecere_gcc_struct _watch;
+struct
+{
+struct Identifier * id;
+struct __ecereNameSpace__ecere__sys__OldList * exp;
+struct __ecereNameSpace__ecere__sys__OldList * filter;
+struct Statement * stmt;
+} ecere_gcc_struct forEachStmt;
+struct Declaration * decl;
+} ecere_gcc_struct __anon1;
+} ecere_gcc_struct;
 
-extern void __ecereNameSpace__ecere__com__eInstance_IncRef(struct __ecereNameSpace__ecere__com__Instance * instance);
+extern struct Statement * MkExpressionStmt(struct __ecereNameSpace__ecere__sys__OldList * expressions);
 
-extern void __ecereNameSpace__ecere__com__eInstance_StopWatching(struct __ecereNameSpace__ecere__com__Instance * instance, struct __ecereNameSpace__ecere__com__Property * _property, struct __ecereNameSpace__ecere__com__Instance * object);
+extern struct Statement * MkCompoundStmt(struct __ecereNameSpace__ecere__sys__OldList * declarations, struct __ecereNameSpace__ecere__sys__OldList * statements);
 
-extern void __ecereNameSpace__ecere__com__eInstance_Watch(void *  instance, struct __ecereNameSpace__ecere__com__Property * _property, void *  object, void (*  callback)(void * , void * ));
+extern void ProcessClassFunctionBody(struct ClassFunction * func, struct Statement * body);
 
-extern void __ecereNameSpace__ecere__com__eInstance_FireWatchers(struct __ecereNameSpace__ecere__com__Instance * instance, struct __ecereNameSpace__ecere__com__Property * _property);
+extern struct Statement * MkReturnStmt(struct __ecereNameSpace__ecere__sys__OldList * exp);
 
-extern struct __ecereNameSpace__ecere__com__Class * __ecereClass___ecereNameSpace__ecere__com__Instance;
+struct __ecereNameSpace__ecere__sys__BinaryTree;
 
-struct __ecereNameSpace__ecere__com__Instance
+struct __ecereNameSpace__ecere__sys__BinaryTree
 {
-int (* *  _vTbl)();
-struct __ecereNameSpace__ecere__com__Class * _class;
-int _refCount;
-} __attribute__ ((gcc_struct));
+struct __ecereNameSpace__ecere__sys__BTNode * root;
+int count;
+int (*  CompareKey)(struct __ecereNameSpace__ecere__sys__BinaryTree * tree, uintptr_t a, uintptr_t b);
+void (*  FreeKey)(void *  key);
+} ecere_gcc_struct;
+
+struct __ecereNameSpace__ecere__sys__BTNode * __ecereMethod___ecereNameSpace__ecere__sys__BinaryTree_FindString(struct __ecereNameSpace__ecere__sys__BinaryTree * this, const char *  key);
+
+unsigned int __ecereMethod___ecereNameSpace__ecere__sys__BinaryTree_Add(struct __ecereNameSpace__ecere__sys__BinaryTree * this, struct __ecereNameSpace__ecere__sys__BTNode * node);
 
-extern struct __ecereNameSpace__ecere__com__Class * __ecereClass___ecereNameSpace__ecere__com__DataMember;
+struct __ecereNameSpace__ecere__com__DataMember;
+
+struct __ecereNameSpace__ecere__com__ClassTemplateArgument
+{
+union
+{
+struct
+{
+const char *  dataTypeString;
+struct __ecereNameSpace__ecere__com__Class * dataTypeClass;
+} ecere_gcc_struct __anon1;
+struct __ecereNameSpace__ecere__com__DataValue expression;
+struct
+{
+const char *  memberString;
+union
+{
+struct __ecereNameSpace__ecere__com__DataMember * member;
+struct __ecereNameSpace__ecere__com__Property * prop;
+struct __ecereNameSpace__ecere__com__Method * method;
+} ecere_gcc_struct __anon1;
+} ecere_gcc_struct __anon2;
+} ecere_gcc_struct __anon1;
+} ecere_gcc_struct;
 
 struct __ecereNameSpace__ecere__com__DataMember
 {
@@ -883,132 +902,247 @@ int memberID;
 struct __ecereNameSpace__ecere__sys__OldList members;
 struct __ecereNameSpace__ecere__sys__BinaryTree membersAlpha;
 int memberOffset;
-int structAlignment;
-} __attribute__ ((gcc_struct));
+short structAlignment;
+short pointerAlignment;
+} ecere_gcc_struct;
 
-extern struct __ecereNameSpace__ecere__com__Class * __ecereClass___ecereNameSpace__ecere__com__SerialBuffer;
+extern struct __ecereNameSpace__ecere__com__DataMember * __ecereNameSpace__ecere__com__eClass_AddDataMember(struct __ecereNameSpace__ecere__com__Class * _class, const char *  name, const char *  type, unsigned int size, unsigned int alignment, int declMode);
 
-struct __ecereNameSpace__ecere__com__SerialBuffer
+struct __ecereNameSpace__ecere__com__Module;
+
+extern unsigned int ModuleAccess(struct __ecereNameSpace__ecere__com__Instance * searchIn, struct __ecereNameSpace__ecere__com__Instance * searchFor);
+
+extern struct __ecereNameSpace__ecere__com__Instance * privateModule;
+
+extern struct __ecereNameSpace__ecere__com__DataMember * __ecereNameSpace__ecere__com__eClass_FindDataMember(struct __ecereNameSpace__ecere__com__Class * _class, const char *  name, struct __ecereNameSpace__ecere__com__Instance * module, struct __ecereNameSpace__ecere__com__DataMember **  subMemberStack, int *  subMemberStackPos);
+
+extern struct __ecereNameSpace__ecere__com__Class * __ecereNameSpace__ecere__com__eSystem_FindClass(struct __ecereNameSpace__ecere__com__Instance * module, const char *  name);
+
+extern struct __ecereNameSpace__ecere__com__Property * __ecereNameSpace__ecere__com__eClass_FindProperty(struct __ecereNameSpace__ecere__com__Class * _class, const char *  name, struct __ecereNameSpace__ecere__com__Instance * module);
+
+extern struct __ecereNameSpace__ecere__com__Method * __ecereNameSpace__ecere__com__eClass_FindMethod(struct __ecereNameSpace__ecere__com__Class * _class, const char *  name, struct __ecereNameSpace__ecere__com__Instance * module);
+
+extern struct __ecereNameSpace__ecere__com__GlobalFunction * __ecereNameSpace__ecere__com__eSystem_RegisterFunction(const char *  name, const char *  type, void *  func, struct __ecereNameSpace__ecere__com__Instance * module, int declMode);
+
+struct TypeName;
+
+struct TypeName
 {
-unsigned char *  _buffer;
-unsigned int count;
-unsigned int _size;
-unsigned int pos;
-} __attribute__ ((gcc_struct));
+struct TypeName * prev;
+struct TypeName * next;
+struct Location loc;
+struct __ecereNameSpace__ecere__sys__OldList *  qualifiers;
+struct Declarator * declarator;
+int classObjectType;
+struct Expression * bitCount;
+} ecere_gcc_struct;
 
-extern struct __ecereNameSpace__ecere__com__Class * __ecereClass___ecereNameSpace__ecere__com__ClassTemplateArgument;
+extern struct TypeName * MkTypeName(struct __ecereNameSpace__ecere__sys__OldList * qualifiers, struct Declarator * declarator);
 
-struct __ecereNameSpace__ecere__com__ClassTemplateArgument
+extern struct Expression * MkExpCast(struct TypeName * typeName, struct Expression * expression);
+
+struct ClassDef;
+
+extern struct ClassDef * MkClassDefDeclaration(struct Declaration * decl);
+
+extern struct ClassDef * MkClassDefFunction(struct ClassFunction * function);
+
+struct ClassDefinition;
+
+struct Context
+{
+struct Context * parent;
+struct __ecereNameSpace__ecere__sys__BinaryTree types;
+struct __ecereNameSpace__ecere__sys__BinaryTree classes;
+struct __ecereNameSpace__ecere__sys__BinaryTree symbols;
+struct __ecereNameSpace__ecere__sys__BinaryTree structSymbols;
+int nextID;
+int simpleID;
+struct __ecereNameSpace__ecere__sys__BinaryTree templateTypes;
+struct ClassDefinition * classDef;
+unsigned int templateTypesOnly;
+unsigned int hasNameSpace;
+} ecere_gcc_struct;
+
+struct ClassDefinition
+{
+struct ClassDefinition * prev;
+struct ClassDefinition * next;
+struct Location loc;
+struct Specifier * _class;
+struct __ecereNameSpace__ecere__sys__OldList *  baseSpecs;
+struct __ecereNameSpace__ecere__sys__OldList *  definitions;
+struct Symbol * symbol;
+struct Location blockStart;
+struct Location nameLoc;
+int declMode;
+unsigned int deleteWatchable;
+} ecere_gcc_struct;
+
+struct Instantiation;
+
+struct Expression
 {
+struct Expression * prev;
+struct Expression * next;
+struct Location loc;
+int type;
 union
 {
 struct
 {
-const char *  dataTypeString;
-struct __ecereNameSpace__ecere__com__Class * dataTypeClass;
-} __attribute__ ((gcc_struct)) __anon1;
-struct __ecereNameSpace__ecere__com__DataValue expression;
+char *  constant;
+struct Identifier * identifier;
+} ecere_gcc_struct __anon1;
+struct Statement * compound;
+struct Instantiation * instance;
 struct
 {
-const char *  memberString;
-union
-{
-struct __ecereNameSpace__ecere__com__DataMember * member;
-struct __ecereNameSpace__ecere__com__Property * prop;
-struct __ecereNameSpace__ecere__com__Method * method;
-} __attribute__ ((gcc_struct)) __anon1;
-} __attribute__ ((gcc_struct)) __anon2;
-} __attribute__ ((gcc_struct)) __anon1;
-} __attribute__ ((gcc_struct));
-
-enum yytokentype
+char *  string;
+unsigned int intlString;
+unsigned int wideString;
+} ecere_gcc_struct __anon2;
+struct __ecereNameSpace__ecere__sys__OldList *  list;
+struct
 {
-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, BOOL = 367, _BOOL = 368, _COMPLEX = 369, _IMAGINARY = 370, RESTRICT = 371, THREAD = 372
-};
-
-typedef union YYSTYPE
+struct __ecereNameSpace__ecere__sys__OldList * specifiers;
+struct Declarator * decl;
+} ecere_gcc_struct _classExp;
+struct
 {
-int specifierType;
-int i;
-int declMode;
 struct Identifier * id;
+} ecere_gcc_struct classData;
+struct
+{
 struct Expression * exp;
-struct Specifier * specifier;
-struct __ecereNameSpace__ecere__sys__OldList * list;
-struct Enumerator * enumerator;
-struct Declarator * declarator;
-struct Pointer * pointer;
+struct __ecereNameSpace__ecere__sys__OldList * arguments;
+struct Location argLoc;
+} ecere_gcc_struct call;
+struct
+{
+struct Expression * exp;
+struct __ecereNameSpace__ecere__sys__OldList * index;
+} ecere_gcc_struct index;
+struct
+{
+struct Expression * exp;
+struct Identifier * member;
+int memberType;
+unsigned int thisPtr;
+} ecere_gcc_struct member;
+struct
+{
+int op;
+struct Expression * exp1;
+struct Expression * exp2;
+} ecere_gcc_struct op;
+struct TypeName * typeName;
+struct Specifier * _class;
+struct
+{
+struct TypeName * typeName;
+struct Expression * exp;
+} ecere_gcc_struct cast;
+struct
+{
+struct Expression * cond;
+struct __ecereNameSpace__ecere__sys__OldList * exp;
+struct Expression * elseExp;
+} ecere_gcc_struct cond;
+struct
+{
+struct TypeName * typeName;
+struct Expression * size;
+} ecere_gcc_struct _new;
+struct
+{
+struct TypeName * typeName;
+struct Expression * size;
+struct Expression * exp;
+} ecere_gcc_struct _renew;
+struct
+{
+char * table;
+struct Identifier * id;
+} ecere_gcc_struct db;
+struct
+{
+struct Expression * ds;
+struct Expression * name;
+} ecere_gcc_struct dbopen;
+struct
+{
+struct TypeName * typeName;
 struct Initializer * initializer;
-struct InitDeclarator * initDeclarator;
+} ecere_gcc_struct initializer;
+struct
+{
+struct Expression * exp;
 struct TypeName * typeName;
-struct Declaration * declaration;
-struct Statement * stmt;
-struct FunctionDefinition * function;
-struct External * external;
-struct Context * context;
-struct AsmField * asmField;
-struct Attrib * attrib;
-struct ExtDecl * extDecl;
-struct Attribute * attribute;
-struct Instantiation * instance;
-struct MembersInit * membersInit;
-struct MemberInit * memberInit;
-struct ClassFunction * classFunction;
-struct ClassDefinition * _class;
-struct ClassDef * classDef;
-struct PropertyDef * prop;
-char * string;
-struct Symbol * symbol;
-struct PropertyWatch * propertyWatch;
-struct TemplateParameter * templateParameter;
-struct TemplateArgument * templateArgument;
-struct TemplateDatatype * templateDatatype;
-struct DBTableEntry * dbtableEntry;
-struct DBIndexItem * dbindexItem;
-struct DBTableDef * dbtableDef;
-} __attribute__ ((gcc_struct)) YYSTYPE;
-
-extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_Enumerator;
-
-struct Enumerator;
-
-extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_InitDeclarator;
-
-struct InitDeclarator;
-
-extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_AsmField;
-
-struct AsmField;
-
-extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_Attribute;
-
-struct Attribute;
+} ecere_gcc_struct vaArg;
+} ecere_gcc_struct __anon1;
+unsigned int debugValue;
+struct __ecereNameSpace__ecere__com__DataValue val;
+uint64 address;
+unsigned int hasAddress;
+struct Type * expType;
+struct Type * destType;
+unsigned int usage;
+int tempCount;
+unsigned int byReference;
+unsigned int isConstant;
+unsigned int addedThis;
+unsigned int needCast;
+unsigned int thisPtr;
+unsigned int opDestType;
+unsigned int needTemplateCast;
+} ecere_gcc_struct;
 
-extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_ClassFunction;
+struct Instantiation
+{
+struct Instantiation * prev;
+struct Instantiation * next;
+struct Location loc;
+struct Specifier * _class;
+struct Expression * exp;
+struct __ecereNameSpace__ecere__sys__OldList *  members;
+struct Symbol * symbol;
+unsigned int fullSet;
+unsigned int isConstant;
+unsigned char *  data;
+struct Location nameLoc;
+struct Location insideLoc;
+unsigned int built;
+} ecere_gcc_struct;
 
-struct ClassFunction
+struct Declaration
+{
+struct Declaration * prev;
+struct Declaration * next;
+struct Location loc;
+int type;
+union
+{
+struct
 {
-struct ClassFunction * prev;
-struct ClassFunction * next;
-struct Location loc;
 struct __ecereNameSpace__ecere__sys__OldList *  specifiers;
-struct Declarator * declarator;
-struct __ecereNameSpace__ecere__sys__OldList *  declarations;
-struct Statement * body;
-struct __ecereNameSpace__ecere__com__Class * _class;
-struct __ecereNameSpace__ecere__sys__OldList attached;
+struct __ecereNameSpace__ecere__sys__OldList *  declarators;
+} ecere_gcc_struct __anon1;
+struct Instantiation * inst;
+struct
+{
+struct Identifier * id;
+struct Expression * exp;
+} ecere_gcc_struct __anon2;
+} ecere_gcc_struct __anon1;
+struct Specifier * extStorage;
+struct Symbol * symbol;
 int declMode;
-struct Type * type;
-struct Symbol * propSet;
-unsigned int isVirtual;
-unsigned int isConstructor;
-unsigned int isDestructor;
-unsigned int dontMangle;
-int id;
-int idCode;
-} __attribute__ ((gcc_struct));
+} ecere_gcc_struct;
 
-extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_MembersInit;
+extern struct Expression * MkExpInstance(struct Instantiation * inst);
+
+struct MembersInit;
 
 struct MembersInit
 {
@@ -1020,10 +1154,10 @@ union
 {
 struct __ecereNameSpace__ecere__sys__OldList *  dataMembers;
 struct ClassFunction * function;
-} __attribute__ ((gcc_struct)) __anon1;
-} __attribute__ ((gcc_struct));
+} ecere_gcc_struct __anon1;
+} ecere_gcc_struct;
 
-extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_MemberInit;
+struct MemberInit;
 
 struct MemberInit
 {
@@ -1036,285 +1170,96 @@ struct Initializer * initializer;
 unsigned int used;
 unsigned int variable;
 unsigned int takeOutExp;
-} __attribute__ ((gcc_struct));
-
-extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_PropertyDef;
-
-struct PropertyDef
-{
-struct PropertyDef * prev;
-struct PropertyDef * next;
-struct Location loc;
-struct __ecereNameSpace__ecere__sys__OldList *  specifiers;
-struct Declarator * declarator;
-struct Identifier * id;
-struct Statement * getStmt;
-struct Statement * setStmt;
-struct Statement * issetStmt;
-struct Symbol * symbol;
-struct Expression * category;
-struct
-{
-unsigned int conversion : 1;
-unsigned int isWatchable : 1;
-unsigned int isDBProp : 1;
-} __attribute__ ((gcc_struct)) __anon1;
-} __attribute__ ((gcc_struct));
-
-extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_PropertyWatch;
-
-struct PropertyWatch;
-
-extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_ClassDef;
-
-struct ClassDef
-{
-struct ClassDef * prev;
-struct ClassDef * next;
-struct Location loc;
-int type;
-union
-{
-struct Declaration * decl;
-struct ClassFunction * function;
-struct __ecereNameSpace__ecere__sys__OldList *  defProperties;
-struct PropertyDef * propertyDef;
-struct PropertyWatch * propertyWatch;
-char *  designer;
-struct Identifier * defaultProperty;
-struct
-{
-struct Identifier * id;
-struct Initializer * initializer;
-} __attribute__ ((gcc_struct)) __anon1;
-} __attribute__ ((gcc_struct)) __anon1;
-int memberAccess;
-void *  object;
-} __attribute__ ((gcc_struct));
-
-extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_DBTableEntry;
-
-struct DBTableEntry;
-
-extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_DBIndexItem;
-
-struct DBIndexItem;
-
-extern YYSTYPE yylval;
+} ecere_gcc_struct;
 
-extern struct Location yylloc;
-
-extern struct External * curExternal;
-
-extern char *  strcat(char * , const char * );
-
-extern size_t strlen(const char * );
-
-extern int strncmp(const char * , const char * , size_t n);
-
-void FullClassNameCat(char * output, const char * className, unsigned int includeTemplateParams)
-{
-int c;
-char ch;
-int len;
+static void CheckPublicExpression(struct Expression *  exp, int access);
 
-for(c = 0; (ch = className[c]) && ch != '<'; c++)
+static void CheckPublicInitializer(struct Initializer * init, int access)
 {
-if(ch == ':')
+switch(init->type)
 {
-strcat(output, "__ecereNameSpace__");
+case 0:
+CheckPublicExpression(init->__anon1.exp, access);
 break;
-}
-}
-len = strlen(output);
-c = 0;
-if(!strncmp(className, "const ", 6))
-c += 6;
-for(; (ch = className[c]); c++)
-{
-if(ch == ':')
-output[len++] = '_';
-else if(ch == ' ')
-output[len++] = '_';
-else if(ch == '*')
-{
-output[len++] = '_';
-output[len++] = 'P';
-output[len++] = 'T';
-output[len++] = 'R';
-output[len++] = '_';
-}
-else if(ch == '=')
-{
-output[len++] = '_';
-output[len++] = 'E';
-output[len++] = 'Q';
-output[len++] = 'U';
-output[len++] = '_';
-}
-else if(ch == '<')
+case 1:
 {
-if(!includeTemplateParams)
+struct Initializer * i;
+
+for(i = (*init->__anon1.list).first; i; i = i->next)
+CheckPublicInitializer(i, access);
 break;
-if(!strncmp(className + c + 1, "const ", 6))
-c += 6;
-output[len++] = '_';
-output[len++] = 'T';
-output[len++] = 'P';
-output[len++] = 'L';
-output[len++] = '_';
 }
-else if(ch == '>')
-{
-output[len++] = '_';
-}
-else if(ch == ',')
-{
-if(!strncmp(className + c + 1, "const ", 6))
-c += 6;
-output[len++] = '_';
-}
-else
-output[len++] = ch;
 }
-output[len++] = (char)0;
-}
-
-extern int AddMembers(struct __ecereNameSpace__ecere__sys__OldList *  declarations, struct __ecereNameSpace__ecere__com__Class * _class, unsigned int isMember, unsigned int *  retSize, struct __ecereNameSpace__ecere__com__Class * topClass, unsigned int *  addedPadding);
-
-static void AddSimpleBaseMembers(struct __ecereNameSpace__ecere__sys__OldList * list, struct __ecereNameSpace__ecere__com__Class * _class, struct __ecereNameSpace__ecere__com__Class * topClass)
-{
-if(_class->type != 1000)
-AddMembers(list, _class, 0, (((void *)0)), topClass, (((void *)0)));
 }
 
-extern struct __ecereNameSpace__ecere__com__Class * __ecereClass___ecereNameSpace__ecere__com__NameSpace;
-
-struct __ecereNameSpace__ecere__com__NameSpace
-{
-const char *  name;
-struct __ecereNameSpace__ecere__com__NameSpace *  btParent;
-struct __ecereNameSpace__ecere__com__NameSpace *  left;
-struct __ecereNameSpace__ecere__com__NameSpace *  right;
-int depth;
-struct __ecereNameSpace__ecere__com__NameSpace *  parent;
-struct __ecereNameSpace__ecere__sys__BinaryTree nameSpaces;
-struct __ecereNameSpace__ecere__sys__BinaryTree classes;
-struct __ecereNameSpace__ecere__sys__BinaryTree defines;
-struct __ecereNameSpace__ecere__sys__BinaryTree functions;
-} __attribute__ ((gcc_struct));
+static void CheckPublicClass(struct Symbol *  classSym, int access, const char *  word);
 
-static unsigned int NameSpaceContained(struct __ecereNameSpace__ecere__com__NameSpace * ns, struct __ecereNameSpace__ecere__com__NameSpace * parent)
+static void CheckPublicTypeName(struct TypeName * type, int access)
 {
-if(ns == parent)
-return 1;
-else if((*ns).parent)
-return NameSpaceContained((*ns).parent, parent);
-else
-return 0;
-}
-
-extern void Compiler_Error(const char *  format, ...);
-
-extern const char *  __ecereNameSpace__ecere__GetTranslatedString(const char * name, const char *  string, const char *  stringAndContext);
-
-extern struct __ecereNameSpace__ecere__com__Class * __ecereClass___ecereNameSpace__ecere__com__Module;
-
-struct __ecereNameSpace__ecere__com__Module
+if(type->qualifiers)
 {
-struct __ecereNameSpace__ecere__com__Instance * application;
-struct __ecereNameSpace__ecere__sys__OldList classes;
-struct __ecereNameSpace__ecere__sys__OldList defines;
-struct __ecereNameSpace__ecere__sys__OldList functions;
-struct __ecereNameSpace__ecere__sys__OldList modules;
-struct __ecereNameSpace__ecere__com__Instance * prev;
-struct __ecereNameSpace__ecere__com__Instance * next;
-const char *  name;
-void *  library;
-void *  Unload;
-int importType;
-int origImportType;
-struct __ecereNameSpace__ecere__com__NameSpace privateNameSpace;
-struct __ecereNameSpace__ecere__com__NameSpace publicNameSpace;
-} __attribute__ ((gcc_struct));
-
-extern struct __ecereNameSpace__ecere__com__Class * __ecereClass___ecereNameSpace__ecere__com__Application;
+struct Specifier * spec;
 
-struct __ecereNameSpace__ecere__com__Application
+for(spec = (*type->qualifiers).first; spec; spec = spec->next)
 {
-int argc;
-const char * *  argv;
-int exitCode;
-unsigned int isGUIApp;
-struct __ecereNameSpace__ecere__sys__OldList allModules;
-char *  parsedCommand;
-struct __ecereNameSpace__ecere__com__NameSpace systemNameSpace;
-} __attribute__ ((gcc_struct));
-
-extern unsigned int ModuleAccess(struct __ecereNameSpace__ecere__com__Instance * searchIn, struct __ecereNameSpace__ecere__com__Instance * searchFor);
-
-extern struct __ecereNameSpace__ecere__com__Instance * privateModule;
-
-static void CheckPublicClass(struct Symbol * classSym, int access, const char * word)
+if(spec->type == 1)
 {
-struct __ecereNameSpace__ecere__com__Class * regClass = classSym ? classSym->__anon1.registered : (((void *)0));
+struct Symbol * classSym = spec->__anon1.__anon1.symbol;
 
-if(regClass)
-{
-if(regClass->templateClass)
-regClass = regClass->templateClass;
-if(classSym->isStatic && access != 3)
-{
-Compiler_Error(__ecereNameSpace__ecere__GetTranslatedString("ec", "Non-static %s making use of a static class\n", (((void *)0))), word);
-}
-else if(access == 1)
-{
-if(!NameSpaceContained(regClass->nameSpace, &((struct __ecereNameSpace__ecere__com__Application *)(((char *)((struct __ecereNameSpace__ecere__com__Module *)(((char *)regClass->module + structSize_Instance)))->application + structSize_Module)))->systemNameSpace))
-{
-if(NameSpaceContained(regClass->nameSpace, &((struct __ecereNameSpace__ecere__com__Module *)(((char *)regClass->module + structSize_Instance)))->privateNameSpace) || !ModuleAccess(privateModule, regClass->module))
-Compiler_Error(__ecereNameSpace__ecere__GetTranslatedString("ec", "Public %s making use of a private class\n", (((void *)0))), word);
+CheckPublicClass(classSym, access, "define");
 }
 }
 }
 }
 
-static void CheckPublicTypeName(struct TypeName * type, int access)
+static void CheckPublicDataType(struct Type * type, int access, const char * word)
 {
-if(type->qualifiers)
+if(type)
 {
-struct Specifier * spec;
-
-for(spec = (*type->qualifiers).first; spec; spec = spec->next)
+switch(type->kind)
+{
+case 8:
+{
+CheckPublicClass(type->__anon1._class, access, word);
+break;
+}
+case 9:
+case 10:
 {
-if(spec->type == 1)
+break;
+}
+case 11:
 {
-struct Symbol * classSym = spec->__anon1.__anon1.symbol;
+struct Type * param;
 
-CheckPublicClass(classSym, access, "define");
-}
-}
-}
+CheckPublicDataType(type->__anon1.__anon2.returnType, access, word);
+for(param = type->__anon1.__anon2.params.first; param; param = param->next)
+CheckPublicDataType(param, access, word);
+CheckPublicClass(type->__anon1.__anon2.thisClass, access, word);
+break;
 }
-
-static void CheckPublicExpression(struct Expression * exp, int access);
-
-static void CheckPublicInitializer(struct Initializer * init, int access)
+case 12:
+CheckPublicDataType(type->__anon1.__anon4.arrayType, access, word);
+if(type->__anon1.__anon4.enumClass)
+CheckPublicClass(type->__anon1.__anon4.enumClass, access, word);
+break;
+case 13:
 {
-switch(init->type)
+CheckPublicDataType(type->__anon1.type, access, word);
+break;
+}
+case 16:
 {
-case 0:
-CheckPublicExpression(init->__anon1.exp, access);
 break;
-case 1:
+}
+case 19:
 {
-struct Initializer * i;
-
-for(i = (*init->__anon1.list).first; i; i = i->next)
-CheckPublicInitializer(i, access);
+CheckPublicClass(type->__anon1._class, access, word);
 break;
 }
 }
 }
+}
 
 static void CheckPublicExpression(struct Expression * exp, int access)
 {
@@ -1425,72 +1370,53 @@ break;
 }
 }
 
-static void CheckPublicDataType(struct Type * type, int access, const char * word)
-{
-if(type)
-{
-switch(type->kind)
-{
-case 8:
-{
-CheckPublicClass(type->__anon1._class, access, word);
-break;
-}
-case 9:
-case 10:
-{
-break;
-}
-case 11:
-{
-struct Type * param;
+struct PropertyDef;
 
-CheckPublicDataType(type->__anon1.__anon2.returnType, access, word);
-for(param = type->__anon1.__anon2.params.first; param; param = param->next)
-CheckPublicDataType(param, access, word);
-CheckPublicClass(type->__anon1.__anon2.thisClass, access, word);
-break;
-}
-case 12:
-CheckPublicDataType(type->__anon1.__anon4.arrayType, access, word);
-if(type->__anon1.__anon4.enumClass)
-CheckPublicClass(type->__anon1.__anon4.enumClass, access, word);
-break;
-case 13:
+struct ClassDef
 {
-CheckPublicDataType(type->__anon1.type, access, word);
-break;
-}
-case 16:
+struct ClassDef * prev;
+struct ClassDef * next;
+struct Location loc;
+int type;
+union
 {
-break;
-}
-case 19:
+struct Declaration * decl;
+struct ClassFunction * function;
+struct __ecereNameSpace__ecere__sys__OldList *  defProperties;
+struct PropertyDef * propertyDef;
+struct PropertyWatch * propertyWatch;
+char *  designer;
+struct Identifier * defaultProperty;
+struct
 {
-CheckPublicClass(type->__anon1._class, access, word);
-break;
-}
-}
-}
-}
-
-extern struct Identifier * GetDeclId(struct Declarator * decl);
-
-extern struct __ecereNameSpace__ecere__com__Class * __ecereClass___ecereNameSpace__ecere__com__BTNamedLink;
+struct Identifier * id;
+struct Initializer * initializer;
+} ecere_gcc_struct __anon1;
+} ecere_gcc_struct __anon1;
+int memberAccess;
+void *  object;
+} ecere_gcc_struct;
 
-struct __ecereNameSpace__ecere__com__BTNamedLink
+struct PropertyDef
 {
-const char *  name;
-struct __ecereNameSpace__ecere__com__BTNamedLink * parent;
-struct __ecereNameSpace__ecere__com__BTNamedLink * left;
-struct __ecereNameSpace__ecere__com__BTNamedLink * right;
-int depth;
-void *  data;
-} __attribute__ ((gcc_struct));
-
-extern struct __ecereNameSpace__ecere__com__DataMember * __ecereNameSpace__ecere__com__eClass_FindDataMember(struct __ecereNameSpace__ecere__com__Class * _class, const char *  name, struct __ecereNameSpace__ecere__com__Instance * module, struct __ecereNameSpace__ecere__com__DataMember **  subMemberStack, int *  subMemberStackPos);
-
-struct __ecereNameSpace__ecere__sys__BTNode * __ecereMethod___ecereNameSpace__ecere__sys__BinaryTree_FindString(struct __ecereNameSpace__ecere__sys__BinaryTree * this, const char *  key);
+struct PropertyDef * prev;
+struct PropertyDef * next;
+struct Location loc;
+struct __ecereNameSpace__ecere__sys__OldList *  specifiers;
+struct Declarator * declarator;
+struct Identifier * id;
+struct Statement * getStmt;
+struct Statement * setStmt;
+struct Statement * issetStmt;
+struct Symbol * symbol;
+struct Expression * category;
+struct
+{
+unsigned int conversion : 1;
+unsigned int isWatchable : 1;
+unsigned int isDBProp : 1;
+} ecere_gcc_struct __anon1;
+} ecere_gcc_struct;
 
 static void CheckMembersDefinitions(struct __ecereNameSpace__ecere__com__Class * regClass, struct __ecereNameSpace__ecere__com__DataMember * member, struct __ecereNameSpace__ecere__sys__OldList * definitions, int access)
 {
@@ -1557,173 +1483,264 @@ if(dataMember)
 CheckPublicDataType(dataMember->dataType, (def->memberAccess == 2) ? 2 : access, __ecereNameSpace__ecere__GetTranslatedString("ec", "class data member", (((void *)0))));
 }
 }
-}
-}
-}
-else if(decl->type == 2)
-{
-CheckPublicClass(decl->__anon1.inst->_class->__anon1.__anon1.symbol, (def->memberAccess == 2) ? 2 : access, __ecereNameSpace__ecere__GetTranslatedString("ec", "class member instance", (((void *)0))));
-}
-}
-}
-}
-}
-
-extern unsigned int inCompiler;
-
-extern struct __ecereNameSpace__ecere__sys__OldList *  MkList(void);
-
-extern struct __ecereNameSpace__ecere__com__Class * __ecereNameSpace__ecere__com__eSystem_FindClass(struct __ecereNameSpace__ecere__com__Instance * module, const char *  name);
-
-extern struct Symbol * FindClass(const char *  name);
-
-extern struct __ecereNameSpace__ecere__com__Property * __ecereNameSpace__ecere__com__eClass_FindProperty(struct __ecereNameSpace__ecere__com__Class * _class, const char *  name, struct __ecereNameSpace__ecere__com__Instance * module);
-
-extern struct __ecereNameSpace__ecere__com__Property * __ecereNameSpace__ecere__com__eClass_AddProperty(struct __ecereNameSpace__ecere__com__Class * _class, const char *  name, const char *  dataType, void *  setStmt, void *  getStmt, int declMode);
-
-extern struct __ecereNameSpace__ecere__com__DataMember * __ecereNameSpace__ecere__com__eClass_AddDataMember(struct __ecereNameSpace__ecere__com__Class * _class, const char *  name, const char *  type, unsigned int size, unsigned int alignment, int declMode);
-
-extern struct __ecereNameSpace__ecere__com__Method * __ecereNameSpace__ecere__com__eClass_FindMethod(struct __ecereNameSpace__ecere__com__Class * _class, const char *  name, struct __ecereNameSpace__ecere__com__Instance * module);
-
-extern struct __ecereNameSpace__ecere__com__Method * __ecereNameSpace__ecere__com__eClass_AddMethod(struct __ecereNameSpace__ecere__com__Class * _class, const char *  name, const char *  type, void *  function, int declMode);
-
-extern struct External * MkExternalDeclaration(struct Declaration * declaration);
-
-extern void ListAdd(struct __ecereNameSpace__ecere__sys__OldList * list, void *  item);
-
-extern struct ClassDef * MkClassDefDeclaration(struct Declaration * decl);
-
-extern struct Specifier * MkSpecifierName(const char *  name);
-
-extern struct Declarator * MkDeclaratorIdentifier(struct Identifier * id);
-
-extern struct Identifier * MkIdentifier(const char *  string);
-
-extern struct Declaration * MkStructDeclaration(struct __ecereNameSpace__ecere__sys__OldList * specifiers, struct __ecereNameSpace__ecere__sys__OldList * declarators, struct Specifier * extStorage);
-
-extern struct Expression * QMkExpId(const char *  id);
-
-extern void FreeDeclarator(struct Declarator * decl);
-
-extern void FreeList(struct __ecereNameSpace__ecere__sys__OldList * list, void (*  FreeFunction)(void * ));
-
-extern void FreeSpecifier(struct Specifier * spec);
-
-extern char *  __ecereNameSpace__ecere__sys__CopyString(const char *  string);
-
-extern struct Type * MkClassType(const char *  name);
-
-extern char *  strcpy(char * , const char * );
-
-extern struct Specifier * MkStructOrUnion(int type, struct Identifier * id, struct __ecereNameSpace__ecere__sys__OldList * definitions);
-
-extern struct __ecereNameSpace__ecere__sys__OldList *  MkListOne(void *  item);
-
-extern struct Declaration * MkDeclaration(struct __ecereNameSpace__ecere__sys__OldList * specifiers, struct __ecereNameSpace__ecere__sys__OldList * initDeclarators);
-
-extern void FreeExternal(struct External * external);
-
-extern int declMode;
-
-extern int structDeclMode;
-
-extern char *  strstr(const char * , const char * );
-
-extern const char *  sourceFile;
-
-extern struct Specifier * MkSpecifier(int specifier);
-
-extern struct InitDeclarator * MkInitDeclarator(struct Declarator * declarator, struct Initializer * initializer);
-
-extern struct Declarator * MkDeclaratorPointer(struct Pointer * pointer, struct Declarator * declarator);
-
-extern struct Pointer * MkPointer(struct __ecereNameSpace__ecere__sys__OldList * qualifiers, struct Pointer * pointer);
-
-extern struct Context * PushContext(void);
-
-extern struct Expression * MkExpOp(struct Expression * exp1, int op, struct Expression * exp2);
-
-extern struct Expression * CopyExpression(struct Expression * exp);
-
-extern struct Statement * MkExpressionStmt(struct __ecereNameSpace__ecere__sys__OldList * expressions);
-
-extern struct Statement * MkCompoundStmt(struct __ecereNameSpace__ecere__sys__OldList * declarations, struct __ecereNameSpace__ecere__sys__OldList * statements);
-
-extern void PopContext(struct Context * ctx);
-
-extern struct Declarator * MkDeclaratorFunction(struct Declarator * declarator, struct __ecereNameSpace__ecere__sys__OldList * parameters);
-
-extern struct __ecereNameSpace__ecere__sys__OldList *  excludedSymbols;
-
-extern struct ClassFunction * MkClassFunction(struct __ecereNameSpace__ecere__sys__OldList * specifiers, struct Specifier * _class, struct Declarator * decl, struct __ecereNameSpace__ecere__sys__OldList * declList);
-
-extern void ProcessClassFunctionBody(struct ClassFunction * func, struct Statement * body);
-
-extern struct ClassDef * MkClassDefFunction(struct ClassFunction * function);
-
-extern struct Specifier * CopySpecifier(struct Specifier * spec);
-
-extern struct Expression * MkExpInstance(struct Instantiation * inst);
-
-extern struct Expression * MkExpCall(struct Expression * expression, struct __ecereNameSpace__ecere__sys__OldList * arguments);
-
-extern struct Expression * MkExpIdentifier(struct Identifier * id);
-
-extern struct Expression * MkExpMember(struct Expression * expression, struct Identifier * member);
-
-extern void FreeInitializer(struct Initializer * initializer);
-
-extern struct Statement * MkReturnStmt(struct __ecereNameSpace__ecere__sys__OldList * exp);
-
-extern struct TypeName * MkTypeName(struct __ecereNameSpace__ecere__sys__OldList * qualifiers, struct Declarator * declarator);
-
-extern struct __ecereNameSpace__ecere__sys__OldList *  CopyList(struct __ecereNameSpace__ecere__sys__OldList *  source, void *  (*  CopyFunction)(void * ));
-
-extern struct Declarator * PlugDeclarator(struct Declarator * decl, struct Declarator * baseDecl);
+}
+}
+}
+else if(decl->type == 2)
+{
+CheckPublicClass(decl->__anon1.inst->_class->__anon1.__anon1.symbol, (def->memberAccess == 2) ? 2 : access, __ecereNameSpace__ecere__GetTranslatedString("ec", "class member instance", (((void *)0))));
+}
+}
+}
+}
+}
 
-extern void Compiler_Warning(const char *  format, ...);
+struct FunctionDefinition;
 
-extern struct Specifier * MkSpecifierExtended(struct ExtDecl * extDecl);
+typedef union YYSTYPE
+{
+int specifierType;
+int i;
+int declMode;
+struct Identifier * id;
+struct Expression * exp;
+struct Specifier * specifier;
+struct __ecereNameSpace__ecere__sys__OldList * list;
+struct Enumerator * enumerator;
+struct Declarator * declarator;
+struct Pointer * pointer;
+struct Initializer * initializer;
+struct InitDeclarator * initDeclarator;
+struct TypeName * typeName;
+struct Declaration * declaration;
+struct Statement * stmt;
+struct FunctionDefinition * function;
+struct External * external;
+struct Context * context;
+struct AsmField * asmField;
+struct Attrib * attrib;
+struct ExtDecl * extDecl;
+struct Attribute * attribute;
+struct Instantiation * instance;
+struct MembersInit * membersInit;
+struct MemberInit * memberInit;
+struct ClassFunction * classFunction;
+struct ClassDefinition * _class;
+struct ClassDef * classDef;
+struct PropertyDef * prop;
+char * string;
+struct Symbol * symbol;
+struct PropertyWatch * propertyWatch;
+struct TemplateParameter * templateParameter;
+struct TemplateArgument * templateArgument;
+struct TemplateDatatype * templateDatatype;
+struct DBTableEntry * dbtableEntry;
+struct DBIndexItem * dbindexItem;
+struct DBTableDef * dbtableDef;
+} ecere_gcc_struct YYSTYPE;
 
-extern struct ExtDecl * MkExtDeclAttrib(struct Attrib * attr);
+extern YYSTYPE yylval;
 
-extern struct Attrib * MkAttrib(int type, struct __ecereNameSpace__ecere__sys__OldList *  attribs);
+struct External
+{
+struct External * prev;
+struct External * next;
+struct Location loc;
+int type;
+struct Symbol * symbol;
+union
+{
+struct FunctionDefinition * function;
+struct ClassDefinition * _class;
+struct Declaration * declaration;
+char *  importString;
+struct Identifier * id;
+struct DBTableDef * table;
+} ecere_gcc_struct __anon1;
+int importType;
+struct External * fwdDecl;
+struct __ecereNameSpace__ecere__com__Instance * outgoing;
+struct __ecereNameSpace__ecere__com__Instance * incoming;
+int nonBreakableIncoming;
+} ecere_gcc_struct;
 
-extern struct Attribute * MkAttribute(char * attr, struct Expression * exp);
+struct FunctionDefinition
+{
+struct FunctionDefinition * prev;
+struct FunctionDefinition * next;
+struct Location loc;
+struct __ecereNameSpace__ecere__sys__OldList *  specifiers;
+struct Declarator * declarator;
+struct __ecereNameSpace__ecere__sys__OldList *  declarations;
+struct Statement * body;
+struct __ecereNameSpace__ecere__com__Class * _class;
+struct __ecereNameSpace__ecere__sys__OldList attached;
+int declMode;
+struct Type * type;
+struct Symbol * propSet;
+int tempCount;
+unsigned int propertyNoThis;
+} ecere_gcc_struct;
 
-extern struct __ecereNameSpace__ecere__sys__OldList *  ast;
+void __ecereMethod_External_CreateUniqueEdge(struct External * this, struct External * from, unsigned int soft);
 
-extern int sprintf(char * , const char * , ...);
+struct __ecereNameSpace__ecere__com__NameSpace;
 
-extern struct Type * ProcessType(struct __ecereNameSpace__ecere__sys__OldList * specs, struct Declarator * decl);
+struct __ecereNameSpace__ecere__com__NameSpace
+{
+const char *  name;
+struct __ecereNameSpace__ecere__com__NameSpace *  btParent;
+struct __ecereNameSpace__ecere__com__NameSpace *  left;
+struct __ecereNameSpace__ecere__com__NameSpace *  right;
+int depth;
+struct __ecereNameSpace__ecere__com__NameSpace *  parent;
+struct __ecereNameSpace__ecere__sys__BinaryTree nameSpaces;
+struct __ecereNameSpace__ecere__sys__BinaryTree classes;
+struct __ecereNameSpace__ecere__sys__BinaryTree defines;
+struct __ecereNameSpace__ecere__sys__BinaryTree functions;
+} ecere_gcc_struct;
 
-extern struct Context * curContext;
+struct __ecereNameSpace__ecere__com__Class
+{
+struct __ecereNameSpace__ecere__com__Class * prev;
+struct __ecereNameSpace__ecere__com__Class * next;
+const char *  name;
+int offset;
+int structSize;
+void * *  _vTbl;
+int vTblSize;
+unsigned int (*  Constructor)(void * );
+void (*  Destructor)(void * );
+int offsetClass;
+int sizeClass;
+struct __ecereNameSpace__ecere__com__Class * base;
+struct __ecereNameSpace__ecere__sys__BinaryTree methods;
+struct __ecereNameSpace__ecere__sys__BinaryTree members;
+struct __ecereNameSpace__ecere__sys__BinaryTree prop;
+struct __ecereNameSpace__ecere__sys__OldList membersAndProperties;
+struct __ecereNameSpace__ecere__sys__BinaryTree classProperties;
+struct __ecereNameSpace__ecere__sys__OldList derivatives;
+int memberID;
+int startMemberID;
+int type;
+struct __ecereNameSpace__ecere__com__Instance * module;
+struct __ecereNameSpace__ecere__com__NameSpace *  nameSpace;
+const char *  dataTypeString;
+struct Type * dataType;
+int typeSize;
+int defaultAlignment;
+void (*  Initialize)();
+int memberOffset;
+struct __ecereNameSpace__ecere__sys__OldList selfWatchers;
+const char *  designerClass;
+unsigned int noExpansion;
+const char *  defaultProperty;
+unsigned int comRedefinition;
+int count;
+int isRemote;
+unsigned int internalDecl;
+void *  data;
+unsigned int computeSize;
+short structAlignment;
+short pointerAlignment;
+int destructionWatchOffset;
+unsigned int fixed;
+struct __ecereNameSpace__ecere__sys__OldList delayedCPValues;
+int inheritanceAccess;
+const char *  fullName;
+void *  symbol;
+struct __ecereNameSpace__ecere__sys__OldList conversions;
+struct __ecereNameSpace__ecere__sys__OldList templateParams;
+struct __ecereNameSpace__ecere__com__ClassTemplateArgument *  templateArgs;
+struct __ecereNameSpace__ecere__com__Class * templateClass;
+struct __ecereNameSpace__ecere__sys__OldList templatized;
+int numParams;
+unsigned int isInstanceClass;
+unsigned int byValueSystemClass;
+} ecere_gcc_struct;
 
-extern struct Initializer * MkInitializerAssignment(struct Expression * exp);
+struct __ecereNameSpace__ecere__com__Application
+{
+int argc;
+const char * *  argv;
+int exitCode;
+unsigned int isGUIApp;
+struct __ecereNameSpace__ecere__sys__OldList allModules;
+char *  parsedCommand;
+struct __ecereNameSpace__ecere__com__NameSpace systemNameSpace;
+} ecere_gcc_struct;
 
-extern struct Expression * MkExpCast(struct TypeName * typeName, struct Expression * expression);
+static unsigned int NameSpaceContained(struct __ecereNameSpace__ecere__com__NameSpace * ns, struct __ecereNameSpace__ecere__com__NameSpace * parent)
+{
+if(ns == parent)
+return 1;
+else if((*ns).parent)
+return NameSpaceContained((*ns).parent, parent);
+else
+return 0;
+}
 
-extern struct Declarator * CopyDeclarator(struct Declarator * declarator);
+static void AddSimpleBaseMembers(struct External * external, struct __ecereNameSpace__ecere__sys__OldList * list, struct __ecereNameSpace__ecere__com__Class * _class, struct __ecereNameSpace__ecere__com__Class * topClass)
+{
+if(_class->type != 1000)
+AddMembers(external, list, _class, 0, (((void *)0)), topClass, (((void *)0)));
+}
 
-extern void FreeType(struct Type * type);
+extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_Symbol;
 
-extern struct Declarator * GetFuncDecl(struct Declarator * decl);
+extern struct __ecereNameSpace__ecere__com__Class * __ecereClass_Instantiation;
 
-extern void ProcessMethodType(struct __ecereNameSpace__ecere__com__Method * method);
+extern struct __ecereNameSpace__ecere__com__Class * __ecereClass___ecereNameSpace__ecere__com__Module;
 
-extern void FreeInitDeclarator(struct InitDeclarator * decl);
+extern struct __ecereNameSpace__ecere__com__Class * __ecereClass___ecereNameSpace__ecere__com__Application;
 
-extern void *  __ecereNameSpace__ecere__com__eInstance_New(struct __ecereNameSpace__ecere__com__Class * _class);
+extern struct __ecereNameSpace__ecere__com__Class * __ecereClass___ecereNameSpace__ecere__com__LinkList;
 
-unsigned int __ecereMethod___ecereNameSpace__ecere__sys__OldList_Insert(struct __ecereNameSpace__ecere__sys__OldList * this, void *  prevItem, void *  item);
+struct __ecereNameSpace__ecere__com__Module
+{
+struct __ecereNameSpace__ecere__com__Instance * application;
+struct __ecereNameSpace__ecere__sys__OldList classes;
+struct __ecereNameSpace__ecere__sys__OldList defines;
+struct __ecereNameSpace__ecere__sys__OldList functions;
+struct __ecereNameSpace__ecere__sys__OldList modules;
+struct __ecereNameSpace__ecere__com__Instance * prev;
+struct __ecereNameSpace__ecere__com__Instance * next;
+const char *  name;
+void *  library;
+void *  Unload;
+int importType;
+int origImportType;
+struct __ecereNameSpace__ecere__com__NameSpace privateNameSpace;
+struct __ecereNameSpace__ecere__com__NameSpace publicNameSpace;
+} ecere_gcc_struct;
 
-unsigned int __ecereMethod___ecereNameSpace__ecere__sys__BinaryTree_Add(struct __ecereNameSpace__ecere__sys__BinaryTree * this, struct __ecereNameSpace__ecere__sys__BTNode * node);
+void __ecereUnregisterModule_pass0(struct __ecereNameSpace__ecere__com__Instance * module)
+{
 
-void __ecereMethod___ecereNameSpace__ecere__sys__OldList_Remove(struct __ecereNameSpace__ecere__sys__OldList * this, void *  item);
+}
 
-void __ecereMethod___ecereNameSpace__ecere__sys__OldList_Add(struct __ecereNameSpace__ecere__sys__OldList * this, void *  item);
+static void CheckPublicClass(struct Symbol * classSym, int access, const char * word)
+{
+struct __ecereNameSpace__ecere__com__Class * regClass = classSym ? classSym->__anon1.registered : (((void *)0));
 
-void __ecereMethod___ecereNameSpace__ecere__sys__OldList_Clear(struct __ecereNameSpace__ecere__sys__OldList * this);
+if(regClass)
+{
+if(regClass->templateClass)
+regClass = regClass->templateClass;
+if(classSym->isStatic && access != 3)
+{
+Compiler_Error(__ecereNameSpace__ecere__GetTranslatedString("ec", "Non-static %s making use of a static class\n", (((void *)0))), word);
+}
+else if(access == 1)
+{
+if(!NameSpaceContained(regClass->nameSpace, &((struct __ecereNameSpace__ecere__com__Application *)(((char *)((struct __ecereNameSpace__ecere__com__Module *)(((char *)regClass->module + sizeof(struct __ecereNameSpace__ecere__com__Instance))))->application + sizeof(struct __ecereNameSpace__ecere__com__Module) + sizeof(struct __ecereNameSpace__ecere__com__Instance))))->systemNameSpace))
+{
+if(NameSpaceContained(regClass->nameSpace, &((struct __ecereNameSpace__ecere__com__Module *)(((char *)regClass->module + sizeof(struct __ecereNameSpace__ecere__com__Instance))))->privateNameSpace) || !ModuleAccess(privateModule, regClass->module))
+Compiler_Error(__ecereNameSpace__ecere__GetTranslatedString("ec", "Public %s making use of a private class\n", (((void *)0))), word);
+}
+}
+}
+}
 
 static void ProcessClass(int classType, struct __ecereNameSpace__ecere__sys__OldList * definitions, struct Symbol * symbol, struct __ecereNameSpace__ecere__sys__OldList * baseSpecs, struct __ecereNameSpace__ecere__sys__OldList * enumValues, struct Location * loc, struct __ecereNameSpace__ecere__sys__OldList * defs, void * after, struct __ecereNameSpace__ecere__sys__OldList * initDeclarators, struct ExtDecl * extDecl)
 {
@@ -1751,7 +1768,7 @@ classType = regClass->type;
 if(inCompiler)
 {
 yylloc = *loc;
-if(!NameSpaceContained(regClass->nameSpace, &((struct __ecereNameSpace__ecere__com__Module *)(((char *)regClass->module + structSize_Instance)))->privateNameSpace) && regClass->inheritanceAccess == 1)
+if(!NameSpaceContained(regClass->nameSpace, &((struct __ecereNameSpace__ecere__com__Module *)(((char *)regClass->module + sizeof(struct __ecereNameSpace__ecere__com__Instance))))->privateNameSpace) && regClass->inheritanceAccess == 1)
 {
 if(!regClass->base->symbol)
 regClass->base->symbol = FindClass(regClass->base->fullName);
@@ -1803,13 +1820,13 @@ curExternal->symbol = symbol;
 }
 if((classType == 1 || classType == 5) && inCompiler)
 {
-AddSimpleBaseMembers(list, regClass->base, regClass);
+AddSimpleBaseMembers(external, list, regClass->base, regClass);
 }
 if(definitions != (((void *)0)))
 {
 if(inCompiler)
 {
-if(!NameSpaceContained(regClass->nameSpace, &((struct __ecereNameSpace__ecere__com__Module *)(((char *)regClass->module + structSize_Instance)))->privateNameSpace))
+if(!NameSpaceContained(regClass->nameSpace, &((struct __ecereNameSpace__ecere__com__Module *)(((char *)regClass->module + sizeof(struct __ecereNameSpace__ecere__com__Instance))))->privateNameSpace))
 CheckMembersDefinitions(regClass, (((void *)0)), definitions, 1);
 else if(!symbol->isStatic)
 CheckMembersDefinitions(regClass, (((void *)0)), definitions, 2);
@@ -1859,7 +1876,7 @@ exp->__anon1.member.thisPtr = 1;
 else
 {
 FreeDeclarator(d);
-FreeList(specifiers, FreeSpecifier);
+FreeList(specifiers, (void *)(FreeSpecifier));
 }
 }
 classSym = inst->_class->__anon1.__anon1.symbol;
@@ -1954,6 +1971,33 @@ spec->__anon1.__anon2.extDeclStruct = extDecl;
 ListAdd(specs, spec);
 }
 external->symbol = symbol;
+if(symbol->__anon2.__anon1.structExternal)
+{
+{
+struct TopoEdge * e;
+struct __ecereNameSpace__ecere__com__Instance * __internalLinkList = symbol->__anon2.__anon1.structExternal->incoming;
+
+for(e = ((struct __ecereNameSpace__ecere__com__LinkList *)(((char *)__internalLinkList + 0 + sizeof(struct __ecereNameSpace__ecere__com__Instance))))->first; e; e = (struct TopoEdge *)((struct __ecereNameSpace__ecere__com__IteratorPointer * (*)(struct __ecereNameSpace__ecere__com__Instance *, struct __ecereNameSpace__ecere__com__IteratorPointer * pointer))__extension__ ({
+struct __ecereNameSpace__ecere__com__Instance * __internal_ClassInst = __internalLinkList;
+
+__internal_ClassInst ? __internal_ClassInst->_vTbl : __ecereClass___ecereNameSpace__ecere__com__LinkList->_vTbl;
+})[__ecereVMethodID___ecereNameSpace__ecere__com__Container_GetNext])(__internalLinkList, (struct __ecereNameSpace__ecere__com__IteratorPointer *)e))
+__ecereMethod_External_CreateUniqueEdge(external, e->from, e->breakable);
+}
+{
+struct TopoEdge * e;
+struct __ecereNameSpace__ecere__com__Instance * __internalLinkList = symbol->__anon2.__anon1.structExternal->outgoing;
+
+for(e = ((struct __ecereNameSpace__ecere__com__LinkList *)(((char *)__internalLinkList + 0 + sizeof(struct __ecereNameSpace__ecere__com__Instance))))->first; e; e = (struct TopoEdge *)((struct __ecereNameSpace__ecere__com__IteratorPointer * (*)(struct __ecereNameSpace__ecere__com__Instance *, struct __ecereNameSpace__ecere__com__IteratorPointer * pointer))__extension__ ({
+struct __ecereNameSpace__ecere__com__Instance * __internal_ClassInst = __internalLinkList;
+
+__internal_ClassInst ? __internal_ClassInst->_vTbl : __ecereClass___ecereNameSpace__ecere__com__LinkList->_vTbl;
+})[__ecereVMethodID___ecereNameSpace__ecere__com__Container_GetNext])(__internalLinkList, (struct __ecereNameSpace__ecere__com__IteratorPointer *)e))
+__ecereMethod_External_CreateUniqueEdge(e->to, external, e->breakable);
+}
+__ecereMethod___ecereNameSpace__ecere__sys__OldList_Remove((&*ast), symbol->__anon2.__anon1.structExternal);
+FreeExternal(symbol->__anon2.__anon1.structExternal);
+}
 symbol->__anon2.__anon1.structExternal = external;
 external->__anon1.declaration = MkDeclaration(specs, declarators);
 after = external;
@@ -1996,8 +2040,9 @@ if(!strstr(sourceFile, ".main.ec"))
 ListAdd(specs, MkSpecifier(STATIC));
 ListAdd(specs, MkStructOrUnion(3, MkIdentifier("__ecereNameSpace__ecere__com__Class"), (((void *)0))));
 ListAdd(declarators, MkInitDeclarator(MkDeclaratorPointer(MkPointer((((void *)0)), (((void *)0))), MkDeclaratorIdentifier(MkIdentifier(className))), (((void *)0))));
-symbol->__anon2.__anon3.methodExternal = MkExternalDeclaration(MkDeclaration(specs, declarators));
-__ecereMethod___ecereNameSpace__ecere__sys__OldList_Insert(defs, after, symbol->__anon2.__anon3.methodExternal);
+symbol->__anon2.__anon1.pointerExternal = MkExternalDeclaration(MkDeclaration(specs, declarators));
+DeclareStruct(symbol->__anon2.__anon1.pointerExternal, "ecere::com::Class", 0, 1);
+__ecereMethod___ecereNameSpace__ecere__sys__OldList_Insert(defs, after, symbol->__anon2.__anon1.pointerExternal);
 after = symbol->__anon2.__anon3.methodExternal;
 }
 if(symbol->needDestructor)
@@ -2049,16 +2094,10 @@ body = MkCompoundStmt(declarations, statements);
 PopContext(context);
 body->__anon1.compound.context = context;
 decl = MkDeclaratorFunction(MkDeclaratorIdentifier(MkIdentifier(destructorName)), (((void *)0)));
-decl->symbol = __extension__ ({
-struct Symbol * __ecereInstance1 = __ecereNameSpace__ecere__com__eInstance_New(__ecereClass_Symbol);
-
-__ecereInstance1->id = symbol->id, __ecereInstance1->idCode = symbol->idCode, __ecereInstance1;
-});
+decl->symbol = __ecereNameSpace__ecere__com__eInstance_New(__ecereClass_Symbol);
 __ecereMethod___ecereNameSpace__ecere__sys__OldList_Add((&*excludedSymbols), decl->symbol);
 function = MkClassFunction(specs, (((void *)0)), decl, (((void *)0)));
 ProcessClassFunctionBody(function, body);
-function->id = symbol->id;
-function->idCode = symbol->idCode;
 function->dontMangle = 1;
 __ecereMethod___ecereNameSpace__ecere__sys__OldList_Insert(definitions, (((void *)0)), MkClassDefFunction(function));
 }
@@ -2163,12 +2202,8 @@ body->__anon1.compound.context = context;
 decl = MkDeclaratorFunction(MkDeclaratorIdentifier(MkIdentifier(constructorName)), (((void *)0)));
 decl->symbol = __ecereNameSpace__ecere__com__eInstance_New(__ecereClass_Symbol);
 __ecereMethod___ecereNameSpace__ecere__sys__OldList_Add((&*excludedSymbols), decl->symbol);
-decl->symbol->id = symbol->id;
-decl->symbol->idCode = symbol->idCode;
 function = MkClassFunction(specs, (((void *)0)), decl, (((void *)0)));
 ProcessClassFunctionBody(function, body);
-function->id = symbol->id;
-function->idCode = symbol->idCode;
 function->dontMangle = 1;
 if(definitions != (((void *)0)))
 __ecereMethod___ecereNameSpace__ecere__sys__OldList_Insert(definitions, (((void *)0)), MkClassDefFunction(function));
@@ -2187,7 +2222,7 @@ struct ClassDef * newDef;
 if(inCompiler)
 {
 yylloc = propertyDef->loc;
-if(!NameSpaceContained(regClass->nameSpace, &((struct __ecereNameSpace__ecere__com__Module *)(((char *)regClass->module + structSize_Instance)))->privateNameSpace) && def->memberAccess == 1)
+if(!NameSpaceContained(regClass->nameSpace, &((struct __ecereNameSpace__ecere__com__Module *)(((char *)regClass->module + sizeof(struct __ecereNameSpace__ecere__com__Instance))))->privateNameSpace) && def->memberAccess == 1)
 CheckPublicDataType(propertyDef->symbol->type, 1, "class property");
 else if(!symbol->isStatic)
 CheckPublicDataType(propertyDef->symbol->type, 2, "class property");
@@ -2208,14 +2243,14 @@ FullClassNameCat(name, propertyDef->id->string, 1);
 params = MkList();
 if(propertyDef->symbol->type && propertyDef->symbol->type->kind == 8 && propertyDef->symbol->type->__anon1._class && propertyDef->symbol->type->__anon1._class->__anon1.registered && propertyDef->symbol->type->__anon1._class->__anon1.registered->type == 1)
 {
-ListAdd(params, MkTypeName(CopyList(propertyDef->specifiers, CopySpecifier), MkDeclaratorIdentifier(MkIdentifier("value"))));
+ListAdd(params, MkTypeName(CopyList(propertyDef->specifiers, (void *)(CopySpecifier)), MkDeclaratorIdentifier(MkIdentifier("value"))));
 decl = PlugDeclarator(propertyDef->declarator, MkDeclaratorFunction(MkDeclaratorIdentifier(MkIdentifier(name)), params));
 func = MkClassFunction(MkListOne(MkSpecifier(VOID)), (((void *)0)), decl, (((void *)0)));
 }
 else
 {
 decl = PlugDeclarator(propertyDef->declarator, MkDeclaratorFunction(MkDeclaratorIdentifier(MkIdentifier(name)), params));
-func = MkClassFunction(CopyList(propertyDef->specifiers, CopySpecifier), (((void *)0)), decl, (((void *)0)));
+func = MkClassFunction(CopyList(propertyDef->specifiers, (void *)(CopySpecifier)), (((void *)0)), decl, (((void *)0)));
 }
 ProcessClassFunctionBody(func, propertyDef->getStmt);
 func->declarator->symbol = propertyDef->symbol;
@@ -2238,7 +2273,7 @@ FullClassNameCat(name, symbol->string, 0);
 strcat(name, "_Set_");
 FullClassNameCat(name, propertyDef->id->string, 1);
 params = MkList();
-ListAdd(params, MkTypeName(CopyList(propertyDef->specifiers, CopySpecifier), PlugDeclarator(propertyDef->declarator, MkDeclaratorIdentifier(MkIdentifier("value")))));
+ListAdd(params, MkTypeName(CopyList(propertyDef->specifiers, (void *)(CopySpecifier)), PlugDeclarator(propertyDef->declarator, MkDeclaratorIdentifier(MkIdentifier("value")))));
 if(propertyDef->__anon1.isDBProp)
 {
 struct Specifier * spec;
@@ -2356,7 +2391,7 @@ struct ClassDef * newDef;
 if(inCompiler)
 {
 yylloc = propertyDef->loc;
-if(!NameSpaceContained(regClass->nameSpace, &((struct __ecereNameSpace__ecere__com__Module *)(((char *)regClass->module + structSize_Instance)))->privateNameSpace))
+if(!NameSpaceContained(regClass->nameSpace, &((struct __ecereNameSpace__ecere__com__Module *)(((char *)regClass->module + sizeof(struct __ecereNameSpace__ecere__com__Instance))))->privateNameSpace))
 CheckPublicDataType(propertyDef->symbol->type, 1, "classwide property");
 else if(!symbol->isStatic)
 CheckPublicDataType(propertyDef->symbol->type, 2, "classwide property");
@@ -2405,6 +2440,7 @@ struct Context * prevCurContext;
 struct __ecereNameSpace__ecere__sys__OldList * specifiers = MkList();
 struct Statement * body = propertyDef->setStmt;
 struct Declarator * ptrDecl;
+struct Expression * e;
 
 strcpy(name, "class::__ecereClassProp_");
 FullClassNameCat(name, symbol->string, 0);
@@ -2421,7 +2457,10 @@ if(propertyDef->symbol->type && propertyDef->symbol->type->kind == 8 && property
 ptrDecl = MkDeclaratorPointer(MkPointer((((void *)0)), (((void *)0))), PlugDeclarator(propertyDef->declarator, MkDeclaratorIdentifier(MkIdentifier("value"))));
 else
 ptrDecl = PlugDeclarator(propertyDef->declarator, MkDeclaratorIdentifier(MkIdentifier("value")));
-ListAdd(body->__anon1.compound.declarations, MkDeclaration(CopyList(propertyDef->specifiers, CopySpecifier), MkListOne(MkInitDeclarator(ptrDecl, MkInitializerAssignment(MkExpCast(MkTypeName(CopyList(propertyDef->specifiers, CopySpecifier), CopyDeclarator(propertyDef->declarator)), MkExpIdentifier(MkIdentifier("_value"))))))));
+e = MkExpIdentifier(MkIdentifier("_value"));
+if(__ecereProp_Type_Get_isPointerType(propertyDef->symbol->type))
+e = MkExpCast(MkTypeName(MkListOne(MkSpecifierName("uintptr")), (((void *)0))), e);
+ListAdd(body->__anon1.compound.declarations, MkDeclaration(CopyList(propertyDef->specifiers, (void *)(CopySpecifier)), MkListOne(MkInitDeclarator(ptrDecl, MkInitializerAssignment(MkExpCast(MkTypeName(CopyList(propertyDef->specifiers, (void *)(CopySpecifier)), CopyDeclarator(propertyDef->declarator)), e))))));
 curContext = prevCurContext;
 {
 struct Symbol * sym = ptrDecl->symbol;
@@ -2474,7 +2513,7 @@ char * newId = __ecereNameSpace__ecere__com__eSystem_New(sizeof(char) * (strlen(
 newId[0] = '\0';
 ProcessMethodType(method);
 yylloc = def->loc;
-if(!NameSpaceContained(regClass->nameSpace, &((struct __ecereNameSpace__ecere__com__Module *)(((char *)regClass->module + structSize_Instance)))->privateNameSpace) && method->memberAccess == 1)
+if(!NameSpaceContained(regClass->nameSpace, &((struct __ecereNameSpace__ecere__com__Module *)(((char *)regClass->module + sizeof(struct __ecereNameSpace__ecere__com__Instance))))->privateNameSpace) && method->memberAccess == 1)
 CheckPublicDataType(method->dataType, 1, "class method");
 strcpy(newId, "__ecereMethod_");
 FullClassNameCat(newId, symbol->string, 0);
@@ -2496,7 +2535,7 @@ if(method->symbol)
 }
 }
 if(initDeclarators != (((void *)0)))
-FreeList(initDeclarators, FreeInitDeclarator);
+FreeList(initDeclarators, (void *)(FreeInitDeclarator));
 }
 
 void PreProcessClassDefinitions()
@@ -2523,7 +2562,7 @@ else if(external->type == 1)
 {
 struct Declaration * declaration = external->__anon1.declaration;
 
-if(declaration->type == 1)
+if(declaration && declaration->type == 1)
 {
 if(declaration->__anon1.__anon1.specifiers)
 {
@@ -2552,7 +2591,7 @@ ProcessClass((specifier->type == 4) ? 6 : 0, specifier->__anon1.__anon2.definiti
 }
 }
 }
-else if(inCompiler && declaration->type == 3)
+else if(declaration && inCompiler && declaration->type == 3)
 {
 yylloc = declaration->loc;
 if(declaration->declMode == 1)
@@ -2578,12 +2617,6 @@ CheckPublicDataType(external->__anon1.function->type, 2, "function");
 }
 }
 
-extern struct __ecereNameSpace__ecere__com__Class * __ecereClass___ecereNameSpace__ecere__com__GlobalFunction;
-
-struct __ecereNameSpace__ecere__com__GlobalFunction;
-
-extern struct __ecereNameSpace__ecere__com__GlobalFunction * __ecereNameSpace__ecere__com__eSystem_RegisterFunction(const char *  name, const char *  type, void *  func, struct __ecereNameSpace__ecere__com__Instance * module, int declMode);
-
 void __ecereRegisterModule_pass0(struct __ecereNameSpace__ecere__com__Instance * module)
 {
 struct __ecereNameSpace__ecere__com__Class __attribute__((unused)) * class;
@@ -2592,8 +2625,3 @@ __ecereNameSpace__ecere__com__eSystem_RegisterFunction("FullClassNameCat", "void
 __ecereNameSpace__ecere__com__eSystem_RegisterFunction("PreProcessClassDefinitions", "void PreProcessClassDefinitions(void)", PreProcessClassDefinitions, module, 1);
 }
 
-void __ecereUnregisterModule_pass0(struct __ecereNameSpace__ecere__com__Instance * module)
-{
-
-}
-