/* 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 <setjmp.h>
#include <string.h>
typedef struct Suggest368803 Suggest368803;
typedef struct Tsym214822 Tsym214822;
typedef struct Tlineinfo182337 Tlineinfo182337;
typedef struct Tcontext264020 Tcontext264020;
typedef struct Tnode214790 Tnode214790;
typedef struct Ttype214828 Ttype214828;
typedef struct NimStringDesc NimStringDesc;
typedef struct TGenericSeq TGenericSeq;
typedef struct Tident189012 Tident189012;
typedef struct Tnodeseq214784 Tnodeseq214784;
typedef struct Tpasscontext261002 Tpasscontext261002;
typedef struct TNimObject TNimObject;
typedef struct TNimType TNimType;
typedef struct TNimNode TNimNode;
typedef struct Tscope214816 Tscope214816;
typedef struct Tproccon264008 Tproccon264008;
typedef struct Tsymseq214792 Tsymseq214792;
typedef struct Intset211035 Intset211035;
typedef struct Trunk211031 Trunk211031;
typedef struct Trunkseq211033 Trunkseq211033;
typedef struct Tlinkedlist135016 Tlinkedlist135016;
typedef struct Tlistentry135010 Tlistentry135010;
typedef struct Tidtable214840 Tidtable214840;
typedef struct Tidpairseq214838 Tidpairseq214838;
typedef struct Tstrtable214794 Tstrtable214794;
typedef struct Tctx263036 Tctx263036;
typedef struct TY264140 TY264140;
typedef struct Exception Exception;
typedef struct TSafePoint TSafePoint;
typedef struct Cell47505 Cell47505;
typedef struct Cellset47517 Cellset47517;
typedef struct Gcheap49818 Gcheap49818;
typedef struct Gcstack49816 Gcstack49816;
typedef struct Cellseq47521 Cellseq47521;
typedef struct Pagedesc47513 Pagedesc47513;
typedef struct Memregion29688 Memregion29688;
typedef struct Smallchunk29640 Smallchunk29640;
typedef struct Llchunk29682 Llchunk29682;
typedef struct Bigchunk29642 Bigchunk29642;
typedef struct Intset29614 Intset29614;
typedef struct Trunk29610 Trunk29610;
typedef struct Avlnode29686 Avlnode29686;
typedef struct Gcstat49814 Gcstat49814;
typedef struct Tidobj189006 Tidobj189006;
typedef struct Ttypeseq214824 Ttypeseq214824;
typedef struct TY214925 TY214925;
typedef struct Tloc214804 Tloc214804;
typedef struct Ropeobj169006 Ropeobj169006;
typedef struct Tlib214808 Tlib214808;
typedef struct Ttabiter221071 Ttabiter221071;
typedef struct TY125202 TY125202;
typedef struct Tdocumentor359004 Tdocumentor359004;
typedef struct Tcandidate362206 Tcandidate362206;
typedef struct TY88487 TY88487;
typedef struct Tidpair214836 Tidpair214836;
typedef struct TY263242 TY263242;
typedef struct TY183090 TY183090;
typedef struct PprocHEX3Aobjecttype263221 PprocHEX3Aobjecttype263221;
typedef struct TY263261 TY263261;
typedef struct Tinstantiationpair264010 Tinstantiationpair264010;
typedef struct Tinstantiation214812 Tinstantiation214812;
typedef struct Basechunk29638 Basechunk29638;
typedef struct Freecell29630 Freecell29630;
typedef struct Rstgenerator326010 Rstgenerator326010;
typedef struct Stringtableobj140209 Stringtableobj140209;
typedef struct TY326029 TY326029;
typedef struct Table326047 Table326047;
typedef struct Keyvaluepairseq326050 Keyvaluepairseq326050;
typedef struct TY263222 TY263222;
typedef struct TY263227 TY263227;
typedef struct TY263262 TY263262;
typedef struct Vmargs263030 Vmargs263030;
typedef struct TY214913 TY214913;
typedef struct Keyvaluepairseq140207 Keyvaluepairseq140207;
typedef struct Tocentry326006 Tocentry326006;
typedef struct Rstnode313008 Rstnode313008;
typedef struct Keyvaluepair326053 Keyvaluepair326053;
typedef struct Tblock263018 Tblock263018;
typedef struct TY263202 TY263202;
typedef struct Keyvaluepair140205 Keyvaluepair140205;
typedef struct Rstnodeseq313006 Rstnodeseq313006;
typedef struct {
N_NIMCALL_PTR(void, ClPrc) (Suggest368803* result, void* ClEnv);
void* ClEnv;
} TY368818;
struct  Tlineinfo182337  {
NI16 line;
NI16 col;
NI32 fileindex;
};
struct  TGenericSeq  {
NI len;
NI reserved;
};
struct  NimStringDesc  {
  TGenericSeq Sup;
NIM_CHAR data[SEQ_DECL_SIZE];
};
struct  Tnode214790  {
Ttype214828* typ;
Tlineinfo182337 info;
NU16 flags;
NU8 kind;
union{
struct {NI64 intval;
} S1;
struct {NF floatval;
} S2;
struct {NimStringDesc* strval;
} S3;
struct {Tsym214822* sym;
} S4;
struct {Tident189012* ident;
} S5;
struct {Tnodeseq214784* sons;
} S6;
} kindU;
NimStringDesc* comment;
};
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  TNimObject  {
TNimType* m_type;
};
struct  Tpasscontext261002  {
  TNimObject Sup;
NIM_BOOL fromcache;
};
struct  Intset211035  {
NI counter;
NI max;
Trunk211031* head;
Trunkseq211033* data;
};
struct  Tlinkedlist135016  {
Tlistentry135010* head;
Tlistentry135010* tail;
NI counter;
};
struct  Tidtable214840  {
NI counter;
Tidpairseq214838* data;
};
typedef N_NIMCALL_PTR(Tnode214790*, TY264071) (Tcontext264020* c, Tnode214790* n);
typedef N_NIMCALL_PTR(Tnode214790*, TY264076) (Tcontext264020* c, Tnode214790* n, NU16 flags);
typedef N_NIMCALL_PTR(Tnode214790*, TY264084) (Tcontext264020* c, Tnode214790* n, NU16 flags);
typedef N_NIMCALL_PTR(Tnode214790*, TY264092) (Tcontext264020* c, Tnode214790* n);
typedef N_NIMCALL_PTR(Tnode214790*, TY264097) (Tcontext264020* c, Tnode214790* n, NU16 flags);
typedef N_NIMCALL_PTR(Tnode214790*, TY264105) (Tcontext264020* c, Tnode214790* n);
typedef N_NIMCALL_PTR(Tnode214790*, TY264110) (Tcontext264020* c, Tnode214790* n, Tnode214790* norig, NU32 filter);
typedef N_NIMCALL_PTR(Ttype214828*, TY264117) (Tcontext264020* c, Tnode214790* n, Ttype214828* prev);
typedef struct {
N_NIMCALL_PTR(Tnode214790*, ClPrc) (Tcontext264020* c, Tidtable214840 pt, Tnode214790* n, void* ClEnv);
void* ClEnv;
} TY264123;
typedef struct {
N_NIMCALL_PTR(Tsym214822*, ClPrc) (Tcontext264020* c, Tsym214822* fn, Tidtable214840 pt, Tlineinfo182337 info, void* ClEnv);
void* ClEnv;
} TY264129;
struct  Tstrtable214794  {
NI counter;
Tsymseq214792* data;
};
typedef N_NIMCALL_PTR(Tsym214822*, TY264145) (Tcontext264020* c, Tsym214822* dc, Ttype214828* t, Tlineinfo182337 info, NU8 op);
struct  Tcontext264020  {
  Tpasscontext261002 Sup;
Tsym214822* module;
Tscope214816* currentscope;
Tscope214816* importtable;
Tscope214816* toplevelscope;
Tproccon264008* p;
Tsymseq214792* friendmodules;
NI instcounter;
Intset211035 ambiguoussymbols;
NI intypeclass;
NI ingenericcontext;
NI inunrolledcontext;
NI compilescontextid;
NI compilescontextidgenerator;
NI ingenericinst;
Tsymseq214792* converters;
Tsymseq214792* patterns;
Tlinkedlist135016 optionstack;
Tidtable214840 symmapping;
Tlinkedlist135016 libs;
TY264071 semconstexpr;
TY264076 semexpr;
TY264084 semtryexpr;
TY264092 semtryconstexpr;
TY264097 semoperand;
TY264105 semconstboolexpr;
TY264110 semoverloadedcall;
TY264117 semtypenode;
TY264123 seminferredlambda;
TY264129 semgenerateinstance;
Intset211035 includedfiles;
Tstrtable214794 userpragmas;
Tctx263036* evalcontext;
Intset211035 unknownidents;
TY264140* generics;
NI lastgenericidx;
NI hloloopdetector;
NI inparallelstmt;
TY264145 insttypeboundop;
};
struct  Exception  {
  TNimObject Sup;
Exception* parent;
NCSTRING name;
NimStringDesc* message;
NimStringDesc* trace;
};
typedef struct {
N_NIMCALL_PTR(NIM_BOOL, ClPrc) (Exception* e, void* ClEnv);
void* ClEnv;
} TY17811;
struct  TSafePoint  {
TSafePoint* prev;
NI status;
jmp_buf context;
NIM_BOOL hasRaiseAction;
TY17811 raiseAction;
};
struct  TNimNode  {
NU8 kind;
NI offset;
TNimType* typ;
NCSTRING name;
NI len;
TNimNode** sons;
};
struct  Cell47505  {
NI refcount;
TNimType* typ;
};
struct  Cellseq47521  {
NI len;
NI cap;
Cell47505** d;
};
struct  Cellset47517  {
NI counter;
NI max;
Pagedesc47513* head;
Pagedesc47513** data;
};
typedef Smallchunk29640* TY29703[512];
typedef Trunk29610* Trunkbuckets29612[256];
struct  Intset29614  {
Trunkbuckets29612 data;
};
struct  Memregion29688  {
NI minlargeobj;
NI maxlargeobj;
TY29703 freesmallchunks;
Llchunk29682* llmem;
NI currmem;
NI maxmem;
NI freemem;
NI lastsize;
Bigchunk29642* freechunkslist;
Intset29614 chunkstarts;
Avlnode29686* root;
Avlnode29686* deleted;
Avlnode29686* last;
Avlnode29686* freeavlnodes;
};
struct  Gcstat49814  {
NI stackscans;
NI cyclecollections;
NI maxthreshold;
NI maxstacksize;
NI maxstackcells;
NI cycletablesize;
NI64 maxpause;
};
struct  Gcheap49818  {
Gcstack49816* stack;
void* stackbottom;
NI cyclethreshold;
Cellseq47521 zct;
Cellseq47521 decstack;
Cellset47517 cycleroots;
Cellseq47521 tempstack;
NI recgclock;
Memregion29688 region;
Gcstat49814 stat;
};
struct  Tidobj189006  {
  TNimObject Sup;
NI id;
};
struct  Tloc214804  {
NU8 k;
NU8 s;
NU16 flags;
Ttype214828* t;
Ropeobj169006* r;
Ropeobj169006* heaproot;
};
struct  Tsym214822  {
  Tidobj189006 Sup;
NU8 kind;
union{
struct {Ttypeseq214824* typeinstcache;
Tscope214816* typscope;
} S1;
struct {TY214925* procinstcache;
Tsym214822* gcunsafetyreason;
} S2;
struct {TY214925* usedgenerics;
Tstrtable214794 tab;
} S3;
struct {Tsym214822* guard;
NI bitsize;
} S4;
} kindU;
NU8 magic;
Ttype214828* typ;
Tident189012* name;
Tlineinfo182337 info;
Tsym214822* owner;
NU32 flags;
Tnode214790* ast;
NU32 options;
NI position;
NI offset;
Tloc214804 loc;
Tlib214808* annex;
Tnode214790* constraint;
};
struct  Tscope214816  {
NI depthlevel;
Tstrtable214794 symbols;
Tnodeseq214784* usingsyms;
Tscope214816* parent;
};
struct  Ttabiter221071  {
NI h;
};
typedef N_CLOSURE_PTR(void, TMP2098) (Suggest368803* result);
struct  Suggest368803  {
NU8 section;
TY125202* qualifiedpath;
NimStringDesc* filepath;
NI line;
NI column;
NimStringDesc* doc;
NU8 symkind;
NimStringDesc* forth;
NI quality;
NIM_BOOL isglobal;
NI tokenlen;
};
struct  Tident189012  {
  Tidobj189006 Sup;
NimStringDesc* s;
Tident189012* next;
NI h;
};
struct  Ttype214828  {
  Tidobj189006 Sup;
NU8 kind;
NU8 callconv;
NU32 flags;
Ttypeseq214824* sons;
Tnode214790* n;
Tsym214822* owner;
Tsym214822* sym;
Tsym214822* destructor;
Tsym214822* deepcopy;
Tsym214822* assignment;
NI64 size;
NI16 align;
NI16 locklevel;
Tloc214804 loc;
};
typedef struct {
N_NIMCALL_PTR(NI, ClPrc) (Tsym214822* x_369850, Tsym214822* y_369852, void* ClEnv);
void* ClEnv;
} TY369848;
typedef N_CLOSURE_PTR(NI, TMP2774) (Tsym214822* x_371637, Tsym214822* y_371639, void* ClEnv);
struct  Tcandidate362206  {
Tcontext264020* c;
NI exactmatches;
NI genericmatches;
NI subtypematches;
NI intconvmatches;
NI convmatches;
NU8 state;
Ttype214828* callee;
Tsym214822* calleesym;
NI calleescope;
Tnode214790* call;
Tidtable214840 bindings;
NIM_BOOL basetypematch;
NU8 fauxmatch;
NIM_BOOL genericconverter;
NIM_BOOL coercedistincts;
NIM_BOOL typedescmatched;
NIM_BOOL isnocall;
NI inheritancepenalty;
Tsymseq214792* errors;
};
typedef Ttype214828* TY366877[1];
struct TY88487 {
NimStringDesc* Field0;
NI Field1;
};
typedef N_CLOSURE_PTR(Tnode214790*, TMP2809) (Tcontext264020* c, Tidtable214840 pt, Tnode214790* n);
typedef N_CLOSURE_PTR(Tsym214822*, TMP2810) (Tcontext264020* c, Tsym214822* fn, Tidtable214840 pt, Tlineinfo182337 info);
typedef N_CLOSURE_PTR(Tnode214790*, TMP2813) (Tcontext264020* c, Tidtable214840 pt, Tnode214790* n);
typedef N_CLOSURE_PTR(Tsym214822*, TMP2814) (Tcontext264020* c, Tsym214822* fn, Tidtable214840 pt, Tlineinfo182337 info);
typedef N_CLOSURE_PTR(NI, TMP2820) (Tsym214822* x_369837, Tsym214822* y_369839, void* ClEnv);
typedef N_CLOSURE_PTR(Tsym214822*, TMP3649) (Tcontext264020* c, Tsym214822* fn, Tidtable214840 pt, Tlineinfo182337 info);
struct  Tproccon264008  {
Tsym214822* owner;
Tsym214822* resultsym;
NI nestedloopcounter;
NI nestedblockcounter;
NI intrystmt;
Tproccon264008* next;
NIM_BOOL wasforwarded;
Tnode214790* bracketexpr;
};
typedef NI TY29619[8];
struct  Trunk211031  {
Trunk211031* next;
NI key;
TY29619 bits;
};
struct  Tlistentry135010  {
  TNimObject Sup;
Tlistentry135010* prev;
Tlistentry135010* next;
};
struct  Tidpair214836  {
Tidobj189006* key;
TNimObject* val;
};
struct  Tctx263036  {
  Tpasscontext261002 Sup;
TY263242* code;
TY183090* debug;
Tnode214790* globals;
Tnode214790* constants;
Ttypeseq214824* types;
Tnode214790* currentexceptiona;
Tnode214790* currentexceptionb;
NI exceptioninstr;
PprocHEX3Aobjecttype263221* prc;
Tsym214822* module;
Tnode214790* callsite;
NU8 mode;
NU8 features;
NIM_BOOL traceactive;
NI loopiterations;
Tlineinfo182337 comesfromheuristic;
TY263261* callbacks;
NimStringDesc* errorflag;
};
struct  Tinstantiationpair264010  {
Tsym214822* genericsym;
Tinstantiation214812* inst;
};
struct  Gcstack49816  {
Gcstack49816* prev;
Gcstack49816* next;
void* starts;
void* pos;
NI maxstacksize;
};
struct  Pagedesc47513  {
Pagedesc47513* next;
NI key;
TY29619 bits;
};
struct  Basechunk29638  {
NI prevsize;
NI size;
NIM_BOOL used;
};
struct  Smallchunk29640  {
  Basechunk29638 Sup;
Smallchunk29640* next;
Smallchunk29640* prev;
Freecell29630* freelist;
NI free;
NI acc;
NF data;
};
struct  Llchunk29682  {
NI size;
NI acc;
Llchunk29682* next;
};
struct  Bigchunk29642  {
  Basechunk29638 Sup;
Bigchunk29642* next;
Bigchunk29642* prev;
NI align;
NF data;
};
struct  Trunk29610  {
Trunk29610* next;
NI key;
TY29619 bits;
};
typedef Avlnode29686* TY29693[2];
struct  Avlnode29686  {
TY29693 link;
NI key;
NI upperbound;
NI level;
};
struct  Ropeobj169006  {
  TNimObject Sup;
Ropeobj169006* left;
Ropeobj169006* right;
NI length;
NimStringDesc* data;
};
struct  Tlib214808  {
  Tlistentry135010 Sup;
NU8 kind;
NIM_BOOL generated;
NIM_BOOL isoverriden;
Ropeobj169006* name;
Tnode214790* path;
};
typedef N_NIMCALL_PTR(NimStringDesc*, Findfilehandler314014) (NimStringDesc* filename);
typedef N_NIMCALL_PTR(void, Msghandler314012) (NimStringDesc* filename, NI line, NI col, NU8 msgkind, NimStringDesc* arg);
typedef NimStringDesc* TY326039[5];
struct  Table326047  {
Keyvaluepairseq326050* data;
NI counter;
};
struct  Rstgenerator326010  {
  TNimObject Sup;
NU8 target;
Stringtableobj140209* config;
NI splitafter;
NI listingcounter;
TY326029* tocpart;
NIM_BOOL hastoc;
NimStringDesc* theindex;
NU8 options;
Findfilehandler314014 findfile;
Msghandler314012 msghandler;
NimStringDesc* filename;
TY326039 meta;
NimStringDesc* currentsection;
Table326047 seenindexterms;
};
typedef Ropeobj169006* Tsections359002[25];
struct  Tdocumentor359004  {
  Rstgenerator326010 Sup;
Ropeobj169006* moddesc;
NI id;
Tsections359002 toc;
Tsections359002 section;
NimStringDesc* indexvalfilename;
NimStringDesc* analytics;
Stringtableobj140209* seensymbols;
};
struct TY263227 {
NIM_BOOL Field0;
NU8 Field1;
};
typedef TY263227 TY263230[256];
struct  PprocHEX3Aobjecttype263221  {
TY263222* blocks;
Tsym214822* sym;
TY263230 slots;
NI maxslots;
};
typedef struct {
N_NIMCALL_PTR(void, ClPrc) (Vmargs263030* args, void* ClEnv);
void* ClEnv;
} Vmcallback263032;
struct TY263262 {
NimStringDesc* Field0;
Vmcallback263032 Field1;
};
struct  Tinstantiation214812  {
Tsym214822* sym;
Ttypeseq214824* concretetypes;
TY214913* usedby;
NI compilesid;
};
struct  Freecell29630  {
Freecell29630* next;
NI zerofield;
};
struct  Stringtableobj140209  {
  TNimObject Sup;
NI counter;
Keyvaluepairseq140207* data;
NU8 mode;
};
struct  Tocentry326006  {
Rstnode313008* n;
NimStringDesc* refname;
NimStringDesc* header;
};
struct Keyvaluepair326053 {
NI Field0;
NimStringDesc* Field1;
NI Field2;
};
struct  Tblock263018  {
Tsym214822* label;
TY263202* fixups;
};
struct  Vmargs263030  {
NI ra;
NI rb;
NI rc;
void* slots;
Tnode214790* currentexception;
};
struct Keyvaluepair140205 {
NimStringDesc* Field0;
NimStringDesc* Field1;
};
struct  Rstnode313008  {
NU8 kind;
NimStringDesc* text;
NI level;
Rstnodeseq313006* sons;
};
struct TY125202 {
  TGenericSeq Sup;
  NimStringDesc* data[SEQ_DECL_SIZE];
};
struct Tsymseq214792 {
  TGenericSeq Sup;
  Tsym214822* data[SEQ_DECL_SIZE];
};
struct Ttypeseq214824 {
  TGenericSeq Sup;
  Ttype214828* data[SEQ_DECL_SIZE];
};
struct Tnodeseq214784 {
  TGenericSeq Sup;
  Tnode214790* data[SEQ_DECL_SIZE];
};
struct Trunkseq211033 {
  TGenericSeq Sup;
  Trunk211031* data[SEQ_DECL_SIZE];
};
struct Tidpairseq214838 {
  TGenericSeq Sup;
  Tidpair214836 data[SEQ_DECL_SIZE];
};
struct TY264140 {
  TGenericSeq Sup;
  Tinstantiationpair264010 data[SEQ_DECL_SIZE];
};
struct TY214925 {
  TGenericSeq Sup;
  Tinstantiation214812* data[SEQ_DECL_SIZE];
};
struct TY263242 {
  TGenericSeq Sup;
  NU32 data[SEQ_DECL_SIZE];
};
struct TY183090 {
  TGenericSeq Sup;
  Tlineinfo182337 data[SEQ_DECL_SIZE];
};
struct TY263261 {
  TGenericSeq Sup;
  TY263262 data[SEQ_DECL_SIZE];
};
struct TY326029 {
  TGenericSeq Sup;
  Tocentry326006 data[SEQ_DECL_SIZE];
};
struct Keyvaluepairseq326050 {
  TGenericSeq Sup;
  Keyvaluepair326053 data[SEQ_DECL_SIZE];
};
struct TY263222 {
  TGenericSeq Sup;
  Tblock263018 data[SEQ_DECL_SIZE];
};
struct TY214913 {
  TGenericSeq Sup;
  NI32 data[SEQ_DECL_SIZE];
};
struct Keyvaluepairseq140207 {
  TGenericSeq Sup;
  Keyvaluepair140205 data[SEQ_DECL_SIZE];
};
struct TY263202 {
  TGenericSeq Sup;
  NI data[SEQ_DECL_SIZE];
};
struct Rstnodeseq313006 {
  TGenericSeq Sup;
  Rstnode313008* data[SEQ_DECL_SIZE];
};
N_NIMCALL(NU8, incheckpoint_371975)(Tlineinfo182337 current);
N_NIMCALL(Tnode214790*, findclosestdot_371979)(Tnode214790* n);
static N_INLINE(NI, safelen_215081)(Tnode214790* n);
N_NIMCALL(Tnode214790*, safesemexpr_372805)(Tcontext264020* c, Tnode214790* n);
static N_INLINE(void, pushSafePoint)(TSafePoint* s);
static N_INLINE(void, popSafePoint)(void);
N_NIMCALL(NIM_BOOL, isObj)(TNimType* obj, TNimType* subclass);
static N_INLINE(Exception*, getCurrentException)(void);
static N_INLINE(void, popCurrentException)(void);
static N_INLINE(void, asgnRef)(void** dest, void* src);
static N_INLINE(void, incref_53819)(Cell47505* c);
static N_INLINE(NIM_BOOL, canbecycleroot_51458)(Cell47505* c);
static N_INLINE(void, rtladdcycleroot_52220)(Cell47505* c);
N_NOINLINE(void, incl_48247)(Cellset47517* s, Cell47505* cell);
static N_INLINE(Cell47505*, usrtocell_51440)(void* usr);
static N_INLINE(void, decref_53401)(Cell47505* c);
static N_INLINE(void, rtladdzct_53001)(Cell47505* c);
N_NOINLINE(void, addzct_51417)(Cellseq47521* s, Cell47505* c);
N_NIMCALL(void, reraiseException)(void);
N_NIMCALL(void, suggestfieldaccess_371747)(Tcontext264020* c, Tnode214790* n, NI* outputs);
N_NIMCALL(Tsym214822*, inittabiter_221073)(Ttabiter221071* ti, Tstrtable214794 tab);
static N_INLINE(NIM_BOOL, filtersym_369221)(Tsym214822* s);
N_NIMCALL(void, suggestresult_369211)(Suggest368803* s);
N_NIMCALL(void, suggestwriteln_183117)(NimStringDesc* s);
N_NIMCALL(NimStringDesc*, HEX24_369002)(Suggest368803* suggest);
N_NIMCALL(NimStringDesc*, HEX24_161680)(NU8 c);
N_NIMCALL(NimStringDesc*, addChar)(NimStringDesc* s, NIM_CHAR c);
static N_INLINE(void, appendString)(NimStringDesc* dest, NimStringDesc* src);
N_NIMCALL(NimStringDesc*, resizeString)(NimStringDesc* dest, NI addlen);
N_NIMCALL(NimStringDesc*, reprEnum)(NI e_85009, TNimType* typ);
N_NIMCALL(NimStringDesc*, nimIntToStr)(NI x);
N_NIMCALL(NimStringDesc*, nsuJoinSep)(NimStringDesc** a, NI aLen0, NimStringDesc* sep);
N_NIMCALL(NimStringDesc*, nsuEscape)(NimStringDesc* s, NimStringDesc* prefix, NimStringDesc* suffix);
N_NIMCALL(void, symtosuggest_369201)(Tsym214822* s, NIM_BOOL islocal, NimStringDesc* section, NI quality, Suggest368803* Result);
N_NIMCALL(void, symtosuggest_368826)(Tsym214822* s, NIM_BOOL islocal, NimStringDesc* section, Tlineinfo182337 li, NI quality, Suggest368803* Result);
N_NIMCALL(NU8, parseidecmd_161676)(NimStringDesc* s);
N_NIMCALL(NimStringDesc*, tofullpath_183266)(NI32 fileidx);
N_NIMCALL(void, unsureAsgnRef)(void** dest, void* src);
static N_INLINE(NI, tolinenumber_183415)(Tlineinfo182337 info);
static N_INLINE(NI, tocolumn_183419)(Tlineinfo182337 info);
N_NIMCALL(void*, newSeq)(TNimType* typ, NI len);
N_NIMCALL(TGenericSeq*, incrSeqV2)(TGenericSeq* seq, NI elemsize);
N_NIMCALL(NimStringDesc*, copyStringRC1)(NimStringDesc* src);
static N_INLINE(void, nimGCunrefNoCycle)(void* p);
N_NIMCALL(NimStringDesc*, typetostring_240017)(Ttype214828* typ, NU8 prefer);
N_NIMCALL(NimStringDesc*, copyString)(NimStringDesc* src);
N_NIMCALL(NimStringDesc*, extractdoccomment_359453)(Tsym214822* s, Tdocumentor359004* d);
N_NOINLINE(void, chckNil)(void* p);
N_NIMCALL(void, genericReset)(void* dest, TNimType* mt);
N_NIMCALL(Tsym214822*, nextiter_221078)(Ttabiter221071* ti, Tstrtable214794 tab);
N_NIMCALL(void, suggesteverything_371695)(Tcontext264020* c, Tnode214790* n, NI* outputs);
N_NIMCALL(void, suggestsymlist_369444)(Tcontext264020* c, Tnode214790* list, NI* outputs);
N_NIMCALL(NI, sonslen_217351)(Tnode214790* n);
N_NIMCALL(void, suggestfield_369411)(Tcontext264020* c, Tsym214822* s, NI* outputs);
static N_INLINE(NIM_BOOL, fieldvisible_369259)(Tcontext264020* c, Tsym214822* f);
N_NIMCALL(Tsym214822*, getmodule_221144)(Tsym214822* s);
N_NIMCALL(void, suggestoperations_371364)(Tcontext264020* c, Tnode214790* n, Ttype214828* typ, NI* outputs);
static N_INLINE(void, asgnRefNoCycle)(void** dest, void* src);
N_NIMCALL(void, genericSeqAssign)(void* dest, void* src_84004, TNimType* mt);
N_NIMCALL(void, sort_369841)(Tsym214822** a, NI aLen0, TY369848 cmp, NU8 order);
N_NIMCALL(NI, HEX3Aanonymous_371630)(Tsym214822* a_371408, Tsym214822* b_371410);
N_NIMCALL(NI, cmp_5680)(NimStringDesc* x, NimStringDesc* y);
static N_INLINE(NIM_BOOL, filtersymnoopr_369234)(Tsym214822* s);
N_NIMCALL(NIM_BOOL, iskeyword_233071)(Tident189012* i);
static N_INLINE(NIM_BOOL, typefits_371273)(Tcontext264020* c, Tsym214822* s, Ttype214828* firstarg);
N_NIMCALL(NI, sonslen_217327)(Ttype214828* n);
N_NIMCALL(Ttype214828*, skiptypes_218113)(Ttype214828* t, NU64 kinds);
N_NIMCALL(Ttype214828*, elemtype_240383)(Ttype214828* t);
N_NIMCALL(NIM_BOOL, argtypematches_368396)(Tcontext264020* c, Ttype214828* f, Ttype214828* a);
N_NIMCALL(void, initcandidate_362257)(Tcontext264020* ctx, Tcandidate362206* c, Ttype214828* callee);
static N_INLINE(void, initcandidateaux_362251)(Tcontext264020* ctx, Tcandidate362206* c, Ttype214828* callee);
N_NIMCALL(void, initidtable_218033)(Tidtable214840* x);
N_NIMCALL(Tnode214790*, paramtypesmatch_367299)(Tcandidate362206* m, Ttype214828* f, Ttype214828* a, Tnode214790* arg, Tnode214790* argorig);
N_NIMCALL(Tnode214790*, paramtypesmatchaux_366793)(Tcandidate362206* m, Ttype214828* f, Ttype214828* argtype_366798, Tnode214790* argsemantized, Tnode214790* argorig);
N_NIMCALL(void, assigntype_217389)(Ttype214828* dest, Ttype214828* src);
N_NIMCALL(Tnode214790*, newnodeit_216801)(NU8 kind, Tlineinfo182337 info, Ttype214828* typ);
N_NIMCALL(Ttype214828*, maketypefromexpr_264556)(Tcontext264020* c, Tnode214790* n);
N_NIMCALL(Ttype214828*, newtypes_264184)(NU8 kind, Tcontext264020* c);
N_NIMCALL(void*, newSeqRC1)(TNimType* typ, NI len);
N_NIMCALL(NU8, typerel_362805)(Tcandidate362206* c, Ttype214828* f, Ttype214828* aorig, NIM_BOOL dobind);
static N_INLINE(void, put_362264)(Tidtable214840* t, Ttype214828* key, Ttype214828* val);
N_NIMCALL(void, idtableput_221115)(Tidtable214840* t, Tidobj189006* key, TNimObject* val);
static N_INLINE(Ttype214828*, skipintlit_258653)(Ttype214828* t);
N_NIMCALL(Ttype214828*, getsystype_258130)(NU8 kind);
N_NIMCALL(Ttype214828*, maybeskipdistinct_364238)(Ttype214828* t, Tsym214822* callee);
N_NIMCALL(NIM_BOOL, shouldskipdistinct_364176)(Tnode214790* rules, Tident189012* callident);
static N_INLINE(NI, len_215059)(Tnode214790* n);
N_NIMCALL(Tident189012*, considerquotedident_269004)(Tnode214790* n);
N_NIMCALL(Ttype214828*, base_240021)(Ttype214828* t);
N_NIMCALL(Ttype214828*, lastson_217377)(Ttype214828* n);
static N_INLINE(NIM_BOOL, sameenumtypes_245402)(Ttype214828* a, Ttype214828* b);
static N_INLINE(Tnode214790*, HEX5BHEX5D_215238)(Tnode214790* n, NI i);
N_NIMCALL(Tnode214790*, tryresolvingstaticexpr_364277)(Tcandidate362206* c, Tnode214790* n);
N_NIMCALL(Tnode214790*, replacetypesinbody_285430)(Tcontext264020* p, Tidtable214840 pt, Tnode214790* n, Tsym214822* owner);
N_NOINLINE(NU8, typerangerel_364019)(Ttype214828* f, Ttype214828* a);
N_NIMCALL(NI64, firstord_240001)(Ttype214828* t);
N_NIMCALL(NI64, lastord_240004)(Ttype214828* t);
N_NIMCALL(NIM_BOOL, isconvertibletorange_362958)(Ttype214828* f, Ttype214828* a);
N_NIMCALL(NU8, handlerange_362848)(Ttype214828* f, Ttype214828* a, NU8 min, NU8 max);
static N_INLINE(NIM_BOOL, isintlit_240222)(Ttype214828* t);
N_NIMCALL(NU8, handlefloatrange_363007)(Ttype214828* f, Ttype214828* a);
static N_INLINE(NIM_BOOL, isfloatlit_240256)(Ttype214828* t);
N_NIMCALL(TNimObject*, idtableget_221107)(Tidtable214840 t, Tidobj189006* key);
N_NIMCALL(Ttype214828*, newtypewithsons_264601)(Tcontext264020* c, NU8 kind, Ttypeseq214824* sons);
N_NIMCALL(Tnode214790*, newintnode_215659)(NU8 kind, NI64 intval);
N_NIMCALL(NI64, lengthord_240007)(Ttype214828* t);
N_NIMCALL(NI, len_217339)(Ttype214828* n);
static N_INLINE(NU8, allowsnil_363589)(Ttype214828* f);
N_NIMCALL(NIM_BOOL, isordinaltype_240057)(Ttype214828* t);
N_NIMCALL(void, internalerror_187113)(NimStringDesc* errmsg);
N_NIMCALL(NU8, recordrel_363450)(Tcandidate362206* c, Ttype214828* f, Ttype214828* a);
N_NIMCALL(NIM_BOOL, sametype_244628)(Ttype214828* a, Ttype214828* b, NU8 flags);
N_NIMCALL(NU8, minrel_363436)(NU8 a, NU8 b);
N_NIMCALL(void, internalerror_187100)(Tlineinfo182337 info, NimStringDesc* errmsg);
N_NIMCALL(NIM_BOOL, sameobjecttypes_245344)(Ttype214828* a, Ttype214828* b);
N_NIMCALL(NI, isobjectsubtype_363060)(Ttype214828* a, Ttype214828* f);
static N_INLINE(NIM_BOOL, samedistincttypes_245397)(Ttype214828* a, Ttype214828* b);
N_NIMCALL(NU8, proctyperel_363688)(Tcandidate362206* c, Ttype214828* f, Ttype214828* a);
N_NIMCALL(NU8, procparamtyperel_363635)(Tcandidate362206* c, Ttype214828* f_363639, Ttype214828* a_363640);
N_NIMCALL(NIM_BOOL, ismetatype_215803)(Ttype214828* t);
N_NIMCALL(Ttype214828*, generatetypeinstance_285450)(Tcontext264020* p, Tidtable214840 pt, Tlineinfo182337 info, Ttype214828* t);
static N_INLINE(NIM_BOOL, inconsistentvartypes_363603)(Ttype214828* f, Ttype214828* a);
N_NIMCALL(NIM_BOOL, compatibleeffects_248614)(Ttype214828* formal, Ttype214828* actual);
N_NIMCALL(Ttype214828*, skipgenericalias_245606)(Ttype214828* t);
N_NIMCALL(Ttype214828*, concretetype_362812)(Tcandidate362206* c, Ttype214828* t);
N_NIMCALL(Ttype214828*, newtype_217107)(NU8 kind, Tsym214822* owner);
N_NIMCALL(void, addsonskipintlit_258680)(Ttype214828* father, Ttype214828* son);
N_NIMCALL(NimStringDesc*, rawNewString)(NI space);
N_NIMCALL(NU8, matchusertypeclass_364028)(Tcontext264020* c, Tcandidate362206* m, Ttype214828* ff, Ttype214828* a);
N_NIMCALL(void, localerror_187085)(Tlineinfo182337 info, NimStringDesc* arg);
N_NIMCALL(NimStringDesc*, HEX24_233066)(Tnode214790* n);
N_NIMCALL(Tscope214816*, openscope_269060)(Tcontext264020* c);
N_NIMCALL(Tsym214822*, newsym_215683)(NU8 symkind, Tident189012* name, Tsym214822* owner, Tlineinfo182337 info);
N_NIMCALL(Ttype214828*, maketypedesc_264523)(Tcontext264020* c, Ttype214828* typ);
N_NIMCALL(void, adddecl_269445)(Tcontext264020* c, Tsym214822* sym);
N_NIMCALL(Ttype214828*, makevartype_264490)(Tcontext264020* c, Ttype214828* basetype);
N_NIMCALL(NimStringDesc*, HEX24_187183)(TY88487 x);
N_NIMCALL(Tnode214790*, copytree_218822)(Tnode214790* src);
N_NIMCALL(void, closescope_269068)(Tcontext264020* c);
N_NIMCALL(NIM_BOOL, HEX3DHEX3D_248927)(Ttypeseq214824* x, Ttypeseq214824* y);
N_NIMCALL(NIM_BOOL, exprstructuralequivalent_239099)(Tnode214790* a, Tnode214790* b, NIM_BOOL strictsymequality);
N_NIMCALL(void, localerror_187080)(Tlineinfo182337 info, NU16 msg, NimStringDesc* arg);
N_NIMCALL(void, incmatches_366732)(Tcandidate362206* m, NU8 r, NI convmatch);
N_NIMCALL(Tnode214790*, newsymnode_216241)(Tsym214822* sym, Tlineinfo182337 info);
N_NIMCALL(Tnode214790*, implicitconv_366525)(NU8 kind, Ttype214828* f, Tnode214790* arg, Tcandidate362206* m, Tcontext264020* c);
N_NIMCALL(Tnode214790*, newnodei_216248)(NU8 kind, Tlineinfo182337 info);
N_NIMCALL(NIM_BOOL, containsgenerictype_248492)(Ttype214828* t);
N_NIMCALL(Ttype214828*, getinstantiatedtype_366494)(Tcontext264020* c, Tnode214790* arg, Tcandidate362206* m, Ttype214828* f);
N_NIMCALL(Ttype214828*, errortype_264901)(Tcontext264020* c);
N_NIMCALL(void, addson_216807)(Tnode214790* father, Tnode214790* son);
N_NIMCALL(NIM_BOOL, isemptycontainer_249113)(Ttype214828* t);
N_NIMCALL(Tnode214790*, userconvmatch_366554)(Tcontext264020* c, Tcandidate362206* m, Ttype214828* f, Ttype214828* a, Tnode214790* arg);
N_NIMCALL(void, markused_362244)(Tlineinfo182337 info, Tsym214822* s);
N_NIMCALL(void, message_187095)(Tlineinfo182337 info, NU16 msg, NimStringDesc* arg);
N_NIMCALL(Tnode214790*, newsymnode_216234)(Tsym214822* sym);
N_NIMCALL(Tnode214790*, localconvmatch_366641)(Tcontext264020* c, Tcandidate362206* m, Ttype214828* f, Ttype214828* a, Tnode214790* arg);
N_NIMCALL(void, add_215114)(Tnode214790* father, Tnode214790* son);
N_NIMCALL(void, copycandidate_362425)(Tcandidate362206* a, Tcandidate362206* b);
N_NIMCALL(void, copyidtable_216066)(Tidtable214840* dest, Tidtable214840 src);
N_NIMCALL(void, genericAssign)(void* dest, void* src, TNimType* mt);
N_NIMCALL(NI, cmpcandidates_362609)(Tcandidate362206* a, Tcandidate362206* b);
N_NIMCALL(NI, complexdisambiguation_362544)(Ttype214828* a, Ttype214828* b);
N_NIMCALL(NI, sumgeneric_362431)(Ttype214828* t_362433);
N_NIMCALL(void, suggestobject_369482)(Tcontext264020* c, Tnode214790* n, NI* outputs);
N_NIMCALL(Tnode214790*, lastson_217364)(Tnode214790* n);
N_NIMCALL(Tnode214790*, findclosestcall_372040)(Tnode214790* n);
N_NIMCALL(Tnode214790*, copynode_218542)(Tnode214790* src);
N_NIMCALL(void, suggestcall_369579)(Tcontext264020* c, Tnode214790* n, Tnode214790* norig, NI* outputs);
N_NIMCALL(NI, HEX3Aanonymous_369830)(Tsym214822* a_369593, Tsym214822* b_369595);
N_NIMCALL(NIM_BOOL, namefits_369533)(Tcontext264020* c, Tsym214822* s, Tnode214790* n);
N_NIMCALL(NIM_BOOL, argsfit_369559)(Tcontext264020* c, Tsym214822* candidate, Tnode214790* n, Tnode214790* norig);
N_NIMCALL(void, initcandidate_362270)(Tcontext264020* ctx, Tcandidate362206* c, Tsym214822* callee, Tnode214790* binding, NI calleescope);
N_NIMCALL(Tsym214822*, originatingmodule_219381)(Tsym214822* s);
N_NIMCALL(Tsym214822*, skipgenericowner_219353)(Tsym214822* s);
N_NIMCALL(void, partialmatch_368302)(Tcontext264020* c, Tnode214790* n, Tnode214790* norig, Tcandidate362206* m);
N_NIMCALL(void, initintset_211885)(Intset211035* Result);
N_NIMCALL(void, matchesaux_367822)(Tcontext264020* c, Tnode214790* n, Tnode214790* norig, Tcandidate362206* m, Intset211035* marker);
N_NIMCALL(Ttype214828*, arrayconstr_367703)(Tcontext264020* c, Tlineinfo182337 info);
N_NIMCALL(void, rawaddson_218408)(Ttype214828* father, Ttype214828* son);
N_NIMCALL(Ttype214828*, makerangetype_264915)(Tcontext264020* c, NI64 first, NI64 last, Tlineinfo182337 info, Ttype214828* inttype);
N_NIMCALL(void, setson_367614)(Tnode214790* father, NI at, Tnode214790* son);
N_NIMCALL(TGenericSeq*, setLengthSeq)(TGenericSeq* seq, NI elemsize, NI newlen);
N_NIMCALL(void, incrindextype_367708)(Ttype214828* t);
N_NIMCALL(void, preparenamedparam_367680)(Tnode214790* a);
N_NIMCALL(Tnode214790*, newidentnode_216228)(Tident189012* ident, Tlineinfo182337 info);
N_NIMCALL(Tsym214822*, getsymfromlist_221135)(Tnode214790* list, Tident189012* ident, NI start);
N_NIMCALL(NIM_BOOL, containsorincl_211862)(Intset211035* s, NI key);
N_NIMCALL(Tnode214790*, prepareoperand_367631)(Tcontext264020* c, Ttype214828* formal, Tnode214790* a);
N_NIMCALL(NIM_BOOL, matchnodekinds_287042)(Tnode214790* p, Tnode214790* n);
N_NIMCALL(NIM_BOOL, islvalue_287027)(Tnode214790* n);
N_NIMCALL(Ttype214828*, arrayconstr_367697)(Tcontext264020* c, Tnode214790* n);
N_NIMCALL(Tnode214790*, prepareoperand_367666)(Tcontext264020* c, Tnode214790* a);
N_NIMCALL(void, suggestquit_183155)(void);
N_NIMCALL(NimStringDesc*, rendertree_233044)(Tnode214790* n, NU8 renderflags);
N_NIMCALL(NimStringDesc*, argtypetostring_362689)(Tnode214790* arg, NU8 prefer);
N_NIMCALL(void, suggestexpr_372810)(Tcontext264020* c, Tnode214790* node);
STRING_LITERAL(TMP2110, "skGlobalVar", 11);
STRING_LITERAL(TMP2111, "skGlobalLet", 11);
STRING_LITERAL(TMP2112, ".", 1);
STRING_LITERAL(TMP2117, "\"", 1);
STRING_LITERAL(TMP2241, "", 0);
STRING_LITERAL(TMP2795, "forward type in typeRel()", 25);
STRING_LITERAL(TMP2796, "recordRel", 9);
STRING_LITERAL(TMP2799, "wrong instantiated type!", 24);
STRING_LITERAL(TMP2800, "cannot resolve type: ", 21);
STRING_LITERAL(TMP2801, " too nested for type matching", 29);
STRING_LITERAL(TMP2805, "compiler/sigmatch.nim", 21);
NIM_CONST TY88487 TMP2804 = {((NimStringDesc*) &TMP2805),
((NI) 562)}
;
NIM_CONST TY88487 TMP2807 = {((NimStringDesc*) &TMP2805),
((NI) 1058)}
;
STRING_LITERAL(TMP2808, " unknown type kind ", 19);
STRING_LITERAL(TMP2811, "getInstantiatedType", 19);
STRING_LITERAL(TMP2812, "implicitConv", 12);
STRING_LITERAL(TMP2819, "x.state is not csMatch", 22);
NIM_CONST TY88487 TMP2821 = {((NimStringDesc*) &TMP2805),
((NI) 124)}
;
STRING_LITERAL(TMP2822, "matches", 7);
STRING_LITERAL(TMP3170, ": ", 2);
STRING_LITERAL(TMP3171, " | ", 3);
STRING_LITERAL(TMP3172, ", ", 2);
STRING_LITERAL(TMP3648, "cannot instantiate \'deepCopy\'", 29);
TY368818 suggestionresulthook_368821;
NI suggestversion_368822;
Tsym214822* usagesym_372201;
Tlineinfo182337 lastlineinfo_372202;
extern Tlineinfo182337 gtrackpos_183441;
extern NU8 gidecmd_160114;
extern TSafePoint* exchandler_19437;
extern TNimType NTI182343; /* ERecoverableError */
extern Exception* currexception_19439;
extern Tnode214790* emptynode_215801;
extern Gcheap49818 gch_49859;
extern TNimType NTI214435; /* TSymKind */
extern NU32 gglobaloptions_160121;
extern TNimType NTI125202; /* seq[string] */
TNimType NTI368803; /* Suggest */
extern TNimType NTI160023; /* IdeCmd */
extern TNimType NTI138; /* string */
extern TNimType NTI104; /* int */
TNimType NTI368813; /* range 0..100(int) */
extern TNimType NTI130; /* bool */
extern TNimType NTI214792; /* TSymSeq */
extern TNimType NTI214824; /* TTypeSeq */
extern TNimType NTI214241; /* TTypeKind */
TNimType NTI362206; /* TCandidate */
extern TNimType NTI264018; /* PContext */
TNimType NTI362202; /* TCandidateState */
extern TNimType NTI214786; /* PType */
extern TNimType NTI214788; /* PSym */
extern TNimType NTI214782; /* PNode */
extern TNimType NTI214840; /* TIdTable */

