/* Generated by Nim Compiler v0.13.0 */
/*   (c) 2015 Andreas Rumpf */
/* The generated code is subject to the original license. */
#define NIM_INTBITS 64

#include "nimbase.h"
#include <string.h>
typedef struct Tsymseq216792 Tsymseq216792;
typedef struct Tsym216822 Tsym216822;
typedef struct TGenericSeq TGenericSeq;
typedef struct TNimType TNimType;
typedef struct TNimNode TNimNode;
typedef struct Cell47304 Cell47304;
typedef struct Cellseq47320 Cellseq47320;
typedef struct Gcheap49618 Gcheap49618;
typedef struct Gcstack49616 Gcstack49616;
typedef struct Cellset47316 Cellset47316;
typedef struct Pagedesc47312 Pagedesc47312;
typedef struct Memregion29488 Memregion29488;
typedef struct Smallchunk29440 Smallchunk29440;
typedef struct Llchunk29482 Llchunk29482;
typedef struct Bigchunk29442 Bigchunk29442;
typedef struct Intset29414 Intset29414;
typedef struct Trunk29410 Trunk29410;
typedef struct Avlnode29486 Avlnode29486;
typedef struct Gcstat49614 Gcstat49614;
typedef struct Ttype216828 Ttype216828;
typedef struct Tcontext266020 Tcontext266020;
typedef struct Tpasscontext263002 Tpasscontext263002;
typedef struct TNimObject TNimObject;
typedef struct Tscope216816 Tscope216816;
typedef struct Tproccon266008 Tproccon266008;
typedef struct Intset213035 Intset213035;
typedef struct Trunk213031 Trunk213031;
typedef struct Trunkseq213033 Trunkseq213033;
typedef struct Tlinkedlist138016 Tlinkedlist138016;
typedef struct Tlistentry138010 Tlistentry138010;
typedef struct Tidtable216840 Tidtable216840;
typedef struct Tidpairseq216838 Tidpairseq216838;
typedef struct Tnode216790 Tnode216790;
typedef struct Tlineinfo184337 Tlineinfo184337;
typedef struct Tstrtable216794 Tstrtable216794;
typedef struct Tctx265036 Tctx265036;
typedef struct TY266140 TY266140;
typedef struct TY533873 TY533873;
typedef struct TY533876 TY533876;
typedef struct Tinstantiationpair266010 Tinstantiationpair266010;
typedef struct Tinstantiation216812 Tinstantiation216812;
typedef struct Toptionentry266002 Toptionentry266002;
typedef struct Tlib216808 Tlib216808;
typedef struct Tidobj191006 Tidobj191006;
typedef struct Ttypeseq216824 Ttypeseq216824;
typedef struct Tloc216804 Tloc216804;
typedef struct Ropeobj172006 Ropeobj172006;
typedef struct NimStringDesc NimStringDesc;
typedef struct TY89887 TY89887;
typedef struct Tident191012 Tident191012;
typedef struct Tnodeseq216784 Tnodeseq216784;
typedef struct TY216925 TY216925;
typedef struct Basechunk29438 Basechunk29438;
typedef struct Freecell29430 Freecell29430;
typedef struct Tidpair216836 Tidpair216836;
typedef struct TY265242 TY265242;
typedef struct TY185090 TY185090;
typedef struct PprocHEX3Aobjecttype265221 PprocHEX3Aobjecttype265221;
typedef struct TY265261 TY265261;
typedef struct TY216913 TY216913;
typedef struct TY265222 TY265222;
typedef struct TY265227 TY265227;
typedef struct TY265262 TY265262;
typedef struct Vmargs265030 Vmargs265030;
typedef struct Tblock265018 Tblock265018;
typedef struct TY265202 TY265202;
struct  TGenericSeq  {
NI len;
NI reserved;
};
typedef N_NIMCALL_PTR(void, TY3489) (void* p, NI op);
typedef N_NIMCALL_PTR(void*, TY3494) (void* p);
struct  TNimType  {
NI size;
NU8 kind;
NU8 flags;
TNimType* base;
TNimNode* node;
void* finalizer;
TY3489 marker;
TY3494 deepcopy;
};
struct  TNimNode  {
NU8 kind;
NI offset;
TNimType* typ;
NCSTRING name;
NI len;
TNimNode** sons;
};
struct  Cell47304  {
NI refcount;
TNimType* typ;
};
struct  Cellseq47320  {
NI len;
NI cap;
Cell47304** d;
};
struct  Cellset47316  {
NI counter;
NI max;
Pagedesc47312* head;
Pagedesc47312** data;
};
typedef Smallchunk29440* TY29503[512];
typedef Trunk29410* Trunkbuckets29412[256];
struct  Intset29414  {
Trunkbuckets29412 data;
};
struct  Memregion29488  {
NI minlargeobj;
NI maxlargeobj;
TY29503 freesmallchunks;
Llchunk29482* llmem;
NI currmem;
NI maxmem;
NI freemem;
NI lastsize;
Bigchunk29442* freechunkslist;
Intset29414 chunkstarts;
Avlnode29486* root;
Avlnode29486* deleted;
Avlnode29486* last;
Avlnode29486* freeavlnodes;
};
struct  Gcstat49614  {
NI stackscans;
NI cyclecollections;
NI maxthreshold;
NI maxstacksize;
NI maxstackcells;
NI cycletablesize;
NI64 maxpause;
};
struct  Gcheap49618  {
Gcstack49616* stack;
void* stackbottom;
NI cyclethreshold;
Cellseq47320 zct;
Cellseq47320 decstack;
Cellset47316 cycleroots;
Cellseq47320 tempstack;
NI recgclock;
Memregion29488 region;
Gcstat49614 stat;
};
struct  TNimObject  {
TNimType* m_type;
};
struct  Tpasscontext263002  {
  TNimObject Sup;
NIM_BOOL fromcache;
};
struct  Intset213035  {
NI counter;
NI max;
Trunk213031* head;
Trunkseq213033* data;
};
struct  Tlinkedlist138016  {
Tlistentry138010* head;
Tlistentry138010* tail;
NI counter;
};
struct  Tidtable216840  {
NI counter;
Tidpairseq216838* data;
};
typedef N_NIMCALL_PTR(Tnode216790*, TY266071) (Tcontext266020* c, Tnode216790* n);
typedef N_NIMCALL_PTR(Tnode216790*, TY266076) (Tcontext266020* c, Tnode216790* n, NU16 flags);
typedef N_NIMCALL_PTR(Tnode216790*, TY266084) (Tcontext266020* c, Tnode216790* n, NU16 flags);
typedef N_NIMCALL_PTR(Tnode216790*, TY266092) (Tcontext266020* c, Tnode216790* n);
typedef N_NIMCALL_PTR(Tnode216790*, TY266097) (Tcontext266020* c, Tnode216790* n, NU16 flags);
typedef N_NIMCALL_PTR(Tnode216790*, TY266105) (Tcontext266020* c, Tnode216790* n);
typedef N_NIMCALL_PTR(Tnode216790*, TY266110) (Tcontext266020* c, Tnode216790* n, Tnode216790* norig, NU32 filter);
typedef N_NIMCALL_PTR(Ttype216828*, TY266117) (Tcontext266020* c, Tnode216790* n, Ttype216828* prev);
typedef struct {
N_NIMCALL_PTR(Tnode216790*, ClPrc) (Tcontext266020* c, Tidtable216840 pt, Tnode216790* n, void* ClEnv);
void* ClEnv;
} TY266123;
typedef struct {
N_NIMCALL_PTR(Tsym216822*, ClPrc) (Tcontext266020* c, Tsym216822* fn, Tidtable216840 pt, Tlineinfo184337 info, void* ClEnv);
void* ClEnv;
} TY266129;
struct  Tstrtable216794  {
NI counter;
Tsymseq216792* data;
};
typedef N_NIMCALL_PTR(Tsym216822*, TY266145) (Tcontext266020* c, Tsym216822* dc, Ttype216828* t, Tlineinfo184337 info, NU8 op);
struct  Tcontext266020  {
  Tpasscontext263002 Sup;
Tsym216822* module;
Tscope216816* currentscope;
Tscope216816* importtable;
Tscope216816* toplevelscope;
Tproccon266008* p;
Tsymseq216792* friendmodules;
NI instcounter;
Intset213035 ambiguoussymbols;
NI intypeclass;
NI ingenericcontext;
NI inunrolledcontext;
NI compilescontextid;
NI compilescontextidgenerator;
NI ingenericinst;
Tsymseq216792* converters;
Tsymseq216792* patterns;
Tlinkedlist138016 optionstack;
Tidtable216840 symmapping;
Tlinkedlist138016 libs;
TY266071 semconstexpr;
TY266076 semexpr;
TY266084 semtryexpr;
TY266092 semtryconstexpr;
TY266097 semoperand;
TY266105 semconstboolexpr;
TY266110 semoverloadedcall;
TY266117 semtypenode;
TY266123 seminferredlambda;
TY266129 semgenerateinstance;
Intset213035 includedfiles;
Tstrtable216794 userpragmas;
Tctx265036* evalcontext;
Intset213035 unknownidents;
TY266140* generics;
NI lastgenericidx;
NI hloloopdetector;
NI inparallelstmt;
TY266145 insttypeboundop;
};
struct  Tproccon266008  {
Tsym216822* owner;
Tsym216822* resultsym;
NI nestedloopcounter;
NI nestedblockcounter;
NI intrystmt;
Tproccon266008* next;
NIM_BOOL wasforwarded;
Tnode216790* bracketexpr;
};
struct TY533873 {
void* Field0;
TY533876* Field1;
};
struct  Tinstantiationpair266010  {
Tsym216822* genericsym;
Tinstantiation216812* inst;
};
struct  Tlistentry138010  {
  TNimObject Sup;
Tlistentry138010* prev;
Tlistentry138010* next;
};
struct  Toptionentry266002  {
  Tlistentry138010 Sup;
NU32 options;
NU8 defaultcc;
Tlib216808* dynlib;
NU64 notes;
Tnode216790* otherpragmas;
};
typedef Tsym216822* TY266331[1];
struct  Tidobj191006  {
  TNimObject Sup;
NI id;
};
struct  Tloc216804  {
NU8 k;
NU8 s;
NU16 flags;
Ttype216828* t;
Ropeobj172006* r;
Ropeobj172006* heaproot;
};
struct  Ttype216828  {
  Tidobj191006 Sup;
NU8 kind;
NU8 callconv;
NU32 flags;
Ttypeseq216824* sons;
Tnode216790* n;
Tsym216822* owner;
Tsym216822* sym;
Tsym216822* destructor;
Tsym216822* deepcopy;
Tsym216822* assignment;
NI64 size;
NI16 align;
NI16 locklevel;
Tloc216804 loc;
};
struct  NimStringDesc  {
  TGenericSeq Sup;
NIM_CHAR data[SEQ_DECL_SIZE];
};
struct TY89887 {
NimStringDesc* Field0;
NI Field1;
};
struct  Tlineinfo184337  {
NI16 line;
NI16 col;
NI32 fileindex;
};
struct  Tnode216790  {
Ttype216828* typ;
Tlineinfo184337 info;
NU16 flags;
NU8 kind;
union{
struct {NI64 intval;
} S1;
struct {NF floatval;
} S2;
struct {NimStringDesc* strval;
} S3;
struct {Tsym216822* sym;
} S4;
struct {Tident191012* ident;
} S5;
struct {Tnodeseq216784* sons;
} S6;
} kindU;
NimStringDesc* comment;
};
typedef Tnode216790* TY232280[1];
typedef Ttype216828* TY368877[1];
typedef Ttype216828* TY266646[2];
typedef Tnode216790* TY384939[2];
struct  Tlib216808  {
  Tlistentry138010 Sup;
NU8 kind;
NIM_BOOL generated;
NIM_BOOL isoverriden;
Ropeobj172006* name;
Tnode216790* path;
};
struct  Tsym216822  {
  Tidobj191006 Sup;
NU8 kind;
union{
struct {Ttypeseq216824* typeinstcache;
Tscope216816* typscope;
} S1;
struct {TY216925* procinstcache;
Tsym216822* gcunsafetyreason;
} S2;
struct {TY216925* usedgenerics;
Tstrtable216794 tab;
} S3;
struct {Tsym216822* guard;
NI bitsize;
} S4;
} kindU;
NU8 magic;
Ttype216828* typ;
Tident191012* name;
Tlineinfo184337 info;
Tsym216822* owner;
NU32 flags;
Tnode216790* ast;
NU32 options;
NI position;
NI offset;
Tloc216804 loc;
Tlib216808* annex;
Tnode216790* constraint;
};
struct  Gcstack49616  {
Gcstack49616* prev;
Gcstack49616* next;
void* starts;
void* pos;
NI maxstacksize;
};
typedef NI TY29419[8];
struct  Pagedesc47312  {
Pagedesc47312* next;
NI key;
TY29419 bits;
};
struct  Basechunk29438  {
NI prevsize;
NI size;
NIM_BOOL used;
};
struct  Smallchunk29440  {
  Basechunk29438 Sup;
Smallchunk29440* next;
Smallchunk29440* prev;
Freecell29430* freelist;
NI free;
NI acc;
NF data;
};
struct  Llchunk29482  {
NI size;
NI acc;
Llchunk29482* next;
};
struct  Bigchunk29442  {
  Basechunk29438 Sup;
Bigchunk29442* next;
Bigchunk29442* prev;
NI align;
NF data;
};
struct  Trunk29410  {
Trunk29410* next;
NI key;
TY29419 bits;
};
typedef Avlnode29486* TY29493[2];
struct  Avlnode29486  {
TY29493 link;
NI key;
NI upperbound;
NI level;
};
struct  Tscope216816  {
NI depthlevel;
Tstrtable216794 symbols;
Tnodeseq216784* usingsyms;
Tscope216816* parent;
};
struct  Trunk213031  {
Trunk213031* next;
NI key;
TY29419 bits;
};
struct  Tidpair216836  {
Tidobj191006* key;
TNimObject* val;
};
struct  Tctx265036  {
  Tpasscontext263002 Sup;
TY265242* code;
TY185090* debug;
Tnode216790* globals;
Tnode216790* constants;
Ttypeseq216824* types;
Tnode216790* currentexceptiona;
Tnode216790* currentexceptionb;
NI exceptioninstr;
PprocHEX3Aobjecttype265221* prc;
Tsym216822* module;
Tnode216790* callsite;
NU8 mode;
NU8 features;
NIM_BOOL traceactive;
NI loopiterations;
Tlineinfo184337 comesfromheuristic;
TY265261* callbacks;
NimStringDesc* errorflag;
};
struct TY533876 {
char dummy;
};
struct  Tinstantiation216812  {
Tsym216822* sym;
Ttypeseq216824* concretetypes;
TY216913* usedby;
NI compilesid;
};
struct  Ropeobj172006  {
  TNimObject Sup;
Ropeobj172006* left;
Ropeobj172006* right;
NI length;
NimStringDesc* data;
};
struct  Tident191012  {
  Tidobj191006 Sup;
NimStringDesc* s;
Tident191012* next;
NI h;
};
struct  Freecell29430  {
Freecell29430* next;
NI zerofield;
};
struct TY265227 {
NIM_BOOL Field0;
NU8 Field1;
};
typedef TY265227 TY265230[256];
struct  PprocHEX3Aobjecttype265221  {
TY265222* blocks;
Tsym216822* sym;
TY265230 slots;
NI maxslots;
};
typedef struct {
N_NIMCALL_PTR(void, ClPrc) (Vmargs265030* args, void* ClEnv);
void* ClEnv;
} Vmcallback265032;
struct TY265262 {
NimStringDesc* Field0;
Vmcallback265032 Field1;
};
struct  Tblock265018  {
Tsym216822* label;
TY265202* fixups;
};
struct  Vmargs265030  {
NI ra;
NI rb;
NI rc;
void* slots;
Tnode216790* currentexception;
};
struct Tsymseq216792 {
  TGenericSeq Sup;
  Tsym216822* data[SEQ_DECL_SIZE];
};
struct TY266140 {
  TGenericSeq Sup;
  Tinstantiationpair266010 data[SEQ_DECL_SIZE];
};
struct Ttypeseq216824 {
  TGenericSeq Sup;
  Ttype216828* data[SEQ_DECL_SIZE];
};
struct Tnodeseq216784 {
  TGenericSeq Sup;
  Tnode216790* data[SEQ_DECL_SIZE];
};
struct Trunkseq213033 {
  TGenericSeq Sup;
  Trunk213031* data[SEQ_DECL_SIZE];
};
struct Tidpairseq216838 {
  TGenericSeq Sup;
  Tidpair216836 data[SEQ_DECL_SIZE];
};
struct TY216925 {
  TGenericSeq Sup;
  Tinstantiation216812* data[SEQ_DECL_SIZE];
};
struct TY265242 {
  TGenericSeq Sup;
  NU32 data[SEQ_DECL_SIZE];
};
struct TY185090 {
  TGenericSeq Sup;
  Tlineinfo184337 data[SEQ_DECL_SIZE];
};
struct TY265261 {
  TGenericSeq Sup;
  TY265262 data[SEQ_DECL_SIZE];
};
struct TY216913 {
  TGenericSeq Sup;
  NI32 data[SEQ_DECL_SIZE];
};
struct TY265222 {
  TGenericSeq Sup;
  Tblock265018 data[SEQ_DECL_SIZE];
};
struct TY265202 {
  TGenericSeq Sup;
  NI data[SEQ_DECL_SIZE];
};
static N_INLINE(void, nimGCunrefNoCycle)(void* p);
static N_INLINE(Cell47304*, usrtocell_51240)(void* usr);
static N_INLINE(void, rtladdzct_52801)(Cell47304* c);
N_NOINLINE(void, addzct_51217)(Cellseq47320* s, Cell47304* c);
N_NIMCALL(void*, newSeqRC1)(TNimType* typ, NI len);
N_NIMCALL(Ttype216828*, newtype_219107)(NU8 kind, Tsym216822* owner);
N_NIMCALL(Tsym216822*, getcurrowner_266209)(void);
N_NIMCALL(void, nimGCvisit)(void* d, NI op);
N_NIMCALL(void, TMP2071)(void* p, NI op);
N_NIMCALL(void, TMP2096)(void* p, NI op);
N_NIMCALL(void, TMP2097)(void* p, NI op);
N_NIMCALL(void*, newObj)(TNimType* typ, NI size);
N_NIMCALL(void, initintset_213885)(Intset213035* Result);
N_NIMCALL(void, initlinkedlist_138028)(Tlinkedlist138016* list);
N_NIMCALL(void, append_138032)(Tlinkedlist138016* list, Tlistentry138010* entry);
N_NIMCALL(Toptionentry266002*, newoptionentry_266171)(void);
N_NIMCALL(void, TMP2102)(void* p, NI op);
static N_INLINE(void, asgnRef)(void** dest, void* src);
static N_INLINE(void, incref_53619)(Cell47304* c);
static N_INLINE(NIM_BOOL, canbecycleroot_51258)(Cell47304* c);
static N_INLINE(void, rtladdcycleroot_52020)(Cell47304* c);
N_NOINLINE(void, incl_48047)(Cellset47316* s, Cell47304* cell);
static N_INLINE(void, decref_53201)(Cell47304* c);
static N_INLINE(void, asgnRefNoCycle)(void** dest, void* src);
N_NIMCALL(void, initstrtable_220001)(Tstrtable216794* x);
N_NIMCALL(Ttype216828*, newtypes_266184)(NU8 kind, Tcontext266020* c);
N_NIMCALL(void, addsonskipintlit_260680)(Ttype216828* father, Ttype216828* son);
N_NIMCALL(void, internalerror_189113)(NimStringDesc* errmsg);
N_NIMCALL(NimStringDesc*, HEX24_189183)(TY89887 x);
N_NIMCALL(void, globalerror_189071)(Tlineinfo184337 info, NU16 msg, NimStringDesc* arg);
N_NIMCALL(NimStringDesc*, rendertree_235044)(Tnode216790* n, NU8 renderflags);
N_NIMCALL(NI, sonslen_219351)(Tnode216790* n);
N_NIMCALL(void, illformedast_266950)(Tnode216790* n);
N_NIMCALL(void, genericSeqAssign)(void* dest, void* src_85404, TNimType* mt);
N_NIMCALL(Tnode216790*, newnodei_218248)(NU8 kind, Tlineinfo184337 info);
N_NIMCALL(void, addson_218807)(Tnode216790* father, Tnode216790* son);
N_NIMCALL(Tnode216790*, newinttypenode_217665)(NU8 kind, NI64 intval, Ttype216828* typ);
N_NIMCALL(Ttype216828*, newtypewithsons_266601)(Tcontext266020* c, NU8 kind, Ttypeseq216824* sons);
N_NIMCALL(void*, newSeq)(TNimType* typ, NI len);
N_NIMCALL(void, propagatetoowner_220190)(Ttype216828* owner, Ttype216828* elem);
N_NIMCALL(Ttype216828*, getsystype_260130)(NU8 kind);
N_NIMCALL(Tnode216790*, newnode_218601)(NU8 kind, Tlineinfo184337 info, Tnodeseq216784* sons, Ttype216828* typ);
N_NIMCALL(Tnode216790*, makestaticexpr_266608)(Tcontext266020* c, Tnode216790* n);
N_NIMCALL(Tnode216790*, nminusone_266828)(Tnode216790* n);
N_NIMCALL(Tnode216790*, newsymnode_218234)(Tsym216822* sym);
N_NIMCALL(Tsym216822*, getsysmagic_260079)(NimStringDesc* name, NU8 m);
N_NIMCALL(TGenericSeq*, incrSeqV2)(TGenericSeq* seq, NI elemsize);
N_NIMCALL(void, unsureAsgnRef)(void** dest, void* src);
N_NIMCALL(void, localerror_189080)(Tlineinfo184337 info, NU16 msg, NimStringDesc* arg);
N_NIMCALL(TGenericSeq*, setLengthSeq)(TGenericSeq* seq, NI elemsize, NI newlen);
N_NIMCALL(Ttype216828*, errortype_266901)(Tcontext266020* c);
N_NIMCALL(Ttype216828*, maketypedesc_266523)(Tcontext266020* c, Ttype216828* typ);
N_NIMCALL(Tsym216822*, linkto_217854)(Tsym216822* s, Ttype216828* t);
N_NIMCALL(Tsym216822*, newsym_217683)(NU8 symkind, Tident191012* name, Tsym216822* owner, Tlineinfo184337 info);
N_NIMCALL(Tnode216790*, newsymnode_218241)(Tsym216822* sym, Tlineinfo184337 info);
N_NIMCALL(void, inclsym_266393)(Tsymseq216792** sq, Tsym216822* s);
STRING_LITERAL(TMP2796, "compiler/semdata.nim", 20);
NIM_CONST TY89887 TMP2795 = {((NimStringDesc*) &TMP2796),
((NI) 226)}
;
NIM_CONST TY89887 TMP2810 = {((NimStringDesc*) &TMP2796),
((NI) 222)}
;
STRING_LITERAL(TMP3164, "<", 1);
STRING_LITERAL(TMP3333, "popOwner", 8);
NIM_CONST TY89887 TMP3376 = {((NimStringDesc*) &TMP2796),
((NI) 215)}
;
Tsymseq216792* gowners_266233;
extern TNimType NTI216792; /* TSymSeq */
extern Gcheap49618 gch_49659;
extern TNimType NTI263002; /* TPassContext */
TNimType NTI266020; /* TContext */
extern TNimType NTI216788; /* PSym */
extern TNimType NTI216818; /* PScope */
TNimType NTI266008; /* TProcCon */
extern TNimType NTI104; /* int */
extern TNimType NTI130; /* bool */
extern TNimType NTI216782; /* PNode */
TNimType NTI266006; /* PProcCon */
extern TNimType NTI213035; /* IntSet */
extern TNimType NTI138016; /* TLinkedList */
extern TNimType NTI216840; /* TIdTable */
TNimType NTI266071; /* proc (c: PContext, n: PNode): PNode */
TNimType NTI266076; /* proc (c: PContext, n: PNode, flags: TExprFlags): PNode */
TNimType NTI266084; /* proc (c: PContext, n: PNode, flags: TExprFlags): PNode */
TNimType NTI266092; /* proc (c: PContext, n: PNode): PNode */
TNimType NTI266097; /* proc (c: PContext, n: PNode, flags: TExprFlags): PNode */
TNimType NTI266105; /* proc (c: PContext, n: PNode): PNode */
TNimType NTI266110; /* proc (c: PContext, n: PNode, nOrig: PNode, filter: TSymKinds): PNode */
TNimType NTI266117; /* proc (c: PContext, n: PNode, prev: PType): PType */
TNimType NTI266123; /* (pointer, ref tuple[]) */
extern TNimType NTI142; /* pointer */
extern TNimType NTI533875; /* ref tuple[] */
TNimType NTI266129; /* (pointer, ref tuple[]) */
extern TNimType NTI216794; /* TStrTable */
extern TNimType NTI265034; /* PCtx */
TNimType NTI266010; /* TInstantiationPair */
extern TNimType NTI216814; /* PInstantiation */
TNimType NTI266140; /* seq[TInstantiationPair] */
TNimType NTI266145; /* proc (c: PContext, dc: PSym, t: PType, info: TLineInfo, op: TTypeAttachedOp): PSym */
TNimType NTI266018; /* PContext */
extern TNimType NTI138010; /* TListEntry */
TNimType NTI266002; /* TOptionEntry */
extern TNimType NTI163011; /* TOptions */
extern TNimType NTI216002; /* TCallingConvention */
extern TNimType NTI216820; /* PLib */
extern TNimType NTI184333; /* TNoteKinds */
TNimType NTI266004; /* POptionEntry */
extern NU32 goptions_163119;
extern NU64 gnotes_185077;
extern TNimType NTI216824; /* TTypeSeq */
extern TNimType NTI216784; /* TNodeSeq */
extern TNimType NTI216808; /* TLib */
extern Tident191012* idanon_191455;