N_NIMCALL(NU8, incheckpoint_371975)(Tlineinfo182337 current) {
	NU8 result;
{	result = 0;
	{
		if (!(current.fileindex == gtrackpos_183441.fileindex)) goto LA3;
		{
			NIM_BOOL LOC7;
			LOC7 = 0;
			LOC7 = (current.line == gtrackpos_183441.line);
			if (!(LOC7)) goto LA8;
			LOC7 = (((NI16)(current.col - gtrackpos_183441.col) > 0? ((NI16)(current.col - gtrackpos_183441.col)) : -((NI16)(current.col - gtrackpos_183441.col))) < ((NI16) 4));
			LA8: ;
			if (!LOC7) goto LA9;
			result = ((NU8) 2);
			goto BeforeRet;
		}
		LA9: ;
		{
			if (!(gtrackpos_183441.line <= current.line)) goto LA13;
			result = ((NU8) 1);
			goto BeforeRet;
		}
		LA13: ;
	}
	LA3: ;
	}BeforeRet: ;
	return result;
}

static N_INLINE(NI, safelen_215081)(Tnode214790* n) {
	NI result;
	result = 0;
	{
		NIM_BOOL LOC3;
		LOC3 = 0;
		LOC3 = ((*n).kind >= ((NU8) 0) && (*n).kind <= ((NU8) 23));
		if (LOC3) goto LA4;
		LOC3 = (*n).kindU.S6.sons == 0;
		LA4: ;
		if (!LOC3) goto LA5;
		result = ((NI) 0);
	}
	goto LA1;
	LA5: ;
	{
		result = ((*n).kindU.S6.sons ? (*n).kindU.S6.sons->Sup.len : 0);
	}
	LA1: ;
	return result;
}

N_NIMCALL(Tnode214790*, findclosestdot_371979)(Tnode214790* n) {
	Tnode214790* result;
{	result = 0;
	{
		NIM_BOOL LOC3;
		NU8 LOC5;
		LOC3 = 0;
		LOC3 = ((*n).kind == ((NU8) 45));
		if (!(LOC3)) goto LA4;
		LOC5 = 0;
		LOC5 = incheckpoint_371975((*n).info);
		LOC3 = (LOC5 == ((NU8) 2));
		LA4: ;
		if (!LOC3) goto LA6;
		result = n;
	}
	goto LA1;
	LA6: ;
	{
		{
			NI i_372018;
			NI HEX3Atmp_372033;
			NI LOC10;
			NI res_372036;
			i_372018 = 0;
			HEX3Atmp_372033 = 0;
			LOC10 = 0;
			LOC10 = safelen_215081(n);
			HEX3Atmp_372033 = (LOC10 - 1);
			res_372036 = ((NI) 0);
			{
				while (1) {
					if (!(res_372036 <= HEX3Atmp_372033)) goto LA12;
					i_372018 = res_372036;
					result = findclosestdot_371979((*n).kindU.S6.sons->data[i_372018]);
					{
						if (!!((result == NIM_NIL))) goto LA15;
						goto BeforeRet;
					}
					LA15: ;
					res_372036 += ((NI) 1);
				} LA12: ;
			}
		}
	}
	LA1: ;
	}BeforeRet: ;
	return result;
}

static N_INLINE(void, pushSafePoint)(TSafePoint* s) {
	(*s).hasRaiseAction = NIM_FALSE;
	(*s).prev = exchandler_19437;
	exchandler_19437 = s;
}

static N_INLINE(void, popSafePoint)(void) {
	exchandler_19437 = (*exchandler_19437).prev;
}

static N_INLINE(Exception*, getCurrentException)(void) {
	Exception* result;
	result = 0;
	result = currexception_19439;
	return result;
}

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

static N_INLINE(void, rtladdcycleroot_52220)(Cell47505* c) {
	{
		if (!!((((NI) ((NI)((*c).refcount & ((NI) 3)))) == ((NI) 3)))) goto LA3;
		(*c).refcount = (NI)((NI)((*c).refcount & ((NI) -4)) | ((NI) 3));
		incl_48247((&gch_49859.cycleroots), c);
	}
	LA3: ;
}

static N_INLINE(void, incref_53819)(Cell47505* c) {
	(*c).refcount = (NI)((NU64)((*c).refcount) + (NU64)(((NI) 8)));
	{
		NIM_BOOL LOC3;
		LOC3 = 0;
		LOC3 = canbecycleroot_51458(c);
		if (!LOC3) goto LA4;
		rtladdcycleroot_52220(c);
	}
	LA4: ;
}

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

static N_INLINE(void, rtladdzct_53001)(Cell47505* c) {
	addzct_51417((&gch_49859.zct), c);
}

static N_INLINE(void, decref_53401)(Cell47505* c) {
	{
		(*c).refcount -= ((NI) 8);
		if (!((NU64)((*c).refcount) < (NU64)(((NI) 8)))) goto LA3;
		rtladdzct_53001(c);
	}
	goto LA1;
	LA3: ;
	{
		NIM_BOOL LOC6;
		LOC6 = 0;
		LOC6 = canbecycleroot_51458(c);
		if (!LOC6) goto LA7;
		rtladdcycleroot_52220(c);
	}
	goto LA1;
	LA7: ;
	LA1: ;
}

static N_INLINE(void, asgnRef)(void** dest, void* src) {
	{
		Cell47505* LOC5;
		if (!!((src == NIM_NIL))) goto LA3;
		LOC5 = 0;
		LOC5 = usrtocell_51440(src);
		incref_53819(LOC5);
	}
	LA3: ;
	{
		Cell47505* LOC10;
		if (!!(((*dest) == NIM_NIL))) goto LA8;
		LOC10 = 0;
		LOC10 = usrtocell_51440((*dest));
		decref_53401(LOC10);
	}
	LA8: ;
	(*dest) = src;
}

static N_INLINE(void, popCurrentException)(void) {
	asgnRef((void**) (&currexception_19439), NIM_NIL);
}

N_NIMCALL(Tnode214790*, safesemexpr_372805)(Tcontext264020* c, Tnode214790* n) {
	Tnode214790* volatile result;
	TSafePoint TMP2097;
	result = 0;
	pushSafePoint(&TMP2097);
	TMP2097.status = _setjmp(TMP2097.context);
	if (TMP2097.status == 0) {
		result = (*c).semexpr(c, n, 0);
		popSafePoint();
	}
	else {
		popSafePoint();
		if (isObj(getCurrentException()->Sup.m_type, (&NTI182343))) {
			TMP2097.status = 0;
			result = emptynode_215801;
			popCurrentException();
		}
	}
	if (TMP2097.status != 0) reraiseException();
	return result;
}

static N_INLINE(NIM_BOOL, filtersym_369221)(Tsym214822* s) {
	NIM_BOOL result;
	result = 0;
	result = !(((*s).kind == ((NU8) 6)));
	return result;
}

static N_INLINE(void, appendString)(NimStringDesc* dest, NimStringDesc* src) {
	memcpy(((NCSTRING) ((&(*dest).data[((*dest).Sup.len)- 0]))), ((NCSTRING) ((*src).data)), (NI)((*src).Sup.len + ((NI) 1)));
	(*dest).Sup.len += (*src).Sup.len;
}

N_NIMCALL(NimStringDesc*, HEX24_369002)(Suggest368803* suggest) {
	NimStringDesc* result;
	result = 0;
	result = HEX24_161680((*suggest).section);
	result = addChar(result, 9);
	{
		NimStringDesc* LOC17;
		NimStringDesc* LOC18;
		NimStringDesc* LOC19;
		if (!((*suggest).section == ((NU8) 8))) goto LA3;
		{
			NIM_BOOL LOC7;
			LOC7 = 0;
			LOC7 = ((*suggest).symkind == ((NU8) 8));
			if (!(LOC7)) goto LA8;
			LOC7 = (*suggest).isglobal;
			LA8: ;
			if (!LOC7) goto LA9;
			result = resizeString(result, 11);
appendString(result, ((NimStringDesc*) &TMP2110));
		}
		goto LA5;
		LA9: ;
		{
			NIM_BOOL LOC12;
			LOC12 = 0;
			LOC12 = ((*suggest).symkind == ((NU8) 9));
			if (!(LOC12)) goto LA13;
			LOC12 = (*suggest).isglobal;
			LA13: ;
			if (!LOC12) goto LA14;
			result = resizeString(result, 11);
appendString(result, ((NimStringDesc*) &TMP2111));
		}
		goto LA5;
		LA14: ;
		{
			result = resizeString(result, reprEnum((*suggest).symkind, (&NTI214435))->Sup.len + 0);
appendString(result, reprEnum((*suggest).symkind, (&NTI214435)));
		}
		LA5: ;
		result = addChar(result, 9);
		LOC17 = 0;
		LOC17 = nimIntToStr((*suggest).line);
		result = resizeString(result, LOC17->Sup.len + 0);
appendString(result, LOC17);
		result = addChar(result, 9);
		LOC18 = 0;
		LOC18 = nimIntToStr((*suggest).column);
		result = resizeString(result, LOC18->Sup.len + 0);
appendString(result, LOC18);
		result = addChar(result, 9);
		LOC19 = 0;
		LOC19 = nimIntToStr((*suggest).tokenlen);
		result = resizeString(result, LOC19->Sup.len + 0);
appendString(result, LOC19);
	}
	goto LA1;
	LA3: ;
	{
		NimStringDesc* LOC21;
		NimStringDesc* LOC22;
		NimStringDesc* LOC23;
		NimStringDesc* LOC24;
		result = resizeString(result, reprEnum((*suggest).symkind, (&NTI214435))->Sup.len + 0);
appendString(result, reprEnum((*suggest).symkind, (&NTI214435)));
		result = addChar(result, 9);
		LOC21 = 0;
		LOC21 = nsuJoinSep((*suggest).qualifiedpath->data, (*suggest).qualifiedpath->Sup.len, ((NimStringDesc*) &TMP2112));
		result = resizeString(result, LOC21->Sup.len + 0);
appendString(result, LOC21);
		result = addChar(result, 9);
		result = resizeString(result, (*suggest).forth->Sup.len + 0);
appendString(result, (*suggest).forth);
		result = addChar(result, 9);
		result = resizeString(result, (*suggest).filepath->Sup.len + 0);
appendString(result, (*suggest).filepath);
		result = addChar(result, 9);
		LOC22 = 0;
		LOC22 = nimIntToStr((*suggest).line);
		result = resizeString(result, LOC22->Sup.len + 0);
appendString(result, LOC22);
		result = addChar(result, 9);
		LOC23 = 0;
		LOC23 = nimIntToStr((*suggest).column);
		result = resizeString(result, LOC23->Sup.len + 0);
appendString(result, LOC23);
		result = addChar(result, 9);
		LOC24 = 0;
		LOC24 = nsuEscape((*suggest).doc, ((NimStringDesc*) &TMP2117), ((NimStringDesc*) &TMP2117));
		result = resizeString(result, LOC24->Sup.len + 0);
appendString(result, LOC24);
		{
			NimStringDesc* LOC29;
			if (!(suggestversion_368822 == ((NI) 2))) goto LA27;
			result = addChar(result, 9);
			LOC29 = 0;
			LOC29 = nimIntToStr(((NI) ((*suggest).quality)));
			result = resizeString(result, LOC29->Sup.len + 0);
appendString(result, LOC29);
		}
		LA27: ;
	}
	LA1: ;
	return result;
}

N_NIMCALL(void, suggestresult_369211)(Suggest368803* s) {
	{
		if (!!(suggestionresulthook_368821.ClPrc == 0)) goto LA3;
		suggestionresulthook_368821.ClEnv? suggestionresulthook_368821.ClPrc(s, suggestionresulthook_368821.ClEnv):((TMP2098)(suggestionresulthook_368821.ClPrc))(s);
	}
	goto LA1;
	LA3: ;
	{
		NimStringDesc* LOC6;
		LOC6 = 0;
		LOC6 = HEX24_369002(s);
		suggestwriteln_183117(LOC6);
	}
	LA1: ;
}

static N_INLINE(NI, tolinenumber_183415)(Tlineinfo182337 info) {
	NI result;
	result = 0;
	result = ((NI) (info.line));
	return result;
}

static N_INLINE(NI, tocolumn_183419)(Tlineinfo182337 info) {
	NI result;
	result = 0;
	result = ((NI) (info.col));
	return result;
}

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

N_NIMCALL(void, symtosuggest_368826)(Tsym214822* s, NIM_BOOL islocal, NimStringDesc* section, Tlineinfo182337 li, NI quality, Suggest368803* Result) {
	(*Result).section = parseidecmd_161676(section);
	(*Result).quality = quality;
	(*Result).isglobal = (((*s).flags &(1U<<((NU)(((NU8) 3))&31U)))!=0);
	(*Result).tokenlen = ((*(*s).name).s ? (*(*s).name).s->Sup.len : 0);
	{
		if (!((gglobaloptions_160121 &(1U<<((NU)(((NU8) 30))&31U)))!=0)) goto LA3;
		(*Result).symkind = (*s).kind;
		unsureAsgnRef((void**) (&(*Result).filepath), tofullpath_183266(li.fileindex));
		(*Result).line = tolinenumber_183415(li);
		(*Result).column = tocolumn_183419(li);
	}
	goto LA1;
	LA3: ;
	{
		NimStringDesc* LOC20;
		(*Result).symkind = (*s).kind;
		unsureAsgnRef((void**) (&(*Result).qualifiedpath), (TY125202*) newSeq((&NTI125202), 0));
		{
			NIM_BOOL LOC8;
			Tsym214822* ow;
			NimStringDesc* LOC19;
			LOC8 = 0;
			LOC8 = !(islocal);
			if (!(LOC8)) goto LA9;
			LOC8 = !(((*s).kind == ((NU8) 6)));
			LA9: ;
			if (!LOC8) goto LA10;
			ow = (*s).owner;
			{
				NIM_BOOL LOC14;
				Tsym214822* ow2;
				NimStringDesc* LOC18;
				LOC14 = 0;
				LOC14 = !(((*ow).kind == ((NU8) 6)));
				if (!(LOC14)) goto LA15;
				LOC14 = !(((*ow).owner == NIM_NIL));
				LA15: ;
				if (!LOC14) goto LA16;
				ow2 = (*ow).owner;
				(*Result).qualifiedpath = (TY125202*) incrSeqV2(&((*Result).qualifiedpath)->Sup, sizeof(NimStringDesc*));
				LOC18 = 0;
				LOC18 = (*Result).qualifiedpath->data[(*Result).qualifiedpath->Sup.len]; (*Result).qualifiedpath->data[(*Result).qualifiedpath->Sup.len] = copyStringRC1((*(*ow2).name).s);
				if (LOC18) nimGCunrefNoCycle(LOC18);
				++(*Result).qualifiedpath->Sup.len;
			}
			LA16: ;
			(*Result).qualifiedpath = (TY125202*) incrSeqV2(&((*Result).qualifiedpath)->Sup, sizeof(NimStringDesc*));
			LOC19 = 0;
			LOC19 = (*Result).qualifiedpath->data[(*Result).qualifiedpath->Sup.len]; (*Result).qualifiedpath->data[(*Result).qualifiedpath->Sup.len] = copyStringRC1((*(*ow).name).s);
			if (LOC19) nimGCunrefNoCycle(LOC19);
			++(*Result).qualifiedpath->Sup.len;
		}
		LA10: ;
		(*Result).qualifiedpath = (TY125202*) incrSeqV2(&((*Result).qualifiedpath)->Sup, sizeof(NimStringDesc*));
		LOC20 = 0;
		LOC20 = (*Result).qualifiedpath->data[(*Result).qualifiedpath->Sup.len]; (*Result).qualifiedpath->data[(*Result).qualifiedpath->Sup.len] = copyStringRC1((*(*s).name).s);
		if (LOC20) nimGCunrefNoCycle(LOC20);
		++(*Result).qualifiedpath->Sup.len;
		{
			if (!!(((*s).typ == NIM_NIL))) goto LA23;
			unsureAsgnRef((void**) (&(*Result).forth), typetostring_240017((*s).typ, ((NU8) 0)));
		}
		goto LA21;
		LA23: ;
		{
			unsureAsgnRef((void**) (&(*Result).forth), copyString(((NimStringDesc*) &TMP2241)));
		}
		LA21: ;
		unsureAsgnRef((void**) (&(*Result).filepath), tofullpath_183266(li.fileindex));
		(*Result).line = tolinenumber_183415(li);
		(*Result).column = tocolumn_183419(li);
		unsureAsgnRef((void**) (&(*Result).doc), extractdoccomment_359453(s, NIM_NIL));
	}
	LA1: ;
}

N_NIMCALL(void, symtosuggest_369201)(Tsym214822* s, NIM_BOOL islocal, NimStringDesc* section, NI quality, Suggest368803* Result) {
	chckNil((void*)Result);
	genericReset((void*)Result, (&NTI368803));
	symtosuggest_368826(s, islocal, section, (*s).info, quality, Result);
}

N_NIMCALL(void, suggesteverything_371695)(Tcontext264020* c, Tnode214790* n, NI* outputs) {
	NIM_BOOL islocal;
	islocal = NIM_TRUE;
	{
		Tscope214816* scope_371702;
		Tscope214816* HEX3Atmp_371743;
		Tscope214816* current_371746;
		scope_371702 = 0;
		HEX3Atmp_371743 = 0;
		HEX3Atmp_371743 = (*c).currentscope;
		current_371746 = HEX3Atmp_371743;
		{
			while (1) {
				if (!!((current_371746 == NIM_NIL))) goto LA3;
				scope_371702 = current_371746;
				{
					if (!(scope_371702 == (*c).toplevelscope)) goto LA6;
					islocal = NIM_FALSE;
				}
				LA6: ;
				{
					Tsym214822* it_371714;
					Tstrtable214794 HEX3Atmp_371737;
					Ttabiter221071 it_371740;
					Tsym214822* s_371742;
					it_371714 = 0;
					memset((void*)(&HEX3Atmp_371737), 0, sizeof(HEX3Atmp_371737));
					HEX3Atmp_371737.counter = (*scope_371702).symbols.counter;
					HEX3Atmp_371737.data = (*scope_371702).symbols.data;
					memset((void*)(&it_371740), 0, sizeof(it_371740));
					s_371742 = inittabiter_221073((&it_371740), HEX3Atmp_371737);
					{
						while (1) {
							if (!!((s_371742 == NIM_NIL))) goto LA10;
							it_371714 = s_371742;
							{
								NIM_BOOL LOC13;
								NimStringDesc* LOC16;
								Suggest368803 LOC17;
								LOC13 = 0;
								LOC13 = filtersym_369221(it_371714);
								if (!LOC13) goto LA14;
								LOC16 = 0;
								LOC16 = HEX24_161680(((NU8) 1));
								memset((void*)(&LOC17), 0, sizeof(LOC17));
								symtosuggest_369201(it_371714, islocal, LOC16, ((NI) 0), (&LOC17));
								suggestresult_369211((&LOC17));
								(*outputs) += ((NI) 1);
							}
							LA14: ;
							s_371742 = nextiter_221078((&it_371740), HEX3Atmp_371737);
						} LA10: ;
					}
				}
				{
					if (!(scope_371702 == (*c).toplevelscope)) goto LA20;
					goto LA1;
				}
				LA20: ;
				current_371746 = (*current_371746).parent;
			} LA3: ;
		}
	} LA1: ;
}

static N_INLINE(NIM_BOOL, fieldvisible_369259)(Tcontext264020* c, Tsym214822* f) {
	NIM_BOOL result;
	NI fmoduleid;
	Tsym214822* LOC1;
	NIM_BOOL LOC2;
	result = 0;
	LOC1 = 0;
	LOC1 = getmodule_221144(f);
	fmoduleid = (*LOC1).Sup.id;
	LOC2 = 0;
	LOC2 = (((*f).flags &(1U<<((NU)(((NU8) 1))&31U)))!=0);
	if (LOC2) goto LA3;
	LOC2 = (fmoduleid == (*(*c).module).Sup.id);
	LA3: ;
	result = LOC2;
	{
		Tsym214822* module_369402;
		Tsymseq214792* HEX3Atmp_369405;
		NI i_369408;
		NI L_369410;
		module_369402 = 0;
		HEX3Atmp_369405 = 0;
		HEX3Atmp_369405 = (*c).friendmodules;
		i_369408 = ((NI) 0);
		L_369410 = (HEX3Atmp_369405 ? HEX3Atmp_369405->Sup.len : 0);
		{
			while (1) {
				if (!(i_369408 < L_369410)) goto LA6;
				module_369402 = HEX3Atmp_369405->data[i_369408];
				{
					if (!(fmoduleid == (*module_369402).Sup.id)) goto LA9;
					result = NIM_TRUE;
					goto LA4;
				}
				LA9: ;
				i_369408 += ((NI) 1);
			} LA6: ;
		}
	} LA4: ;
	return result;
}

N_NIMCALL(void, suggestfield_369411)(Tcontext264020* c, Tsym214822* s, NI* outputs) {
	{
		NIM_BOOL LOC3;
		NimStringDesc* LOC7;
		Suggest368803 LOC8;
		LOC3 = 0;
		LOC3 = filtersym_369221(s);
		if (!(LOC3)) goto LA4;
		LOC3 = fieldvisible_369259(c, s);
		LA4: ;
		if (!LOC3) goto LA5;
		LOC7 = 0;
		LOC7 = HEX24_161680(((NU8) 1));
		memset((void*)(&LOC8), 0, sizeof(LOC8));
		symtosuggest_369201(s, NIM_TRUE, LOC7, ((NI) 100), (&LOC8));
		suggestresult_369211((&LOC8));
		(*outputs) += ((NI) 1);
	}
	LA5: ;
}

N_NIMCALL(void, suggestsymlist_369444)(Tcontext264020* c, Tnode214790* list, NI* outputs) {
	{
		NI i_369461;
		NI HEX3Atmp_369475;
		NI LOC2;
		NI res_369478;
		i_369461 = 0;
		HEX3Atmp_369475 = 0;
		LOC2 = 0;
		LOC2 = sonslen_217351(list);
		HEX3Atmp_369475 = (NI)(LOC2 - ((NI) 1));
		res_369478 = ((NI) 0);
		{
			while (1) {
				if (!(res_369478 <= HEX3Atmp_369475)) goto LA4;
				i_369461 = res_369478;
				{
					if (!((*(*list).kindU.S6.sons->data[i_369461]).kind == ((NU8) 3))) goto LA7;
					suggestfield_369411(c, (*(*list).kindU.S6.sons->data[i_369461]).kindU.S4.sym, outputs);
				}
				LA7: ;
				res_369478 += ((NI) 1);
			} LA4: ;
		}
	}
}

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

N_NIMCALL(NI, HEX3Aanonymous_371630)(Tsym214822* a_371408, Tsym214822* b_371410) {
	NI result;
{	result = 0;
	result = cmp_5680((*(*a_371408).name).s, (*(*b_371410).name).s);
	goto BeforeRet;
	}BeforeRet: ;
	return result;
}

static N_INLINE(NIM_BOOL, filtersymnoopr_369234)(Tsym214822* s) {
	NIM_BOOL result;
	NIM_BOOL LOC1;
	NIM_BOOL LOC2;
	NIM_BOOL LOC5;
	result = 0;
	LOC1 = 0;
	LOC2 = 0;
	LOC2 = !(((*s).kind == ((NU8) 6)));
	if (!(LOC2)) goto LA3;
	LOC2 = (((NU8)((*(*s).name).s->data[((NI) 0)])) >= ((NU8)(97)) && ((NU8)((*(*s).name).s->data[((NI) 0)])) <= ((NU8)(122)) || ((NU8)((*(*s).name).s->data[((NI) 0)])) >= ((NU8)(65)) && ((NU8)((*(*s).name).s->data[((NI) 0)])) <= ((NU8)(90)) || ((NU8)((*(*s).name).s->data[((NI) 0)])) >= ((NU8)(48)) && ((NU8)((*(*s).name).s->data[((NI) 0)])) <= ((NU8)(57)) || ((NU8)((*(*s).name).s->data[((NI) 0)])) >= ((NU8)(128)) && ((NU8)((*(*s).name).s->data[((NI) 0)])) <= ((NU8)(255)));
	LA3: ;
	LOC1 = LOC2;
	if (!(LOC1)) goto LA4;
	LOC5 = 0;
	LOC5 = iskeyword_233071((*s).name);
	LOC1 = !(LOC5);
	LA4: ;
	result = LOC1;
	return result;
}

static N_INLINE(void, initcandidateaux_362251)(Tcontext264020* ctx, Tcandidate362206* c, Ttype214828* callee) {
	unsureAsgnRef((void**) (&(*c).c), ctx);
	(*c).exactmatches = ((NI) 0);
	(*c).subtypematches = ((NI) 0);
	(*c).convmatches = ((NI) 0);
	(*c).intconvmatches = ((NI) 0);
	(*c).genericmatches = ((NI) 0);
	(*c).state = ((NU8) 0);
	unsureAsgnRef((void**) (&(*c).callee), callee);
	unsureAsgnRef((void**) (&(*c).call), NIM_NIL);
	(*c).basetypematch = NIM_FALSE;
	(*c).genericconverter = NIM_FALSE;
	(*c).inheritancepenalty = ((NI) 0);
}

N_NIMCALL(void, initcandidate_362257)(Tcontext264020* ctx, Tcandidate362206* c, Ttype214828* callee) {
	initcandidateaux_362251(ctx, c, callee);
	unsureAsgnRef((void**) (&(*c).calleesym), NIM_NIL);
	initidtable_218033((&(*c).bindings));
}

static N_INLINE(Ttype214828*, skipintlit_258653)(Ttype214828* t) {
	Ttype214828* result;
{	result = 0;
	{
		if (!!(((*t).n == NIM_NIL))) goto LA3;
		{
			if (!((IL64(70866960384) &((NU64)1<<((NU)((*t).kind)&63U)))!=0)) goto LA7;
			result = getsystype_258130((*t).kind);
			goto BeforeRet;
		}
		LA7: ;
	}
	LA3: ;
	result = t;
	}BeforeRet: ;
	return result;
}

static N_INLINE(void, put_362264)(Tidtable214840* t, Ttype214828* key, Ttype214828* val) {
	Tidobj189006* LOC1;
	Ttype214828* LOC2;
	TNimObject* LOC3;
	LOC1 = 0;
	LOC1 = &key->Sup;
	LOC2 = 0;
	LOC2 = skipintlit_258653(val);
	LOC3 = 0;
	LOC3 = &LOC2->Sup.Sup;
	idtableput_221115(t, LOC1, LOC3);
}

static N_INLINE(NI, len_215059)(Tnode214790* n) {
	NI result;
	result = 0;
	{
		if (!(*n).kindU.S6.sons == 0) goto LA3;
		result = ((NI) 0);
	}
	goto LA1;
	LA3: ;
	{
		result = ((*n).kindU.S6.sons ? (*n).kindU.S6.sons->Sup.len : 0);
	}
	LA1: ;
	return result;
}

N_NIMCALL(NIM_BOOL, shouldskipdistinct_364176)(Tnode214790* rules, Tident189012* callident) {
	NIM_BOOL result;
{	result = 0;
	{
		if (!((*rules).kind == ((NU8) 130))) goto LA3;
		{
			Tnode214790* r_364190;
			r_364190 = 0;
			{
				NI i_364220;
				NI HEX3Atmp_364222;
				NI LOC7;
				NI res_364224;
				i_364220 = 0;
				HEX3Atmp_364222 = 0;
				LOC7 = 0;
				LOC7 = len_215059(rules);
				HEX3Atmp_364222 = (LOC7 - 1);
				res_364224 = ((NI) 0);
				{
					while (1) {
						if (!(res_364224 <= HEX3Atmp_364222)) goto LA9;
						i_364220 = res_364224;
						r_364190 = (*rules).kindU.S6.sons->data[i_364220];
						{
							Tident189012* LOC12;
							LOC12 = 0;
							LOC12 = considerquotedident_269004(r_364190);
							if (!(LOC12 == callident)) goto LA13;
							result = NIM_TRUE;
							goto BeforeRet;
						}
						LA13: ;
						res_364224 += ((NI) 1);
					} LA9: ;
				}
			}
		}
		result = NIM_FALSE;
		goto BeforeRet;
	}
	goto LA1;
	LA3: ;
	{
		{
			Tnode214790* r_364203;
			r_364203 = 0;
			{
				NI i_364231;
				NI HEX3Atmp_364233;
				NI LOC18;
				NI res_364235;
				i_364231 = 0;
				HEX3Atmp_364233 = 0;
				LOC18 = 0;
				LOC18 = len_215059(rules);
				HEX3Atmp_364233 = (LOC18 - 1);
				res_364235 = ((NI) 0);
				{
					while (1) {
						if (!(res_364235 <= HEX3Atmp_364233)) goto LA20;
						i_364231 = res_364235;
						r_364203 = (*rules).kindU.S6.sons->data[i_364231];
						{
							Tident189012* LOC23;
							LOC23 = 0;
							LOC23 = considerquotedident_269004(r_364203);
							if (!(LOC23 == callident)) goto LA24;
							result = NIM_FALSE;
							goto BeforeRet;
						}
						LA24: ;
						res_364235 += ((NI) 1);
					} LA20: ;
				}
			}
		}
		result = NIM_TRUE;
		goto BeforeRet;
	}
	LA1: ;
	}BeforeRet: ;
	return result;
}

N_NIMCALL(Ttype214828*, maybeskipdistinct_364238)(Ttype214828* t, Tsym214822* callee) {
	Ttype214828* result;
	result = 0;
	{
		NIM_BOOL LOC3;
		NIM_BOOL LOC4;
		NIM_BOOL LOC5;
		LOC3 = 0;
		LOC4 = 0;
		LOC5 = 0;
		LOC5 = !((t == NIM_NIL));
		if (!(LOC5)) goto LA6;
		LOC5 = ((*t).kind == ((NU8) 13));
		LA6: ;
		LOC4 = LOC5;
		if (!(LOC4)) goto LA7;
		LOC4 = !(((*t).n == NIM_NIL));
		LA7: ;
		LOC3 = LOC4;
		if (!(LOC3)) goto LA8;
		LOC3 = shouldskipdistinct_364176((*t).n, (*callee).name);
		LA8: ;
		if (!LOC3) goto LA9;
		result = base_240021(t);
	}
	goto LA1;
	LA9: ;
	{
		result = t;
	}
	LA1: ;
	return result;
}

static N_INLINE(NIM_BOOL, sameenumtypes_245402)(Ttype214828* a, Ttype214828* b) {
	NIM_BOOL result;
	result = 0;
	result = ((*a).Sup.id == (*b).Sup.id);
	return result;
}

static N_INLINE(Tnode214790*, HEX5BHEX5D_215238)(Tnode214790* n, NI i) {
	Tnode214790* result;
	result = 0;
	result = (*n).kindU.S6.sons->data[i];
	return result;
}

N_NIMCALL(Tnode214790*, tryresolvingstaticexpr_364277)(Tcandidate362206* c, Tnode214790* n) {
	Tnode214790* result;
	Tnode214790* instantiated;
	result = 0;
	instantiated = replacetypesinbody_285430((*c).c, (*c).bindings, n, NIM_NIL);
	result = (*(*c).c).semexpr((*c).c, instantiated, 0);
	return result;
}

N_NOINLINE(NU8, typerangerel_364019)(Ttype214828* f, Ttype214828* a) {
	NU8 result;
	NI64 a0;
	NI64 a1;
	NI64 f0;
	NI64 f1;
	result = 0;
	a0 = firstord_240001(a);
	a1 = lastord_240004(a);
	f0 = firstord_240001(f);
	f1 = lastord_240004(f);
	{
		NIM_BOOL LOC3;
		LOC3 = 0;
		LOC3 = (a0 == f0);
		if (!(LOC3)) goto LA4;
		LOC3 = (a1 == f1);
		LA4: ;
		if (!LOC3) goto LA5;
		result = ((NU8) 10);
	}
	goto LA1;
	LA5: ;
	{
		NIM_BOOL LOC8;
		LOC8 = 0;
		LOC8 = (f0 <= a0);
		if (!(LOC8)) goto LA9;
		LOC8 = (a1 <= f1);
		LA9: ;
		if (!LOC8) goto LA10;
		result = ((NU8) 1);
	}
	goto LA1;
	LA10: ;
	{
		NIM_BOOL LOC13;
		LOC13 = 0;
		LOC13 = (a0 <= f1);
		if (!(LOC13)) goto LA14;
		LOC13 = (f0 <= a1);
		LA14: ;
		if (!LOC13) goto LA15;
		result = ((NU8) 1);
	}
	goto LA1;
	LA15: ;
	{
		result = ((NU8) 0);
	}
	LA1: ;
	return result;
}

N_NIMCALL(NIM_BOOL, isconvertibletorange_362958)(Ttype214828* f, Ttype214828* a) {
	NIM_BOOL result;
	result = 0;
	{
		NIM_BOOL LOC3;
		LOC3 = 0;
		LOC3 = ((IL64(34151432454144) &((NU64)1<<((NU)((*f).kind)&63U)))!=0);
		if (!(LOC3)) goto LA4;
		LOC3 = ((IL64(34151432454144) &((NU64)1<<((NU)((*a).kind)&63U)))!=0);
		LA4: ;
		if (!LOC3) goto LA5;
		result = NIM_TRUE;
	}
	goto LA1;
	LA5: ;
	{
		NIM_BOOL LOC8;
		LOC8 = 0;
		LOC8 = ((IL64(1030792151040) &((NU64)1<<((NU)((*f).kind)&63U)))!=0);
		if (!(LOC8)) goto LA9;
		LOC8 = ((IL64(1030792151040) &((NU64)1<<((NU)((*a).kind)&63U)))!=0);
		LA9: ;
		if (!LOC8) goto LA10;
		result = NIM_TRUE;
	}
	goto LA1;
	LA10: ;
	LA1: ;
	return result;
}

static N_INLINE(NIM_BOOL, isintlit_240222)(Ttype214828* t) {
	NIM_BOOL result;
	NIM_BOOL LOC1;
	NIM_BOOL LOC2;
	result = 0;
	LOC1 = 0;
	LOC2 = 0;
	LOC2 = ((*t).kind == ((NU8) 31));
	if (!(LOC2)) goto LA3;
	LOC2 = !(((*t).n == NIM_NIL));
	LA3: ;
	LOC1 = LOC2;
	if (!(LOC1)) goto LA4;
	LOC1 = ((*(*t).n).kind == ((NU8) 6));
	LA4: ;
	result = LOC1;
	return result;
}

N_NIMCALL(NU8, handlerange_362848)(Ttype214828* f, Ttype214828* a, NU8 min, NU8 max) {
	NU8 result;
	result = 0;
	{
		if (!((*a).kind == (*f).kind)) goto LA3;
		result = ((NU8) 10);
	}
	goto LA1;
	LA3: ;
	{
		Ttype214828* ab;
		NU8 k;
		ab = skiptypes_218113(a, 1048576);
		k = (*ab).kind;
		{
			if (!(k == (*f).kind)) goto LA8;
			result = ((NU8) 4);
		}
		goto LA6;
		LA8: ;
		{
			NIM_BOOL LOC11;
			NIM_BOOL LOC12;
			NIM_BOOL LOC13;
			NIM_BOOL LOC14;
			NI64 LOC18;
			NI64 LOC20;
			LOC11 = 0;
			LOC12 = 0;
			LOC13 = 0;
			LOC14 = 0;
			LOC14 = (k == ((NU8) 31));
			if (!(LOC14)) goto LA15;
			LOC14 = ((IL64(34149286019072) &((NU64)1<<((NU)((*f).kind)&63U)))!=0);
			LA15: ;
			LOC13 = LOC14;
			if (!(LOC13)) goto LA16;
			LOC13 = isintlit_240222(ab);
			LA16: ;
			LOC12 = LOC13;
			if (!(LOC12)) goto LA17;
			LOC18 = 0;
			LOC18 = firstord_240001(f);
			LOC12 = (LOC18 <= (*(*ab).n).kindU.S1.intval);
			LA17: ;
			LOC11 = LOC12;
			if (!(LOC11)) goto LA19;
			LOC20 = 0;
			LOC20 = lastord_240004(f);
			LOC11 = ((*(*ab).n).kindU.S1.intval <= LOC20);
			LA19: ;
			if (!LOC11) goto LA21;
			result = ((NU8) 9);
		}
		goto LA6;
		LA21: ;
		{
			NIM_BOOL LOC24;
			LOC24 = 0;
			LOC24 = ((*f).kind == ((NU8) 31));
			if (!(LOC24)) goto LA25;
			LOC24 = ((IL64(30064771072) &((NU64)1<<((NU)(k)&63U)))!=0);
			LA25: ;
			if (!LOC24) goto LA26;
			result = ((NU8) 2);
		}
		goto LA6;
		LA26: ;
		{
			NIM_BOOL LOC29;
			LOC29 = 0;
			LOC29 = (min <= k);
			if (!(LOC29)) goto LA30;
			LOC29 = (k <= max);
			LA30: ;
			if (!LOC29) goto LA31;
			result = ((NU8) 1);
		}
		goto LA6;
		LA31: ;
		{
			NIM_BOOL LOC34;
			NIM_BOOL LOC35;
			NIM_BOOL LOC36;
			NI64 LOC39;
			Tnode214790* LOC40;
			Tnode214790* LOC42;
			NI64 LOC43;
			LOC34 = 0;
			LOC35 = 0;
			LOC36 = 0;
			LOC36 = ((*a).kind == ((NU8) 20));
			if (!(LOC36)) goto LA37;
			LOC36 = ((IL64(15459734781952) &((NU64)1<<((NU)((*(*a).sons->data[((NI) 0)]).kind)&63U)))!=0);
			LA37: ;
			LOC35 = LOC36;
			if (!(LOC35)) goto LA38;
			LOC39 = 0;
			LOC39 = firstord_240001(f);
			LOC40 = 0;
			LOC40 = HEX5BHEX5D_215238((*a).n, ((NI) 0));
			LOC35 = (LOC39 <= (*LOC40).kindU.S1.intval);
			LA38: ;
			LOC34 = LOC35;
			if (!(LOC34)) goto LA41;
			LOC42 = 0;
			LOC42 = HEX5BHEX5D_215238((*a).n, ((NI) 1));
			LOC43 = 0;
			LOC43 = lastord_240004(f);
			LOC34 = ((*LOC42).kindU.S1.intval <= LOC43);
			LA41: ;
			if (!LOC34) goto LA44;
			result = ((NU8) 1);
		}
		goto LA6;
		LA44: ;
		{
			result = ((NU8) 0);
		}
		LA6: ;
	}
	LA1: ;
	return result;
}

static N_INLINE(NIM_BOOL, isfloatlit_240256)(Ttype214828* t) {
	NIM_BOOL result;
	NIM_BOOL LOC1;
	NIM_BOOL LOC2;
	result = 0;
	LOC1 = 0;
	LOC2 = 0;
	LOC2 = ((*t).kind == ((NU8) 36));
	if (!(LOC2)) goto LA3;
	LOC2 = !(((*t).n == NIM_NIL));
	LA3: ;
	LOC1 = LOC2;
	if (!(LOC1)) goto LA4;
	LOC1 = ((*(*t).n).kind == ((NU8) 16));
	LA4: ;
	result = LOC1;
	return result;
}

N_NIMCALL(NU8, handlefloatrange_363007)(Ttype214828* f, Ttype214828* a) {
	NU8 result;
	result = 0;
	{
		if (!((*a).kind == (*f).kind)) goto LA3;
		result = ((NU8) 10);
	}
	goto LA1;
	LA3: ;
	{
		Ttype214828* ab;
		NU8 k;
		ab = skiptypes_218113(a, 1048576);
		k = (*ab).kind;
		{
			if (!(k == (*f).kind)) goto LA8;
			result = ((NU8) 4);
		}
		goto LA6;
		LA8: ;
		{
			NIM_BOOL LOC11;
			LOC11 = 0;
			LOC11 = isfloatlit_240256(ab);
			if (!LOC11) goto LA12;
			result = ((NU8) 9);
		}
		goto LA6;
		LA12: ;
		{
			NIM_BOOL LOC15;
			LOC15 = 0;
			LOC15 = isintlit_240222(ab);
			if (!LOC15) goto LA16;
			result = ((NU8) 1);
		}
		goto LA6;
		LA16: ;
		{
			NIM_BOOL LOC19;
			LOC19 = 0;
			LOC19 = (((NU8) 36) <= k);
			if (!(LOC19)) goto LA20;
			LOC19 = (k <= ((NU8) 39));
			LA20: ;
			if (!LOC19) goto LA21;
			{
				if (!((*f).kind == ((NU8) 37))) goto LA25;
				result = ((NU8) 1);
			}
			goto LA23;
			LA25: ;
			{
				result = ((NU8) 2);
			}
			LA23: ;
		}
		goto LA6;
		LA21: ;
		{
			result = ((NU8) 0);
		}
		LA6: ;
	}
	LA1: ;
	return result;
}

static N_INLINE(NU8, allowsnil_363589)(Ttype214828* f) {
	NU8 result;
	result = 0;
	{
		if (!!((((*f).flags &(1U<<((NU)(((NU8) 16))&31U)))!=0))) goto LA3;
		result = ((NU8) 3);
	}
	goto LA1;
	LA3: ;
	{
		result = ((NU8) 0);
	}
	LA1: ;
	return result;
}

N_NIMCALL(NU8, minrel_363436)(NU8 a, NU8 b) {
	NU8 result;
	result = 0;
	{
		if (!(a <= b)) goto LA3;
		result = a;
	}
	goto LA1;
	LA3: ;
	{
		result = b;
	}
	LA1: ;
	return result;
}

N_NIMCALL(NU8, recordrel_363450)(Tcandidate362206* c, Ttype214828* f, Ttype214828* a) {
	NU8 result;
{	result = 0;
	result = ((NU8) 0);
	{
		NIM_BOOL LOC3;
		LOC3 = 0;
		LOC3 = sametype_244628(f, a, 0);
		if (!LOC3) goto LA4;
		result = ((NU8) 10);
	}
	goto LA1;
	LA4: ;
	{
		NI LOC7;
		NI LOC8;
		NI firstfield;
		LOC7 = 0;
		LOC7 = sonslen_217327(a);
		LOC8 = 0;
		LOC8 = sonslen_217327(f);
		if (!(LOC7 == LOC8)) goto LA9;
		result = ((NU8) 10);
		{
			if (!((*f).kind == ((NU8) 18))) goto LA13;
			firstfield = ((NI) 0);
		}
		goto LA11;
		LA13: ;
		{
			firstfield = ((NI) 1);
		}
		LA11: ;
		{
			NI i_363478;
			NI HEX3Atmp_363574;
			NI LOC17;
			NI res_363577;
			i_363478 = 0;
			HEX3Atmp_363574 = 0;
			LOC17 = 0;
			LOC17 = sonslen_217327(f);
			HEX3Atmp_363574 = (NI)(LOC17 - ((NI) 1));
			res_363577 = firstfield;
			{
				while (1) {
					NU8 m;
					if (!(res_363577 <= HEX3Atmp_363574)) goto LA19;
					i_363478 = res_363577;
					m = typerel_362805(c, (*f).sons->data[i_363478], (*a).sons->data[i_363478], NIM_TRUE);
					{
						if (!(m < ((NU8) 3))) goto LA22;
						result = ((NU8) 0);
						goto BeforeRet;
					}
					LA22: ;
					result = minrel_363436(result, m);
					res_363577 += ((NI) 1);
				} LA19: ;
			}
		}
		{
			NIM_BOOL LOC26;
			LOC26 = 0;
			LOC26 = !(((*f).n == NIM_NIL));
			if (!(LOC26)) goto LA27;
			LOC26 = !(((*a).n == NIM_NIL));
			LA27: ;
			if (!LOC26) goto LA28;
			{
				NI i_363524;
				NI HEX3Atmp_363582;
				NI LOC31;
				NI res_363585;
				i_363524 = 0;
				HEX3Atmp_363582 = 0;
				LOC31 = 0;
				LOC31 = sonslen_217351((*f).n);
				HEX3Atmp_363582 = (NI)(LOC31 - ((NI) 1));
				res_363585 = ((NI) 0);
				{
					while (1) {
						if (!(res_363585 <= HEX3Atmp_363582)) goto LA33;
						i_363524 = res_363585;
						{
							if (!!(((*(*(*f).n).kindU.S6.sons->data[i_363524]).kind == ((NU8) 3)))) goto LA36;
							internalerror_187100((*(*f).n).info, ((NimStringDesc*) &TMP2796));
						}
						goto LA34;
						LA36: ;
						{
							if (!!(((*(*(*a).n).kindU.S6.sons->data[i_363524]).kind == ((NU8) 3)))) goto LA39;
							internalerror_187100((*(*a).n).info, ((NimStringDesc*) &TMP2796));
						}
						goto LA34;
						LA39: ;
						{
							Tsym214822* x;
							Tsym214822* y;
							x = (*(*(*f).n).kindU.S6.sons->data[i_363524]).kindU.S4.sym;
							y = (*(*(*a).n).kindU.S6.sons->data[i_363524]).kindU.S4.sym;
							{
								NIM_BOOL LOC44;
								NU8 LOC46;
								LOC44 = 0;
								LOC44 = ((*f).kind == ((NU8) 17));
								if (!(LOC44)) goto LA45;
								LOC46 = 0;
								LOC46 = typerel_362805(c, (*x).typ, (*y).typ, NIM_TRUE);
								LOC44 = (LOC46 < ((NU8) 3));
								LA45: ;
								if (!LOC44) goto LA47;
								result = ((NU8) 0);
								goto BeforeRet;
							}
							LA47: ;
							{
								if (!!(((*(*x).name).Sup.id == (*(*y).name).Sup.id))) goto LA51;
								result = ((NU8) 0);
								goto BeforeRet;
							}
							LA51: ;
						}
						LA34: ;
						res_363585 += ((NI) 1);
					} LA33: ;
				}
			}
		}
		LA28: ;
	}
	goto LA1;
	LA9: ;
	LA1: ;
	}BeforeRet: ;
	return result;
}

N_NIMCALL(NI, isobjectsubtype_363060)(Ttype214828* a, Ttype214828* f) {
	NI result;
	Ttype214828* t;
	NI depth;
	result = 0;
	t = a;
	depth = ((NI) 0);
	{
		while (1) {
			NIM_BOOL LOC3;
			NIM_BOOL LOC5;
			LOC3 = 0;
			LOC3 = !((t == NIM_NIL));
			if (!(LOC3)) goto LA4;
			LOC5 = 0;
			LOC5 = sameobjecttypes_245344(f, t);
			LOC3 = !(LOC5);
			LA4: ;
			if (!LOC3) goto LA2;
			t = (*t).sons->data[((NI) 0)];
			{
				if (!(t == NIM_NIL)) goto LA8;
				goto LA1;
			}
			LA8: ;
			t = skiptypes_218113(t, 2048);
			depth += ((NI) 1);
		} LA2: ;
	} LA1: ;
	{
		if (!!((t == NIM_NIL))) goto LA12;
		result = depth;
	}
	LA12: ;
	return result;
}

static N_INLINE(NIM_BOOL, samedistincttypes_245397)(Ttype214828* a, Ttype214828* b) {
	NIM_BOOL result;
	result = 0;
	result = sameobjecttypes_245344(a, b);
	return result;
}

static N_INLINE(NIM_BOOL, inconsistentvartypes_363603)(Ttype214828* f, Ttype214828* a) {
	NIM_BOOL result;
	NIM_BOOL LOC1;
	NIM_BOOL LOC3;
	result = 0;
	LOC1 = 0;
	LOC1 = !(((*f).kind == (*a).kind));
	if (!(LOC1)) goto LA2;
	LOC3 = 0;
	LOC3 = ((*f).kind == ((NU8) 23));
	if (LOC3) goto LA4;
	LOC3 = ((*a).kind == ((NU8) 23));
	LA4: ;
	LOC1 = LOC3;
	LA2: ;
	result = LOC1;
	return result;
}

N_NIMCALL(NU8, procparamtyperel_363635)(Tcandidate362206* c, Ttype214828* f_363639, Ttype214828* a_363640) {
	NU8 result;
	Ttype214828* f;
	Ttype214828* a;
{	result = 0;
	f = f_363639;
	a = a_363640;
	{
		NIM_BOOL LOC3;
		Ttype214828* aresolved;
		Tidobj189006* LOC6;
		TNimObject* LOC7;
		LOC3 = 0;
		LOC3 = ismetatype_215803(a);
		if (!LOC3) goto LA4;
		LOC6 = 0;
		LOC6 = &a->Sup;
		LOC7 = 0;
		LOC7 = idtableget_221107((*c).bindings, LOC6);
		aresolved = ((Ttype214828*) (LOC7));
		{
			if (!!((aresolved == NIM_NIL))) goto LA10;
			a = aresolved;
		}
		LA10: ;
	}
	LA4: ;
	{
		NIM_BOOL LOC14;
		NU8 reverserel;
		LOC14 = 0;
		LOC14 = ismetatype_215803(a);
		if (!LOC14) goto LA15;
		{
			NIM_BOOL LOC19;
			LOC19 = 0;
			LOC19 = ismetatype_215803(f);
			if (!LOC19) goto LA20;
			f = generatetypeinstance_285450((*c).c, (*c).bindings, (*(*c).call).info, f);
			{
				NIM_BOOL LOC24;
				LOC24 = 0;
				LOC24 = (f == NIM_NIL);
				if (LOC24) goto LA25;
				LOC24 = ismetatype_215803(f);
				LA25: ;
				if (!LOC24) goto LA26;
				result = ((NU8) 5);
				goto BeforeRet;
			}
			LA26: ;
		}
		LA20: ;
		reverserel = typerel_362805(c, a, f, NIM_TRUE);
		{
			if (!(((NU8) 8) <= reverserel)) goto LA30;
			result = ((NU8) 6);
		}
		LA30: ;
	}
	goto LA12;
	LA15: ;
	{
		result = typerel_362805(c, f, a, NIM_TRUE);
	}
	LA12: ;
	{
		NIM_BOOL LOC35;
		LOC35 = 0;
		LOC35 = (result <= ((NU8) 3));
		if (LOC35) goto LA36;
		LOC35 = inconsistentvartypes_363603(f, a);
		LA36: ;
		if (!LOC35) goto LA37;
		result = ((NU8) 0);
	}
	LA37: ;
	}BeforeRet: ;
	return result;
}

N_NIMCALL(NU8, proctyperel_363688)(Tcandidate362206* c, Ttype214828* f, Ttype214828* a) {
	NU8 result;
{	result = 0;
	switch ((*a).kind) {
	case ((NU8) 25):
	{
		{
			NI LOC4;
			NI LOC5;
			LOC4 = 0;
			LOC4 = sonslen_217327(f);
			LOC5 = 0;
			LOC5 = sonslen_217327(a);
			if (!!((LOC4 == LOC5))) goto LA6;
			goto BeforeRet;
		}
		LA6: ;
		result = ((NU8) 10);
		{
			NI i_363719;
			NI HEX3Atmp_364012;
			NI LOC9;
			NI res_364015;
			i_363719 = 0;
			HEX3Atmp_364012 = 0;
			LOC9 = 0;
			LOC9 = sonslen_217327(f);
			HEX3Atmp_364012 = (LOC9 - 1);
			res_364015 = ((NI) 1);
			{
				while (1) {
					NU8 LOC12;
					if (!(res_364015 <= HEX3Atmp_364012)) goto LA11;
					i_363719 = res_364015;
					LOC12 = 0;
					LOC12 = procparamtyperel_363635(c, (*f).sons->data[i_363719], (*a).sons->data[i_363719]);
					result = minrel_363436(result, LOC12);
					{
						if (!(result == ((NU8) 0))) goto LA15;
						goto BeforeRet;
					}
					LA15: ;
					res_364015 += ((NI) 1);
				} LA11: ;
			}
		}
		{
			if (!!(((*f).sons->data[((NI) 0)] == NIM_NIL))) goto LA19;
			{
				NU8 LOC25;
				if (!!(((*a).sons->data[((NI) 0)] == NIM_NIL))) goto LA23;
				LOC25 = 0;
				LOC25 = procparamtyperel_363635(c, (*f).sons->data[((NI) 0)], (*a).sons->data[((NI) 0)]);
				result = minrel_363436(result, LOC25);
				{
					if (!(result == ((NU8) 0))) goto LA28;
					goto BeforeRet;
				}
				LA28: ;
			}
			goto LA21;
			LA23: ;
			{
				result = ((NU8) 0);
				goto BeforeRet;
			}
			LA21: ;
		}
		goto LA17;
		LA19: ;
		{
			if (!!(((*a).sons->data[((NI) 0)] == NIM_NIL))) goto LA32;
			result = ((NU8) 0);
			goto BeforeRet;
		}
		goto LA17;
		LA32: ;
		LA17: ;
		{
			NIM_BOOL LOC36;
			LOC36 = 0;
			LOC36 = (((*f).flags &(1U<<((NU)(((NU8) 1))&31U)))!=0);
			if (!(LOC36)) goto LA37;
			LOC36 = !((((*a).flags &(1U<<((NU)(((NU8) 1))&31U)))!=0));
			LA37: ;
			if (!LOC36) goto LA38;
			result = ((NU8) 0);
			goto BeforeRet;
		}
		goto LA34;
		LA38: ;
		{
			NIM_BOOL LOC41;
			NIM_BOOL LOC42;
			LOC41 = 0;
			LOC42 = 0;
			LOC42 = (((*f).flags &(1U<<((NU)(((NU8) 7))&31U)))!=0);
			if (!(LOC42)) goto LA43;
			LOC42 = (((*a).flags & 130) == 0);
			LA43: ;
			LOC41 = LOC42;
			if (!(LOC41)) goto LA44;
			LOC41 = ((gglobaloptions_160121 &(1U<<((NU)(((NU8) 24))&31U)))!=0);
			LA44: ;
			if (!LOC41) goto LA45;
			result = ((NU8) 0);
			goto BeforeRet;
		}
		goto LA34;
		LA45: ;
		{
			if (!!((((*f).flags & 16384) == ((*a).flags & 16384)))) goto LA48;
			result = ((NU8) 0);
			goto BeforeRet;
		}
		goto LA34;
		LA48: ;
		{
			if (!!(((*f).callconv == (*a).callconv))) goto LA51;
			{
				NIM_BOOL LOC55;
				LOC55 = 0;
				LOC55 = ((*f).callconv == ((NU8) 8));
				if (!(LOC55)) goto LA56;
				LOC55 = ((*a).callconv == ((NU8) 0));
				LA56: ;
				if (!LOC55) goto LA57;
				{
					if (!(result == ((NU8) 6))) goto LA61;
					result = ((NU8) 7);
				}
				goto LA59;
				LA61: ;
				{
					if (!(result == ((NU8) 5))) goto LA64;
					result = ((NU8) 5);
				}
				goto LA59;
				LA64: ;
				{
					result = ((NU8) 1);
				}
				LA59: ;
			}
			goto LA53;
			LA57: ;
			{
				result = ((NU8) 0);
				goto BeforeRet;
			}
			LA53: ;
		}
		goto LA34;
		LA51: ;
		LA34: ;
		{
			NIM_BOOL LOC70;
			LOC70 = 0;
			LOC70 = compatibleeffects_248614(f, a);
			if (!!(LOC70)) goto LA71;
			result = ((NU8) 0);
			goto BeforeRet;
		}
		LA71: ;
	}
	break;
	case ((NU8) 5):
	{
		result = allowsnil_363589(f);
	}
	break;
	case ((NU8) 49):
	{
		{
			Ttype214828* LOC79;
			Ttype214828* LOC80;
			if (!(((*f).flags &(1U<<((NU)(((NU8) 14))&31U)))!=0)) goto LA77;
			LOC79 = 0;
			LOC79 = base_240021(f);
			LOC80 = 0;
			LOC80 = base_240021(a);
			result = typerel_362805(c, LOC79, LOC80, NIM_TRUE);
		}
		LA77: ;
	}
	break;
	default:
	{
	}
	break;
	}
	}BeforeRet: ;
	return result;
}

N_NIMCALL(Ttype214828*, concretetype_362812)(Tcandidate362206* c, Ttype214828* t) {
	Ttype214828* result;
	result = 0;
	switch ((*t).kind) {
	case ((NU8) 4):
	{
		result = newtype_217107(((NU8) 16), (*t).owner);
		addsonskipintlit_258680(result, (*t).sons->data[((NI) 0)]);
		addsonskipintlit_258680(result, (*t).sons->data[((NI) 1)]);
	}
	break;
	case ((NU8) 5):
	{
		result = NIM_NIL;
	}
	break;
	case ((NU8) 8):
	{
		{
			if (!(*c).isnocall) goto LA6;
			result = t;
		}
		goto LA4;
		LA6: ;
		{
			result = NIM_NIL;
		}
		LA4: ;
	}
	break;
	case ((NU8) 24):
	case ((NU8) 19):
	{
		{
			if (!((*(*t).sons->data[((NI) 0)]).kind == ((NU8) 3))) goto LA12;
			result = NIM_NIL;
		}
		goto LA10;
		LA12: ;
		{
			result = t;
		}
		LA10: ;
	}
	break;
	case ((NU8) 12):
	case ((NU8) 58):
	{
		result = t;
		{
			while (1) {
				Tidobj189006* LOC18;
				TNimObject* LOC19;
				LOC18 = 0;
				LOC18 = &t->Sup;
				LOC19 = 0;
				LOC19 = idtableget_221107((*c).bindings, LOC18);
				result = ((Ttype214828*) (LOC19));
				{
					if (!(result == NIM_NIL)) goto LA22;
					goto LA16;
				}
				LA22: ;
				{
					if (!!(((*result).kind == ((NU8) 12)))) goto LA26;
					goto LA16;
				}
				LA26: ;
			}
		} LA16: ;
	}
	break;
	case ((NU8) 9):
	{
		NimStringDesc* LOC29;
		NimStringDesc* LOC30;
		LOC29 = 0;
		LOC30 = 0;
		LOC30 = typetostring_240017(t, ((NU8) 0));
		LOC29 = rawNewString(LOC30->Sup.len + 21);
appendString(LOC29, ((NimStringDesc*) &TMP2800));
appendString(LOC29, LOC30);
		internalerror_187113(LOC29);
		result = t;
	}
	break;
	default:
	{
		result = t;
	}
	break;
	}
	return result;
}