static N_INLINE(Cell47304*, usrtocell_51240)(void* usr) {
	Cell47304* result;
	result = 0;
	result = ((Cell47304*) ((NI)((NU64)(((NI) (usr))) - (NU64)(((NI)sizeof(Cell47304))))));
	return result;
}

static N_INLINE(void, rtladdzct_52801)(Cell47304* c) {
	addzct_51217((&gch_49659.zct), c);
}

static N_INLINE(void, nimGCunrefNoCycle)(void* p) {
	Cell47304* c;
	c = usrtocell_51240(p);
	{
		(*c).refcount -= ((NI) 8);
		if (!((NU64)((*c).refcount) < (NU64)(((NI) 8)))) goto LA3;
		rtladdzct_52801(c);
	}
	LA3: ;
}

N_NIMCALL(Tsym216822*, getcurrowner_266209)(void) {
	Tsym216822* result;
	result = 0;
	result = gowners_266233->data[(gowners_266233 ? (gowners_266233->Sup.len-1) : -1)];
	return result;
}

N_NIMCALL(Ttype216828*, newtypes_266184)(NU8 kind, Tcontext266020* c) {
	Ttype216828* result;
	Tsym216822* LOC1;
	result = 0;
	LOC1 = 0;
	LOC1 = getcurrowner_266209();
	result = newtype_219107(kind, LOC1);
	return result;
}
N_NIMCALL(void, TMP2071)(void* p, NI op) {
	Tproccon266008* a;
	a = (Tproccon266008*)p;
	nimGCvisit((void*)(*a).owner, op);
	nimGCvisit((void*)(*a).resultsym, op);
	nimGCvisit((void*)(*a).next, op);
	nimGCvisit((void*)(*a).bracketexpr, op);
}
N_NIMCALL(void, TMP2096)(void* p, NI op) {
	TY266140* a;
	NI LOC1;
	a = (TY266140*)p;
	LOC1 = 0;
	for (LOC1 = 0; LOC1 < a->Sup.len; LOC1++) {
	nimGCvisit((void*)a->data[LOC1].genericsym, op);
	nimGCvisit((void*)a->data[LOC1].inst, op);
	}
}
N_NIMCALL(void, TMP2097)(void* p, NI op) {
	Tcontext266020* a;
	a = (Tcontext266020*)p;
	nimGCvisit((void*)(*a).module, op);
	nimGCvisit((void*)(*a).currentscope, op);
	nimGCvisit((void*)(*a).importtable, op);
	nimGCvisit((void*)(*a).toplevelscope, op);
	nimGCvisit((void*)(*a).p, op);
	nimGCvisit((void*)(*a).friendmodules, op);
	nimGCvisit((void*)(*a).ambiguoussymbols.head, op);
	nimGCvisit((void*)(*a).ambiguoussymbols.data, op);
	nimGCvisit((void*)(*a).converters, op);
	nimGCvisit((void*)(*a).patterns, op);
	nimGCvisit((void*)(*a).optionstack.head, op);
	nimGCvisit((void*)(*a).optionstack.tail, op);
	nimGCvisit((void*)(*a).symmapping.data, op);
	nimGCvisit((void*)(*a).libs.head, op);
	nimGCvisit((void*)(*a).libs.tail, op);
	nimGCvisit((void*)(*a).seminferredlambda.ClEnv, op);
	nimGCvisit((void*)(*a).semgenerateinstance.ClEnv, op);
	nimGCvisit((void*)(*a).includedfiles.head, op);
	nimGCvisit((void*)(*a).includedfiles.data, op);
	nimGCvisit((void*)(*a).userpragmas.data, op);
	nimGCvisit((void*)(*a).evalcontext, op);
	nimGCvisit((void*)(*a).unknownidents.head, op);
	nimGCvisit((void*)(*a).unknownidents.data, op);
	nimGCvisit((void*)(*a).generics, op);
}
N_NIMCALL(void, TMP2102)(void* p, NI op) {
	Toptionentry266002* a;
	a = (Toptionentry266002*)p;
	nimGCvisit((void*)(*a).Sup.prev, op);
	nimGCvisit((void*)(*a).Sup.next, op);
	nimGCvisit((void*)(*a).dynlib, op);
	nimGCvisit((void*)(*a).otherpragmas, op);
}

static N_INLINE(NIM_BOOL, canbecycleroot_51258)(Cell47304* c) {
	NIM_BOOL result;
	result = 0;
	result = !((((*(*c).typ).flags &(1U<<((NU)(((NU8) 1))&7U)))!=0));
	return result;
}

static N_INLINE(void, rtladdcycleroot_52020)(Cell47304* c) {
	{
		if (!!((((NI) ((NI)((*c).refcount & ((NI) 3)))) == ((NI) 3)))) goto LA3;
		(*c).refcount = (NI)((NI)((*c).refcount & ((NI) -4)) | ((NI) 3));
		incl_48047((&gch_49659.cycleroots), c);
	}
	LA3: ;
}

static N_INLINE(void, incref_53619)(Cell47304* c) {
	(*c).refcount = (NI)((NU64)((*c).refcount) + (NU64)(((NI) 8)));
	{
		NIM_BOOL LOC3;
		LOC3 = 0;
		LOC3 = canbecycleroot_51258(c);
		if (!LOC3) goto LA4;
		rtladdcycleroot_52020(c);
	}
	LA4: ;
}

static N_INLINE(void, decref_53201)(Cell47304* c) {
	{
		(*c).refcount -= ((NI) 8);
		if (!((NU64)((*c).refcount) < (NU64)(((NI) 8)))) goto LA3;
		rtladdzct_52801(c);
	}
	goto LA1;
	LA3: ;
	{
		NIM_BOOL LOC6;
		LOC6 = 0;
		LOC6 = canbecycleroot_51258(c);
		if (!LOC6) goto LA7;
		rtladdcycleroot_52020(c);
	}
	goto LA1;
	LA7: ;
	LA1: ;
}