N_NIMCALL(NU8, matchusertypeclass_364028)(Tcontext264020* c, Tcandidate362206* m, Ttype214828* ff, Ttype214828* a) {
	NU8 volatile result;
	Ttype214828* body;
	Tscope214816* LOC9;
	TSafePoint TMP2802;
{	result = 0;
	body = skiptypes_218113(ff, IL64(9007199254740992));
	{
		Tnode214790* LOC5;
		NimStringDesc* LOC6;
		Tnode214790* LOC7;
		NimStringDesc* LOC8;
		if (!(((NI) 20) < (*c).intypeclass)) goto LA3;
		LOC5 = 0;
		LOC5 = HEX5BHEX5D_215238((*body).n, ((NI) 3));
		LOC6 = 0;
		LOC7 = 0;
		LOC7 = HEX5BHEX5D_215238((*body).n, ((NI) 3));
		LOC8 = 0;
		LOC8 = HEX24_233066(LOC7);
		LOC6 = rawNewString(LOC8->Sup.len + 29);
appendString(LOC6, LOC8);
appendString(LOC6, ((NimStringDesc*) &TMP2801));
		localerror_187085((*LOC5).info, LOC6);
		result = ((NU8) 0);
		goto BeforeRet;
	}
	LA3: ;
	LOC9 = 0;
	LOC9 = openscope_269060(c);
	(*c).intypeclass += ((NI) 1);
	pushSafePoint(&TMP2802);
	TMP2802.status = _setjmp(TMP2802.context);
	if (TMP2802.status == 0) {
		Tnode214790* checkedbody;
		Tnode214790* LOC43;
		Tnode214790* LOC44;
		{
			if (!((*ff).kind == ((NU8) 53))) goto LA13;
			{
				NI i_364082;
				NI HEX3Atmp_364155;
				NI LOC16;
				NI res_364158;
				i_364082 = 0;
				HEX3Atmp_364155 = 0;
				LOC16 = 0;
				LOC16 = len_217339(ff);
				HEX3Atmp_364155 = ((NI)(LOC16 - ((NI) 1)) - 1);
				res_364158 = ((NI) 1);
				{
					while (1) {
						Tident189012* typeparamname;
						Ttype214828* LOC19;
						Ttype214828* typ;
						Tsym214822* volatile param;
						if (!(res_364158 <= HEX3Atmp_364155)) goto LA18;
						i_364082 = res_364158;
						LOC19 = 0;
						LOC19 = base_240021(ff);
						typeparamname = (*(*(*LOC19).sons->data[(NI)(i_364082 - ((NI) 1))]).sym).name;
						typ = (*ff).sons->data[i_364082];
						param = 0;
						switch ((*typ).kind) {
						case ((NU8) 59):
						{
							param = newsym_215683(((NU8) 10), typeparamname, (*body).sym, (*(*body).sym).info);
							asgnRefNoCycle((void**) (&(*param).typ), base_240021(typ));
							asgnRefNoCycle((void**) (&(*param).ast), (*typ).n);
						}
						break;
						case ((NU8) 60):
						{
							param = newsym_215683(((NU8) 8), typeparamname, (*body).sym, (*(*body).sym).info);
							asgnRefNoCycle((void**) (&(*param).typ), typ);
						}
						break;
						default:
						{
							param = newsym_215683(((NU8) 7), typeparamname, (*body).sym, (*(*body).sym).info);
							asgnRefNoCycle((void**) (&(*param).typ), maketypedesc_264523(c, typ));
						}
						break;
						}
						adddecl_269445(c, param);
						res_364158 += ((NI) 1);
					} LA18: ;
				}
			}
		}
		LA13: ;
		{
			Tnode214790* param_364098;
			Tnode214790* HEX3Atmp_364165;
			param_364098 = 0;
			HEX3Atmp_364165 = 0;
			HEX3Atmp_364165 = HEX5BHEX5D_215238((*body).n, ((NI) 0));
			{
				NI i_364169;
				NI HEX3Atmp_364171;
				NI LOC25;
				NI res_364173;
				i_364169 = 0;
				HEX3Atmp_364171 = 0;
				LOC25 = 0;
				LOC25 = len_215059(HEX3Atmp_364165);
				HEX3Atmp_364171 = (LOC25 - 1);
				res_364173 = ((NI) 0);
				{
					while (1) {
						Tnode214790* volatile dummyname;
						Ttype214828* volatile dummytype;
						Tsym214822* dummyparam;
						if (!(res_364173 <= HEX3Atmp_364171)) goto LA27;
						i_364169 = res_364173;
						param_364098 = (*HEX3Atmp_364165).kindU.S6.sons->data[i_364169];
						dummyname = 0;
						dummytype = 0;
						{
							if (!((*param_364098).kind == ((NU8) 143))) goto LA30;
							dummyname = HEX5BHEX5D_215238(param_364098, ((NI) 0));
							{
								if (!!(((*a).kind == ((NU8) 23)))) goto LA34;
								dummytype = makevartype_264490(c, a);
							}
							goto LA32;
							LA34: ;
							{
								dummytype = a;
							}
							LA32: ;
						}
						goto LA28;
						LA30: ;
						{
							dummyname = param_364098;
							dummytype = a;
						}
						LA28: ;
						{
							NimStringDesc* LOC42;
							if (!!(((*dummyname).kind == ((NU8) 2)))) goto LA40;
							LOC42 = 0;
							LOC42 = HEX24_187183(TMP2804);
							internalerror_187113(LOC42);
						}
						LA40: ;
						dummyparam = newsym_215683(((NU8) 8), (*dummyname).kindU.S5.ident, (*body).sym, (*(*body).sym).info);
						asgnRefNoCycle((void**) (&(*dummyparam).typ), dummytype);
						adddecl_269445(c, dummyparam);
						res_364173 += ((NI) 1);
					} LA27: ;
				}
			}
		}
		LOC43 = 0;
		LOC43 = HEX5BHEX5D_215238((*body).n, ((NI) 3));
		LOC44 = 0;
		LOC44 = copytree_218822(LOC43);
		checkedbody = (*c).semtryexpr(c, LOC44, 0);
		{
			if (!(checkedbody == NIM_NIL)) goto LA47;
			result = ((NU8) 0);
			popSafePoint();
			(*c).intypeclass -= ((NI) 1);
			closescope_269068(c);
			goto BeforeRet;
		}
		LA47: ;
		result = ((NU8) 8);
		popSafePoint();
		(*c).intypeclass -= ((NI) 1);
		closescope_269068(c);
		goto BeforeRet;
		popSafePoint();
	}
	else {
		popSafePoint();
	}
	{
		(*c).intypeclass -= ((NI) 1);
		closescope_269068(c);
	}
	if (TMP2802.status != 0) reraiseException();
	}BeforeRet: ;
	return result;
}