static N_INLINE(void, asgnRef)(void** dest, void* src) {
	{
		Cell47304* LOC5;
		if (!!((src == NIM_NIL))) goto LA3;
		LOC5 = 0;
		LOC5 = usrtocell_51240(src);
		incref_53619(LOC5);
	}
	LA3: ;
	{
		Cell47304* LOC10;
		if (!!(((*dest) == NIM_NIL))) goto LA8;
		LOC10 = 0;
		LOC10 = usrtocell_51240((*dest));
		decref_53201(LOC10);
	}
	LA8: ;
	(*dest) = src;
}

N_NIMCALL(Toptionentry266002*, newoptionentry_266171)(void) {
	Toptionentry266002* result;
	result = 0;
	result = (Toptionentry266002*) newObj((&NTI266004), sizeof(Toptionentry266002));
	(*result).Sup.Sup.m_type = (&NTI266002);
	(*result).options = goptions_163119;
	(*result).defaultcc = ((NU8) 0);
	asgnRef((void**) (&(*result).dynlib), NIM_NIL);
	(*result).notes = gnotes_185077;
	return result;
}

static N_INLINE(void, asgnRefNoCycle)(void** dest, void* src) {
	{
		Cell47304* c;
		if (!!((src == NIM_NIL))) goto LA3;
		c = usrtocell_51240(src);
		(*c).refcount += ((NI) 8);
	}
	LA3: ;
	{
		Cell47304* c;
		if (!!(((*dest) == NIM_NIL))) goto LA7;
		c = usrtocell_51240((*dest));
		{
			(*c).refcount -= ((NI) 8);
			if (!((NU64)((*c).refcount) < (NU64)(((NI) 8)))) goto LA11;
			rtladdzct_52801(c);
		}
		LA11: ;
	}
	LA7: ;
	(*dest) = src;
}

N_NIMCALL(Tcontext266020*, newcontext_266165)(Tsym216822* module) {
	Tcontext266020* result;
	Toptionentry266002* LOC1;
	Tlistentry138010* LOC2;
	TY266331 LOC3;
	result = 0;
	result = (Tcontext266020*) newObj((&NTI266018), sizeof(Tcontext266020));
	(*result).Sup.Sup.m_type = (&NTI266020);
	initintset_213885((&(*result).ambiguoussymbols));
	initlinkedlist_138028((&(*result).optionstack));
	initlinkedlist_138028((&(*result).libs));
	LOC1 = 0;
	LOC1 = newoptionentry_266171();
	LOC2 = 0;
	LOC2 = &LOC1->Sup;
	append_138032((&(*result).optionstack), LOC2);
	asgnRefNoCycle((void**) (&(*result).module), module);
	if ((*result).friendmodules) nimGCunrefNoCycle((*result).friendmodules);
	(*result).friendmodules = (Tsymseq216792*) newSeqRC1((&NTI216792), 1);
	memset((void*)LOC3, 0, sizeof(LOC3));
	LOC3[0] = module;
	asgnRefNoCycle((void**) (&(*result).friendmodules->data[0]), LOC3[0]);
	if ((*result).converters) nimGCunrefNoCycle((*result).converters);
	(*result).converters = (Tsymseq216792*) newSeqRC1((&NTI216792), 0);
	if ((*result).patterns) nimGCunrefNoCycle((*result).patterns);
	(*result).patterns = (Tsymseq216792*) newSeqRC1((&NTI216792), 0);
	initintset_213885((&(*result).includedfiles));
	initstrtable_220001((&(*result).userpragmas));
	if ((*result).generics) nimGCunrefNoCycle((*result).generics);
	(*result).generics = (TY266140*) newSeqRC1((&NTI266140), 0);
	initintset_213885((&(*result).unknownidents));
	return result;
}

N_NIMCALL(Ttype216828*, maketypefromexpr_266556)(Tcontext266020* c, Tnode216790* n) {
	Ttype216828* result;
	result = 0;
	result = newtypes_266184(((NU8) 60), c);
	asgnRefNoCycle((void**) (&(*result).n), n);
	return result;
}

N_NIMCALL(Ttype216828*, errortype_266901)(Tcontext266020* c) {
	Ttype216828* result;
	result = 0;
	result = newtypes_266184(((NU8) 50), c);
	return result;
}

N_NIMCALL(Ttype216828*, maketypedesc_266523)(Tcontext266020* c, Ttype216828* typ) {
	Ttype216828* result;
	result = 0;
	result = newtypes_266184(((NU8) 8), c);
	{
		NimStringDesc* LOC5;
		if (!(typ == NIM_NIL)) goto LA3;
		LOC5 = 0;
		LOC5 = HEX24_189183(TMP2795);
		internalerror_189113(LOC5);
	}
	LA3: ;
	addsonskipintlit_260680(result, typ);
	return result;
}

N_NIMCALL(void, illformedast_266950)(Tnode216790* n) {
	NimStringDesc* LOC1;
	LOC1 = 0;
	LOC1 = rendertree_235044(n, 4);
	globalerror_189071((*n).info, ((NU16) 1), LOC1);
}

N_NIMCALL(void, checksonslen_266958)(Tnode216790* n, NI length) {
	{
		NI LOC3;
		LOC3 = 0;
		LOC3 = sonslen_219351(n);
		if (!!((LOC3 == length))) goto LA4;
		illformedast_266950(n);
	}
	LA4: ;
}

N_NIMCALL(Ttype216828*, newtypewithsons_266601)(Tcontext266020* c, NU8 kind, Ttypeseq216824* sons) {
	Ttype216828* result;
	Tsym216822* LOC1;
	result = 0;
	LOC1 = 0;
	LOC1 = getcurrowner_266209();
	result = newtype_219107(kind, LOC1);
	genericSeqAssign((&(*result).sons), sons, (&NTI216824));
	return result;
}

N_NIMCALL(Ttype216828*, makevartype_266490)(Tcontext266020* c, Ttype216828* basetype) {
	Ttype216828* result;
	result = 0;
	{
		if (!((*basetype).kind == ((NU8) 23))) goto LA3;
		result = basetype;
	}
	goto LA1;
	LA3: ;
	{
		result = newtypes_266184(((NU8) 23), c);
		{
			NimStringDesc* LOC10;
			if (!(basetype == NIM_NIL)) goto LA8;
			LOC10 = 0;
			LOC10 = HEX24_189183(TMP2810);
			internalerror_189113(LOC10);
		}
		LA8: ;
		addsonskipintlit_260680(result, basetype);
	}
	LA1: ;
	return result;
}

N_NIMCALL(Ttype216828*, makerangetype_266915)(Tcontext266020* c, NI64 first, NI64 last, Tlineinfo184337 info, Ttype216828* inttype) {
	Ttype216828* result;
	Tnode216790* n;
	Tnode216790* LOC1;
	Tnode216790* LOC2;
	result = 0;
	n = newnodei_218248(((NU8) 44), info);
	LOC1 = 0;
	LOC1 = newinttypenode_217665(((NU8) 6), first, inttype);
	addson_218807(n, LOC1);
	LOC2 = 0;
	LOC2 = newinttypenode_217665(((NU8) 6), last, inttype);
	addson_218807(n, LOC2);
	result = newtypes_266184(((NU8) 20), c);
	asgnRefNoCycle((void**) (&(*result).n), n);
	addsonskipintlit_260680(result, inttype);
	return result;
}

N_NIMCALL(Tnode216790*, makestaticexpr_266608)(Tcontext266020* c, Tnode216790* n) {
	Tnode216790* result;
	TY232280 LOC1;
	Ttypeseq216824* LOC2;
	TY368877 LOC3;
	result = 0;
	result = newnodei_218248(((NU8) 62), (*n).info);
	if ((*result).kindU.S6.sons) nimGCunrefNoCycle((*result).kindU.S6.sons);
	(*result).kindU.S6.sons = (Tnodeseq216784*) newSeqRC1((&NTI216784), 1);
	memset((void*)LOC1, 0, sizeof(LOC1));
	LOC1[0] = n;
	asgnRefNoCycle((void**) (&(*result).kindU.S6.sons->data[0]), LOC1[0]);
	LOC2 = 0;
	LOC2 = (Ttypeseq216824*) newSeq((&NTI216824), 1);
	memset((void*)LOC3, 0, sizeof(LOC3));
	LOC3[0] = (*n).typ;
	asgnRefNoCycle((void**) (&LOC2->data[0]), LOC3[0]);
	asgnRefNoCycle((void**) (&(*result).typ), newtypewithsons_266601(c, ((NU8) 59), LOC2));
	return result;
}

N_NIMCALL(Ttype216828*, makeandtype_266640)(Tcontext266020* c, Ttype216828* t1, Ttype216828* t2) {
	Ttype216828* result;
	TY266646 LOC1;
	result = 0;
	result = newtypes_266184(((NU8) 55), c);
	if ((*result).sons) nimGCunrefNoCycle((*result).sons);
	(*result).sons = (Ttypeseq216824*) newSeqRC1((&NTI216824), 2);
	memset((void*)LOC1, 0, sizeof(LOC1));
	LOC1[0] = t1;
	LOC1[1] = t2;
	asgnRefNoCycle((void**) (&(*result).sons->data[0]), LOC1[0]);
	asgnRefNoCycle((void**) (&(*result).sons->data[1]), LOC1[1]);
	propagatetoowner_220190(result, t1);
	propagatetoowner_220190(result, t2);
	(*result).flags = ((*result).flags | (((*t1).flags | (*t2).flags) & 4194304));
	(*result).flags |= ((NU32)1)<<((((NU8) 19))%(sizeof(NU32)*8));
	return result;
}

N_NIMCALL(Ttype216828*, makeortype_266707)(Tcontext266020* c, Ttype216828* t1, Ttype216828* t2) {
	Ttype216828* result;
	TY266646 LOC1;
	result = 0;
	result = newtypes_266184(((NU8) 56), c);
	if ((*result).sons) nimGCunrefNoCycle((*result).sons);
	(*result).sons = (Ttypeseq216824*) newSeqRC1((&NTI216824), 2);
	memset((void*)LOC1, 0, sizeof(LOC1));
	LOC1[0] = t1;
	LOC1[1] = t2;
	asgnRefNoCycle((void**) (&(*result).sons->data[0]), LOC1[0]);
	asgnRefNoCycle((void**) (&(*result).sons->data[1]), LOC1[1]);
	propagatetoowner_220190(result, t1);
	propagatetoowner_220190(result, t2);
	(*result).flags = ((*result).flags | (((*t1).flags | (*t2).flags) & 4194304));
	(*result).flags |= ((NU32)1)<<((((NU8) 19))%(sizeof(NU32)*8));
	return result;
}

N_NIMCALL(Ttype216828*, makenottype_266774)(Tcontext266020* c, Ttype216828* t1) {
	Ttype216828* result;
	TY368877 LOC1;
	result = 0;
	result = newtypes_266184(((NU8) 57), c);
	if ((*result).sons) nimGCunrefNoCycle((*result).sons);
	(*result).sons = (Ttypeseq216824*) newSeqRC1((&NTI216824), 1);
	memset((void*)LOC1, 0, sizeof(LOC1));
	LOC1[0] = t1;
	asgnRefNoCycle((void**) (&(*result).sons->data[0]), LOC1[0]);
	propagatetoowner_220190(result, t1);
	(*result).flags = ((*result).flags | ((*t1).flags & 4194304));
	(*result).flags |= ((NU32)1)<<((((NU8) 19))%(sizeof(NU32)*8));
	return result;
}