N_NIMCALL(NU8, typerel_362805)(Tcandidate362206* c, Ttype214828* f, Ttype214828* aorig, NIM_BOOL dobind) {
	NU8 result;
	Ttype214828* a;
	Ttype214828* LOC9;
{	result = 0;
	result = ((NU8) 0);
	{
		if (!((*f).kind == ((NU8) 6))) goto LA3;
		{
			if (!!((aorig == NIM_NIL))) goto LA7;
			put_362264((&(*c).bindings), f, aorig);
		}
		LA7: ;
		result = ((NU8) 8);
		goto BeforeRet;
	}
	LA3: ;
	LOC9 = 0;
	LOC9 = skiptypes_218113(aorig, IL64(576460752311812096));
	a = maybeskipdistinct_364238(LOC9, (*c).calleesym);
	{
		NIM_BOOL LOC12;
		Ttype214828* LOC14;
		Ttype214828* LOC17;
		LOC12 = 0;
		LOC12 = ((*a).kind == ((NU8) 11));
		if (!(LOC12)) goto LA13;
		LOC14 = 0;
		LOC14 = skiptypes_218113(f, 8388608);
		LOC12 = !(((IL64(574208952489745920) &((NU64)1<<((NU)((*LOC14).kind)&63U)))!=0));
		LA13: ;
		if (!LOC12) goto LA15;
		LOC17 = 0;
		LOC17 = lastson_217377(a);
		result = typerel_362805(c, f, LOC17, NIM_TRUE);
		goto BeforeRet;
	}
	LA15: ;
	switch ((*a).kind) {
	case ((NU8) 56):
	{
		result = ((NU8) 8);
		{
			Ttype214828* branch_364658;
			Ttypeseq214824* HEX3Atmp_366410;
			NI i_366413;
			NI L_366415;
			branch_364658 = 0;
			HEX3Atmp_366410 = 0;
			HEX3Atmp_366410 = (*a).sons;
			i_366413 = ((NI) 0);
			L_366415 = (HEX3Atmp_366410 ? HEX3Atmp_366410->Sup.len : 0);
			{
				while (1) {
					NU8 x;
					if (!(i_366413 < L_366415)) goto LA21;
					branch_364658 = HEX3Atmp_366410->data[i_366413];
					x = typerel_362805(c, f, branch_364658, NIM_FALSE);
					{
						if (!(x == ((NU8) 0))) goto LA24;
						result = ((NU8) 0);
						goto BeforeRet;
					}
					LA24: ;
					{
						if (!(x < result)) goto LA28;
						result = x;
					}
					LA28: ;
					i_366413 += ((NI) 1);
				} LA21: ;
			}
		}
	}
	break;
	case ((NU8) 55):
	{
		{
			Ttype214828* branch_364686;
			Ttypeseq214824* HEX3Atmp_366417;
			NI i_366420;
			NI L_366422;
			branch_364686 = 0;
			HEX3Atmp_366417 = 0;
			HEX3Atmp_366417 = (*a).sons;
			i_366420 = ((NI) 0);
			L_366422 = (HEX3Atmp_366417 ? HEX3Atmp_366417->Sup.len : 0);
			{
				while (1) {
					NU8 x;
					if (!(i_366420 < L_366422)) goto LA33;
					branch_364686 = HEX3Atmp_366417->data[i_366420];
					x = typerel_362805(c, f, branch_364686, NIM_FALSE);
					{
						if (!!((x == ((NU8) 0)))) goto LA36;
						{
							if (!(((NU8) 8) <= x)) goto LA40;
							result = ((NU8) 8);
						}
						goto LA38;
						LA40: ;
						{
							result = x;
						}
						LA38: ;
						goto BeforeRet;
					}
					LA36: ;
					i_366420 += ((NI) 1);
				} LA33: ;
			}
		}
		result = ((NU8) 0);
	}
	break;
	case ((NU8) 57):
	{
		switch ((*f).kind) {
		case ((NU8) 57):
		{
			Ttype214828* LOC45;
			Ttype214828* LOC46;
			LOC45 = 0;
			LOC45 = lastson_217377(a);
			LOC46 = 0;
			LOC46 = lastson_217377(f);
			result = typerel_362805(c, LOC45, LOC46, NIM_TRUE);
			goto BeforeRet;
		}
		break;
		default:
		{
			{
				if (!((*f).kind == ((NU8) 58))) goto LA50;
				result = ((NU8) 8);
			}
			goto LA48;
			LA50: ;
			{
				result = ((NU8) 0);
			}
			LA48: ;
			goto BeforeRet;
		}
		break;
		}
	}
	break;
	case ((NU8) 58):
	{
		{
			if (!((*f).kind == ((NU8) 58))) goto LA56;
			result = ((NU8) 8);
		}
		goto LA54;
		LA56: ;
		{
			result = ((NU8) 0);
		}
		LA54: ;
		goto BeforeRet;
	}
	break;
	case ((NU8) 52):
	case ((NU8) 53):
	{
		NU8 x;
		x = typerel_362805(c, a, f, NIM_FALSE);
		{
			if (!(((NU8) 8) <= x)) goto LA62;
			result = ((NU8) 8);
			goto BeforeRet;
		}
		LA62: ;
	}
	break;
	default:
	{
	}
	break;
	}
	switch ((*f).kind) {
	case ((NU8) 14):
	{
		{
			NIM_BOOL LOC68;
			LOC68 = 0;
			LOC68 = ((*a).kind == (*f).kind);
			if (!(LOC68)) goto LA69;
			LOC68 = sameenumtypes_245402(f, a);
			LA69: ;
			if (!LOC68) goto LA70;
			result = ((NU8) 10);
		}
		goto LA66;
		LA70: ;
		{
			Ttype214828* LOC73;
			NIM_BOOL LOC74;
			LOC73 = 0;
			LOC73 = skiptypes_218113(a, 1048576);
			LOC74 = 0;
			LOC74 = sameenumtypes_245402(f, LOC73);
			if (!LOC74) goto LA75;
			result = ((NU8) 3);
		}
		goto LA66;
		LA75: ;
		LA66: ;
	}
	break;
	case ((NU8) 1):
	case ((NU8) 2):
	{
		{
			if (!((*a).kind == (*f).kind)) goto LA80;
			result = ((NU8) 10);
		}
		goto LA78;
		LA80: ;
		{
			Ttype214828* LOC83;
			LOC83 = 0;
			LOC83 = skiptypes_218113(a, 1048576);
			if (!((*LOC83).kind == (*f).kind)) goto LA84;
			result = ((NU8) 3);
		}
		goto LA78;
		LA84: ;
		LA78: ;
	}
	break;
	case ((NU8) 20):
	{
		{
			Ttype214828* LOC96;
			Ttype214828* LOC97;
			if (!((*a).kind == (*f).kind)) goto LA89;
			{
				Ttype214828* LOC93;
				LOC93 = 0;
				LOC93 = base_240021(f);
				if (!((*LOC93).kind == ((NU8) 0))) goto LA94;
				result = ((NU8) 8);
				goto BeforeRet;
			}
			LA94: ;
			LOC96 = 0;
			LOC96 = base_240021(f);
			LOC97 = 0;
			LOC97 = base_240021(a);
			result = typerel_362805(c, LOC96, LOC97, NIM_TRUE);
			{
				if (!!(((257 &(1U<<((NU)(result)&15U)))!=0))) goto LA100;
				{
					NI i_364801;
					NI res_366426;
					i_364801 = 0;
					res_366426 = ((NI) 0);
					{
						while (1) {
							if (!(res_366426 <= ((NI) 1))) goto LA104;
							i_364801 = res_366426;
							{
								Tnode214790* LOC107;
								Tnode214790* LOC110;
								LOC107 = 0;
								LOC107 = HEX5BHEX5D_215238((*f).n, i_364801);
								if (!((*LOC107).kind == ((NU8) 62))) goto LA108;
								LOC110 = 0;
								LOC110 = HEX5BHEX5D_215238((*f).n, i_364801);
								asgnRefNoCycle((void**) (&(*(*f).n).kindU.S6.sons->data[i_364801]), tryresolvingstaticexpr_364277(c, LOC110));
							}
							LA108: ;
							res_366426 += ((NI) 1);
						} LA104: ;
					}
				}
				result = typerangerel_364019(f, a);
			}
			LA100: ;
		}
		goto LA87;
		LA89: ;
		{
			{
				Ttype214828* LOC114;
				LOC114 = 0;
				LOC114 = skiptypes_218113(f, 1048576);
				if (!((*LOC114).kind == (*a).kind)) goto LA115;
				result = ((NU8) 2);
			}
			goto LA112;
			LA115: ;
			{
				Ttype214828* LOC118;
				NIM_BOOL LOC119;
				LOC118 = 0;
				LOC118 = skiptypes_218113(f, 1048576);
				LOC119 = 0;
				LOC119 = isconvertibletorange_362958(LOC118, a);
				if (!LOC119) goto LA120;
				result = ((NU8) 1);
			}
			goto LA112;
			LA120: ;
			LA112: ;
		}
		LA87: ;
	}
	break;
	case ((NU8) 31):
	{
		result = handlerange_362848(f, a, ((NU8) 32), ((NU8) 34));
	}
	break;
	case ((NU8) 32):
	{
		result = handlerange_362848(f, a, ((NU8) 32), ((NU8) 32));
	}
	break;
	case ((NU8) 33):
	{
		result = handlerange_362848(f, a, ((NU8) 32), ((NU8) 33));
	}
	break;
	case ((NU8) 34):
	{
		result = handlerange_362848(f, a, ((NU8) 32), ((NU8) 34));
	}
	break;
	case ((NU8) 35):
	{
		result = handlerange_362848(f, a, ((NU8) 31), ((NU8) 35));
	}
	break;
	case ((NU8) 40):
	{
		result = handlerange_362848(f, a, ((NU8) 41), ((NU8) 43));
	}
	break;
	case ((NU8) 41):
	{
		result = handlerange_362848(f, a, ((NU8) 41), ((NU8) 41));
	}
	break;
	case ((NU8) 42):
	{
		result = handlerange_362848(f, a, ((NU8) 41), ((NU8) 42));
	}
	break;
	case ((NU8) 43):
	{
		result = handlerange_362848(f, a, ((NU8) 41), ((NU8) 43));
	}
	break;
	case ((NU8) 44):
	{
		result = handlerange_362848(f, a, ((NU8) 40), ((NU8) 44));
	}
	break;
	case ((NU8) 36):
	{
		result = handlefloatrange_363007(f, a);
	}
	break;
	case ((NU8) 37):
	{
		result = handlefloatrange_363007(f, a);
	}
	break;
	case ((NU8) 38):
	{
		result = handlefloatrange_363007(f, a);
	}
	break;
	case ((NU8) 39):
	{
		result = handlefloatrange_363007(f, a);
	}
	break;
	case ((NU8) 23):
	{
		{
			Ttype214828* LOC141;
			Ttype214828* LOC142;
			if (!((*aorig).kind == ((NU8) 23))) goto LA139;
			LOC141 = 0;
			LOC141 = base_240021(f);
			LOC142 = 0;
			LOC142 = base_240021(aorig);
			result = typerel_362805(c, LOC141, LOC142, NIM_TRUE);
		}
		goto LA137;
		LA139: ;
		{
			Ttype214828* LOC144;
			LOC144 = 0;
			LOC144 = base_240021(f);
			result = typerel_362805(c, LOC144, aorig, NIM_TRUE);
		}
		LA137: ;
	}
	break;
	case ((NU8) 16):
	case ((NU8) 4):
	{
		switch ((*a).kind) {
		case ((NU8) 16):
		case ((NU8) 4):
		{
			Ttype214828* frange;
			frange = (*f).sons->data[((NI) 0)];
			{
				Ttype214828* prev;
				Tidobj189006* LOC151;
				TNimObject* LOC152;
				if (!((*frange).kind == ((NU8) 12))) goto LA149;
				LOC151 = 0;
				LOC151 = &frange->Sup;
				LOC152 = 0;
				LOC152 = idtableget_221107((*c).bindings, LOC151);
				prev = ((Ttype214828*) (LOC152));
				{
					if (!(prev == NIM_NIL)) goto LA155;
					put_362264((&(*c).bindings), frange, (*a).sons->data[((NI) 0)]);
					frange = a;
				}
				goto LA153;
				LA155: ;
				{
					frange = prev;
				}
				LA153: ;
			}
			LA149: ;
			result = typerel_362805(c, (*f).sons->data[((NI) 1)], (*a).sons->data[((NI) 1)], NIM_TRUE);
			{
				if (!(result < ((NU8) 8))) goto LA160;
				result = ((NU8) 0);
				goto BeforeRet;
			}
			LA160: ;
			{
				NIM_BOOL LOC164;
				NIM_BOOL LOC165;
				NI LOC167;
				Tnode214790* LOC169;
				Tnode214790* len;
				Tnode214790* LOC182;
				LOC164 = 0;
				LOC165 = 0;
				LOC165 = !(((*frange).n == NIM_NIL));
				if (!(LOC165)) goto LA166;
				LOC167 = 0;
				LOC167 = len_215059((*frange).n);
				LOC165 = (((NI) 1) < LOC167);
				LA166: ;
				LOC164 = LOC165;
				if (!(LOC164)) goto LA168;
				LOC169 = 0;
				LOC169 = HEX5BHEX5D_215238((*frange).n, ((NI) 1));
				LOC164 = ((*LOC169).kind == ((NU8) 62));
				LA168: ;
				if (!LOC164) goto LA170;
				{
					Ttype214828* rangestatict;
					Tnode214790* LOC176;
					Tnode214790* LOC177;
					Tnode214790* LOC178;
					Ttype214828* replacementt;
					Ttypeseq214824* LOC179;
					TY366877 LOC180;
					NI64 inputupperbound;
					Tnode214790* LOC181;
					if (!(((*frange).flags &(1U<<((NU)(((NU8) 9))&31U)))!=0)) goto LA174;
					LOC176 = 0;
					LOC176 = HEX5BHEX5D_215238((*frange).n, ((NI) 1));
					LOC177 = 0;
					LOC177 = HEX5BHEX5D_215238(LOC176, ((NI) 0));
					LOC178 = 0;
					LOC178 = HEX5BHEX5D_215238(LOC177, ((NI) 1));
					rangestatict = (*LOC178).typ;
					LOC179 = 0;
					LOC179 = (Ttypeseq214824*) newSeq((&NTI214824), 1);
					memset((void*)LOC180, 0, sizeof(LOC180));
					LOC180[0] = getsystype_258130(((NU8) 31));
					asgnRefNoCycle((void**) (&LOC179->data[0]), LOC180[0]);
					replacementt = newtypewithsons_264601((*c).c, ((NU8) 59), LOC179);
					LOC181 = 0;
					LOC181 = HEX5BHEX5D_215238((*(*a).sons->data[((NI) 0)]).n, ((NI) 1));
					inputupperbound = (*LOC181).kindU.S1.intval;
					asgnRefNoCycle((void**) (&(*replacementt).n), newintnode_215659(((NU8) 6), (NI64)(inputupperbound + IL64(1))));
					put_362264((&(*c).bindings), rangestatict, replacementt);
					result = ((NU8) 8);
					goto BeforeRet;
				}
				LA174: ;
				LOC182 = 0;
				LOC182 = HEX5BHEX5D_215238((*frange).n, ((NI) 1));
				len = tryresolvingstaticexpr_364277(c, LOC182);
				{
					NIM_BOOL LOC185;
					NI64 LOC187;
					LOC185 = 0;
					LOC185 = ((*len).kind == ((NU8) 6));
					if (!(LOC185)) goto LA186;
					LOC187 = 0;
					LOC187 = lengthord_240007(a);
					LOC185 = ((NI64)((*len).kindU.S1.intval + IL64(1)) == LOC187);
					LA186: ;
					if (!LOC185) goto LA188;
					goto BeforeRet;
				}
				goto LA183;
				LA188: ;
				{
					result = ((NU8) 0);
					goto BeforeRet;
				}
				LA183: ;
			}
			goto LA162;
			LA170: ;
			{
				NI64 LOC192;
				NI64 LOC193;
				LOC192 = 0;
				LOC192 = lengthord_240007(frange);
				LOC193 = 0;
				LOC193 = lengthord_240007(a);
				if (!!((LOC192 == LOC193))) goto LA194;
				result = ((NU8) 0);
			}
			goto LA162;
			LA194: ;
			LA162: ;
		}
		break;
		default:
		{
		}
		break;
		}
	}
	break;
	case ((NU8) 27):
	case ((NU8) 48):
	{
		{
			if (!((*f).kind == ((NU8) 48))) goto LA200;
			{
				if (!(((*(*f).sons->data[((NI) 0)]).flags &(1U<<((NU)(((NU8) 0))&31U)))!=0)) goto LA204;
				{
					if (!((*(*f).sons->data[((NI) 0)]).kind == ((NU8) 6))) goto LA208;
					goto BeforeRet;
				}
				LA208: ;
			}
			goto LA202;
			LA204: ;
			{
				if (!((*(*f).sons->data[((NI) 0)]).kind == ((NU8) 7))) goto LA211;
				goto BeforeRet;
			}
			goto LA202;
			LA211: ;
			LA202: ;
		}
		LA200: ;
		switch ((*a).kind) {
		case ((NU8) 27):
		case ((NU8) 48):
		{
			Ttype214828* LOC214;
			Ttype214828* LOC215;
			LOC214 = 0;
			LOC214 = base_240021(f);
			LOC215 = 0;
			LOC215 = base_240021(a);
			result = typerel_362805(c, LOC214, LOC215, NIM_TRUE);
			{
				if (!(result < ((NU8) 8))) goto LA218;
				result = ((NU8) 0);
			}
			LA218: ;
		}
		break;
		case ((NU8) 4):
		{
			{
				NIM_BOOL LOC223;
				LOC223 = 0;
				LOC223 = !(((*(*f).sons->data[((NI) 0)]).kind == ((NU8) 12)));
				if (!(LOC223)) goto LA224;
				LOC223 = ((*(*a).sons->data[((NI) 1)]).kind == ((NU8) 3));
				LA224: ;
				if (!LOC223) goto LA225;
				result = ((NU8) 3);
			}
			goto LA221;
			LA225: ;
			{
				Ttype214828* LOC228;
				NU8 LOC229;
				LOC228 = 0;
				LOC228 = base_240021(f);
				LOC229 = 0;
				LOC229 = typerel_362805(c, LOC228, (*a).sons->data[((NI) 1)], NIM_TRUE);
				if (!(((NU8) 8) <= LOC229)) goto LA230;
				result = ((NU8) 3);
			}
			goto LA221;
			LA230: ;
			LA221: ;
		}
		break;
		case ((NU8) 16):
		{
			{
				NIM_BOOL LOC235;
				LOC235 = 0;
				LOC235 = !(((*(*f).sons->data[((NI) 0)]).kind == ((NU8) 12)));
				if (!(LOC235)) goto LA236;
				LOC235 = ((*(*a).sons->data[((NI) 1)]).kind == ((NU8) 3));
				LA236: ;
				if (!LOC235) goto LA237;
				result = ((NU8) 3);
			}
			goto LA233;
			LA237: ;
			{
				Ttype214828* LOC240;
				NU8 LOC241;
				LOC240 = 0;
				LOC240 = base_240021(f);
				LOC241 = 0;
				LOC241 = typerel_362805(c, LOC240, (*a).sons->data[((NI) 1)], NIM_TRUE);
				if (!(((NU8) 8) <= LOC241)) goto LA242;
				result = ((NU8) 1);
			}
			goto LA233;
			LA242: ;
			LA233: ;
		}
		break;
		case ((NU8) 24):
		{
			{
				NIM_BOOL LOC247;
				LOC247 = 0;
				LOC247 = !(((*(*f).sons->data[((NI) 0)]).kind == ((NU8) 12)));
				if (!(LOC247)) goto LA248;
				LOC247 = ((*(*a).sons->data[((NI) 0)]).kind == ((NU8) 3));
				LA248: ;
				if (!LOC247) goto LA249;
				result = ((NU8) 1);
			}
			goto LA245;
			LA249: ;
			{
				Ttype214828* LOC252;
				NU8 LOC253;
				LOC252 = 0;
				LOC252 = base_240021(f);
				LOC253 = 0;
				LOC253 = typerel_362805(c, LOC252, (*a).sons->data[((NI) 0)], NIM_TRUE);
				if (!(((NU8) 8) <= LOC253)) goto LA254;
				result = ((NU8) 1);
			}
			goto LA245;
			LA254: ;
			LA245: ;
		}
		break;
		case ((NU8) 28):
		{
			{
				if (!((*f).kind == ((NU8) 27))) goto LA259;
				{
					if (!((*(*f).sons->data[((NI) 0)]).kind == ((NU8) 2))) goto LA263;
					result = ((NU8) 1);
				}
				goto LA261;
				LA263: ;
				{
					NIM_BOOL LOC266;
					NIM_BOOL LOC267;
					NI LOC269;
					Ttype214828* LOC271;
					Ttype214828* LOC272;
					NU8 LOC273;
					LOC266 = 0;
					LOC267 = 0;
					LOC267 = ((*(*f).sons->data[((NI) 0)]).kind == ((NU8) 12));
					if (!(LOC267)) goto LA268;
					LOC269 = 0;
					LOC269 = len_217339(a);
					LOC267 = (((NI) 0) < LOC269);
					LA268: ;
					LOC266 = LOC267;
					if (!(LOC266)) goto LA270;
					LOC271 = 0;
					LOC271 = base_240021(f);
					LOC272 = 0;
					LOC272 = base_240021(a);
					LOC273 = 0;
					LOC273 = typerel_362805(c, LOC271, LOC272, NIM_TRUE);
					LOC266 = (((NU8) 8) <= LOC273);
					LA270: ;
					if (!LOC266) goto LA274;
					result = ((NU8) 1);
				}
				goto LA261;
				LA274: ;
				LA261: ;
			}
			LA259: ;
		}
		break;
		default:
		{
		}
		break;
		}
	}
	break;
	case ((NU8) 24):
	{
		switch ((*a).kind) {
		case ((NU8) 24):
		{
			{
				NIM_BOOL LOC281;
				LOC281 = 0;
				LOC281 = !(((*(*f).sons->data[((NI) 0)]).kind == ((NU8) 12)));
				if (!(LOC281)) goto LA282;
				LOC281 = ((*(*a).sons->data[((NI) 0)]).kind == ((NU8) 3));
				LA282: ;
				if (!LOC281) goto LA283;
				result = ((NU8) 3);
			}
			goto LA279;
			LA283: ;
			{
				result = typerel_362805(c, (*f).sons->data[((NI) 0)], (*a).sons->data[((NI) 0)], NIM_TRUE);
				{
					if (!(result < ((NU8) 8))) goto LA288;
					result = ((NU8) 0);
				}
				goto LA286;
				LA288: ;
				{
					NIM_BOOL LOC291;
					LOC291 = 0;
					LOC291 = (((*f).flags &(1U<<((NU)(((NU8) 16))&31U)))!=0);
					if (!(LOC291)) goto LA292;
					LOC291 = !((((*a).flags &(1U<<((NU)(((NU8) 16))&31U)))!=0));
					LA292: ;
					if (!LOC291) goto LA293;
					result = ((NU8) 1);
				}
				goto LA286;
				LA293: ;
				LA286: ;
			}
			LA279: ;
		}
		break;
		case ((NU8) 5):
		{
			result = allowsnil_363589(f);
		}
		break;
		default:
		{
		}
		break;
		}
	}
	break;
	case ((NU8) 15):
	{
		{
			NIM_BOOL LOC300;
			Ttype214828* x;
			LOC300 = 0;
			LOC300 = isordinaltype_240057(a);
			if (!LOC300) goto LA301;
			{
				if (!((*a).kind == ((NU8) 15))) goto LA305;
				x = (*a).sons->data[((NI) 0)];
			}
			goto LA303;
			LA305: ;
			{
				x = a;
			}
			LA303: ;
			{
				if (!((*(*f).sons->data[((NI) 0)]).kind == ((NU8) 0))) goto LA310;
				result = ((NU8) 8);
			}
			goto LA308;
			LA310: ;
			{
				result = typerel_362805(c, (*f).sons->data[((NI) 0)], x, NIM_TRUE);
				{
					if (!(result < ((NU8) 8))) goto LA315;
					result = ((NU8) 0);
				}
				LA315: ;
			}
			LA308: ;
		}
		goto LA298;
		LA301: ;
		{
			if (!((*a).kind == ((NU8) 12))) goto LA318;
			result = ((NU8) 8);
		}
		goto LA298;
		LA318: ;
		LA298: ;
	}
	break;
	case ((NU8) 30):
	{
		internalerror_187113(((NimStringDesc*) &TMP2795));
	}
	break;
	case ((NU8) 5):
	{
		{
			if (!((*a).kind == (*f).kind)) goto LA324;
			result = ((NU8) 10);
		}
		LA324: ;
	}
	break;
	case ((NU8) 18):
	{
		{
			if (!((*a).kind == ((NU8) 18))) goto LA329;
			result = recordrel_363450(c, f, a);
		}
		LA329: ;
	}
	break;
	case ((NU8) 17):
	{
		{
			if (!((*a).kind == ((NU8) 17))) goto LA334;
			{
				NIM_BOOL LOC338;
				LOC338 = 0;
				LOC338 = sameobjecttypes_245344(f, a);
				if (!LOC338) goto LA339;
				result = ((NU8) 10);
			}
			goto LA336;
			LA339: ;
			{
				NI depth;
				depth = isobjectsubtype_363060(a, f);
				{
					if (!(((NI) 0) < depth)) goto LA344;
					(*c).inheritancepenalty += depth;
					result = ((NU8) 3);
				}
				LA344: ;
			}
			LA336: ;
		}
		LA334: ;
	}
	break;
	case ((NU8) 13):
	{
		{
			NIM_BOOL LOC349;
			LOC349 = 0;
			LOC349 = ((*a).kind == ((NU8) 13));
			if (!(LOC349)) goto LA350;
			LOC349 = samedistincttypes_245397(f, a);
			LA350: ;
			if (!LOC349) goto LA351;
			result = ((NU8) 10);
		}
		goto LA347;
		LA351: ;
		{
			Ttype214828* LOC356;
			if (!(*c).coercedistincts) goto LA354;
			LOC356 = 0;
			LOC356 = base_240021(f);
			result = typerel_362805(c, LOC356, a, NIM_TRUE);
		}
		goto LA347;
		LA354: ;
		LA347: ;
	}
	break;
	case ((NU8) 19):
	{
		{
			if (!((*a).kind == ((NU8) 19))) goto LA360;
			{
				NIM_BOOL LOC364;
				LOC364 = 0;
				LOC364 = !(((*(*f).sons->data[((NI) 0)]).kind == ((NU8) 12)));
				if (!(LOC364)) goto LA365;
				LOC364 = ((*(*a).sons->data[((NI) 0)]).kind == ((NU8) 3));
				LA365: ;
				if (!LOC364) goto LA366;
				result = ((NU8) 3);
			}
			goto LA362;
			LA366: ;
			{
				result = typerel_362805(c, (*f).sons->data[((NI) 0)], (*a).sons->data[((NI) 0)], NIM_TRUE);
				{
					if (!(result <= ((NU8) 1))) goto LA371;
					result = ((NU8) 0);
				}
				LA371: ;
			}
			LA362: ;
		}
		LA360: ;
	}
	break;
	case ((NU8) 21):
	case ((NU8) 22):
	{
		{
			Ttype214828* LOC393;
			Ttype214828* LOC394;
			if (!((*a).kind == (*f).kind)) goto LA376;
			{
				NI LOC380;
				NI LOC381;
				LOC380 = 0;
				LOC380 = len_217339(a);
				LOC381 = 0;
				LOC381 = len_217339(f);
				if (!(LOC380 < LOC381)) goto LA382;
				result = ((NU8) 0);
				goto BeforeRet;
			}
			LA382: ;
			{
				NI i_365273;
				NI HEX3Atmp_366431;
				NI LOC385;
				NI res_366434;
				i_365273 = 0;
				HEX3Atmp_366431 = 0;
				LOC385 = 0;
				LOC385 = len_217339(f);
				HEX3Atmp_366431 = (NI)(LOC385 - ((NI) 2));
				res_366434 = ((NI) 0);
				{
					while (1) {
						if (!(res_366434 <= HEX3Atmp_366431)) goto LA387;
						i_365273 = res_366434;
						{
							NU8 LOC390;
							LOC390 = 0;
							LOC390 = typerel_362805(c, (*f).sons->data[i_365273], (*a).sons->data[i_365273], NIM_TRUE);
							if (!(LOC390 == ((NU8) 0))) goto LA391;
							result = ((NU8) 0);
							goto BeforeRet;
						}
						LA391: ;
						res_366434 += ((NI) 1);
					} LA387: ;
				}
			}
			LOC393 = 0;
			LOC393 = lastson_217377(f);
			LOC394 = 0;
			LOC394 = lastson_217377(a);
			result = typerel_362805(c, LOC393, LOC394, NIM_TRUE);
			{
				if (!(result <= ((NU8) 1))) goto LA397;
				result = ((NU8) 0);
			}
			goto LA395;
			LA397: ;
			{
				NIM_BOOL LOC400;
				LOC400 = 0;
				LOC400 = (((*f).flags &(1U<<((NU)(((NU8) 16))&31U)))!=0);
				if (!(LOC400)) goto LA401;
				LOC400 = !((((*a).flags &(1U<<((NU)(((NU8) 16))&31U)))!=0));
				LA401: ;
				if (!LOC400) goto LA402;
				result = ((NU8) 1);
			}
			goto LA395;
			LA402: ;
			LA395: ;
		}
		goto LA374;
		LA376: ;
		{
			if (!((*a).kind == ((NU8) 5))) goto LA405;
			result = allowsnil_363589(f);
		}
		goto LA374;
		LA405: ;
		{
		}
		LA374: ;
	}
	break;
	case ((NU8) 25):
	{
		result = proctyperel_363688(c, f, a);
		{
			NIM_BOOL LOC411;
			NIM_BOOL LOC412;
			LOC411 = 0;
			LOC412 = 0;
			LOC412 = !((result == ((NU8) 0)));
			if (!(LOC412)) goto LA413;
			LOC412 = (((*f).flags &(1U<<((NU)(((NU8) 16))&31U)))!=0);
			LA413: ;
			LOC411 = LOC412;
			if (!(LOC411)) goto LA414;
			LOC411 = !((((*a).flags &(1U<<((NU)(((NU8) 16))&31U)))!=0));
			LA414: ;
			if (!LOC411) goto LA415;
			result = ((NU8) 1);
		}
		LA415: ;
	}
	break;
	case ((NU8) 26):
	{
		switch ((*a).kind) {
		case ((NU8) 26):
		{
			{
				NIM_BOOL LOC421;
				LOC421 = 0;
				LOC421 = (((*f).flags &(1U<<((NU)(((NU8) 16))&31U)))!=0);
				if (!(LOC421)) goto LA422;
				LOC421 = !((((*a).flags &(1U<<((NU)(((NU8) 16))&31U)))!=0));
				LA422: ;
				if (!LOC421) goto LA423;
				result = ((NU8) 1);
			}
			goto LA419;
			LA423: ;
			{
				result = ((NU8) 10);
			}
			LA419: ;
		}
		break;
		case ((NU8) 5):
		{
			result = allowsnil_363589(f);
		}
		break;
		case ((NU8) 25):
		{
			{
				if (!!(((*a).callconv == ((NU8) 8)))) goto LA430;
				result = ((NU8) 1);
			}
			LA430: ;
		}
		break;
		case ((NU8) 21):
		{
			{
				NI LOC435;
				LOC435 = 0;
				LOC435 = len_217339(a);
				if (!(LOC435 == ((NI) 1))) goto LA436;
				result = ((NU8) 1);
			}
			LA436: ;
		}
		break;
		case ((NU8) 29):
		{
			result = ((NU8) 1);
		}
		break;
		default:
		{
		}
		break;
		}
	}
	break;
	case ((NU8) 28):
	{
		switch ((*a).kind) {
		case ((NU8) 28):
		{
			{
				NIM_BOOL LOC444;
				LOC444 = 0;
				LOC444 = (((*f).flags &(1U<<((NU)(((NU8) 16))&31U)))!=0);
				if (!(LOC444)) goto LA445;
				LOC444 = !((((*a).flags &(1U<<((NU)(((NU8) 16))&31U)))!=0));
				LA445: ;
				if (!LOC444) goto LA446;
				result = ((NU8) 1);
			}
			goto LA442;
			LA446: ;
			{
				result = ((NU8) 10);
			}
			LA442: ;
		}
		break;
		case ((NU8) 5):
		{
			result = allowsnil_363589(f);
		}
		break;
		default:
		{
		}
		break;
		}
	}
	break;
	case ((NU8) 29):
	{
		switch ((*a).kind) {
		case ((NU8) 29):
		{
			{
				NIM_BOOL LOC455;
				LOC455 = 0;
				LOC455 = (((*f).flags &(1U<<((NU)(((NU8) 16))&31U)))!=0);
				if (!(LOC455)) goto LA456;
				LOC455 = !((((*a).flags &(1U<<((NU)(((NU8) 16))&31U)))!=0));
				LA456: ;
				if (!LOC455) goto LA457;
				result = ((NU8) 1);
			}
			goto LA453;
			LA457: ;
			{
				result = ((NU8) 10);
			}
			LA453: ;
		}
		break;
		case ((NU8) 5):
		{
			result = allowsnil_363589(f);
		}
		break;
		case ((NU8) 28):
		{
			result = ((NU8) 1);
		}
		break;
		case ((NU8) 21):
		{
			{
				NIM_BOOL LOC465;
				NI LOC466;
				LOC465 = 0;
				LOC466 = 0;
				LOC466 = len_217339(a);
				LOC465 = (LOC466 == ((NI) 1));
				if (!(LOC465)) goto LA467;
				LOC465 = ((*(*a).sons->data[((NI) 0)]).kind == ((NU8) 2));
				LA467: ;
				if (!LOC465) goto LA468;
				result = ((NU8) 1);
			}
			LA468: ;
		}
		break;
		case ((NU8) 16):
		{
			{
				NIM_BOOL LOC473;
				NIM_BOOL LOC474;
				NI64 LOC475;
				Ttype214828* LOC477;
				LOC473 = 0;
				LOC474 = 0;
				LOC475 = 0;
				LOC475 = firstord_240001((*a).sons->data[((NI) 0)]);
				LOC474 = (LOC475 == IL64(0));
				if (!(LOC474)) goto LA476;
				LOC477 = 0;
				LOC477 = skiptypes_218113((*a).sons->data[((NI) 0)], 1048576);
				LOC474 = ((IL64(66571993088) &((NU64)1<<((NU)((*LOC477).kind)&63U)))!=0);
				LA476: ;
				LOC473 = LOC474;
				if (!(LOC473)) goto LA478;
				LOC473 = ((*(*a).sons->data[((NI) 1)]).kind == ((NU8) 2));
				LA478: ;
				if (!LOC473) goto LA479;
				result = ((NU8) 1);
			}
			LA479: ;
		}
		break;
		default:
		{
		}
		break;
		}
	}
	break;
	case ((NU8) 3):
	{
		{
			if (!((*a).kind == ((NU8) 3))) goto LA485;
			result = ((NU8) 10);
		}
		LA485: ;
	}
	break;
	case ((NU8) 11):
	{
		Ttype214828* roota;
		Ttype214828* rootf;
		roota = skipgenericalias_245606(a);
		rootf = skipgenericalias_245606(f);
		{
			NIM_BOOL LOC490;
			Ttype214828* LOC492;
			Ttype214828* LOC493;
			LOC490 = 0;
			LOC490 = ((*a).kind == ((NU8) 11));
			if (!(LOC490)) goto LA491;
			LOC492 = 0;
			LOC492 = base_240021(roota);
			LOC493 = 0;
			LOC493 = base_240021(rootf);
			LOC490 = (LOC492 == LOC493);
			LA491: ;
			if (!LOC490) goto LA494;
			{
				NI i_365489;
				NI HEX3Atmp_366439;
				NI LOC497;
				NI res_366442;
				i_365489 = 0;
				HEX3Atmp_366439 = 0;
				LOC497 = 0;
				LOC497 = sonslen_217327(rootf);
				HEX3Atmp_366439 = (NI)(LOC497 - ((NI) 2));
				res_366442 = ((NI) 1);
				{
					while (1) {
						Ttype214828* ff;
						Ttype214828* aa;
						if (!(res_366442 <= HEX3Atmp_366439)) goto LA499;
						i_365489 = res_366442;
						ff = (*rootf).sons->data[i_365489];
						aa = (*roota).sons->data[i_365489];
						result = typerel_362805(c, ff, aa, NIM_TRUE);
						{
							if (!(result == ((NU8) 0))) goto LA502;
							goto BeforeRet;
						}
						LA502: ;
						{
							NIM_BOOL LOC506;
							LOC506 = 0;
							LOC506 = ((*ff).kind == ((NU8) 20));
							if (!(LOC506)) goto LA507;
							LOC506 = !((result == ((NU8) 10)));
							LA507: ;
							if (!LOC506) goto LA508;
							result = ((NU8) 0);
							goto BeforeRet;
						}
						LA508: ;
						res_366442 += ((NI) 1);
					} LA499: ;
				}
			}
		}
		goto LA488;
		LA494: ;
		{
			Ttype214828* LOC511;
			LOC511 = 0;
			LOC511 = lastson_217377(f);
			result = typerel_362805(c, LOC511, a, NIM_TRUE);
		}
		LA488: ;
	}
	break;
	case ((NU8) 10):
	{
		Ttype214828* prev_365520;
		Tidobj189006* LOC513;
		TNimObject* LOC514;
		LOC513 = 0;
		LOC513 = &f->Sup;
		LOC514 = 0;
		LOC514 = idtableget_221107((*c).bindings, LOC513);
		prev_365520 = ((Ttype214828*) (LOC514));
		{
			Ttype214828* ff;
			if (!(prev_365520 == NIM_NIL)) goto LA517;
			{
				NIM_BOOL LOC521;
				LOC521 = 0;
				LOC521 = ((*a).kind == ((NU8) 11));
				if (!(LOC521)) goto LA522;
				LOC521 = ((*a).sons->data[((NI) 0)] == f);
				LA522: ;
				if (!LOC521) goto LA523;
				{
					Ttype214828* bound_365554;
					Ttype214828* LOC529;
					if (!dobind) goto LA527;
					LOC529 = 0;
					LOC529 = skiptypes_218113(aorig, 1048576);
					bound_365554 = skipintlit_258653(LOC529);
					{
						if (!dobind) goto LA532;
						put_362264((&(*c).bindings), f, bound_365554);
					}
					LA532: ;
				}
				LA527: ;
				result = ((NU8) 8);
				goto BeforeRet;
			}
			LA523: ;
			ff = lastson_217377(f);
			{
				if (!!((ff == NIM_NIL))) goto LA536;
				result = typerel_362805(c, ff, a, NIM_TRUE);
			}
			LA536: ;
		}
		goto LA515;
		LA517: ;
		{
			result = typerel_362805(c, prev_365520, a, NIM_TRUE);
			goto BeforeRet;
		}
		LA515: ;
	}
	break;
	case ((NU8) 9):
	{
		Ttype214828* x_365570;
		x_365570 = skipgenericalias_245606(a);
		{
			NIM_BOOL LOC542;
			LOC542 = 0;
			LOC542 = ((*x_365570).kind == ((NU8) 9));
			if (LOC542) goto LA543;
			LOC542 = !(((*(*f).sons->data[((NI) 0)]).kind == ((NU8) 10)));
			LA543: ;
			if (!LOC542) goto LA544;
		}
		goto LA540;
		LA544: ;
		{
			NIM_BOOL LOC547;
			NIM_BOOL LOC548;
			NI LOC551;
			NI LOC552;
			LOC547 = 0;
			LOC548 = 0;
			LOC548 = ((*x_365570).kind == ((NU8) 11));
			if (!(LOC548)) goto LA549;
			LOC548 = ((*f).sons->data[((NI) 0)] == (*x_365570).sons->data[((NI) 0)]);
			LA549: ;
			LOC547 = LOC548;
			if (!(LOC547)) goto LA550;
			LOC551 = 0;
			LOC551 = sonslen_217327(x_365570);
			LOC552 = 0;
			LOC552 = sonslen_217327(f);
			LOC547 = ((NI)(LOC551 - ((NI) 1)) == LOC552);
			LA550: ;
			if (!LOC547) goto LA553;
			{
				NI i_365620;
				NI HEX3Atmp_366447;
				NI LOC556;
				NI res_366450;
				i_365620 = 0;
				HEX3Atmp_366447 = 0;
				LOC556 = 0;
				LOC556 = sonslen_217327(f);
				HEX3Atmp_366447 = (NI)(LOC556 - ((NI) 1));
				res_366450 = ((NI) 1);
				{
					while (1) {
						if (!(res_366450 <= HEX3Atmp_366447)) goto LA558;
						i_365620 = res_366450;
						{
							if (!((*(*x_365570).sons->data[i_365620]).kind == ((NU8) 12))) goto LA561;
							internalerror_187113(((NimStringDesc*) &TMP2799));
						}
						goto LA559;
						LA561: ;
						{
							NU8 LOC564;
							LOC564 = 0;
							LOC564 = typerel_362805(c, (*f).sons->data[i_365620], (*x_365570).sons->data[i_365620], NIM_TRUE);
							if (!(LOC564 <= ((NU8) 3))) goto LA565;
							goto BeforeRet;
						}
						goto LA559;
						LA565: ;
						LA559: ;
						res_366450 += ((NI) 1);
					} LA558: ;
				}
			}
			result = ((NU8) 8);
		}
		goto LA540;
		LA553: ;
		{
			Ttype214828* genericbody;
			genericbody = (*f).sons->data[((NI) 0)];
			result = typerel_362805(c, genericbody, x_365570, NIM_TRUE);
			{
				if (!!((result == ((NU8) 0)))) goto LA570;
				{
					NI i_365660;
					NI HEX3Atmp_366455;
					NI LOC573;
					NI res_366458;
					i_365660 = 0;
					HEX3Atmp_366455 = 0;
					LOC573 = 0;
					LOC573 = sonslen_217327(f);
					HEX3Atmp_366455 = (NI)(LOC573 - ((NI) 1));
					res_366458 = ((NI) 1);
					{
						while (1) {
							Ttype214828* x;
							Tidobj189006* LOC576;
							TNimObject* LOC577;
							if (!(res_366458 <= HEX3Atmp_366455)) goto LA575;
							i_365660 = res_366458;
							LOC576 = 0;
							LOC576 = &(*genericbody).sons->data[(NI)(i_365660 - ((NI) 1))]->Sup;
							LOC577 = 0;
							LOC577 = idtableget_221107((*c).bindings, LOC576);
							x = ((Ttype214828*) (LOC577));
							{
								if (!(x == NIM_NIL)) goto LA580;
							}
							goto LA578;
							LA580: ;
							{
								if (!((4608 &((NU64)1<<((NU)((*x).kind)&63U)))!=0)) goto LA583;
								internalerror_187113(((NimStringDesc*) &TMP2799));
							}
							goto LA578;
							LA583: ;
							{
								put_362264((&(*c).bindings), (*f).sons->data[i_365660], x);
							}
							LA578: ;
							res_366458 += ((NI) 1);
						} LA575: ;
					}
				}
			}
			LA570: ;
		}
		LA540: ;
	}
	break;
	case ((NU8) 55):
	{
		Ttype214828* prev_365687;
		Tidobj189006* LOC587;
		TNimObject* LOC588;
		LOC587 = 0;
		LOC587 = &f->Sup;
		LOC588 = 0;
		LOC588 = idtableget_221107((*c).bindings, LOC587);
		prev_365687 = ((Ttype214828*) (LOC588));
		{
			if (!(prev_365687 == NIM_NIL)) goto LA591;
			result = ((NU8) 10);
			{
				Ttype214828* branch_365708;
				Ttypeseq214824* HEX3Atmp_366463;
				NI i_366466;
				NI L_366468;
				branch_365708 = 0;
				HEX3Atmp_366463 = 0;
				HEX3Atmp_366463 = (*f).sons;
				i_366466 = ((NI) 0);
				L_366468 = (HEX3Atmp_366463 ? HEX3Atmp_366463->Sup.len : 0);
				{
					while (1) {
						NU8 x;
						if (!(i_366466 < L_366468)) goto LA595;
						branch_365708 = HEX3Atmp_366463->data[i_366466];
						x = typerel_362805(c, branch_365708, aorig, NIM_TRUE);
						{
							if (!(x < ((NU8) 3))) goto LA598;
							result = ((NU8) 0);
							goto BeforeRet;
						}
						LA598: ;
						{
							if (!(x < result)) goto LA602;
							result = x;
						}
						LA602: ;
						i_366466 += ((NI) 1);
					} LA595: ;
				}
			}
			{
				Ttype214828* bound_365729;
				Ttype214828* LOC608;
				if (!dobind) goto LA606;
				LOC608 = 0;
				LOC608 = skiptypes_218113(aorig, 1048576);
				bound_365729 = skipintlit_258653(LOC608);
				{
					if (!dobind) goto LA611;
					put_362264((&(*c).bindings), f, bound_365729);
				}
				LA611: ;
			}
			LA606: ;
			goto BeforeRet;
		}
		goto LA589;
		LA591: ;
		{
			result = typerel_362805(c, prev_365687, a, NIM_TRUE);
			goto BeforeRet;
		}
		LA589: ;
	}
	break;
	case ((NU8) 56):
	{
		Ttype214828* prev_365733;
		Tidobj189006* LOC615;
		TNimObject* LOC616;
		LOC615 = 0;
		LOC615 = &f->Sup;
		LOC616 = 0;
		LOC616 = idtableget_221107((*c).bindings, LOC615);
		prev_365733 = ((Ttype214828*) (LOC616));
		{
			if (!(prev_365733 == NIM_NIL)) goto LA619;
			result = ((NU8) 0);
			{
				Ttype214828* branch_365754;
				Ttypeseq214824* HEX3Atmp_366470;
				NI i_366473;
				NI L_366475;
				branch_365754 = 0;
				HEX3Atmp_366470 = 0;
				HEX3Atmp_366470 = (*f).sons;
				i_366473 = ((NI) 0);
				L_366475 = (HEX3Atmp_366470 ? HEX3Atmp_366470->Sup.len : 0);
				{
					while (1) {
						NU8 x;
						if (!(i_366473 < L_366475)) goto LA623;
						branch_365754 = HEX3Atmp_366470->data[i_366473];
						x = typerel_362805(c, branch_365754, aorig, NIM_TRUE);
						{
							if (!(result < x)) goto LA626;
							result = x;
						}
						LA626: ;
						i_366473 += ((NI) 1);
					} LA623: ;
				}
			}
			{
				if (!(((NU8) 3) <= result)) goto LA630;
				{
					Ttype214828* bound_365775;
					Ttype214828* LOC636;
					if (!dobind) goto LA634;
					LOC636 = 0;
					LOC636 = skiptypes_218113(aorig, 1048576);
					bound_365775 = skipintlit_258653(LOC636);
					{
						if (!dobind) goto LA639;
						put_362264((&(*c).bindings), f, bound_365775);
					}
					LA639: ;
				}
				LA634: ;
				goto BeforeRet;
			}
			goto LA628;
			LA630: ;
			{
				result = ((NU8) 0);
			}
			LA628: ;
		}
		goto LA617;
		LA619: ;
		{
			result = typerel_362805(c, prev_365733, a, NIM_TRUE);
			goto BeforeRet;
		}
		LA617: ;
	}
	break;
	case ((NU8) 57):
	{
		Ttype214828* prev_365779;
		Tidobj189006* LOC644;
		TNimObject* LOC645;
		LOC644 = 0;
		LOC644 = &f->Sup;
		LOC645 = 0;
		LOC645 = idtableget_221107((*c).bindings, LOC644);
		prev_365779 = ((Ttype214828*) (LOC645));
		{
			if (!(prev_365779 == NIM_NIL)) goto LA648;
			{
				Ttype214828* branch_365800;
				Ttypeseq214824* HEX3Atmp_366477;
				NI i_366480;
				NI L_366482;
				branch_365800 = 0;
				HEX3Atmp_366477 = 0;
				HEX3Atmp_366477 = (*f).sons;
				i_366480 = ((NI) 0);
				L_366482 = (HEX3Atmp_366477 ? HEX3Atmp_366477->Sup.len : 0);
				{
					while (1) {
						if (!(i_366480 < L_366482)) goto LA652;
						branch_365800 = HEX3Atmp_366477->data[i_366480];
						{
							NU8 LOC655;
							LOC655 = 0;
							LOC655 = typerel_362805(c, branch_365800, aorig, NIM_TRUE);
							if (!!((LOC655 == ((NU8) 0)))) goto LA656;
							result = ((NU8) 0);
							goto BeforeRet;
						}
						LA656: ;
						i_366480 += ((NI) 1);
					} LA652: ;
				}
			}
			{
				Ttype214828* bound_365811;
				Ttype214828* LOC662;
				if (!dobind) goto LA660;
				LOC662 = 0;
				LOC662 = skiptypes_218113(aorig, 1048576);
				bound_365811 = skipintlit_258653(LOC662);
				{
					if (!dobind) goto LA665;
					put_362264((&(*c).bindings), f, bound_365811);
				}
				LA665: ;
			}
			LA660: ;
			result = ((NU8) 8);
			goto BeforeRet;
		}
		goto LA646;
		LA648: ;
		{
			result = typerel_362805(c, prev_365779, a, NIM_TRUE);
			goto BeforeRet;
		}
		LA646: ;
	}
	break;
	case ((NU8) 58):
	{
		Ttype214828* prev_365815;
		Tidobj189006* LOC669;
		TNimObject* LOC670;
		LOC669 = 0;
		LOC669 = &f->Sup;
		LOC670 = 0;
		LOC670 = idtableget_221107((*c).bindings, LOC669);
		prev_365815 = ((Ttype214828*) (LOC670));
		{
			Ttype214828* concrete;
			if (!(prev_365815 == NIM_NIL)) goto LA673;
			concrete = concretetype_362812((&(*c)), a);
			{
				NIM_BOOL LOC677;
				LOC677 = 0;
				LOC677 = !((concrete == NIM_NIL));
				if (!(LOC677)) goto LA678;
				LOC677 = dobind;
				LA678: ;
				if (!LOC677) goto LA679;
				put_362264((&(*c).bindings), f, concrete);
			}
			LA679: ;
			result = ((NU8) 8);
			goto BeforeRet;
		}
		goto LA671;
		LA673: ;
		{
			result = typerel_362805(c, prev_365815, a, NIM_TRUE);
			goto BeforeRet;
		}
		LA671: ;
	}
	break;
	case ((NU8) 51):
	{
		Ttype214828* prev_365843;
		Tidobj189006* LOC683;
		TNimObject* LOC684;
		LOC683 = 0;
		LOC683 = &f->Sup;
		LOC684 = 0;
		LOC684 = idtableget_221107((*c).bindings, LOC683);
		prev_365843 = ((Ttype214828*) (LOC684));
		{
			NU8 targetkind;
			if (!(prev_365843 == NIM_NIL)) goto LA687;
			targetkind = (*(*f).sons->data[((NI) 0)]).kind;
			{
				NIM_BOOL LOC691;
				Ttype214828* LOC692;
				NIM_BOOL LOC694;
				LOC691 = 0;
				LOC692 = 0;
				LOC692 = skiptypes_218113(a, 1050624);
				LOC691 = (targetkind == (*LOC692).kind);
				if (LOC691) goto LA693;
				LOC694 = 0;
				LOC694 = ((100663296 &((NU64)1<<((NU)(targetkind)&63U)))!=0);
				if (!(LOC694)) goto LA695;
				LOC694 = ((*a).kind == ((NU8) 5));
				LA695: ;
				LOC691 = LOC694;
				LA693: ;
				if (!LOC691) goto LA696;
				put_362264((&(*c).bindings), f, a);
				result = ((NU8) 8);
				goto BeforeRet;
			}
			goto LA689;
			LA696: ;
			{
				result = ((NU8) 0);
				goto BeforeRet;
			}
			LA689: ;
		}
		goto LA685;
		LA687: ;
		{
			result = typerel_362805(c, prev_365843, a, NIM_TRUE);
			goto BeforeRet;
		}
		LA685: ;
	}
	break;
	case ((NU8) 52):
	case ((NU8) 53):
	{
		Ttype214828* prev_365889;
		Tidobj189006* LOC701;
		TNimObject* LOC702;
		LOC701 = 0;
		LOC701 = &f->Sup;
		LOC702 = 0;
		LOC702 = idtableget_221107((*c).bindings, LOC701);
		prev_365889 = ((Ttype214828*) (LOC702));
		{
			if (!(prev_365889 == NIM_NIL)) goto LA705;
			result = matchusertypeclass_364028((*c).c, c, f, aorig);
			{
				if (!(result == ((NU8) 8))) goto LA709;
				put_362264((&(*c).bindings), f, a);
			}
			LA709: ;
		}
		goto LA703;
		LA705: ;
		{
			result = typerel_362805(c, prev_365889, a, NIM_TRUE);
			goto BeforeRet;
		}
		LA703: ;
	}
	break;
	case ((NU8) 54):
	{
		Ttype214828* prev_365913;
		Tidobj189006* LOC713;
		TNimObject* LOC714;
		LOC713 = 0;
		LOC713 = &f->Sup;
		LOC714 = 0;
		LOC714 = idtableget_221107((*c).bindings, LOC713);
		prev_365913 = ((Ttype214828*) (LOC714));
		{
			if (!(prev_365913 == NIM_NIL)) goto LA717;
			{
				NU8 LOC721;
				LOC721 = 0;
				LOC721 = typerel_362805(c, (*f).sons->data[((NI) 1)], a, NIM_TRUE);
				if (!!((LOC721 == ((NU8) 0)))) goto LA722;
				put_362264((&(*c).bindings), f, a);
				result = ((NU8) 8);
				goto BeforeRet;
			}
			goto LA719;
			LA722: ;
			{
				result = ((NU8) 0);
				goto BeforeRet;
			}
			LA719: ;
		}
		goto LA715;
		LA717: ;
		{
			result = typerel_362805(c, prev_365913, a, NIM_TRUE);
			goto BeforeRet;
		}
		LA715: ;
	}
	break;
	case ((NU8) 12):
	{
		Ttype214828* x;
		Tidobj189006* LOC727;
		TNimObject* LOC728;
		LOC727 = 0;
		LOC727 = &f->Sup;
		LOC728 = 0;
		LOC728 = idtableget_221107((*c).bindings, LOC727);
		x = ((Ttype214828*) (LOC728));
		{
			if (!(x == NIM_NIL)) goto LA731;
			{
				NIM_BOOL LOC735;
				NIM_BOOL LOC736;
				LOC735 = 0;
				LOC736 = 0;
				LOC736 = ((*(*c).callee).kind == ((NU8) 10));
				if (!(LOC736)) goto LA737;
				LOC736 = ((*f).kind == ((NU8) 12));
				LA737: ;
				LOC735 = LOC736;
				if (!(LOC735)) goto LA738;
				LOC735 = !((*c).typedescmatched);
				LA738: ;
				if (!LOC735) goto LA739;
				{
					if (!(((*a).flags &(1U<<((NU)(((NU8) 25))&31U)))!=0)) goto LA743;
					result = ((NU8) 8);
				}
				goto LA741;
				LA743: ;
				{
					if (!((*a).kind == ((NU8) 8))) goto LA746;
					{
						NI LOC750;
						LOC750 = 0;
						LOC750 = sonslen_217327(f);
						if (!(LOC750 == ((NI) 0))) goto LA751;
						result = ((NU8) 8);
					}
					goto LA748;
					LA751: ;
					{
						Ttype214828* aa;
						Ttype214828* LOC767;
						{
							NIM_BOOL LOC756;
							NIM_BOOL LOC757;
							NimStringDesc* LOC761;
							LOC756 = 0;
							LOC757 = 0;
							LOC757 = HEX3DHEX3D_248927((*a).sons, NIM_NIL);
							LOC756 = !(LOC757);
							if (!(LOC756)) goto LA758;
							LOC756 = (((NI) 0) < ((*a).sons ? (*a).sons->Sup.len : 0));
							LA758: ;
							if (!!(LOC756)) goto LA759;
							LOC761 = 0;
							LOC761 = HEX24_187183(TMP2807);
							internalerror_187113(LOC761);
						}
						LA759: ;
						(*c).typedescmatched = NIM_TRUE;
						aa = a;
						{
							while (1) {
								NIM_BOOL LOC764;
								NI LOC766;
								LOC764 = 0;
								LOC764 = ((4352 &((NU64)1<<((NU)((*aa).kind)&63U)))!=0);
								if (!(LOC764)) goto LA765;
								LOC766 = 0;
								LOC766 = len_217339(aa);
								LOC764 = (((NI) 0) < LOC766);
								LA765: ;
								if (!LOC764) goto LA763;
								aa = lastson_217377(aa);
							} LA763: ;
						}
						LOC767 = 0;
						LOC767 = base_240021(f);
						result = typerel_362805(c, LOC767, aa, NIM_TRUE);
						{
							if (!(((NU8) 8) < result)) goto LA770;
							result = ((NU8) 8);
						}
						LA770: ;
					}
					LA748: ;
				}
				goto LA741;
				LA746: ;
				{
					result = ((NU8) 0);
				}
				LA741: ;
			}
			goto LA733;
			LA739: ;
			{
				{
					NIM_BOOL LOC776;
					NI LOC777;
					Ttype214828* LOC781;
					LOC776 = 0;
					LOC777 = 0;
					LOC777 = sonslen_217327(f);
					LOC776 = (((NI) 0) < LOC777);
					if (!(LOC776)) goto LA778;
					LOC776 = !(((*(*f).sons->data[((NI) 0)]).kind == ((NU8) 0)));
					LA778: ;
					if (!LOC776) goto LA779;
					LOC781 = 0;
					LOC781 = lastson_217377(f);
					result = typerel_362805(c, LOC781, a, NIM_TRUE);
					{
						NIM_BOOL LOC784;
						Ttype214828* concrete;
						LOC784 = 0;
						LOC784 = dobind;
						if (!(LOC784)) goto LA785;
						LOC784 = !(((257 &(1U<<((NU)(result)&15U)))!=0));
						LA785: ;
						if (!LOC784) goto LA786;
						concrete = concretetype_362812((&(*c)), a);
						{
							if (!(concrete == NIM_NIL)) goto LA790;
							result = ((NU8) 0);
							goto BeforeRet;
						}
						LA790: ;
						put_362264((&(*c).bindings), f, concrete);
					}
					LA786: ;
				}
				goto LA774;
				LA779: ;
				{
					result = ((NU8) 8);
				}
				LA774: ;
			}
			LA733: ;
			{
				Ttype214828* concrete;
				if (!(result == ((NU8) 8))) goto LA795;
				concrete = a;
				{
					if (!(((*a).flags &(1U<<((NU)(((NU8) 25))&31U)))!=0)) goto LA799;
					(*(*a).sym).kind = ((NU8) 7);
					(*a).flags &= ~(((NU32)1) << ((((NU8) 25)) % (sizeof(NU32)*8)));
				}
				goto LA797;
				LA799: ;
				{
					concrete = concretetype_362812((&(*c)), a);
					{
						if (!(concrete == NIM_NIL)) goto LA804;
						result = ((NU8) 0);
						goto BeforeRet;
					}
					LA804: ;
				}
				LA797: ;
				{
					if (!dobind) goto LA808;
					put_362264((&(*c).bindings), f, concrete);
				}
				LA808: ;
			}
			goto LA793;
			LA795: ;
			{
				if (!(((NU8) 8) < result)) goto LA811;
				result = ((NU8) 8);
			}
			goto LA793;
			LA811: ;
			LA793: ;
		}
		goto LA729;
		LA731: ;
		{
			if (!((*a).kind == ((NU8) 3))) goto LA814;
			result = ((NU8) 8);
		}
		goto LA729;
		LA814: ;
		{
			if (!((*x).kind == ((NU8) 12))) goto LA817;
			result = ((NU8) 8);
		}
		goto LA729;
		LA817: ;
		{
			result = typerel_362805(c, x, a, NIM_TRUE);
			{
				if (!(((NU8) 8) < result)) goto LA822;
				result = ((NU8) 8);
			}
			LA822: ;
		}
		LA729: ;
	}
	break;
	case ((NU8) 59):
	{
		Ttype214828* prev;
		Tidobj189006* LOC825;
		TNimObject* LOC826;
		LOC825 = 0;
		LOC825 = &f->Sup;
		LOC826 = 0;
		LOC826 = idtableget_221107((*c).bindings, LOC825);
		prev = ((Ttype214828*) (LOC826));
		{
			if (!(prev == NIM_NIL)) goto LA829;
			{
				Ttype214828* LOC835;
				if (!((*aorig).kind == ((NU8) 59))) goto LA833;
				LOC835 = 0;
				LOC835 = lastson_217377(f);
				result = typerel_362805(c, LOC835, a, NIM_TRUE);
				{
					NIM_BOOL LOC838;
					LOC838 = 0;
					LOC838 = !((result == ((NU8) 0)));
					if (!(LOC838)) goto LA839;
					LOC838 = !(((*f).n == NIM_NIL));
					LA839: ;
					if (!LOC838) goto LA840;
					{
						NIM_BOOL LOC844;
						LOC844 = 0;
						LOC844 = exprstructuralequivalent_239099((*f).n, (*aorig).n, NIM_FALSE);
						if (!!(LOC844)) goto LA845;
						result = ((NU8) 0);
					}
					LA845: ;
				}
				LA840: ;
				{
					if (!!((result == ((NU8) 0)))) goto LA849;
					put_362264((&(*c).bindings), f, aorig);
				}
				LA849: ;
			}
			goto LA831;
			LA833: ;
			{
				result = ((NU8) 0);
			}
			LA831: ;
		}
		goto LA827;
		LA829: ;
		{
			if (!((*prev).kind == ((NU8) 59))) goto LA853;
			{
				Ttype214828* LOC859;
				if (!((*aorig).kind == ((NU8) 59))) goto LA857;
				LOC859 = 0;
				LOC859 = lastson_217377(prev);
				result = typerel_362805(c, LOC859, a, NIM_TRUE);
				{
					NIM_BOOL LOC862;
					LOC862 = 0;
					LOC862 = !((result == ((NU8) 0)));
					if (!(LOC862)) goto LA863;
					LOC862 = !(((*prev).n == NIM_NIL));
					LA863: ;
					if (!LOC862) goto LA864;
					{
						NIM_BOOL LOC868;
						LOC868 = 0;
						LOC868 = exprstructuralequivalent_239099((*prev).n, (*aorig).n, NIM_FALSE);
						if (!!(LOC868)) goto LA869;
						result = ((NU8) 0);
					}
					LA869: ;
				}
				LA864: ;
			}
			goto LA855;
			LA857: ;
			{
				result = ((NU8) 0);
			}
			LA855: ;
		}
		goto LA827;
		LA853: ;
		{
			result = ((NU8) 0);
		}
		LA827: ;
	}
	break;
	case ((NU8) 8):
	{
		Ttype214828* prev;
		Tidobj189006* LOC874;
		TNimObject* LOC875;
		LOC874 = 0;
		LOC874 = &f->Sup;
		LOC875 = 0;
		LOC875 = idtableget_221107((*c).bindings, LOC874);
		prev = ((Ttype214828*) (LOC875));
		{
			if (!(prev == NIM_NIL)) goto LA878;
			{
				if (!!(((*a).kind == ((NU8) 8)))) goto LA882;
				result = ((NU8) 0);
				goto BeforeRet;
			}
			LA882: ;
			{
				Ttype214828* LOC886;
				LOC886 = 0;
				LOC886 = base_240021(f);
				if (!((*LOC886).kind == ((NU8) 0))) goto LA887;
				result = ((NU8) 8);
			}
			goto LA884;
			LA887: ;
			{
				Ttype214828* LOC890;
				Ttype214828* LOC891;
				LOC890 = 0;
				LOC890 = base_240021(f);
				LOC891 = 0;
				LOC891 = base_240021(a);
				result = typerel_362805(c, LOC890, LOC891, NIM_TRUE);
			}
			LA884: ;
			{
				if (!!((result == ((NU8) 0)))) goto LA894;
				put_362264((&(*c).bindings), f, a);
			}
			LA894: ;
		}
		goto LA876;
		LA878: ;
		{
			{
				Ttype214828* LOC901;
				if (!(((*f).flags &(1U<<((NU)(((NU8) 9))&31U)))!=0)) goto LA899;
				LOC901 = 0;
				LOC901 = base_240021(prev);
				result = typerel_362805(c, LOC901, a, NIM_TRUE);
			}
			goto LA897;
			LA899: ;
			{
				Ttype214828* LOC905;
				Ttype214828* LOC906;
				if (!((*a).kind == ((NU8) 8))) goto LA903;
				LOC905 = 0;
				LOC905 = base_240021(prev);
				LOC906 = 0;
				LOC906 = base_240021(a);
				result = typerel_362805(c, LOC905, LOC906, NIM_TRUE);
			}
			goto LA897;
			LA903: ;
			{
				result = ((NU8) 0);
			}
			LA897: ;
		}
		LA876: ;
	}
	break;
	case ((NU8) 49):
	{
		{
			NIM_BOOL LOC911;
			NIM_BOOL LOC913;
			Ttype214828* LOC917;
			Ttype214828* LOC918;
			LOC911 = 0;
			LOC911 = ((*a).kind == ((NU8) 49));
			if (LOC911) goto LA912;
			LOC913 = 0;
			LOC913 = ((*a).kind == ((NU8) 25));
			if (!(LOC913)) goto LA914;
			LOC913 = (((*a).flags &(1U<<((NU)(((NU8) 14))&31U)))!=0);
			LA914: ;
			LOC911 = LOC913;
			LA912: ;
			if (!LOC911) goto LA915;
			LOC917 = 0;
			LOC917 = base_240021(f);
			LOC918 = 0;
			LOC918 = base_240021(a);
			result = typerel_362805(c, LOC917, LOC918, NIM_TRUE);
		}
		goto LA909;
		LA915: ;
		{
			result = ((NU8) 0);
		}
		LA909: ;
	}
	break;
	case ((NU8) 7):
	{
		{
			NIM_BOOL LOC923;
			LOC923 = 0;
			LOC923 = !((aorig == NIM_NIL));
			if (!(LOC923)) goto LA924;
			LOC923 = !((((*f).flags &(1U<<((NU)(((NU8) 0))&31U)))!=0));
			LA924: ;
			if (!LOC923) goto LA925;
			put_362264((&(*c).bindings), f, aorig);
		}
		LA925: ;
		result = ((NU8) 8);
	}
	break;
	case ((NU8) 50):
	{
		result = ((NU8) 10);
	}
	break;
	case ((NU8) 60):
	{
		Tnode214790* reevaluated;
		{
			NIM_BOOL LOC931;
			LOC931 = 0;
			LOC931 = ((*f).n == NIM_NIL);
			if (LOC931) goto LA932;
			LOC931 = ((*(*f).n).kind == ((NU8) 1));
			LA932: ;
			if (!LOC931) goto LA933;
			result = ((NU8) 8);
			goto BeforeRet;
		}
		LA933: ;
		reevaluated = tryresolvingstaticexpr_364277(c, (*f).n);
		switch ((*(*reevaluated).typ).kind) {
		case ((NU8) 8):
		{
			Ttype214828* LOC936;
			LOC936 = 0;
			LOC936 = base_240021((*reevaluated).typ);
			result = typerel_362805(c, a, LOC936, NIM_TRUE);
		}
		break;
		case ((NU8) 59):
		{
			Ttype214828* LOC938;
			LOC938 = 0;
			LOC938 = base_240021((*reevaluated).typ);
			result = typerel_362805(c, a, LOC938, NIM_TRUE);
			{
				NIM_BOOL LOC941;
				LOC941 = 0;
				LOC941 = !((result == ((NU8) 0)));
				if (!(LOC941)) goto LA942;
				LOC941 = !(((*(*reevaluated).typ).n == NIM_NIL));
				LA942: ;
				if (!LOC941) goto LA943;
				{
					NIM_BOOL LOC947;
					LOC947 = 0;
					LOC947 = exprstructuralequivalent_239099((*aorig).n, (*(*reevaluated).typ).n, NIM_FALSE);
					if (!!(LOC947)) goto LA948;
					result = ((NU8) 0);
				}
				LA948: ;
			}
			LA943: ;
		}
		break;
		default:
		{
			localerror_187080((*(*f).n).info, ((NU16) 67), ((NimStringDesc*) &TMP2241));
			result = ((NU8) 0);
		}
		break;
		}
	}
	break;
	case ((NU8) 0):
	{
		{
			if (!((*a).kind == ((NU8) 0))) goto LA954;
			result = ((NU8) 10);
		}
		LA954: ;
	}
	break;
	default:
	{
		NimStringDesc* LOC957;
		LOC957 = 0;
		LOC957 = rawNewString(reprEnum((*f).kind, (&NTI214241))->Sup.len + 19);
appendString(LOC957, ((NimStringDesc*) &TMP2808));
appendString(LOC957, reprEnum((*f).kind, (&NTI214241)));
		internalerror_187113(LOC957);
	}
	break;
	}
	}BeforeRet: ;
	return result;
}