N_NIMCALL(void, checkminsonslen_266962)(Tnode216790* n, NI length) {
	{
		NI LOC3;
		LOC3 = 0;
		LOC3 = sonslen_219351(n);
		if (!(LOC3 < length)) goto LA4;
		illformedast_266950(n);
	}
	LA4: ;
}

N_NIMCALL(Tnode216790*, nminusone_266828)(Tnode216790* n) {
	Tnode216790* result;
	Tnodeseq216784* LOC1;
	TY384939 LOC2;
	Tsym216822* LOC3;
	result = 0;
	LOC1 = 0;
	LOC1 = (Tnodeseq216784*) newSeq((&NTI216784), 2);
	memset((void*)LOC2, 0, sizeof(LOC2));
	LOC3 = 0;
	LOC3 = getsysmagic_260079(((NimStringDesc*) &TMP3164), ((NU8) 25));
	LOC2[0] = newsymnode_218234(LOC3);
	LOC2[1] = n;
	asgnRefNoCycle((void**) (&LOC1->data[0]), LOC2[0]);
	asgnRefNoCycle((void**) (&LOC1->data[1]), LOC2[1]);
	result = newnode_218601(((NU8) 27), (*n).info, LOC1, NIM_NIL);
	return result;
}

N_NIMCALL(Ttype216828*, makerangewithstaticexpr_266845)(Tcontext266020* c, Tnode216790* n) {
	Ttype216828* result;
	Ttype216828* inttype;
	TY368877 LOC1;
	Tnodeseq216784* LOC2;
	TY384939 LOC3;
	Tnode216790* LOC4;
	result = 0;
	inttype = getsystype_260130(((NU8) 31));
	result = newtypes_266184(((NU8) 20), c);
	if ((*result).sons) nimGCunrefNoCycle((*result).sons);
	(*result).sons = (Ttypeseq216824*) newSeqRC1((&NTI216824), 1);
	memset((void*)LOC1, 0, sizeof(LOC1));
	LOC1[0] = inttype;
	asgnRefNoCycle((void**) (&(*result).sons->data[0]), LOC1[0]);
	LOC2 = 0;
	LOC2 = (Tnodeseq216784*) newSeq((&NTI216784), 2);
	memset((void*)LOC3, 0, sizeof(LOC3));
	LOC3[0] = newinttypenode_217665(((NU8) 6), IL64(0), inttype);
	LOC4 = 0;
	LOC4 = nminusone_266828(n);
	LOC3[1] = makestaticexpr_266608(c, LOC4);
	asgnRefNoCycle((void**) (&LOC2->data[0]), LOC3[0]);
	asgnRefNoCycle((void**) (&LOC2->data[1]), LOC3[1]);
	asgnRefNoCycle((void**) (&(*result).n), newnode_218601(((NU8) 44), (*n).info, LOC2, NIM_NIL));
	return result;
}

N_NIMCALL(void, pushowner_266211)(Tsym216822* owner) {
	gowners_266233 = (Tsymseq216792*) incrSeqV2(&(gowners_266233)->Sup, sizeof(Tsym216822*));
	asgnRefNoCycle((void**) (&gowners_266233->data[gowners_266233->Sup.len]), owner);
	++gowners_266233->Sup.len;
}

N_NIMCALL(void, makeinstpair_266153)(Tsym216822* s, Tinstantiation216812* inst, Tinstantiationpair266010* Result) {
	unsureAsgnRef((void**) (&(*Result).genericsym), s);
	unsureAsgnRef((void**) (&(*Result).inst), inst);
}

N_NIMCALL(Tlib216808*, newlib_266173)(NU8 kind) {
	Tlib216808* result;
	result = 0;
	result = (Tlib216808*) newObj((&NTI216820), sizeof(Tlib216808));
	(*result).Sup.Sup.m_type = (&NTI216808);
	(*result).kind = kind;
	return result;
}

N_NIMCALL(void, addtolib_266176)(Tlib216808* lib, Tsym216822* sym) {
	asgnRef((void**) (&(*sym).annex), lib);
}

N_NIMCALL(void, illformedastlocal_266954)(Tnode216790* n) {
	NimStringDesc* LOC1;
	LOC1 = 0;
	LOC1 = rendertree_235044(n, 4);
	localerror_189080((*n).info, ((NU16) 1), LOC1);
}

N_NIMCALL(Toptionentry266002*, lastoptionentry_266168)(Tcontext266020* c) {
	Toptionentry266002* result;
	result = 0;
	result = ((Toptionentry266002*) ((*c).optionstack.tail));
	return result;
}

N_NIMCALL(void, popowner_266214)(void) {
	NI length;
	length = (gowners_266233 ? gowners_266233->Sup.len : 0);
	{
		if (!(((NI) 0) < length)) goto LA3;
		gowners_266233 = (Tsymseq216792*) setLengthSeq(&(gowners_266233)->Sup, sizeof(Tsym216822*), ((NI) ((NI)(length - ((NI) 1)))));
	}
	goto LA1;
	LA3: ;
	{
		internalerror_189113(((NimStringDesc*) &TMP3333));
	}
	LA1: ;
}

N_NIMCALL(Ttype216828*, makeptrtype_266180)(Tcontext266020* c, Ttype216828* basetype) {
	Ttype216828* result;
	result = 0;
	result = newtypes_266184(((NU8) 21), c);
	{
		NimStringDesc* LOC5;
		if (!(basetype == NIM_NIL)) goto LA3;
		LOC5 = 0;
		LOC5 = HEX24_189183(TMP3376);
		internalerror_189113(LOC5);
	}
	LA3: ;
	addsonskipintlit_260680(result, basetype);
	return result;
}

N_NIMCALL(Tnode216790*, errornode_266905)(Tcontext266020* c, Tnode216790* n) {
	Tnode216790* result;
	result = 0;
	result = newnodei_218248(((NU8) 1), (*n).info);
	asgnRefNoCycle((void**) (&(*result).typ), errortype_266901(c));
	return result;
}

N_NIMCALL(Tnode216790*, maketypesymnode_266547)(Tcontext266020* c, Ttype216828* typ, Tlineinfo184337 info) {
	Tnode216790* result;
	Ttype216828* typedesc;
	Tsym216822* sym;
	Tsym216822* LOC1;
	Tsym216822* LOC2;
{	result = 0;
	typedesc = maketypedesc_266523(c, typ);
	LOC1 = 0;
	LOC1 = getcurrowner_266209();
	LOC2 = 0;
	LOC2 = newsym_217683(((NU8) 7), idanon_191455, LOC1, info);
	sym = linkto_217854(LOC2, typedesc);
	result = newsymnode_218241(sym, info);
	goto BeforeRet;
	}BeforeRet: ;
	return result;
}

N_NIMCALL(void, inclsym_266393)(Tsymseq216792** sq, Tsym216822* s) {
	NI L;
{	L = ((*sq) ? (*sq)->Sup.len : 0);
	{
		NI i_266418;
		NI HEX3Atmp_266432;
		NI res_266435;
		i_266418 = 0;
		HEX3Atmp_266432 = 0;
		HEX3Atmp_266432 = (NI)(L - ((NI) 1));
		res_266435 = ((NI) 0);
		{
			while (1) {
				if (!(res_266435 <= HEX3Atmp_266432)) goto LA3;
				i_266418 = res_266435;
				{
					if (!((*(*sq)->data[i_266418]).Sup.id == (*s).Sup.id)) goto LA6;
					goto BeforeRet;
				}
				LA6: ;
				res_266435 += ((NI) 1);
			} LA3: ;
		}
	}
	(*sq) = (Tsymseq216792*) setLengthSeq(&((*sq))->Sup, sizeof(Tsym216822*), ((NI) ((NI)(L + ((NI) 1)))));
	asgnRefNoCycle((void**) (&(*sq)->data[L]), s);
	}BeforeRet: ;
}

N_NIMCALL(void, addconverter_266439)(Tcontext266020* c, Tsym216822* conv) {
	inclsym_266393((&(*c).converters), conv);
}

N_NIMCALL(void, addpattern_266444)(Tcontext266020* c, Tsym216822* p) {
	inclsym_266393((&(*c).patterns), p);
}
NIM_EXTERNC N_NOINLINE(void, compiler_semdataInit000)(void) {
	if (gowners_266233) nimGCunrefNoCycle(gowners_266233);
	gowners_266233 = (Tsymseq216792*) newSeqRC1((&NTI216792), 0);
}