N_NIMCALL(void, incmatches_366732)(Tcandidate362206* m, NU8 r, NI convmatch) {
	switch (r) {
	case ((NU8) 1):
	case ((NU8) 2):
	{
		(*m).convmatches += convmatch;
	}
	break;
	case ((NU8) 3):
	case ((NU8) 4):
	{
		(*m).subtypematches += ((NI) 1);
	}
	break;
	case ((NU8) 8):
	case ((NU8) 6):
	case ((NU8) 5):
	{
		(*m).genericmatches += ((NI) 1);
	}
	break;
	case ((NU8) 9):
	{
		(*m).intconvmatches += ((NI) 256);
	}
	break;
	case ((NU8) 7):
	{
		(*m).convmatches += ((NI) 1);
	}
	break;
	case ((NU8) 10):
	{
		(*m).exactmatches += ((NI) 1);
	}
	break;
	case ((NU8) 0):
	{
	}
	break;
	}
}

N_NIMCALL(Ttype214828*, getinstantiatedtype_366494)(Tcontext264020* c, Tnode214790* arg, Tcandidate362206* m, Ttype214828* f) {
	Ttype214828* result;
	Tidobj189006* LOC1;
	TNimObject* LOC2;
	result = 0;
	LOC1 = 0;
	LOC1 = &f->Sup;
	LOC2 = 0;
	LOC2 = idtableget_221107((*m).bindings, LOC1);
	result = ((Ttype214828*) (LOC2));
	{
		if (!(result == NIM_NIL)) goto LA5;
		result = generatetypeinstance_285450(c, (*m).bindings, (*arg).info, f);
	}
	LA5: ;
	{
		if (!(result == NIM_NIL)) goto LA9;
		internalerror_187100((*arg).info, ((NimStringDesc*) &TMP2811));
		result = errortype_264901(c);
	}
	LA9: ;
	return result;
}

N_NIMCALL(Tnode214790*, implicitconv_366525)(NU8 kind, Ttype214828* f, Tnode214790* arg, Tcandidate362206* m, Tcontext264020* c) {
	Tnode214790* result;
	result = 0;
	result = newnodei_216248(kind, (*arg).info);
	{
		NIM_BOOL LOC3;
		LOC3 = 0;
		LOC3 = containsgenerictype_248492(f);
		if (!LOC3) goto LA4;
		{
			if (!!(!(((*m).fauxmatch == ((NU8) 0))))) goto LA8;
			asgnRefNoCycle((void**) (&(*result).typ), getinstantiatedtype_366494(c, arg, m, f));
		}
		goto LA6;
		LA8: ;
		{
			asgnRefNoCycle((void**) (&(*result).typ), errortype_264901(c));
		}
		LA6: ;
	}
	goto LA1;
	LA4: ;
	{
		asgnRefNoCycle((void**) (&(*result).typ), f);
	}
	LA1: ;
	{
		if (!((*result).typ == NIM_NIL)) goto LA14;
		internalerror_187100((*arg).info, ((NimStringDesc*) &TMP2812));
	}
	LA14: ;
	addson_216807(result, emptynode_215801);
	addson_216807(result, arg);
	return result;
}

N_NIMCALL(void, markused_362244)(Tlineinfo182337 info, Tsym214822* s) {
	(*s).flags |= ((NU32)1)<<((((NU8) 0))%(sizeof(NU32)*8));
	{
		if (!!(((1572864 & (*s).flags) == 0))) goto LA3;
		{
			if (!(((*s).flags &(1U<<((NU)(((NU8) 19))&31U)))!=0)) goto LA7;
			message_187095(info, ((NU16) 241), (*(*s).name).s);
		}
		LA7: ;
		{
			if (!(((*s).flags &(1U<<((NU)(((NU8) 20))&31U)))!=0)) goto LA11;
			localerror_187080(info, ((NU16) 226), (*(*s).name).s);
		}
		LA11: ;
	}
	LA3: ;
}

N_NIMCALL(Tnode214790*, userconvmatch_366554)(Tcontext264020* c, Tcandidate362206* m, Ttype214828* f, Ttype214828* a, Tnode214790* arg) {
	Tnode214790* result;
{	result = 0;
	result = NIM_NIL;
	{
		NI i_366582;
		NI HEX3Atmp_366634;
		NI res_366637;
		i_366582 = 0;
		HEX3Atmp_366634 = 0;
		HEX3Atmp_366634 = (NI)(((*c).converters ? (*c).converters->Sup.len : 0) - ((NI) 1));
		res_366637 = ((NI) 0);
		{
			while (1) {
				if (!(res_366637 <= HEX3Atmp_366634)) goto LA3;
				i_366582 = res_366637;
				{
					Ttype214828* src;
					Ttype214828* dest;
					NU8 srca;
					NIM_BOOL destisgeneric;
					NU8 fdest;
					src = (*(*(*c).converters->data[i_366582]).typ).sons->data[((NI) 1)];
					dest = (*(*(*c).converters->data[i_366582]).typ).sons->data[((NI) 0)];
					srca = typerel_362805(m, src, a, NIM_TRUE);
					{
						if (!!(((1280 &(1U<<((NU)(srca)&15U)))!=0))) goto LA7;
						goto LA4;
					}
					LA7: ;
					destisgeneric = containsgenerictype_248492(dest);
					{
						if (!destisgeneric) goto LA11;
						dest = generatetypeinstance_285450(c, (*m).bindings, (*arg).info, dest);
					}
					LA11: ;
					fdest = typerel_362805(m, f, dest, NIM_TRUE);
					{
						Tnode214790* s;
						Tnode214790* LOC17;
						NIM_BOOL LOC18;
						if (!((1280 &(1U<<((NU)(fdest)&15U)))!=0)) goto LA15;
						markused_362244((*arg).info, (*c).converters->data[i_366582]);
						s = newsymnode_216234((*c).converters->data[i_366582]);
						asgnRefNoCycle((void**) (&(*s).typ), (*(*c).converters->data[i_366582]).typ);
						(*s).info = (*arg).info;
						result = newnodeit_216801(((NU8) 32), (*arg).info, dest);
						addson_216807(result, s);
						LOC17 = 0;
						LOC17 = copytree_218822(arg);
						addson_216807(result, LOC17);
						(*m).convmatches += ((NI) 1);
						LOC18 = 0;
						LOC18 = (srca == ((NU8) 8));
						if (LOC18) goto LA19;
						LOC18 = destisgeneric;
						LA19: ;
						(*m).genericconverter = LOC18;
						goto BeforeRet;
					}
					LA15: ;
				} LA4: ;
				res_366637 += ((NI) 1);
			} LA3: ;
		}
	}
	}BeforeRet: ;
	return result;
}

N_NIMCALL(Tnode214790*, localconvmatch_366641)(Tcontext264020* c, Tcandidate362206* m, Ttype214828* f, Ttype214828* a, Tnode214790* arg) {
	Tnode214790* result;
	Tnode214790* call;
	Tnode214790* LOC11;
	Tnode214790* LOC12;
{	result = 0;
	{
		if (!(*arg).typ == 0) goto LA3;
		result = NIM_NIL;
		goto BeforeRet;
	}
	LA3: ;
	{
		NIM_BOOL LOC7;
		LOC7 = 0;
		LOC7 = (f == (*arg).typ);
		if (!(LOC7)) goto LA8;
		LOC7 = ((*arg).kind == ((NU8) 58));
		LA8: ;
		if (!LOC7) goto LA9;
		result = arg;
		goto BeforeRet;
	}
	LA9: ;
	call = newnodei_216248(((NU8) 27), (*arg).info);
	LOC11 = 0;
	LOC11 = copytree_218822((*f).n);
	add_215114(call, LOC11);
	LOC12 = 0;
	LOC12 = copytree_218822(arg);
	add_215114(call, LOC12);
	result = (*c).semoverloadedcall(c, call, call, 258048);
	{
		NU8 r;
		if (!!((result == NIM_NIL))) goto LA15;
		r = typerel_362805(m, (*f).sons->data[((NI) 0)], (*result).typ, NIM_TRUE);
		{
			if (!(r < ((NU8) 8))) goto LA19;
			result = NIM_NIL;
			goto BeforeRet;
		}
		LA19: ;
		{
			if (!((*result).kind == ((NU8) 27))) goto LA23;
			(*result).kind = ((NU8) 32);
		}
		LA23: ;
		(*m).convmatches += ((NI) 1);
		{
			Ttype214828* LOC29;
			if (!(r == ((NU8) 8))) goto LA27;
			LOC29 = 0;
			LOC29 = base_240021(f);
			asgnRefNoCycle((void**) (&(*result).typ), getinstantiatedtype_366494(c, arg, (&(*m)), LOC29));
		}
		LA27: ;
		(*m).basetypematch = NIM_TRUE;
	}
	LA15: ;
	}BeforeRet: ;
	return result;
}

N_NIMCALL(Tnode214790*, paramtypesmatchaux_366793)(Tcandidate362206* m, Ttype214828* f, Ttype214828* argtype_366798, Tnode214790* argsemantized, Tnode214790* argorig) {
	Tnode214790* result;
	Ttype214828* fmaybestatic;
	Tnode214790* arg;
	Ttype214828* argtype;
	Tcontext264020* c;
	Ttype214828* a;
	NU8 r;
	NI bothmetacounter;
	NI lastbindingslength;
{	result = 0;
	fmaybestatic = skiptypes_218113(f, 8192);
	arg = argsemantized;
	argtype = argtype_366798;
	c = (*m).c;
	{
		if (!(((*fmaybestatic).flags &(1U<<((NU)(((NU8) 22))&31U)))!=0)) goto LA3;
		{
			NIM_BOOL LOC7;
			LOC7 = 0;
			LOC7 = ((*argtype).kind == ((NU8) 12));
			if (!(LOC7)) goto LA8;
			LOC7 = (((*argtype).flags &(1U<<((NU)(((NU8) 25))&31U)))!=0);
			LA8: ;
			if (!LOC7) goto LA9;
			assigntype_217389(argtype, f);
			result = argsemantized;
			goto BeforeRet;
		}
		LA9: ;
		{
			if (!((*argtype).kind == ((NU8) 59))) goto LA13;
			{
				NIM_BOOL LOC17;
				Ttype214828* LOC21;
				LOC17 = 0;
				LOC17 = ((*(*m).callee).kind == ((NU8) 10));
				if (!(LOC17)) goto LA18;
				LOC17 = !((((*argtype).flags &(1U<<((NU)(((NU8) 23))&31U)))!=0));
				LA18: ;
				if (!LOC17) goto LA19;
				LOC21 = 0;
				LOC21 = maketypefromexpr_264556(c, arg);
				result = newnodeit_216801(((NU8) 4), (*argorig).info, LOC21);
				goto BeforeRet;
			}
			LA19: ;
		}
		goto LA11;
		LA13: ;
		{
			Tnode214790* evaluated;
			evaluated = (*c).semtryconstexpr(c, arg);
			{
				TY366877 LOC27;
				if (!!((evaluated == NIM_NIL))) goto LA25;
				asgnRefNoCycle((void**) (&(*arg).typ), newtypes_264184(((NU8) 59), c));
				if ((*(*arg).typ).sons) nimGCunrefNoCycle((*(*arg).typ).sons);
				(*(*arg).typ).sons = (Ttypeseq214824*) newSeqRC1((&NTI214824), 1);
				memset((void*)LOC27, 0, sizeof(LOC27));
				LOC27[0] = (*evaluated).typ;
				asgnRefNoCycle((void**) (&(*(*arg).typ).sons->data[0]), LOC27[0]);
				asgnRefNoCycle((void**) (&(*(*arg).typ).n), evaluated);
				argtype = (*arg).typ;
			}
			LA25: ;
		}
		LA11: ;
	}
	LA3: ;
	{
		if (!(((NI) 0) < (*c).intypeclass)) goto LA30;
		a = skiptypes_218113(argtype, IL64(2305843009213694208));
	}
	goto LA28;
	LA30: ;
	{
		a = argtype;
	}
	LA28: ;
	r = typerel_362805(m, f, a, NIM_TRUE);
	{
		NIM_BOOL LOC35;
		NIM_BOOL LOC36;
		LOC35 = 0;
		LOC36 = 0;
		LOC36 = !((r == ((NU8) 0)));
		if (!(LOC36)) goto LA37;
		LOC36 = !(((*m).calleesym == NIM_NIL));
		LA37: ;
		LOC35 = LOC36;
		if (!(LOC35)) goto LA38;
		LOC35 = ((196608 &(1U<<((NU)((*(*m).calleesym).kind)&31U)))!=0);
		LA38: ;
		if (!LOC35) goto LA39;
		incmatches_366732(m, r, ((NI) 1));
		{
			if (!((*f).kind == ((NU8) 7))) goto LA43;
			result = arg;
			goto BeforeRet;
		}
		goto LA41;
		LA43: ;
		{
			if (!((*f).kind == ((NU8) 8))) goto LA46;
			result = arg;
			goto BeforeRet;
		}
		goto LA41;
		LA46: ;
		{
			if (!((*f).kind == ((NU8) 59))) goto LA49;
			result = (*(*arg).typ).n;
			goto BeforeRet;
		}
		goto LA41;
		LA49: ;
		{
			result = argsemantized;
			goto BeforeRet;
		}
		LA41: ;
	}
	LA39: ;
	bothmetacounter = ((NI) 0);
	lastbindingslength = ((NI) -1);
	{
		while (1) {
			NIM_BOOL LOC54;
			NIM_BOOL LOC55;
			LOC54 = 0;
			LOC55 = 0;
			LOC55 = (r == ((NU8) 5));
			if (!(LOC55)) goto LA56;
			LOC55 = !((lastbindingslength == (*m).bindings.counter));
			LA56: ;
			LOC54 = LOC55;
			if (!(LOC54)) goto LA57;
			LOC54 = (bothmetacounter < ((NI) 100));
			LA57: ;
			if (!LOC54) goto LA53;
			lastbindingslength = (*m).bindings.counter;
			bothmetacounter += ((NI) 1);
			{
				if (!((*arg).kind >= ((NU8) 51) && (*arg).kind <= ((NU8) 52) || (*arg).kind == ((NU8) 79) || (*arg).kind == ((NU8) 84))) goto LA60;
				result = (*c).seminferredlambda.ClEnv? (*c).seminferredlambda.ClPrc(c, (*m).bindings, arg, (*c).seminferredlambda.ClEnv):((TMP2809)((*c).seminferredlambda.ClPrc))(c, (*m).bindings, arg);
			}
			goto LA58;
			LA60: ;
			{
				if (!!(((*arg).kind == ((NU8) 3)))) goto LA63;
				result = NIM_NIL;
				goto BeforeRet;
			}
			goto LA58;
			LA63: ;
			{
				Tsym214822* inferred;
				inferred = (*c).semgenerateinstance.ClEnv? (*c).semgenerateinstance.ClPrc(c, (*arg).kindU.S4.sym, (*m).bindings, (*arg).info, (*c).semgenerateinstance.ClEnv):((TMP2810)((*c).semgenerateinstance.ClPrc))(c, (*arg).kindU.S4.sym, (*m).bindings, (*arg).info);
				result = newsymnode_216241(inferred, (*arg).info);
			}
			LA58: ;
			(*m).convmatches += ((NI) 1);
			arg = result;
			r = typerel_362805(m, f, (*arg).typ, NIM_TRUE);
		} LA53: ;
	}
	switch (r) {
	case ((NU8) 1):
	{
		(*m).convmatches += ((NI) 1);
		result = implicitconv_366525(((NU8) 58), f, arg, (&(*m)), c);
	}
	break;
	case ((NU8) 2):
	{
		(*m).intconvmatches += ((NI) 1);
		result = implicitconv_366525(((NU8) 58), f, arg, (&(*m)), c);
	}
	break;
	case ((NU8) 3):
	{
		(*m).subtypematches += ((NI) 1);
		{
			if (!((*f).kind == ((NU8) 8))) goto LA71;
			result = arg;
		}
		goto LA69;
		LA71: ;
		{
			result = implicitconv_366525(((NU8) 59), f, arg, (&(*m)), c);
		}
		LA69: ;
	}
	break;
	case ((NU8) 4):
	{
		(*m).subtypematches += ((NI) 1);
		{
			if (!((*f).kind == ((NU8) 23))) goto LA77;
			result = arg;
		}
		goto LA75;
		LA77: ;
		{
			result = implicitconv_366525(((NU8) 58), f, arg, (&(*m)), c);
		}
		LA75: ;
	}
	break;
	case ((NU8) 6):
	case ((NU8) 7):
	{
		{
			if (!((*arg).kind >= ((NU8) 51) && (*arg).kind <= ((NU8) 52) || (*arg).kind == ((NU8) 79) || (*arg).kind == ((NU8) 84))) goto LA83;
			result = (*c).seminferredlambda.ClEnv? (*c).seminferredlambda.ClPrc(c, (*m).bindings, arg, (*c).seminferredlambda.ClEnv):((TMP2813)((*c).seminferredlambda.ClPrc))(c, (*m).bindings, arg);
		}
		goto LA81;
		LA83: ;
		{
			if (!!(((*arg).kind == ((NU8) 3)))) goto LA86;
			result = NIM_NIL;
			goto BeforeRet;
		}
		goto LA81;
		LA86: ;
		{
			Tsym214822* inferred;
			inferred = (*c).semgenerateinstance.ClEnv? (*c).semgenerateinstance.ClPrc(c, (*arg).kindU.S4.sym, (*m).bindings, (*arg).info, (*c).semgenerateinstance.ClEnv):((TMP2814)((*c).semgenerateinstance.ClPrc))(c, (*arg).kindU.S4.sym, (*m).bindings, (*arg).info);
			result = newsymnode_216241(inferred, (*arg).info);
		}
		LA81: ;
		{
			if (!(r == ((NU8) 7))) goto LA91;
			(*m).convmatches += ((NI) 1);
			result = implicitconv_366525(((NU8) 58), f, result, (&(*m)), c);
		}
		goto LA89;
		LA91: ;
		{
			(*m).genericmatches += ((NI) 1);
		}
		LA89: ;
	}
	break;
	case ((NU8) 8):
	{
		(*m).genericmatches += ((NI) 1);
		{
			if (!((*arg).typ == NIM_NIL)) goto LA97;
			result = arg;
		}
		goto LA95;
		LA97: ;
		{
			Ttype214828* LOC100;
			LOC100 = 0;
			LOC100 = skiptypes_218113((*arg).typ, IL64(211106240964608));
			if (!((*LOC100).kind == ((NU8) 18))) goto LA101;
			result = implicitconv_366525(((NU8) 59), f, arg, (&(*m)), c);
		}
		goto LA95;
		LA101: ;
		{
			NIM_BOOL LOC104;
			LOC104 = 0;
			LOC104 = isemptycontainer_249113((*arg).typ);
			if (!LOC104) goto LA105;
			result = copytree_218822(arg);
			asgnRefNoCycle((void**) (&(*result).typ), getinstantiatedtype_366494(c, arg, (&(*m)), f));
		}
		goto LA95;
		LA105: ;
		{
			result = arg;
		}
		LA95: ;
	}
	break;
	case ((NU8) 5):
	{
		result = NIM_NIL;
	}
	break;
	case ((NU8) 9):
	{
		(*m).intconvmatches += ((NI) 256);
		result = implicitconv_366525(((NU8) 58), f, arg, (&(*m)), c);
	}
	break;
	case ((NU8) 10):
	{
		(*m).exactmatches += ((NI) 1);
		result = arg;
		{
			Ttype214828* LOC113;
			LOC113 = 0;
			LOC113 = skiptypes_218113(f, IL64(211106240964608));
			if (!((262144 &((NU64)1<<((NU)((*LOC113).kind)&63U)))!=0)) goto LA114;
			result = implicitconv_366525(((NU8) 59), f, arg, (&(*m)), c);
		}
		LA114: ;
	}
	break;
	case ((NU8) 0):
	{
		{
			if (!((IL64(1154047404513689600) &((NU64)1<<((NU)((*a).kind)&63U)))!=0)) goto LA119;
			(*m).genericmatches += ((NI) 1);
			(*m).fauxmatch = (*a).kind;
			result = arg;
			goto BeforeRet;
		}
		LA119: ;
		result = userconvmatch_366554(c, m, f, a, arg);
		{
			NIM_BOOL LOC123;
			LOC123 = 0;
			LOC123 = (result == NIM_NIL);
			if (!(LOC123)) goto LA124;
			LOC123 = ((*f).kind == ((NU8) 48));
			LA124: ;
			if (!LOC123) goto LA125;
			{
				if (!!(((*f).n == NIM_NIL))) goto LA129;
				result = localconvmatch_366641(c, m, f, a, arg);
			}
			goto LA127;
			LA129: ;
			{
				Ttype214828* LOC132;
				LOC132 = 0;
				LOC132 = base_240021(f);
				r = typerel_362805(m, LOC132, a, NIM_TRUE);
				{
					if (!(((NU8) 8) <= r)) goto LA135;
					(*m).convmatches += ((NI) 1);
					result = copytree_218822(arg);
					{
						Ttype214828* LOC141;
						if (!(r == ((NU8) 8))) goto LA139;
						LOC141 = 0;
						LOC141 = base_240021(f);
						asgnRefNoCycle((void**) (&(*result).typ), getinstantiatedtype_366494(c, arg, (&(*m)), LOC141));
					}
					LA139: ;
					(*m).basetypematch = NIM_TRUE;
				}
				goto LA133;
				LA135: ;
				{
					Ttype214828* LOC143;
					LOC143 = 0;
					LOC143 = base_240021(f);
					result = userconvmatch_366554(c, m, LOC143, a, arg);
				}
				LA133: ;
			}
			LA127: ;
		}
		LA125: ;
	}
	break;
	}
	}BeforeRet: ;
	return result;
}

N_NIMCALL(void, copycandidate_362425)(Tcandidate362206* a, Tcandidate362206* b) {
	unsureAsgnRef((void**) (&(*a).c), (*b).c);
	(*a).exactmatches = (*b).exactmatches;
	(*a).subtypematches = (*b).subtypematches;
	(*a).convmatches = (*b).convmatches;
	(*a).intconvmatches = (*b).intconvmatches;
	(*a).genericmatches = (*b).genericmatches;
	(*a).state = (*b).state;
	unsureAsgnRef((void**) (&(*a).callee), (*b).callee);
	unsureAsgnRef((void**) (&(*a).calleesym), (*b).calleesym);
	unsureAsgnRef((void**) (&(*a).call), copytree_218822((*b).call));
	(*a).basetypematch = (*b).basetypematch;
	copyidtable_216066((&(*a).bindings), (*b).bindings);
}

N_NIMCALL(NI, sumgeneric_362431)(Ttype214828* t_362433) {
	NI result;
	Ttype214828* t;
	NI isvar;
{	result = 0;
	t = t_362433;
	isvar = ((NI) 1);
	{
		while (1) {
			switch ((*t).kind) {
			case ((NU8) 11):
			case ((NU8) 16):
			case ((NU8) 22):
			case ((NU8) 21):
			case ((NU8) 13):
			case ((NU8) 4):
			case ((NU8) 27):
			case ((NU8) 48):
			case ((NU8) 19):
			case ((NU8) 20):
			case ((NU8) 24):
			case ((NU8) 10):
			{
				t = lastson_217377(t);
				result += ((NI) 1);
			}
			break;
			case ((NU8) 23):
			{
				t = (*t).sons->data[((NI) 0)];
				result += ((NI) 1);
				isvar += ((NI) 1);
			}
			break;
			case ((NU8) 8):
			{
				t = lastson_217377(t);
				{
					if (!((*t).kind == ((NU8) 3))) goto LA8;
					goto LA1;
				}
				LA8: ;
				result += ((NI) 1);
			}
			break;
			case ((NU8) 9):
			case ((NU8) 18):
			case ((NU8) 25):
			{
				result += ((NI) (((*t).kind == ((NU8) 9))));
				{
					NI i_362525;
					NI HEX3Atmp_362537;
					NI LOC12;
					NI res_362540;
					i_362525 = 0;
					HEX3Atmp_362537 = 0;
					LOC12 = 0;
					LOC12 = len_217339(t);
					HEX3Atmp_362537 = (LOC12 - 1);
					res_362540 = ((NI) 0);
					{
						while (1) {
							NI LOC15;
							if (!(res_362540 <= HEX3Atmp_362537)) goto LA14;
							i_362525 = res_362540;
							LOC15 = 0;
							LOC15 = sumgeneric_362431((*t).sons->data[i_362525]);
							result += LOC15;
							res_362540 += ((NI) 1);
						} LA14: ;
					}
				}
				goto LA1;
			}
			break;
			case ((NU8) 12):
			case ((NU8) 6):
			case ((NU8) 59):
			case ((NU8) 7):
			{
				goto LA1;
			}
			break;
			case ((NU8) 1):
			case ((NU8) 2):
			case ((NU8) 14):
			case ((NU8) 17):
			case ((NU8) 26):
			case ((NU8) 28):
			case ((NU8) 29):
			case ((NU8) 31) ... ((NU8) 35):
			case ((NU8) 36) ... ((NU8) 39):
			case ((NU8) 40) ... ((NU8) 44):
			{
				result = isvar;
				goto BeforeRet;
			}
			break;
			default:
			{
				result = ((NI) 0);
				goto BeforeRet;
			}
			break;
			}
		}
	} LA1: ;
	}BeforeRet: ;
	return result;
}

N_NIMCALL(NI, complexdisambiguation_362544)(Ttype214828* a, Ttype214828* b) {
	NI result;
	NI winner;
{	result = 0;
	winner = ((NI) 0);
	{
		NI i_362571;
		NI HEX3Atmp_362602;
		NI LOC2;
		NI LOC3;
		NI res_362605;
		i_362571 = 0;
		HEX3Atmp_362602 = 0;
		LOC2 = 0;
		LOC2 = len_217339(a);
		LOC3 = 0;
		LOC3 = len_217339(b);
		HEX3Atmp_362602 = (((LOC2 <= LOC3) ? LOC2 : LOC3) - 1);
		res_362605 = ((NI) 1);
		{
			while (1) {
				NI x;
				NI y;
				if (!(res_362605 <= HEX3Atmp_362602)) goto LA5;
				i_362571 = res_362605;
				x = sumgeneric_362431((*a).sons->data[i_362571]);
				y = sumgeneric_362431((*b).sons->data[i_362571]);
				{
					if (!!((x == y))) goto LA8;
					{
						if (!(winner == ((NI) 0))) goto LA12;
						{
							if (!(y < x)) goto LA16;
							winner = ((NI) 1);
						}
						goto LA14;
						LA16: ;
						{
							winner = ((NI) -1);
						}
						LA14: ;
					}
					goto LA10;
					LA12: ;
					{
						if (!(y < x)) goto LA20;
						{
							if (!!((winner == ((NI) 1)))) goto LA24;
							result = ((NI) 0);
							goto BeforeRet;
						}
						LA24: ;
					}
					goto LA10;
					LA20: ;
					{
						{
							if (!!((winner == ((NI) -1)))) goto LA29;
							result = ((NI) 0);
							goto BeforeRet;
						}
						LA29: ;
					}
					LA10: ;
				}
				LA8: ;
				res_362605 += ((NI) 1);
			} LA5: ;
		}
	}
	result = winner;
	}BeforeRet: ;
	return result;
}

N_NIMCALL(NI, cmpcandidates_362609)(Tcandidate362206* a, Tcandidate362206* b) {
	NI result;
{	result = 0;
	result = (NI)((*a).exactmatches - (*b).exactmatches);
	{
		if (!!((result == ((NI) 0)))) goto LA3;
		goto BeforeRet;
	}
	LA3: ;
	result = (NI)((*a).genericmatches - (*b).genericmatches);
	{
		if (!!((result == ((NI) 0)))) goto LA7;
		goto BeforeRet;
	}
	LA7: ;
	result = (NI)((*a).subtypematches - (*b).subtypematches);
	{
		if (!!((result == ((NI) 0)))) goto LA11;
		goto BeforeRet;
	}
	LA11: ;
	result = (NI)((*a).intconvmatches - (*b).intconvmatches);
	{
		if (!!((result == ((NI) 0)))) goto LA15;
		goto BeforeRet;
	}
	LA15: ;
	result = (NI)((*a).convmatches - (*b).convmatches);
	{
		if (!!((result == ((NI) 0)))) goto LA19;
		goto BeforeRet;
	}
	LA19: ;
	result = (NI)((*a).calleescope - (*b).calleescope);
	{
		if (!!((result == ((NI) 0)))) goto LA23;
		goto BeforeRet;
	}
	LA23: ;
	result = (NI)((*b).inheritancepenalty - (*a).inheritancepenalty);
	{
		if (!!((result == ((NI) 0)))) goto LA27;
		goto BeforeRet;
	}
	LA27: ;
	result = complexdisambiguation_362544((*a).callee, (*b).callee);
	}BeforeRet: ;
	return result;
}

N_NIMCALL(Tnode214790*, paramtypesmatch_367299)(Tcandidate362206* m, Ttype214828* f, Ttype214828* a, Tnode214790* arg, Tnode214790* argorig) {
	Tnode214790* result;
	result = 0;
	{
		NIM_BOOL LOC3;
		LOC3 = 0;
		LOC3 = (arg == NIM_NIL);
		if (LOC3) goto LA4;
		LOC3 = !(((*arg).kind == ((NU8) 56) || (*arg).kind == ((NU8) 57)));
		LA4: ;
		if (!LOC3) goto LA5;
		result = paramtypesmatchaux_366793(m, f, a, arg, argorig);
	}
	goto LA1;
	LA5: ;
	{
		Tcontext264020* c;
		Tcandidate362206 x;
		Tcandidate362206 y;
		Tcandidate362206 z;
		NI best;
		c = (*m).c;
		memset((void*)(&x), 0, sizeof(x));
		memset((void*)(&y), 0, sizeof(y));
		memset((void*)(&z), 0, sizeof(z));
		initcandidate_362257(c, (&x), (*m).callee);
		initcandidate_362257(c, (&y), (*m).callee);
		initcandidate_362257(c, (&z), (*m).callee);
		x.calleesym = (*m).calleesym;
		y.calleesym = (*m).calleesym;
		z.calleesym = (*m).calleesym;
		best = ((NI) -1);
		{
			NI i_367349;
			NI HEX3Atmp_367607;
			NI LOC9;
			NI res_367610;
			i_367349 = 0;
			HEX3Atmp_367607 = 0;
			LOC9 = 0;
			LOC9 = sonslen_217351(arg);
			HEX3Atmp_367607 = (NI)(LOC9 - ((NI) 1));
			res_367610 = ((NI) 0);
			{
				while (1) {
					if (!(res_367610 <= HEX3Atmp_367607)) goto LA11;
					i_367349 = res_367610;
					{
						NU8 r;
						if (!((61440 &(1U<<((NU)((*(*(*arg).kindU.S6.sons->data[i_367349]).kindU.S4.sym).kind)&31U)))!=0)) goto LA14;
						copycandidate_362425((&z), (&(*m)));
						z.callee = (*(*arg).kindU.S6.sons->data[i_367349]).typ;
						z.calleesym = (*(*arg).kindU.S6.sons->data[i_367349]).kindU.S4.sym;
						r = typerel_362805((&z), f, (*(*arg).kindU.S6.sons->data[i_367349]).typ, NIM_TRUE);
						incmatches_366732((&z), r, ((NI) 2));
						{
							if (!!((r == ((NU8) 0)))) goto LA18;
							z.state = ((NU8) 1);
							switch (x.state) {
							case ((NU8) 0):
							case ((NU8) 2):
							{
								genericAssign((void*)(&x), (void*)(&z), (&NTI362206));
								best = i_367349;
							}
							break;
							case ((NU8) 1):
							{
								NI cmp;
								cmp = cmpcandidates_362609((&x), (&z));
								{
									if (!(cmp < ((NI) 0))) goto LA24;
									best = i_367349;
									genericAssign((void*)(&x), (void*)(&z), (&NTI362206));
								}
								goto LA22;
								LA24: ;
								{
									if (!(cmp == ((NI) 0))) goto LA27;
									genericAssign((void*)(&y), (void*)(&z), (&NTI362206));
								}
								goto LA22;
								LA27: ;
								LA22: ;
							}
							break;
							}
						}
						LA18: ;
					}
					LA14: ;
					res_367610 += ((NI) 1);
				} LA11: ;
			}
		}
		{
			if (!(x.state == ((NU8) 0))) goto LA31;
			result = NIM_NIL;
		}
		goto LA29;
		LA31: ;
		{
			NIM_BOOL LOC34;
			NI LOC36;
			LOC34 = 0;
			LOC34 = (y.state == ((NU8) 1));
			if (!(LOC34)) goto LA35;
			LOC36 = 0;
			LOC36 = cmpcandidates_362609((&x), (&y));
			LOC34 = (LOC36 == ((NI) 0));
			LA35: ;
			if (!LOC34) goto LA37;
			{
				if (!!((x.state == ((NU8) 1)))) goto LA41;
				internalerror_187100((*arg).info, ((NimStringDesc*) &TMP2819));
			}
			LA41: ;
			{
				if (!((*f).kind == ((NU8) 6))) goto LA45;
				result = arg;
			}
			goto LA43;
			LA45: ;
			{
				result = NIM_NIL;
			}
			LA43: ;
		}
		goto LA29;
		LA37: ;
		{
			markused_362244((*arg).info, (*(*arg).kindU.S6.sons->data[best]).kindU.S4.sym);
			result = paramtypesmatchaux_366793(m, f, (*(*arg).kindU.S6.sons->data[best]).typ, (*arg).kindU.S6.sons->data[best], argorig);
		}
		LA29: ;
	}
	LA1: ;
	return result;
}

N_NIMCALL(NIM_BOOL, argtypematches_368396)(Tcontext264020* c, Ttype214828* f, Ttype214828* a) {
	NIM_BOOL result;
	Tcandidate362206 m;
	Tnode214790* res;
	result = 0;
	memset((void*)(&m), 0, sizeof(m));
	initcandidate_362257(c, (&m), f);
	res = paramtypesmatch_367299((&m), f, a, emptynode_215801, NIM_NIL);
	result = !((res == NIM_NIL));
	return result;
}

static N_INLINE(NIM_BOOL, typefits_371273)(Tcontext264020* c, Tsym214822* s, Ttype214828* firstarg) {
	NIM_BOOL result;
{	result = 0;
	{
		NIM_BOOL LOC3;
		NIM_BOOL LOC4;
		NI LOC6;
		Tsym214822* m;
		LOC3 = 0;
		LOC4 = 0;
		LOC4 = !(((*s).typ == NIM_NIL));
		if (!(LOC4)) goto LA5;
		LOC6 = 0;
		LOC6 = sonslen_217327((*s).typ);
		LOC4 = (((NI) 1) < LOC6);
		LA5: ;
		LOC3 = LOC4;
		if (!(LOC3)) goto LA7;
		LOC3 = !(((*(*s).typ).sons->data[((NI) 1)] == NIM_NIL));
		LA7: ;
		if (!LOC3) goto LA8;
		m = getmodule_221144(s);
		{
			NIM_BOOL LOC12;
			Ttype214828* exp;
			LOC12 = 0;
			LOC12 = !((m == NIM_NIL));
			if (!(LOC12)) goto LA13;
			LOC12 = (((*m).flags &(1U<<((NU)(((NU8) 13))&31U)))!=0);
			LA13: ;
			if (!LOC12) goto LA14;
			{
				if (!((*s).kind == ((NU8) 7))) goto LA18;
				goto BeforeRet;
			}
			LA18: ;
			exp = skiptypes_218113((*(*s).typ).sons->data[((NI) 1)], 8390656);
			{
				if (!((*exp).kind == ((NU8) 48))) goto LA22;
				exp = elemtype_240383(exp);
			}
			LA22: ;
			{
				if (!((IL64(288230376151716032) &((NU64)1<<((NU)((*exp).kind)&63U)))!=0)) goto LA26;
				goto BeforeRet;
			}
			LA26: ;
		}
		LA14: ;
		result = argtypematches_368396(c, (*(*s).typ).sons->data[((NI) 1)], firstarg);
	}
	LA8: ;
	}BeforeRet: ;
	return result;
}

N_NIMCALL(void, suggestoperations_371364)(Tcontext264020* c, Tnode214790* n, Ttype214828* typ, NI* outputs) {
	NIM_BOOL islocal_371402;
	islocal_371402 = NIM_TRUE;
	{
		Tscope214816* scope_371404;
		Tscope214816* HEX3Atmp_371691;
		Tscope214816* current_371694;
		scope_371404 = 0;
		HEX3Atmp_371691 = 0;
		HEX3Atmp_371691 = (*c).currentscope;
		current_371694 = HEX3Atmp_371691;
		{
			while (1) {
				Tsymseq214792* entries_371406;
				Tsymseq214792* result_371427;
				TY369848 LOC11;
				if (!!((current_371694 == NIM_NIL))) goto LA3;
				scope_371404 = current_371694;
				{
					if (!(scope_371404 == (*c).toplevelscope)) goto LA6;
					islocal_371402 = NIM_FALSE;
				}
				LA6: ;
				result_371427 = (Tsymseq214792*) newSeq((&NTI214792), 0);
				{
					Tsym214822* x_371431;
					Tstrtable214794 HEX3Atmp_371679;
					Ttabiter221071 it_371682;
					Tsym214822* s_371684;
					x_371431 = 0;
					memset((void*)(&HEX3Atmp_371679), 0, sizeof(HEX3Atmp_371679));
					HEX3Atmp_371679.counter = (*scope_371404).symbols.counter;
					HEX3Atmp_371679.data = (*scope_371404).symbols.data;
					memset((void*)(&it_371682), 0, sizeof(it_371682));
					s_371684 = inittabiter_221073((&it_371682), HEX3Atmp_371679);
					{
						while (1) {
							if (!!((s_371684 == NIM_NIL))) goto LA10;
							x_371431 = s_371684;
							result_371427 = (Tsymseq214792*) incrSeqV2(&(result_371427)->Sup, sizeof(Tsym214822*));
							asgnRefNoCycle((void**) (&result_371427->data[result_371427->Sup.len]), x_371431);
							++result_371427->Sup.len;
							s_371684 = nextiter_221078((&it_371682), HEX3Atmp_371679);
						} LA10: ;
					}
				}
				genericSeqAssign((&entries_371406), result_371427, (&NTI214792));
				memset((void*)(&LOC11), 0, sizeof(LOC11));
				LOC11.ClPrc = ((TMP2774) (HEX3Aanonymous_371630)); LOC11.ClEnv = NIM_NIL;
				sort_369841(entries_371406->data, entries_371406->Sup.len, LOC11, ((NU8) 1));
				{
					Tsym214822* item_371412;
					NI i_371688;
					NI L_371690;
					item_371412 = 0;
					i_371688 = ((NI) 0);
					L_371690 = (entries_371406 ? entries_371406->Sup.len : 0);
					{
						while (1) {
							Tsym214822* it;
							if (!(i_371688 < L_371690)) goto LA14;
							item_371412 = entries_371406->data[i_371688];
							it = item_371412;
							{
								NIM_BOOL LOC17;
								NimStringDesc* LOC21;
								Suggest368803 LOC22;
								LOC17 = 0;
								LOC17 = filtersymnoopr_369234(it);
								if (!(LOC17)) goto LA18;
								LOC17 = typefits_371273(c, it, typ);
								LA18: ;
								if (!LOC17) goto LA19;
								LOC21 = 0;
								LOC21 = HEX24_161680(((NU8) 1));
								memset((void*)(&LOC22), 0, sizeof(LOC22));
								symtosuggest_369201(it, islocal_371402, LOC21, ((NI) 100), (&LOC22));
								suggestresult_369211((&LOC22));
								(*outputs) += ((NI) 1);
							}
							LA19: ;
							i_371688 += ((NI) 1);
						} LA14: ;
					}
				}
				current_371694 = (*current_371694).parent;
			} LA3: ;
		}
	}
}

N_NIMCALL(void, suggestobject_369482)(Tcontext264020* c, Tnode214790* n, NI* outputs) {
	switch ((*n).kind) {
	case ((NU8) 138):
	{
		{
			NI i_369499;
			NI HEX3Atmp_369518;
			NI LOC3;
			NI res_369521;
			i_369499 = 0;
			HEX3Atmp_369518 = 0;
			LOC3 = 0;
			LOC3 = sonslen_217351(n);
			HEX3Atmp_369518 = (NI)(LOC3 - ((NI) 1));
			res_369521 = ((NI) 0);
			{
				while (1) {
					if (!(res_369521 <= HEX3Atmp_369518)) goto LA5;
					i_369499 = res_369521;
					suggestobject_369482(c, (*n).kindU.S6.sons->data[i_369499], outputs);
					res_369521 += ((NI) 1);
				} LA5: ;
			}
		}
	}
	break;
	case ((NU8) 139):
	{
		NI L;
		L = sonslen_217351(n);
		{
			if (!(((NI) 0) < L)) goto LA9;
			suggestobject_369482(c, (*n).kindU.S6.sons->data[((NI) 0)], outputs);
			{
				NI i_369514;
				NI HEX3Atmp_369526;
				NI res_369529;
				i_369514 = 0;
				HEX3Atmp_369526 = 0;
				HEX3Atmp_369526 = (NI)(L - ((NI) 1));
				res_369529 = ((NI) 1);
				{
					while (1) {
						Tnode214790* LOC14;
						if (!(res_369529 <= HEX3Atmp_369526)) goto LA13;
						i_369514 = res_369529;
						LOC14 = 0;
						LOC14 = lastson_217364((*n).kindU.S6.sons->data[i_369514]);
						suggestobject_369482(c, LOC14, outputs);
						res_369529 += ((NI) 1);
					} LA13: ;
				}
			}
		}
		LA9: ;
	}
	break;
	case ((NU8) 3):
	{
		suggestfield_369411(c, (*n).kindU.S4.sym, outputs);
	}
	break;
	default:
	{
	}
	break;
	}
}

N_NIMCALL(void, suggestfieldaccess_371747)(Tcontext264020* c, Tnode214790* n, NI* outputs) {
	Ttype214828* typ;
	typ = (*n).typ;
	{
		if (!(typ == NIM_NIL)) goto LA3;
		{
			NIM_BOOL LOC7;
			LOC7 = 0;
			LOC7 = ((*n).kind == ((NU8) 3));
			if (!(LOC7)) goto LA8;
			LOC7 = ((*(*n).kindU.S4.sym).kind == ((NU8) 6));
			LA8: ;
			if (!LOC7) goto LA9;
			{
				if (!((*n).kindU.S4.sym == (*c).module)) goto LA13;
				{
					Tsym214822* it_371844;
					Tstrtable214794 HEX3Atmp_371955;
					Ttabiter221071 it_371958;
					Tsym214822* s_371960;
					it_371844 = 0;
					memset((void*)(&HEX3Atmp_371955), 0, sizeof(HEX3Atmp_371955));
					HEX3Atmp_371955.counter = (*(*c).toplevelscope).symbols.counter;
					HEX3Atmp_371955.data = (*(*c).toplevelscope).symbols.data;
					memset((void*)(&it_371958), 0, sizeof(it_371958));
					s_371960 = inittabiter_221073((&it_371958), HEX3Atmp_371955);
					{
						while (1) {
							if (!!((s_371960 == NIM_NIL))) goto LA17;
							it_371844 = s_371960;
							{
								NIM_BOOL LOC20;
								NimStringDesc* LOC23;
								Suggest368803 LOC24;
								LOC20 = 0;
								LOC20 = filtersym_369221(it_371844);
								if (!LOC20) goto LA21;
								LOC23 = 0;
								LOC23 = HEX24_161680(((NU8) 1));
								memset((void*)(&LOC24), 0, sizeof(LOC24));
								symtosuggest_369201(it_371844, NIM_FALSE, LOC23, ((NI) 100), (&LOC24));
								suggestresult_369211((&LOC24));
								(*outputs) += ((NI) 1);
							}
							LA21: ;
							s_371960 = nextiter_221078((&it_371958), HEX3Atmp_371955);
						} LA17: ;
					}
				}
			}
			goto LA11;
			LA13: ;
			{
				{
					Tsym214822* it_371857;
					Tstrtable214794 HEX3Atmp_371962;
					Ttabiter221071 it_371965;
					Tsym214822* s_371967;
					it_371857 = 0;
					memset((void*)(&HEX3Atmp_371962), 0, sizeof(HEX3Atmp_371962));
					HEX3Atmp_371962.counter = (*(*n).kindU.S4.sym).kindU.S3.tab.counter;
					HEX3Atmp_371962.data = (*(*n).kindU.S4.sym).kindU.S3.tab.data;
					memset((void*)(&it_371965), 0, sizeof(it_371965));
					s_371967 = inittabiter_221073((&it_371965), HEX3Atmp_371962);
					{
						while (1) {
							if (!!((s_371967 == NIM_NIL))) goto LA28;
							it_371857 = s_371967;
							{
								NIM_BOOL LOC31;
								NimStringDesc* LOC34;
								Suggest368803 LOC35;
								LOC31 = 0;
								LOC31 = filtersym_369221(it_371857);
								if (!LOC31) goto LA32;
								LOC34 = 0;
								LOC34 = HEX24_161680(((NU8) 1));
								memset((void*)(&LOC35), 0, sizeof(LOC35));
								symtosuggest_369201(it_371857, NIM_FALSE, LOC34, ((NI) 100), (&LOC35));
								suggestresult_369211((&LOC35));
								(*outputs) += ((NI) 1);
							}
							LA32: ;
							s_371967 = nextiter_221078((&it_371965), HEX3Atmp_371962);
						} LA28: ;
					}
				}
			}
			LA11: ;
		}
		goto LA5;
		LA9: ;
		{
			suggesteverything_371695(c, n, outputs);
		}
		LA5: ;
	}
	goto LA1;
	LA3: ;
	{
		NIM_BOOL LOC38;
		NIM_BOOL LOC39;
		Ttype214828* t;
		LOC38 = 0;
		LOC39 = 0;
		LOC39 = ((*typ).kind == ((NU8) 14));
		if (!(LOC39)) goto LA40;
		LOC39 = ((*n).kind == ((NU8) 3));
		LA40: ;
		LOC38 = LOC39;
		if (!(LOC38)) goto LA41;
		LOC38 = ((*(*n).kindU.S4.sym).kind == ((NU8) 7));
		LA41: ;
		if (!LOC38) goto LA42;
		t = typ;
		{
			while (1) {
				if (!!((t == NIM_NIL))) goto LA45;
				suggestsymlist_369444(c, (*t).n, outputs);
				t = (*t).sons->data[((NI) 0)];
			} LA45: ;
		}
		suggestoperations_371364(c, n, typ, outputs);
	}
	goto LA1;
	LA42: ;
	{
		typ = skiptypes_218113(typ, 14682112);
		{
			Ttype214828* t;
			if (!((*typ).kind == ((NU8) 17))) goto LA49;
			t = typ;
			{
				while (1) {
					suggestobject_369482(c, (*t).n, outputs);
					{
						if (!((*t).sons->data[((NI) 0)] == NIM_NIL)) goto LA55;
						goto LA51;
					}
					LA55: ;
					t = skiptypes_218113((*t).sons->data[((NI) 0)], 2048);
				}
			} LA51: ;
			suggestoperations_371364(c, n, typ, outputs);
		}
		goto LA47;
		LA49: ;
		{
			NIM_BOOL LOC58;
			LOC58 = 0;
			LOC58 = ((*typ).kind == ((NU8) 18));
			if (!(LOC58)) goto LA59;
			LOC58 = !(((*typ).n == NIM_NIL));
			LA59: ;
			if (!LOC58) goto LA60;
			suggestsymlist_369444(c, (*typ).n, outputs);
			suggestoperations_371364(c, n, typ, outputs);
		}
		goto LA47;
		LA60: ;
		{
			suggestoperations_371364(c, n, typ, outputs);
		}
		LA47: ;
	}
	LA1: ;
}

N_NIMCALL(Tnode214790*, findclosestcall_372040)(Tnode214790* n) {
	Tnode214790* result;
{	result = 0;
	{
		NIM_BOOL LOC3;
		NU8 LOC5;
		LOC3 = 0;
		LOC3 = ((*n).kind == ((NU8) 27) || (*n).kind == ((NU8) 29) || (*n).kind == ((NU8) 30) || (*n).kind == ((NU8) 31) || (*n).kind == ((NU8) 26) || (*n).kind == ((NU8) 28) || (*n).kind == ((NU8) 32));
		if (!(LOC3)) goto LA4;
		LOC5 = 0;
		LOC5 = incheckpoint_371975((*n).info);
		LOC3 = (LOC5 == ((NU8) 2));
		LA4: ;
		if (!LOC3) goto LA6;
		result = n;
	}
	goto LA1;
	LA6: ;
	{
		{
			NI i_372080;
			NI HEX3Atmp_372095;
			NI LOC10;
			NI res_372098;
			i_372080 = 0;
			HEX3Atmp_372095 = 0;
			LOC10 = 0;
			LOC10 = safelen_215081(n);
			HEX3Atmp_372095 = (LOC10 - 1);
			res_372098 = ((NI) 0);
			{
				while (1) {
					if (!(res_372098 <= HEX3Atmp_372095)) goto LA12;
					i_372080 = res_372098;
					result = findclosestcall_372040((*n).kindU.S6.sons->data[i_372080]);
					{
						if (!!((result == NIM_NIL))) goto LA15;
						goto BeforeRet;
					}
					LA15: ;
					res_372098 += ((NI) 1);
				} LA12: ;
			}
		}
	}
	LA1: ;
	}BeforeRet: ;
	return result;
}

N_NIMCALL(NI, HEX3Aanonymous_369830)(Tsym214822* a_369593, Tsym214822* b_369595) {
	NI result;
{	result = 0;
	result = cmp_5680((*(*a_369593).name).s, (*(*b_369595).name).s);
	goto BeforeRet;
	}BeforeRet: ;
	return result;
}

N_NIMCALL(NIM_BOOL, namefits_369533)(Tcontext264020* c, Tsym214822* s, Tnode214790* n) {
	NIM_BOOL result;
	Tnode214790* op;
	Tident189012* opr;
{	result = 0;
	op = (*n).kindU.S6.sons->data[((NI) 0)];
	{
		if (!((*op).kind == ((NU8) 57) || (*op).kind == ((NU8) 56))) goto LA3;
		op = (*op).kindU.S6.sons->data[((NI) 0)];
	}
	LA3: ;
	opr = 0;
	switch ((*op).kind) {
	case ((NU8) 3):
	{
		opr = (*(*op).kindU.S4.sym).name;
	}
	break;
	case ((NU8) 2):
	{
		opr = (*op).kindU.S5.ident;
	}
	break;
	default:
	{
		result = NIM_FALSE;
		goto BeforeRet;
	}
	break;
	}
	result = ((*opr).Sup.id == (*(*s).name).Sup.id);
	}BeforeRet: ;
	return result;
}

N_NIMCALL(void, initcandidate_362270)(Tcontext264020* ctx, Tcandidate362206* c, Tsym214822* callee, Tnode214790* binding, NI calleescope) {
	initcandidateaux_362251(ctx, c, (*callee).typ);
	unsureAsgnRef((void**) (&(*c).calleesym), callee);
	{
		NIM_BOOL LOC3;
		LOC3 = 0;
		LOC3 = ((258048 &(1U<<((NU)((*callee).kind)&31U)))!=0);
		if (!(LOC3)) goto LA4;
		LOC3 = (calleescope == ((NI) -1));
		LA4: ;
		if (!LOC3) goto LA5;
		{
			Tsym214822* LOC9;
			Tsym214822* owner;
			LOC9 = 0;
			LOC9 = originatingmodule_219381(callee);
			if (!(LOC9 == (*ctx).module)) goto LA10;
			(*c).calleescope = ((NI) 2);
			owner = callee;
			{
				while (1) {
					owner = skipgenericowner_219353(owner);
					{
						if (!((*owner).kind == ((NU8) 6))) goto LA16;
						goto LA12;
					}
					LA16: ;
					(*c).calleescope += ((NI) 1);
				}
			} LA12: ;
		}
		goto LA7;
		LA10: ;
		{
			(*c).calleescope = ((NI) 1);
		}
		LA7: ;
	}
	goto LA1;
	LA5: ;
	{
		(*c).calleescope = calleescope;
	}
	LA1: ;
	initidtable_218033((&(*c).bindings));
	genericSeqAssign((&(*c).errors), NIM_NIL, (&NTI214792));
	{
		NIM_BOOL LOC22;
		Tnode214790* typeparams;
		LOC22 = 0;
		LOC22 = !((binding == NIM_NIL));
		if (!(LOC22)) goto LA23;
		LOC22 = ((258048 &(1U<<((NU)((*callee).kind)&31U)))!=0);
		LA23: ;
		if (!LOC22) goto LA24;
		typeparams = HEX5BHEX5D_215238((*callee).ast, ((NI) 2));
		{
			NI i_362359;
			NI HEX3Atmp_362404;
			NI LOC27;
			NI LOC28;
			NI res_362407;
			i_362359 = 0;
			HEX3Atmp_362404 = 0;
			LOC27 = 0;
			LOC27 = sonslen_217351(typeparams);
			LOC28 = 0;
			LOC28 = sonslen_217351(binding);
			HEX3Atmp_362404 = ((LOC27 <= (NI)(LOC28 - ((NI) 1))) ? LOC27 : (NI)(LOC28 - ((NI) 1)));
			res_362407 = ((NI) 1);
			{
				while (1) {
					Ttype214828* formaltypeparam;
					Ttype214828* bound;
					Tnode214790* LOC31;
					if (!(res_362407 <= HEX3Atmp_362404)) goto LA30;
					i_362359 = res_362407;
					formaltypeparam = (*(*typeparams).kindU.S6.sons->data[(NI)(i_362359 - ((NI) 1))]).typ;
					LOC31 = 0;
					LOC31 = HEX5BHEX5D_215238(binding, i_362359);
					bound = (*LOC31).typ;
					{
						NimStringDesc* LOC36;
						if (!!(!((bound == NIM_NIL)))) goto LA34;
						LOC36 = 0;
						LOC36 = HEX24_187183(TMP2821);
						internalerror_187113(LOC36);
					}
					LA34: ;
					{
						if (!((*formaltypeparam).kind == ((NU8) 8))) goto LA39;
						{
							if (!!(((*bound).kind == ((NU8) 8)))) goto LA43;
							bound = maketypedesc_264523(ctx, bound);
						}
						LA43: ;
					}
					goto LA37;
					LA39: ;
					{
						bound = skiptypes_218113(bound, 256);
					}
					LA37: ;
					put_362264((&(*c).bindings), formaltypeparam, bound);
					res_362407 += ((NI) 1);
				} LA30: ;
			}
		}
	}
	LA24: ;
}

N_NIMCALL(Ttype214828*, arrayconstr_367703)(Tcontext264020* c, Tlineinfo182337 info) {
	Ttype214828* result;
	Ttype214828* LOC1;
	Ttype214828* LOC2;
	Ttype214828* LOC3;
	result = 0;
	result = newtypes_264184(((NU8) 4), c);
	LOC1 = 0;
	LOC1 = getsystype_258130(((NU8) 31));
	LOC2 = 0;
	LOC2 = makerangetype_264915(c, IL64(0), IL64(-1), info, LOC1);
	rawaddson_218408(result, LOC2);
	LOC3 = 0;
	LOC3 = newtypes_264184(((NU8) 3), c);
	rawaddson_218408(result, LOC3);
	return result;
}

N_NIMCALL(void, setson_367614)(Tnode214790* father, NI at, Tnode214790* son) {
	{
		NI LOC3;
		LOC3 = 0;
		LOC3 = sonslen_217351(father);
		if (!(LOC3 <= at)) goto LA4;
		(*father).kindU.S6.sons = (Tnodeseq214784*) setLengthSeq(&((*father).kindU.S6.sons)->Sup, sizeof(Tnode214790*), ((NI) ((NI)(at + ((NI) 1)))));
	}
	LA4: ;
	asgnRefNoCycle((void**) (&(*father).kindU.S6.sons->data[at]), son);
}

N_NIMCALL(void, incrindextype_367708)(Ttype214828* t) {
	(*(*(*(*t).sons->data[((NI) 0)]).n).kindU.S6.sons->data[((NI) 1)]).kindU.S1.intval += ((NI) 1);
}

N_NIMCALL(void, preparenamedparam_367680)(Tnode214790* a) {
	{
		Tlineinfo182337 info;
		Tident189012* LOC5;
		if (!!(((*(*a).kindU.S6.sons->data[((NI) 0)]).kind == ((NU8) 2)))) goto LA3;
		info = (*(*a).kindU.S6.sons->data[((NI) 0)]).info;
		LOC5 = 0;
		LOC5 = considerquotedident_269004((*a).kindU.S6.sons->data[((NI) 0)]);
		asgnRefNoCycle((void**) (&(*a).kindU.S6.sons->data[((NI) 0)]), newidentnode_216228(LOC5, info));
	}
	LA3: ;
}

N_NIMCALL(Tnode214790*, prepareoperand_367631)(Tcontext264020* c, Ttype214828* formal, Tnode214790* a) {
	Tnode214790* result;
	result = 0;
	{
		NIM_BOOL LOC3;
		NI LOC5;
		LOC3 = 0;
		LOC3 = ((*formal).kind == ((NU8) 6));
		if (!(LOC3)) goto LA4;
		LOC5 = 0;
		LOC5 = len_217339(formal);
		LOC3 = !((LOC5 == ((NI) 1)));
		LA4: ;
		if (!LOC3) goto LA6;
		result = a;
	}
	goto LA1;
	LA6: ;
	{
		NU16 flags;
		if (!(*a).typ == 0) goto LA9;
		{
			if (!((*formal).kind == ((NU8) 49))) goto LA13;
			flags = 34;
		}
		goto LA11;
		LA13: ;
		{
			flags = 48;
		}
		LA11: ;
		result = (*c).semoperand(c, a, flags);
	}
	goto LA1;
	LA9: ;
	{
		result = a;
	}
	LA1: ;
	return result;
}

N_NIMCALL(Ttype214828*, arrayconstr_367697)(Tcontext264020* c, Tnode214790* n) {
	Ttype214828* result;
	Ttype214828* LOC1;
	Ttype214828* LOC2;
	Ttype214828* LOC3;
	result = 0;
	result = newtypes_264184(((NU8) 4), c);
	LOC1 = 0;
	LOC1 = getsystype_258130(((NU8) 31));
	LOC2 = 0;
	LOC2 = makerangetype_264915(c, IL64(0), IL64(0), (*n).info, LOC1);
	rawaddson_218408(result, LOC2);
	LOC3 = 0;
	LOC3 = skiptypes_218113((*n).typ, 8423424);
	addsonskipintlit_258680(result, LOC3);
	return result;
}

N_NIMCALL(Tnode214790*, prepareoperand_367666)(Tcontext264020* c, Tnode214790* a) {
	Tnode214790* result;
	result = 0;
	{
		if (!(*a).typ == 0) goto LA3;
		result = (*c).semoperand(c, a, 32);
	}
	goto LA1;
	LA3: ;
	{
		result = a;
	}
	LA1: ;
	return result;
}

N_NIMCALL(void, matchesaux_367822)(Tcontext264020* c, Tnode214790* n, Tnode214790* norig, Tcandidate362206* m, Intset211035* marker) {
	NI f;
	NI a;
	NI formallen;
	Tnode214790* LOC6;
	Tnode214790* container;
	Tsym214822* formal;
{	{
		if (!!(((*(*m).callee).kind == ((NU8) 10)))) goto LA3;
		f = ((NI) 1);
	}
	goto LA1;
	LA3: ;
	{
		f = ((NI) 0);
	}
	LA1: ;
	a = ((NI) 1);
	(*m).state = ((NU8) 1);
	unsureAsgnRef((void**) (&(*m).call), newnodei_216248((*n).kind, (*n).info));
	asgnRefNoCycle((void**) (&(*(*m).call).typ), base_240021((*m).callee));
	formallen = len_215059((*(*m).callee).n);
	LOC6 = 0;
	LOC6 = copytree_218822((*n).kindU.S6.sons->data[((NI) 0)]);
	addson_216807((*m).call, LOC6);
	container = NIM_NIL;
	{
		if (!(((NI) 1) < formallen)) goto LA9;
		formal = (*(*(*(*m).callee).n).kindU.S6.sons->data[((NI) 1)]).kindU.S4.sym;
	}
	goto LA7;
	LA9: ;
	{
		formal = NIM_NIL;
	}
	LA7: ;
	{
		while (1) {
			NI LOC14;
			LOC14 = 0;
			LOC14 = len_215059(n);
			if (!(a < LOC14)) goto LA13;
			{
				NIM_BOOL LOC17;
				NIM_BOOL LOC18;
				NIM_BOOL LOC21;
				NIM_BOOL LOC22;
				LOC17 = 0;
				LOC18 = 0;
				LOC18 = ((NI)(formallen - ((NI) 1)) <= a);
				if (!(LOC18)) goto LA19;
				LOC18 = !((formal == NIM_NIL));
				LA19: ;
				LOC17 = LOC18;
				if (!(LOC17)) goto LA20;
				LOC21 = 0;
				LOC22 = 0;
				LOC22 = ((*(*formal).typ).kind == ((NU8) 48));
				if (!(LOC22)) goto LA23;
				LOC22 = ((*(*(*formal).typ).sons->data[((NI) 0)]).kind == ((NU8) 6));
				LA23: ;
				LOC21 = LOC22;
				if (!(LOC21)) goto LA24;
				LOC21 = !((((*(*(*formal).typ).sons->data[((NI) 0)]).flags &(1U<<((NU)(((NU8) 0))&31U)))!=0));
				LA24: ;
				LOC17 = LOC21;
				LA20: ;
				if (!LOC17) goto LA25;
				{
					Ttype214828* LOC31;
					if (!container == 0) goto LA29;
					LOC31 = 0;
					LOC31 = arrayconstr_367703(c, (*n).info);
					container = newnodeit_216801(((NU8) 41), (*(*n).kindU.S6.sons->data[a]).info, LOC31);
					setson_367614((*m).call, (NI)((*formal).position + ((NI) 1)), container);
				}
				goto LA27;
				LA29: ;
				{
					incrindextype_367708((*container).typ);
				}
				LA27: ;
				addson_216807(container, (*n).kindU.S6.sons->data[a]);
			}
			goto LA15;
			LA25: ;
			{
				Tnode214790* arg;
				if (!((*(*n).kindU.S6.sons->data[a]).kind == ((NU8) 33))) goto LA34;
				preparenamedparam_367680((*n).kindU.S6.sons->data[a]);
				{
					if (!!(((*(*(*n).kindU.S6.sons->data[a]).kindU.S6.sons->data[((NI) 0)]).kind == ((NU8) 2)))) goto LA38;
					localerror_187080((*(*n).kindU.S6.sons->data[a]).info, ((NU16) 163), ((NimStringDesc*) &TMP2241));
					(*m).state = ((NU8) 2);
					goto BeforeRet;
				}
				LA38: ;
				formal = getsymfromlist_221135((*(*m).callee).n, (*(*(*n).kindU.S6.sons->data[a]).kindU.S6.sons->data[((NI) 0)]).kindU.S5.ident, ((NI) 1));
				{
					if (!(formal == NIM_NIL)) goto LA42;
					(*m).state = ((NU8) 2);
					goto BeforeRet;
				}
				LA42: ;
				{
					NIM_BOOL LOC46;
					LOC46 = 0;
					LOC46 = containsorincl_211862(marker, (*formal).position);
					if (!LOC46) goto LA47;
					localerror_187080((*(*n).kindU.S6.sons->data[a]).info, ((NU16) 147), (*(*formal).name).s);
					(*m).state = ((NU8) 2);
					goto BeforeRet;
				}
				LA47: ;
				(*m).basetypematch = NIM_FALSE;
				asgnRefNoCycle((void**) (&(*(*n).kindU.S6.sons->data[a]).kindU.S6.sons->data[((NI) 1)]), prepareoperand_367631(c, (*formal).typ, (*(*n).kindU.S6.sons->data[a]).kindU.S6.sons->data[((NI) 1)]));
				asgnRefNoCycle((void**) (&(*(*n).kindU.S6.sons->data[a]).typ), (*(*(*n).kindU.S6.sons->data[a]).kindU.S6.sons->data[((NI) 1)]).typ);
				arg = paramtypesmatch_367299(m, (*formal).typ, (*(*n).kindU.S6.sons->data[a]).typ, (*(*n).kindU.S6.sons->data[a]).kindU.S6.sons->data[((NI) 1)], (*(*n).kindU.S6.sons->data[a]).kindU.S6.sons->data[((NI) 1)]);
				{
					if (!(arg == NIM_NIL)) goto LA51;
					(*m).state = ((NU8) 2);
					goto BeforeRet;
				}
				LA51: ;
				{
					if (!!((*formal).constraint == 0)) goto LA55;
					{
						NIM_BOOL LOC59;
						LOC59 = 0;
						LOC59 = matchnodekinds_287042((*formal).constraint, (*(*n).kindU.S6.sons->data[a]).kindU.S6.sons->data[((NI) 1)]);
						if (!LOC59) goto LA60;
						(*m).genericmatches += ((NI) 100);
					}
					goto LA57;
					LA60: ;
					{
						(*m).state = ((NU8) 2);
						goto BeforeRet;
					}
					LA57: ;
				}
				LA55: ;
				{
					if (!((*(*formal).typ).kind == ((NU8) 23))) goto LA65;
					{
						NIM_BOOL LOC69;
						LOC69 = 0;
						LOC69 = islvalue_287027((*(*n).kindU.S6.sons->data[a]).kindU.S6.sons->data[((NI) 1)]);
						if (!!(LOC69)) goto LA70;
						(*m).state = ((NU8) 2);
						goto BeforeRet;
					}
					LA70: ;
				}
				LA65: ;
				{
					Ttype214828* LOC76;
					if (!(*m).basetypematch) goto LA74;
					LOC76 = 0;
					LOC76 = arrayconstr_367697(c, arg);
					container = newnodeit_216801(((NU8) 41), (*(*n).kindU.S6.sons->data[a]).info, LOC76);
					addson_216807(container, arg);
					setson_367614((*m).call, (NI)((*formal).position + ((NI) 1)), container);
					{
						if (!!((f == (NI)(formallen - ((NI) 1))))) goto LA79;
						container = NIM_NIL;
					}
					LA79: ;
				}
				goto LA72;
				LA74: ;
				{
					setson_367614((*m).call, (NI)((*formal).position + ((NI) 1)), arg);
				}
				LA72: ;
				f += ((NI) 1);
			}
			goto LA15;
			LA34: ;
			{
				{
					if (!(formallen <= f)) goto LA85;
					{
						if (!(((*(*m).callee).flags &(1U<<((NU)(((NU8) 0))&31U)))!=0)) goto LA89;
						asgnRefNoCycle((void**) (&(*n).kindU.S6.sons->data[a]), prepareoperand_367666(c, (*n).kindU.S6.sons->data[a]));
						{
							Ttype214828* LOC93;
							Ttype214828* LOC96;
							Tnode214790* LOC97;
							Tnode214790* LOC98;
							LOC93 = 0;
							LOC93 = skiptypes_218113((*(*n).kindU.S6.sons->data[a]).typ, IL64(211106240964608));
							if (!((*LOC93).kind == ((NU8) 28))) goto LA94;
							LOC96 = 0;
							LOC96 = getsystype_258130(((NU8) 29));
							LOC97 = 0;
							LOC97 = copytree_218822((*n).kindU.S6.sons->data[a]);
							LOC98 = 0;
							LOC98 = implicitconv_366525(((NU8) 58), LOC96, LOC97, (&(*m)), c);
							addson_216807((*m).call, LOC98);
						}
						goto LA91;
						LA94: ;
						{
							Tnode214790* LOC100;
							LOC100 = 0;
							LOC100 = copytree_218822((*n).kindU.S6.sons->data[a]);
							addson_216807((*m).call, LOC100);
						}
						LA91: ;
					}
					goto LA87;
					LA89: ;
					{
						NIM_BOOL LOC102;
						Tnode214790* arg;
						LOC102 = 0;
						LOC102 = !((formal == NIM_NIL));
						if (!(LOC102)) goto LA103;
						LOC102 = ((*(*formal).typ).kind == ((NU8) 48));
						LA103: ;
						if (!LOC102) goto LA104;
						(*m).basetypematch = NIM_FALSE;
						asgnRefNoCycle((void**) (&(*n).kindU.S6.sons->data[a]), prepareoperand_367631(c, (*formal).typ, (*n).kindU.S6.sons->data[a]));
						arg = paramtypesmatch_367299(m, (*formal).typ, (*(*n).kindU.S6.sons->data[a]).typ, (*n).kindU.S6.sons->data[a], (*norig).kindU.S6.sons->data[a]);
						{
							NIM_BOOL LOC108;
							NIM_BOOL LOC109;
							LOC108 = 0;
							LOC109 = 0;
							LOC109 = !((arg == NIM_NIL));
							if (!(LOC109)) goto LA110;
							LOC109 = (*m).basetypematch;
							LA110: ;
							LOC108 = LOC109;
							if (!(LOC108)) goto LA111;
							LOC108 = !((container == NIM_NIL));
							LA111: ;
							if (!LOC108) goto LA112;
							addson_216807(container, arg);
							incrindextype_367708((*container).typ);
							{
								if (!!((*formal).constraint == 0)) goto LA116;
								{
									NIM_BOOL LOC120;
									LOC120 = 0;
									LOC120 = matchnodekinds_287042((*formal).constraint, (*n).kindU.S6.sons->data[a]);
									if (!LOC120) goto LA121;
									(*m).genericmatches += ((NI) 100);
								}
								goto LA118;
								LA121: ;
								{
									(*m).state = ((NU8) 2);
									goto BeforeRet;
								}
								LA118: ;
							}
							LA116: ;
							{
								if (!((*(*formal).typ).kind == ((NU8) 23))) goto LA126;
								{
									NIM_BOOL LOC130;
									LOC130 = 0;
									LOC130 = islvalue_287027((*n).kindU.S6.sons->data[a]);
									if (!!(LOC130)) goto LA131;
									(*m).state = ((NU8) 2);
									goto BeforeRet;
								}
								LA131: ;
							}
							LA126: ;
						}
						goto LA106;
						LA112: ;
						{
							(*m).state = ((NU8) 2);
							goto BeforeRet;
						}
						LA106: ;
					}
					goto LA87;
					LA104: ;
					{
						(*m).state = ((NU8) 2);
						goto BeforeRet;
					}
					LA87: ;
				}
				goto LA83;
				LA85: ;
				{
					Tnode214790* arg;
					{
						if (!!(((*(*(*(*m).callee).n).kindU.S6.sons->data[f]).kind == ((NU8) 3)))) goto LA138;
						internalerror_187100((*(*n).kindU.S6.sons->data[a]).info, ((NimStringDesc*) &TMP2822));
						goto BeforeRet;
					}
					LA138: ;
					formal = (*(*(*(*m).callee).n).kindU.S6.sons->data[f]).kindU.S4.sym;
					{
						NIM_BOOL LOC142;
						LOC142 = 0;
						LOC142 = containsorincl_211862(marker, (*formal).position);
						if (!(LOC142)) goto LA143;
						LOC142 = container == 0;
						LA143: ;
						if (!LOC142) goto LA144;
						localerror_187080((*(*n).kindU.S6.sons->data[a]).info, ((NU16) 147), (*(*formal).name).s);
						(*m).state = ((NU8) 2);
						goto BeforeRet;
					}
					LA144: ;
					(*m).basetypematch = NIM_FALSE;
					asgnRefNoCycle((void**) (&(*n).kindU.S6.sons->data[a]), prepareoperand_367631(c, (*formal).typ, (*n).kindU.S6.sons->data[a]));
					arg = paramtypesmatch_367299(m, (*formal).typ, (*(*n).kindU.S6.sons->data[a]).typ, (*n).kindU.S6.sons->data[a], (*norig).kindU.S6.sons->data[a]);
					{
						if (!(arg == NIM_NIL)) goto LA148;
						(*m).state = ((NU8) 2);
						goto BeforeRet;
					}
					LA148: ;
					{
						Tnode214790* LOC160;
						NI LOC161;
						if (!(*m).basetypematch) goto LA152;
						{
							Ttype214828* LOC158;
							if (!container == 0) goto LA156;
							LOC158 = 0;
							LOC158 = arrayconstr_367697(c, arg);
							container = newnodeit_216801(((NU8) 41), (*(*n).kindU.S6.sons->data[a]).info, LOC158);
						}
						goto LA154;
						LA156: ;
						{
							incrindextype_367708((*container).typ);
						}
						LA154: ;
						addson_216807(container, arg);
						LOC160 = 0;
						LOC160 = implicitconv_366525(((NU8) 58), (*formal).typ, container, (&(*m)), c);
						setson_367614((*m).call, (NI)((*formal).position + ((NI) 1)), LOC160);
						LOC161 = 0;
						LOC161 = len_215059(n);
						f = ((f >= (NI)((NI)((NI)(formallen - LOC161) + a) + ((NI) 1))) ? f : (NI)((NI)((NI)(formallen - LOC161) + a) + ((NI) 1)));
					}
					goto LA150;
					LA152: ;
					{
						setson_367614((*m).call, (NI)((*formal).position + ((NI) 1)), arg);
						f += ((NI) 1);
						container = NIM_NIL;
					}
					LA150: ;
					{
						if (!!((*formal).constraint == 0)) goto LA165;
						{
							NIM_BOOL LOC169;
							LOC169 = 0;
							LOC169 = matchnodekinds_287042((*formal).constraint, (*n).kindU.S6.sons->data[a]);
							if (!LOC169) goto LA170;
							(*m).genericmatches += ((NI) 100);
						}
						goto LA167;
						LA170: ;
						{
							(*m).state = ((NU8) 2);
							goto BeforeRet;
						}
						LA167: ;
					}
					LA165: ;
					{
						if (!((*(*formal).typ).kind == ((NU8) 23))) goto LA175;
						{
							NIM_BOOL LOC179;
							LOC179 = 0;
							LOC179 = islvalue_287027((*n).kindU.S6.sons->data[a]);
							if (!!(LOC179)) goto LA180;
							(*m).state = ((NU8) 2);
							goto BeforeRet;
						}
						LA180: ;
					}
					LA175: ;
				}
				LA83: ;
			}
			LA15: ;
			a += ((NI) 1);
		} LA13: ;
	}
	}BeforeRet: ;
}