NIM_EXTERNC N_NOINLINE(void, compiler_semdataDatInit000)(void) {
static TNimNode* TMP2069[38];
static TNimNode* TMP2070[8];
static TNimNode* TMP2072[2];
static TNimNode* TMP2073[2];
static TNimNode* TMP2095[2];
static TNimNode* TMP2098[5];
static TNimNode TMP943[63];
NTI266020.size = sizeof(Tcontext266020);
NTI266020.kind = 17;
NTI266020.base = (&NTI263002);
TMP2069[0] = &TMP943[1];
TMP943[1].kind = 1;
TMP943[1].offset = offsetof(Tcontext266020, module);
TMP943[1].typ = (&NTI216788);
TMP943[1].name = "module";
TMP2069[1] = &TMP943[2];
TMP943[2].kind = 1;
TMP943[2].offset = offsetof(Tcontext266020, currentscope);
TMP943[2].typ = (&NTI216818);
TMP943[2].name = "currentScope";
TMP2069[2] = &TMP943[3];
TMP943[3].kind = 1;
TMP943[3].offset = offsetof(Tcontext266020, importtable);
TMP943[3].typ = (&NTI216818);
TMP943[3].name = "importTable";
TMP2069[3] = &TMP943[4];
TMP943[4].kind = 1;
TMP943[4].offset = offsetof(Tcontext266020, toplevelscope);
TMP943[4].typ = (&NTI216818);
TMP943[4].name = "topLevelScope";
TMP2069[4] = &TMP943[5];
NTI266008.size = sizeof(Tproccon266008);
NTI266008.kind = 18;
NTI266008.base = 0;
TMP2070[0] = &TMP943[7];
TMP943[7].kind = 1;
TMP943[7].offset = offsetof(Tproccon266008, owner);
TMP943[7].typ = (&NTI216788);
TMP943[7].name = "owner";
TMP2070[1] = &TMP943[8];
TMP943[8].kind = 1;
TMP943[8].offset = offsetof(Tproccon266008, resultsym);
TMP943[8].typ = (&NTI216788);
TMP943[8].name = "resultSym";
TMP2070[2] = &TMP943[9];
TMP943[9].kind = 1;
TMP943[9].offset = offsetof(Tproccon266008, nestedloopcounter);
TMP943[9].typ = (&NTI104);
TMP943[9].name = "nestedLoopCounter";
TMP2070[3] = &TMP943[10];
TMP943[10].kind = 1;
TMP943[10].offset = offsetof(Tproccon266008, nestedblockcounter);
TMP943[10].typ = (&NTI104);
TMP943[10].name = "nestedBlockCounter";
TMP2070[4] = &TMP943[11];
TMP943[11].kind = 1;
TMP943[11].offset = offsetof(Tproccon266008, intrystmt);
TMP943[11].typ = (&NTI104);
TMP943[11].name = "inTryStmt";
TMP2070[5] = &TMP943[12];
TMP943[12].kind = 1;
TMP943[12].offset = offsetof(Tproccon266008, next);
TMP943[12].typ = (&NTI266006);
TMP943[12].name = "next";
TMP2070[6] = &TMP943[13];
TMP943[13].kind = 1;
TMP943[13].offset = offsetof(Tproccon266008, wasforwarded);
TMP943[13].typ = (&NTI130);
TMP943[13].name = "wasForwarded";
TMP2070[7] = &TMP943[14];
TMP943[14].kind = 1;
TMP943[14].offset = offsetof(Tproccon266008, bracketexpr);
TMP943[14].typ = (&NTI216782);
TMP943[14].name = "bracketExpr";
TMP943[6].len = 8; TMP943[6].kind = 2; TMP943[6].sons = &TMP2070[0];
NTI266008.node = &TMP943[6];
NTI266006.size = sizeof(Tproccon266008*);
NTI266006.kind = 22;
NTI266006.base = (&NTI266008);
NTI266006.marker = TMP2071;
TMP943[5].kind = 1;
TMP943[5].offset = offsetof(Tcontext266020, p);
TMP943[5].typ = (&NTI266006);
TMP943[5].name = "p";
TMP2069[5] = &TMP943[15];
TMP943[15].kind = 1;
TMP943[15].offset = offsetof(Tcontext266020, friendmodules);
TMP943[15].typ = (&NTI216792);
TMP943[15].name = "friendModules";
TMP2069[6] = &TMP943[16];
TMP943[16].kind = 1;
TMP943[16].offset = offsetof(Tcontext266020, instcounter);
TMP943[16].typ = (&NTI104);
TMP943[16].name = "instCounter";
TMP2069[7] = &TMP943[17];
TMP943[17].kind = 1;
TMP943[17].offset = offsetof(Tcontext266020, ambiguoussymbols);
TMP943[17].typ = (&NTI213035);
TMP943[17].name = "ambiguousSymbols";
TMP2069[8] = &TMP943[18];
TMP943[18].kind = 1;
TMP943[18].offset = offsetof(Tcontext266020, intypeclass);
TMP943[18].typ = (&NTI104);
TMP943[18].name = "inTypeClass";
TMP2069[9] = &TMP943[19];
TMP943[19].kind = 1;
TMP943[19].offset = offsetof(Tcontext266020, ingenericcontext);
TMP943[19].typ = (&NTI104);
TMP943[19].name = "inGenericContext";
TMP2069[10] = &TMP943[20];
TMP943[20].kind = 1;
TMP943[20].offset = offsetof(Tcontext266020, inunrolledcontext);
TMP943[20].typ = (&NTI104);
TMP943[20].name = "inUnrolledContext";
TMP2069[11] = &TMP943[21];
TMP943[21].kind = 1;
TMP943[21].offset = offsetof(Tcontext266020, compilescontextid);
TMP943[21].typ = (&NTI104);
TMP943[21].name = "compilesContextId";
TMP2069[12] = &TMP943[22];
TMP943[22].kind = 1;
TMP943[22].offset = offsetof(Tcontext266020, compilescontextidgenerator);
TMP943[22].typ = (&NTI104);
TMP943[22].name = "compilesContextIdGenerator";
TMP2069[13] = &TMP943[23];
TMP943[23].kind = 1;
TMP943[23].offset = offsetof(Tcontext266020, ingenericinst);
TMP943[23].typ = (&NTI104);
TMP943[23].name = "inGenericInst";
TMP2069[14] = &TMP943[24];
TMP943[24].kind = 1;
TMP943[24].offset = offsetof(Tcontext266020, converters);
TMP943[24].typ = (&NTI216792);
TMP943[24].name = "converters";
TMP2069[15] = &TMP943[25];
TMP943[25].kind = 1;
TMP943[25].offset = offsetof(Tcontext266020, patterns);
TMP943[25].typ = (&NTI216792);
TMP943[25].name = "patterns";
TMP2069[16] = &TMP943[26];
TMP943[26].kind = 1;
TMP943[26].offset = offsetof(Tcontext266020, optionstack);
TMP943[26].typ = (&NTI138016);
TMP943[26].name = "optionStack";
TMP2069[17] = &TMP943[27];
TMP943[27].kind = 1;
TMP943[27].offset = offsetof(Tcontext266020, symmapping);
TMP943[27].typ = (&NTI216840);
TMP943[27].name = "symMapping";
TMP2069[18] = &TMP943[28];
TMP943[28].kind = 1;
TMP943[28].offset = offsetof(Tcontext266020, libs);
TMP943[28].typ = (&NTI138016);
TMP943[28].name = "libs";
TMP2069[19] = &TMP943[29];
NTI266071.size = sizeof(TY266071);
NTI266071.kind = 25;
NTI266071.base = 0;
NTI266071.flags = 3;
TMP943[29].kind = 1;
TMP943[29].offset = offsetof(Tcontext266020, semconstexpr);
TMP943[29].typ = (&NTI266071);
TMP943[29].name = "semConstExpr";
TMP2069[20] = &TMP943[30];
NTI266076.size = sizeof(TY266076);
NTI266076.kind = 25;
NTI266076.base = 0;
NTI266076.flags = 3;
TMP943[30].kind = 1;
TMP943[30].offset = offsetof(Tcontext266020, semexpr);
TMP943[30].typ = (&NTI266076);
TMP943[30].name = "semExpr";
TMP2069[21] = &TMP943[31];
NTI266084.size = sizeof(TY266084);
NTI266084.kind = 25;
NTI266084.base = 0;
NTI266084.flags = 3;
TMP943[31].kind = 1;
TMP943[31].offset = offsetof(Tcontext266020, semtryexpr);
TMP943[31].typ = (&NTI266084);
TMP943[31].name = "semTryExpr";
TMP2069[22] = &TMP943[32];
NTI266092.size = sizeof(TY266092);
NTI266092.kind = 25;
NTI266092.base = 0;
NTI266092.flags = 3;
TMP943[32].kind = 1;
TMP943[32].offset = offsetof(Tcontext266020, semtryconstexpr);
TMP943[32].typ = (&NTI266092);
TMP943[32].name = "semTryConstExpr";
TMP2069[23] = &TMP943[33];
NTI266097.size = sizeof(TY266097);
NTI266097.kind = 25;
NTI266097.base = 0;
NTI266097.flags = 3;
TMP943[33].kind = 1;
TMP943[33].offset = offsetof(Tcontext266020, semoperand);
TMP943[33].typ = (&NTI266097);
TMP943[33].name = "semOperand";
TMP2069[24] = &TMP943[34];
NTI266105.size = sizeof(TY266105);
NTI266105.kind = 25;
NTI266105.base = 0;
NTI266105.flags = 3;
TMP943[34].kind = 1;
TMP943[34].offset = offsetof(Tcontext266020, semconstboolexpr);
TMP943[34].typ = (&NTI266105);
TMP943[34].name = "semConstBoolExpr";
TMP2069[25] = &TMP943[35];
NTI266110.size = sizeof(TY266110);
NTI266110.kind = 25;
NTI266110.base = 0;
NTI266110.flags = 3;
TMP943[35].kind = 1;
TMP943[35].offset = offsetof(Tcontext266020, semoverloadedcall);
TMP943[35].typ = (&NTI266110);
TMP943[35].name = "semOverloadedCall";
TMP2069[26] = &TMP943[36];
NTI266117.size = sizeof(TY266117);
NTI266117.kind = 25;
NTI266117.base = 0;
NTI266117.flags = 3;
TMP943[36].kind = 1;
TMP943[36].offset = offsetof(Tcontext266020, semtypenode);
TMP943[36].typ = (&NTI266117);
TMP943[36].name = "semTypeNode";
TMP2069[27] = &TMP943[37];
NTI266123.size = sizeof(TY533873);
NTI266123.kind = 18;
NTI266123.base = 0;
NTI266123.flags = 2;
TMP2072[0] = &TMP943[39];
TMP943[39].kind = 1;
TMP943[39].offset = offsetof(TY533873, Field0);
TMP943[39].typ = (&NTI142);
TMP943[39].name = "Field0";
TMP2072[1] = &TMP943[40];
TMP943[40].kind = 1;
TMP943[40].offset = offsetof(TY533873, Field1);
TMP943[40].typ = (&NTI533875);
TMP943[40].name = "Field1";
TMP943[38].len = 2; TMP943[38].kind = 2; TMP943[38].sons = &TMP2072[0];
NTI266123.node = &TMP943[38];
TMP943[37].kind = 1;
TMP943[37].offset = offsetof(Tcontext266020, seminferredlambda);
TMP943[37].typ = (&NTI266123);
TMP943[37].name = "semInferredLambda";
TMP2069[28] = &TMP943[41];
NTI266129.size = sizeof(TY533873);
NTI266129.kind = 18;
NTI266129.base = 0;
NTI266129.flags = 2;
TMP2073[0] = &TMP943[43];
TMP943[43].kind = 1;
TMP943[43].offset = offsetof(TY533873, Field0);
TMP943[43].typ = (&NTI142);
TMP943[43].name = "Field0";
TMP2073[1] = &TMP943[44];
TMP943[44].kind = 1;
TMP943[44].offset = offsetof(TY533873, Field1);
TMP943[44].typ = (&NTI533875);
TMP943[44].name = "Field1";
TMP943[42].len = 2; TMP943[42].kind = 2; TMP943[42].sons = &TMP2073[0];
NTI266129.node = &TMP943[42];
TMP943[41].kind = 1;
TMP943[41].offset = offsetof(Tcontext266020, semgenerateinstance);
TMP943[41].typ = (&NTI266129);
TMP943[41].name = "semGenerateInstance";
TMP2069[29] = &TMP943[45];
TMP943[45].kind = 1;
TMP943[45].offset = offsetof(Tcontext266020, includedfiles);
TMP943[45].typ = (&NTI213035);
TMP943[45].name = "includedFiles";
TMP2069[30] = &TMP943[46];
TMP943[46].kind = 1;
TMP943[46].offset = offsetof(Tcontext266020, userpragmas);
TMP943[46].typ = (&NTI216794);
TMP943[46].name = "userPragmas";
TMP2069[31] = &TMP943[47];
TMP943[47].kind = 1;
TMP943[47].offset = offsetof(Tcontext266020, evalcontext);
TMP943[47].typ = (&NTI265034);
TMP943[47].name = "evalContext";
TMP2069[32] = &TMP943[48];
TMP943[48].kind = 1;
TMP943[48].offset = offsetof(Tcontext266020, unknownidents);
TMP943[48].typ = (&NTI213035);
TMP943[48].name = "unknownIdents";
TMP2069[33] = &TMP943[49];
NTI266010.size = sizeof(Tinstantiationpair266010);
NTI266010.kind = 18;
NTI266010.base = 0;
NTI266010.flags = 2;
TMP2095[0] = &TMP943[51];
TMP943[51].kind = 1;
TMP943[51].offset = offsetof(Tinstantiationpair266010, genericsym);
TMP943[51].typ = (&NTI216788);
TMP943[51].name = "genericSym";
TMP2095[1] = &TMP943[52];
TMP943[52].kind = 1;
TMP943[52].offset = offsetof(Tinstantiationpair266010, inst);
TMP943[52].typ = (&NTI216814);
TMP943[52].name = "inst";
TMP943[50].len = 2; TMP943[50].kind = 2; TMP943[50].sons = &TMP2095[0];
NTI266010.node = &TMP943[50];
NTI266140.size = sizeof(TY266140*);
NTI266140.kind = 24;
NTI266140.base = (&NTI266010);
NTI266140.flags = 2;
NTI266140.marker = TMP2096;
TMP943[49].kind = 1;
TMP943[49].offset = offsetof(Tcontext266020, generics);
TMP943[49].typ = (&NTI266140);
TMP943[49].name = "generics";
TMP2069[34] = &TMP943[53];
TMP943[53].kind = 1;
TMP943[53].offset = offsetof(Tcontext266020, lastgenericidx);
TMP943[53].typ = (&NTI104);
TMP943[53].name = "lastGenericIdx";
TMP2069[35] = &TMP943[54];
TMP943[54].kind = 1;
TMP943[54].offset = offsetof(Tcontext266020, hloloopdetector);
TMP943[54].typ = (&NTI104);
TMP943[54].name = "hloLoopDetector";
TMP2069[36] = &TMP943[55];
TMP943[55].kind = 1;
TMP943[55].offset = offsetof(Tcontext266020, inparallelstmt);
TMP943[55].typ = (&NTI104);
TMP943[55].name = "inParallelStmt";
TMP2069[37] = &TMP943[56];
NTI266145.size = sizeof(TY266145);
NTI266145.kind = 25;
NTI266145.base = 0;
NTI266145.flags = 3;
TMP943[56].kind = 1;
TMP943[56].offset = offsetof(Tcontext266020, insttypeboundop);
TMP943[56].typ = (&NTI266145);
TMP943[56].name = "instTypeBoundOp";
TMP943[0].len = 38; TMP943[0].kind = 2; TMP943[0].sons = &TMP2069[0];
NTI266020.node = &TMP943[0];
NTI266018.size = sizeof(Tcontext266020*);
NTI266018.kind = 22;
NTI266018.base = (&NTI266020);
NTI266018.marker = TMP2097;
NTI266002.size = sizeof(Toptionentry266002);
NTI266002.kind = 17;
NTI266002.base = (&NTI138010);
TMP2098[0] = &TMP943[58];
TMP943[58].kind = 1;
TMP943[58].offset = offsetof(Toptionentry266002, options);
TMP943[58].typ = (&NTI163011);
TMP943[58].name = "options";
TMP2098[1] = &TMP943[59];
TMP943[59].kind = 1;
TMP943[59].offset = offsetof(Toptionentry266002, defaultcc);
TMP943[59].typ = (&NTI216002);
TMP943[59].name = "defaultCC";
TMP2098[2] = &TMP943[60];
TMP943[60].kind = 1;
TMP943[60].offset = offsetof(Toptionentry266002, dynlib);
TMP943[60].typ = (&NTI216820);
TMP943[60].name = "dynlib";
TMP2098[3] = &TMP943[61];
TMP943[61].kind = 1;
TMP943[61].offset = offsetof(Toptionentry266002, notes);
TMP943[61].typ = (&NTI184333);
TMP943[61].name = "notes";
TMP2098[4] = &TMP943[62];
TMP943[62].kind = 1;
TMP943[62].offset = offsetof(Toptionentry266002, otherpragmas);
TMP943[62].typ = (&NTI216782);
TMP943[62].name = "otherPragmas";
TMP943[57].len = 5; TMP943[57].kind = 2; TMP943[57].sons = &TMP2098[0];
NTI266002.node = &TMP943[57];
NTI266004.size = sizeof(Toptionentry266002*);
NTI266004.kind = 22;
NTI266004.base = (&NTI266002);
NTI266004.marker = TMP2102;
}