N_NIMCALL(void, partialmatch_368302)(Tcontext264020* c, Tnode214790* n, Tnode214790* norig, Tcandidate362206* m) {
	Intset211035 marker;
	memset((void*)(&marker), 0, sizeof(marker));
	chckNil((void*)(&marker));
	memset((void*)(&marker), 0, sizeof(marker));
	initintset_211885((&marker));
	matchesaux_367822(c, n, norig, m, (&marker));
}

N_NIMCALL(NIM_BOOL, argsfit_369559)(Tcontext264020* c, Tsym214822* candidate, Tnode214790* n, Tnode214790* norig) {
	NIM_BOOL result;
	result = 0;
	switch ((*candidate).kind) {
	case ((NU8) 12):
	case ((NU8) 13):
	case ((NU8) 14):
	case ((NU8) 15):
	case ((NU8) 6):
	case ((NU8) 17):
	case ((NU8) 16):
	{
		Tcandidate362206 m;
		memset((void*)(&m), 0, sizeof(m));
		initcandidate_362270(c, (&m), candidate, NIM_NIL, ((NI) -1));
		partialmatch_368302(c, n, norig, (&m));
		result = !((m.state == ((NU8) 2)));
	}
	break;
	default:
	{
		result = NIM_FALSE;
	}
	break;
	}
	return result;
}

N_NIMCALL(void, suggestcall_369579)(Tcontext264020* c, Tnode214790* n, Tnode214790* norig, NI* outputs) {
	NIM_BOOL islocal_369587;
	islocal_369587 = NIM_TRUE;
	{
		Tscope214816* scope_369589;
		Tscope214816* HEX3Atmp_371269;
		Tscope214816* current_371272;
		scope_369589 = 0;
		HEX3Atmp_371269 = 0;
		HEX3Atmp_371269 = (*c).currentscope;
		current_371272 = HEX3Atmp_371269;
		{
			while (1) {
				Tsymseq214792* entries_369591;
				Tsymseq214792* result_369612;
				TY369848 LOC11;
				if (!!((current_371272 == NIM_NIL))) goto LA3;
				scope_369589 = current_371272;
				{
					if (!(scope_369589 == (*c).toplevelscope)) goto LA6;
					islocal_369587 = NIM_FALSE;
				}
				LA6: ;
				result_369612 = (Tsymseq214792*) newSeq((&NTI214792), 0);
				{
					Tsym214822* x_369616;
					Tstrtable214794 HEX3Atmp_371257;
					Ttabiter221071 it_371260;
					Tsym214822* s_371262;
					x_369616 = 0;
					memset((void*)(&HEX3Atmp_371257), 0, sizeof(HEX3Atmp_371257));
					HEX3Atmp_371257.counter = (*scope_369589).symbols.counter;
					HEX3Atmp_371257.data = (*scope_369589).symbols.data;
					memset((void*)(&it_371260), 0, sizeof(it_371260));
					s_371262 = inittabiter_221073((&it_371260), HEX3Atmp_371257);
					{
						while (1) {
							if (!!((s_371262 == NIM_NIL))) goto LA10;
							x_369616 = s_371262;
							result_369612 = (Tsymseq214792*) incrSeqV2(&(result_369612)->Sup, sizeof(Tsym214822*));
							asgnRefNoCycle((void**) (&result_369612->data[result_369612->Sup.len]), x_369616);
							++result_369612->Sup.len;
							s_371262 = nextiter_221078((&it_371260), HEX3Atmp_371257);
						} LA10: ;
					}
				}
				genericSeqAssign((&entries_369591), result_369612, (&NTI214792));
				memset((void*)(&LOC11), 0, sizeof(LOC11));
				LOC11.ClPrc = ((TMP2820) (HEX3Aanonymous_369830)); LOC11.ClEnv = NIM_NIL;
				sort_369841(entries_369591->data, entries_369591->Sup.len, LOC11, ((NU8) 1));
				{
					Tsym214822* item_369597;
					NI i_371266;
					NI L_371268;
					item_369597 = 0;
					i_371266 = ((NI) 0);
					L_371268 = (entries_369591 ? entries_369591->Sup.len : 0);
					{
						while (1) {
							Tsym214822* it;
							if (!(i_371266 < L_371268)) goto LA14;
							item_369597 = entries_369591->data[i_371266];
							it = item_369597;
							{
								NIM_BOOL LOC17;
								NIM_BOOL LOC18;
								NimStringDesc* LOC23;
								Suggest368803 LOC24;
								LOC17 = 0;
								LOC18 = 0;
								LOC18 = filtersym_369221(it);
								if (!(LOC18)) goto LA19;
								LOC18 = namefits_369533(c, it, n);
								LA19: ;
								LOC17 = LOC18;
								if (!(LOC17)) goto LA20;
								LOC17 = argsfit_369559(c, it, n, norig);
								LA20: ;
								if (!LOC17) goto LA21;
								LOC23 = 0;
								LOC23 = HEX24_161680(((NU8) 2));
								memset((void*)(&LOC24), 0, sizeof(LOC24));
								symtosuggest_369201(it, islocal_369587, LOC23, ((NI) 100), (&LOC24));
								suggestresult_369211((&LOC24));
								(*outputs) += ((NI) 1);
							}
							LA21: ;
							i_371266 += ((NI) 1);
						} LA14: ;
					}
				}
				current_371272 = (*current_371272).parent;
			} LA3: ;
		}
	}
}

N_NIMCALL(void, suggestexpr_372810)(Tcontext264020* c, Tnode214790* node) {
	NI outputs;
{	{
		NU8 cp;
		if (!!((((*node).flags &(1U<<((NU)(((NU8) 14))&15U)))!=0))) goto LA3;
		{
			if (!(gtrackpos_183441.line < ((NI16) 0))) goto LA7;
			goto BeforeRet;
		}
		LA7: ;
		cp = incheckpoint_371975((*node).info);
		{
			if (!(cp == ((NU8) 0))) goto LA11;
			goto BeforeRet;
		}
		LA11: ;
	}
	LA3: ;
	outputs = ((NI) 0);
	{
		if (!(((NI) 0) < (*c).compilescontextid)) goto LA15;
		goto BeforeRet;
	}
	LA15: ;
	(*c).compilescontextid += ((NI) 1);
	{
		Tnode214790* n;
		if (!(gidecmd_160114 == ((NU8) 1))) goto LA19;
		{
			if (!(((*node).flags &(1U<<((NU)(((NU8) 14))&15U)))!=0)) goto LA23;
			n = node;
		}
		goto LA21;
		LA23: ;
		{
			n = findclosestdot_371979(node);
		}
		LA21: ;
		{
			if (!(n == NIM_NIL)) goto LA28;
			n = node;
		}
		LA28: ;
		{
			Tnode214790* obj;
			if (!((*n).kind == ((NU8) 45))) goto LA32;
			obj = safesemexpr_372805(c, (*n).kindU.S6.sons->data[((NI) 0)]);
			suggestfieldaccess_371747(c, obj, (&outputs));
		}
		goto LA30;
		LA32: ;
		{
			suggesteverything_371695(c, n, (&outputs));
		}
		LA30: ;
	}
	goto LA17;
	LA19: ;
	{
		Tnode214790* n;
		if (!(gidecmd_160114 == ((NU8) 2))) goto LA36;
		{
			if (!(((*node).flags &(1U<<((NU)(((NU8) 14))&15U)))!=0)) goto LA40;
			n = node;
		}
		goto LA38;
		LA40: ;
		{
			n = findclosestcall_372040(node);
		}
		LA38: ;
		{
			if (!(n == NIM_NIL)) goto LA45;
			n = node;
		}
		LA45: ;
		{
			Tnode214790* a;
			Tnode214790* x_372933;
			if (!((*n).kind == ((NU8) 27) || (*n).kind == ((NU8) 29) || (*n).kind == ((NU8) 30) || (*n).kind == ((NU8) 31) || (*n).kind == ((NU8) 26) || (*n).kind == ((NU8) 28) || (*n).kind == ((NU8) 32))) goto LA49;
			a = copynode_218542(n);
			x_372933 = safesemexpr_372805(c, (*n).kindU.S6.sons->data[((NI) 0)]);
			{
				NIM_BOOL LOC53;
				LOC53 = 0;
				LOC53 = ((*x_372933).kind == ((NU8) 1));
				if (LOC53) goto LA54;
				LOC53 = ((*x_372933).typ == NIM_NIL);
				LA54: ;
				if (!LOC53) goto LA55;
				x_372933 = (*n).kindU.S6.sons->data[((NI) 0)];
			}
			LA55: ;
			addson_216807(a, x_372933);
			{
				NI i_372965;
				NI HEX3Atmp_373011;
				NI LOC58;
				NI res_373014;
				i_372965 = 0;
				HEX3Atmp_373011 = 0;
				LOC58 = 0;
				LOC58 = sonslen_217351(n);
				HEX3Atmp_373011 = (NI)(LOC58 - ((NI) 1));
				res_373014 = ((NI) 1);
				{
					while (1) {
						Tnode214790* x;
						if (!(res_373014 <= HEX3Atmp_373011)) goto LA60;
						i_372965 = res_373014;
						x = safesemexpr_372805(c, (*n).kindU.S6.sons->data[i_372965]);
						{
							NIM_BOOL LOC63;
							LOC63 = 0;
							LOC63 = ((*x).kind == ((NU8) 1));
							if (LOC63) goto LA64;
							LOC63 = ((*x).typ == NIM_NIL);
							LA64: ;
							if (!LOC63) goto LA65;
							goto LA57;
						}
						LA65: ;
						addson_216807(a, x);
						res_373014 += ((NI) 1);
					} LA60: ;
				}
			} LA57: ;
			suggestcall_369579(c, a, n, (&outputs));
		}
		LA49: ;
	}
	goto LA17;
	LA36: ;
	LA17: ;
	(*c).compilescontextid -= ((NI) 1);
	{
		NIM_BOOL LOC69;
		LOC69 = 0;
		LOC69 = (((NI) 0) < outputs);
		if (!(LOC69)) goto LA70;
		LOC69 = ((14 &(1U<<((NU)(gidecmd_160114)&15U)))!=0);
		LA70: ;
		if (!LOC69) goto LA71;
		suggestquit_183155();
	}
	LA71: ;
	}BeforeRet: ;
}

N_NIMCALL(void, newcandidate_362419)(Tcontext264020* ctx, Ttype214828* callee, Tcandidate362206* Result) {
	initcandidate_362257(ctx, Result, callee);
}

N_NIMCALL(void, matches_368311)(Tcontext264020* c, Tnode214790* n, Tnode214790* norig, Tcandidate362206* m) {
	Intset211035 marker;
	NI f;
{	{
		NIM_BOOL LOC3;
		LOC3 = 0;
		LOC3 = !(((*m).calleesym == NIM_NIL));
		if (!(LOC3)) goto LA4;
		LOC3 = ((*(*m).calleesym).magic == ((NU8) 4) || (*(*m).calleesym).magic == ((NU8) 5));
		LA4: ;
		if (!LOC3) goto LA5;
		(*m).state = ((NU8) 1);
		unsureAsgnRef((void**) (&(*m).call), n);
		goto BeforeRet;
	}
	LA5: ;
	memset((void*)(&marker), 0, sizeof(marker));
	chckNil((void*)(&marker));
	memset((void*)(&marker), 0, sizeof(marker));
	initintset_211885((&marker));
	matchesaux_367822(c, n, norig, m, (&marker));
	{
		if (!((*m).state == ((NU8) 2))) goto LA9;
		goto BeforeRet;
	}
	LA9: ;
	f = ((NI) 1);
	{
		while (1) {
			NI LOC13;
			Tsym214822* formal;
			LOC13 = 0;
			LOC13 = sonslen_217351((*(*m).callee).n);
			if (!(f < LOC13)) goto LA12;
			formal = (*(*(*(*m).callee).n).kindU.S6.sons->data[f]).kindU.S4.sym;
			{
				NIM_BOOL LOC16;
				LOC16 = 0;
				LOC16 = containsorincl_211862((&marker), (*formal).position);
				if (!!(LOC16)) goto LA17;
				{
					if (!((*formal).ast == NIM_NIL)) goto LA21;
					{
						Tnode214790* container;
						Ttype214828* LOC27;
						Tnode214790* LOC28;
						if (!((*(*formal).typ).kind == ((NU8) 48))) goto LA25;
						LOC27 = 0;
						LOC27 = arrayconstr_367703(c, (*n).info);
						container = newnodeit_216801(((NU8) 41), (*n).info, LOC27);
						LOC28 = 0;
						LOC28 = implicitconv_366525(((NU8) 58), (*formal).typ, container, (&(*m)), c);
						addson_216807((*m).call, LOC28);
					}
					goto LA23;
					LA25: ;
					{
						(*m).state = ((NU8) 2);
						goto LA11;
					}
					LA23: ;
				}
				goto LA19;
				LA21: ;
				{
					Tnode214790* LOC31;
					LOC31 = 0;
					LOC31 = copytree_218822((*formal).ast);
					setson_367614((*m).call, (NI)((*formal).position + ((NI) 1)), LOC31);
				}
				LA19: ;
			}
			LA17: ;
			f += ((NI) 1);
		} LA12: ;
	} LA11: ;
	}BeforeRet: ;
}

N_NIMCALL(NimStringDesc*, argtypetostring_362689)(Tnode214790* arg, NU8 prefer) {
	NimStringDesc* result;
	result = 0;
	{
		Tnode214790* LOC5;
		if (!((*arg).kind == ((NU8) 56) || (*arg).kind == ((NU8) 57))) goto LA3;
		LOC5 = 0;
		LOC5 = HEX5BHEX5D_215238(arg, ((NI) 0));
		result = typetostring_240017((*LOC5).typ, prefer);
		{
			NI i_362722;
			NI HEX3Atmp_362724;
			NI LOC7;
			NI res_362727;
			i_362722 = 0;
			HEX3Atmp_362724 = 0;
			LOC7 = 0;
			LOC7 = len_215059(arg);
			HEX3Atmp_362724 = (LOC7 - 1);
			res_362727 = ((NI) 1);
			{
				while (1) {
					Tnode214790* LOC10;
					NimStringDesc* LOC11;
					if (!(res_362727 <= HEX3Atmp_362724)) goto LA9;
					i_362722 = res_362727;
					result = resizeString(result, 3);
appendString(result, ((NimStringDesc*) &TMP3171));
					LOC10 = 0;
					LOC10 = HEX5BHEX5D_215238(arg, i_362722);
					LOC11 = 0;
					LOC11 = typetostring_240017((*LOC10).typ, prefer);
					result = resizeString(result, LOC11->Sup.len + 0);
appendString(result, LOC11);
					res_362727 += ((NI) 1);
				} LA9: ;
			}
		}
	}
	goto LA1;
	LA3: ;
	{
		result = typetostring_240017((*arg).typ, prefer);
	}
	LA1: ;
	return result;
}

N_NIMCALL(NimStringDesc*, describeargs_362731)(Tcontext264020* c, Tnode214790* n, NI startidx, NU8 prefer) {
	NimStringDesc* result;
{	result = 0;
	result = copyString(((NimStringDesc*) &TMP2241));
	{
		NI i_362750;
		NI HEX3Atmp_362798;
		NI LOC2;
		NI res_362801;
		i_362750 = 0;
		HEX3Atmp_362798 = 0;
		LOC2 = 0;
		LOC2 = len_215059(n);
		HEX3Atmp_362798 = (NI)(LOC2 - ((NI) 1));
		res_362801 = startidx;
		{
			while (1) {
				Tnode214790* arg;
				NimStringDesc* LOC23;
				if (!(res_362801 <= HEX3Atmp_362798)) goto LA4;
				i_362750 = res_362801;
				arg = (*n).kindU.S6.sons->data[i_362750];
				{
					NimStringDesc* LOC9;
					if (!((*(*n).kindU.S6.sons->data[i_362750]).kind == ((NU8) 33))) goto LA7;
					LOC9 = 0;
					LOC9 = rendertree_233044((*(*n).kindU.S6.sons->data[i_362750]).kindU.S6.sons->data[((NI) 0)], 0);
					result = resizeString(result, LOC9->Sup.len + 0);
appendString(result, LOC9);
					result = resizeString(result, 2);
appendString(result, ((NimStringDesc*) &TMP3170));
					{
						if (!(*arg).typ == 0) goto LA12;
						arg = (*c).semoperand(c, (*(*n).kindU.S6.sons->data[i_362750]).kindU.S6.sons->data[((NI) 1)], 0);
						asgnRefNoCycle((void**) (&(*(*n).kindU.S6.sons->data[i_362750]).typ), (*arg).typ);
						asgnRefNoCycle((void**) (&(*(*n).kindU.S6.sons->data[i_362750]).kindU.S6.sons->data[((NI) 1)]), arg);
					}
					LA12: ;
				}
				goto LA5;
				LA7: ;
				{
					{
						if (!(*arg).typ == 0) goto LA17;
						arg = (*c).semoperand(c, (*n).kindU.S6.sons->data[i_362750], 0);
						asgnRefNoCycle((void**) (&(*n).kindU.S6.sons->data[i_362750]), arg);
					}
					LA17: ;
				}
				LA5: ;
				{
					if (!((*(*arg).typ).kind == ((NU8) 50))) goto LA21;
					goto BeforeRet;
				}
				LA21: ;
				LOC23 = 0;
				LOC23 = argtypetostring_362689(arg, prefer);
				result = resizeString(result, LOC23->Sup.len + 0);
appendString(result, LOC23);
				{
					NI LOC26;
					LOC26 = 0;
					LOC26 = sonslen_217351(n);
					if (!!((i_362750 == (NI)(LOC26 - ((NI) 1))))) goto LA27;
					result = resizeString(result, 2);
appendString(result, ((NimStringDesc*) &TMP3172));
				}
				LA27: ;
				res_362801 += ((NI) 1);
			} LA4: ;
		}
	}
	}BeforeRet: ;
	return result;
}

N_NIMCALL(Tnode214790*, usesym_372801)(Tsym214822* sym) {
	Tnode214790* result;
	result = 0;
	result = newsymnode_216234(sym);
	markused_362244((*result).info, sym);
	return result;
}

N_NIMCALL(void, semfinishoperands_368269)(Tcontext264020* c, Tnode214790* n) {
	{
		NI i_368291;
		NI HEX3Atmp_368295;
		NI LOC2;
		NI res_368298;
		i_368291 = 0;
		HEX3Atmp_368295 = 0;
		LOC2 = 0;
		LOC2 = len_215059(n);
		HEX3Atmp_368295 = (LOC2 - 1);
		res_368298 = ((NI) 1);
		{
			while (1) {
				if (!(res_368298 <= HEX3Atmp_368295)) goto LA4;
				i_368291 = res_368298;
				asgnRefNoCycle((void**) (&(*n).kindU.S6.sons->data[i_368291]), prepareoperand_367666(c, (*n).kindU.S6.sons->data[i_368291]));
				res_368298 += ((NI) 1);
			} LA4: ;
		}
	}
}

N_NIMCALL(NU8, cmptypes_366484)(Tcontext264020* c, Ttype214828* f, Ttype214828* a) {
	NU8 result;
	Tcandidate362206 m;
	result = 0;
	memset((void*)(&m), 0, sizeof(m));
	initcandidate_362257(c, (&m), f);
	result = typerel_362805((&m), f, a, NIM_TRUE);
	return result;
}

N_NIMCALL(void, suggeststmt_373018)(Tcontext264020* c, Tnode214790* n) {
	suggestexpr_372810(c, n);
}

N_NIMCALL(Tsym214822*, insttypeboundop_368419)(Tcontext264020* c, Tsym214822* dc, Ttype214828* t, Tlineinfo182337 info, NU8 op) {
	Tsym214822* result;
	Tcandidate362206 m;
	Ttype214828* f;
	result = 0;
	memset((void*)(&m), 0, sizeof(m));
	initcandidate_362257(c, (&m), (*dc).typ);
	f = (*(*dc).typ).sons->data[((NI) 1)];
	{
		if (!(op == ((NU8) 1))) goto LA3;
		{
			if (!((6291456 &((NU64)1<<((NU)((*f).kind)&63U)))!=0)) goto LA7;
			f = lastson_217377(f);
		}
		LA7: ;
	}
	goto LA1;
	LA3: ;
	{
		{
			if (!((*f).kind == ((NU8) 23))) goto LA12;
			f = lastson_217377(f);
		}
		LA12: ;
	}
	LA1: ;
	{
		NU8 LOC16;
		LOC16 = 0;
		LOC16 = typerel_362805((&m), f, t, NIM_TRUE);
		if (!(LOC16 == ((NU8) 0))) goto LA17;
		localerror_187080(info, ((NU16) 4), ((NimStringDesc*) &TMP3648));
	}
	goto LA14;
	LA17: ;
	{
		result = (*c).semgenerateinstance.ClEnv? (*c).semgenerateinstance.ClPrc(c, dc, m.bindings, info, (*c).semgenerateinstance.ClEnv):((TMP3649)((*c).semgenerateinstance.ClPrc))(c, dc, m.bindings, info);
	}
	LA14: ;
	return result;
}
NIM_EXTERNC N_NOINLINE(void, compiler_sigmatchInit000)(void) {
}

NIM_EXTERNC N_NOINLINE(void, compiler_sigmatchDatInit000)(void) {
static TNimNode* TMP2768[11];
static TNimNode* TMP2815[20];
static TNimNode* TMP2816[3];
NI TMP2818;
static char* NIM_CONST TMP2817[3] = {
"csEmpty", 
"csMatch", 
"csNoMatch"};
static TNimNode TMP957[37];
NTI368803.size = sizeof(Suggest368803);
NTI368803.kind = 18;
NTI368803.base = 0;
NTI368803.flags = 2;
TMP2768[0] = &TMP957[1];
TMP957[1].kind = 1;
TMP957[1].offset = offsetof(Suggest368803, section);
TMP957[1].typ = (&NTI160023);
TMP957[1].name = "section";
TMP2768[1] = &TMP957[2];
TMP957[2].kind = 1;
TMP957[2].offset = offsetof(Suggest368803, qualifiedpath);
TMP957[2].typ = (&NTI125202);
TMP957[2].name = "qualifiedPath";
TMP2768[2] = &TMP957[3];
TMP957[3].kind = 1;
TMP957[3].offset = offsetof(Suggest368803, filepath);
TMP957[3].typ = (&NTI138);
TMP957[3].name = "filePath";
TMP2768[3] = &TMP957[4];
TMP957[4].kind = 1;
TMP957[4].offset = offsetof(Suggest368803, line);
TMP957[4].typ = (&NTI104);
TMP957[4].name = "line";
TMP2768[4] = &TMP957[5];
TMP957[5].kind = 1;
TMP957[5].offset = offsetof(Suggest368803, column);
TMP957[5].typ = (&NTI104);
TMP957[5].name = "column";
TMP2768[5] = &TMP957[6];
TMP957[6].kind = 1;
TMP957[6].offset = offsetof(Suggest368803, doc);
TMP957[6].typ = (&NTI138);
TMP957[6].name = "doc";
TMP2768[6] = &TMP957[7];
TMP957[7].kind = 1;
TMP957[7].offset = offsetof(Suggest368803, symkind);
TMP957[7].typ = (&NTI214435);
TMP957[7].name = "symkind";
TMP2768[7] = &TMP957[8];
TMP957[8].kind = 1;
TMP957[8].offset = offsetof(Suggest368803, forth);
TMP957[8].typ = (&NTI138);
TMP957[8].name = "forth";
TMP2768[8] = &TMP957[9];
NTI368813.size = sizeof(NI);
NTI368813.kind = 20;
NTI368813.base = (&NTI104);
NTI368813.flags = 3;
TMP957[9].kind = 1;
TMP957[9].offset = offsetof(Suggest368803, quality);
TMP957[9].typ = (&NTI368813);
TMP957[9].name = "quality";
TMP2768[9] = &TMP957[10];
TMP957[10].kind = 1;
TMP957[10].offset = offsetof(Suggest368803, isglobal);
TMP957[10].typ = (&NTI130);
TMP957[10].name = "isGlobal";
TMP2768[10] = &TMP957[11];
TMP957[11].kind = 1;
TMP957[11].offset = offsetof(Suggest368803, tokenlen);
TMP957[11].typ = (&NTI104);
TMP957[11].name = "tokenLen";
TMP957[0].len = 11; TMP957[0].kind = 2; TMP957[0].sons = &TMP2768[0];
NTI368803.node = &TMP957[0];
NTI362206.size = sizeof(Tcandidate362206);
NTI362206.kind = 18;
NTI362206.base = 0;
TMP2815[0] = &TMP957[13];
TMP957[13].kind = 1;
TMP957[13].offset = offsetof(Tcandidate362206, c);
TMP957[13].typ = (&NTI264018);
TMP957[13].name = "c";
TMP2815[1] = &TMP957[14];
TMP957[14].kind = 1;
TMP957[14].offset = offsetof(Tcandidate362206, exactmatches);
TMP957[14].typ = (&NTI104);
TMP957[14].name = "exactMatches";
TMP2815[2] = &TMP957[15];
TMP957[15].kind = 1;
TMP957[15].offset = offsetof(Tcandidate362206, genericmatches);
TMP957[15].typ = (&NTI104);
TMP957[15].name = "genericMatches";
TMP2815[3] = &TMP957[16];
TMP957[16].kind = 1;
TMP957[16].offset = offsetof(Tcandidate362206, subtypematches);
TMP957[16].typ = (&NTI104);
TMP957[16].name = "subtypeMatches";
TMP2815[4] = &TMP957[17];
TMP957[17].kind = 1;
TMP957[17].offset = offsetof(Tcandidate362206, intconvmatches);
TMP957[17].typ = (&NTI104);
TMP957[17].name = "intConvMatches";
TMP2815[5] = &TMP957[18];
TMP957[18].kind = 1;
TMP957[18].offset = offsetof(Tcandidate362206, convmatches);
TMP957[18].typ = (&NTI104);
TMP957[18].name = "convMatches";
TMP2815[6] = &TMP957[19];
NTI362202.size = sizeof(NU8);
NTI362202.kind = 14;
NTI362202.base = 0;
NTI362202.flags = 3;
for (TMP2818 = 0; TMP2818 < 3; TMP2818++) {
TMP957[TMP2818+20].kind = 1;
TMP957[TMP2818+20].offset = TMP2818;
TMP957[TMP2818+20].name = TMP2817[TMP2818];
TMP2816[TMP2818] = &TMP957[TMP2818+20];
}
TMP957[23].len = 3; TMP957[23].kind = 2; TMP957[23].sons = &TMP2816[0];
NTI362202.node = &TMP957[23];
TMP957[19].kind = 1;
TMP957[19].offset = offsetof(Tcandidate362206, state);
TMP957[19].typ = (&NTI362202);
TMP957[19].name = "state";
TMP2815[7] = &TMP957[24];
TMP957[24].kind = 1;
TMP957[24].offset = offsetof(Tcandidate362206, callee);
TMP957[24].typ = (&NTI214786);
TMP957[24].name = "callee";
TMP2815[8] = &TMP957[25];
TMP957[25].kind = 1;
TMP957[25].offset = offsetof(Tcandidate362206, calleesym);
TMP957[25].typ = (&NTI214788);
TMP957[25].name = "calleeSym";
TMP2815[9] = &TMP957[26];
TMP957[26].kind = 1;
TMP957[26].offset = offsetof(Tcandidate362206, calleescope);
TMP957[26].typ = (&NTI104);
TMP957[26].name = "calleeScope";
TMP2815[10] = &TMP957[27];
TMP957[27].kind = 1;
TMP957[27].offset = offsetof(Tcandidate362206, call);
TMP957[27].typ = (&NTI214782);
TMP957[27].name = "call";
TMP2815[11] = &TMP957[28];
TMP957[28].kind = 1;
TMP957[28].offset = offsetof(Tcandidate362206, bindings);
TMP957[28].typ = (&NTI214840);
TMP957[28].name = "bindings";
TMP2815[12] = &TMP957[29];
TMP957[29].kind = 1;
TMP957[29].offset = offsetof(Tcandidate362206, basetypematch);
TMP957[29].typ = (&NTI130);
TMP957[29].name = "baseTypeMatch";
TMP2815[13] = &TMP957[30];
TMP957[30].kind = 1;
TMP957[30].offset = offsetof(Tcandidate362206, fauxmatch);
TMP957[30].typ = (&NTI214241);
TMP957[30].name = "fauxMatch";
TMP2815[14] = &TMP957[31];
TMP957[31].kind = 1;
TMP957[31].offset = offsetof(Tcandidate362206, genericconverter);
TMP957[31].typ = (&NTI130);
TMP957[31].name = "genericConverter";
TMP2815[15] = &TMP957[32];
TMP957[32].kind = 1;
TMP957[32].offset = offsetof(Tcandidate362206, coercedistincts);
TMP957[32].typ = (&NTI130);
TMP957[32].name = "coerceDistincts";
TMP2815[16] = &TMP957[33];
TMP957[33].kind = 1;
TMP957[33].offset = offsetof(Tcandidate362206, typedescmatched);
TMP957[33].typ = (&NTI130);
TMP957[33].name = "typedescMatched";
TMP2815[17] = &TMP957[34];
TMP957[34].kind = 1;
TMP957[34].offset = offsetof(Tcandidate362206, isnocall);
TMP957[34].typ = (&NTI130);
TMP957[34].name = "isNoCall";
TMP2815[18] = &TMP957[35];
TMP957[35].kind = 1;
TMP957[35].offset = offsetof(Tcandidate362206, inheritancepenalty);
TMP957[35].typ = (&NTI104);
TMP957[35].name = "inheritancePenalty";
TMP2815[19] = &TMP957[36];
TMP957[36].kind = 1;
TMP957[36].offset = offsetof(Tcandidate362206, errors);
TMP957[36].typ = (&NTI214792);
TMP957[36].name = "errors";
TMP957[12].len = 20; TMP957[12].kind = 2; TMP957[12].sons = &TMP2815[0];
NTI362206.node = &TMP957[12];
}

