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

#include "nimbase.h"
#include <setjmp.h>
#include <string.h>
#include <stdio.h>
typedef struct Suggest395010 Suggest395010;
typedef struct Tsym225841 Tsym225841;
typedef struct Tlineinfo190352 Tlineinfo190352;
typedef struct Tcontext280023 Tcontext280023;
typedef struct Tnode225809 Tnode225809;
typedef struct Ttype225847 Ttype225847;
typedef struct NimStringDesc NimStringDesc;
typedef struct TGenericSeq TGenericSeq;
typedef struct Tident198021 Tident198021;
typedef struct Tnodeseq225803 Tnodeseq225803;
typedef struct Tpasscontext277005 Tpasscontext277005;
typedef struct TNimObject TNimObject;
typedef struct TNimType TNimType;
typedef struct TNimNode TNimNode;
typedef struct Tscope225835 Tscope225835;
typedef struct Tproccon280011 Tproccon280011;
typedef struct Tsymseq225811 Tsymseq225811;
typedef struct Intset222056 Intset222056;
typedef struct Trunk222052 Trunk222052;
typedef struct Trunkseq222054 Trunkseq222054;
typedef struct Tlinkedlist140028 Tlinkedlist140028;
typedef struct Tlistentry140022 Tlistentry140022;
typedef struct Tidtable225859 Tidtable225859;
typedef struct Tidpairseq225857 Tidpairseq225857;
typedef struct Tstrtable225813 Tstrtable225813;
typedef struct Tctx279048 Tctx279048;
typedef struct TY280143 TY280143;
typedef struct Exception Exception;
typedef struct TSafePoint TSafePoint;
typedef struct Cell48946 Cell48946;
typedef struct Cellset48958 Cellset48958;
typedef struct Gcheap51018 Gcheap51018;
typedef struct Gcstack51016 Gcstack51016;
typedef struct Cellseq48962 Cellseq48962;
typedef struct Pagedesc48954 Pagedesc48954;
typedef struct Memregion30890 Memregion30890;
typedef struct Smallchunk30842 Smallchunk30842;
typedef struct Llchunk30884 Llchunk30884;
typedef struct Bigchunk30844 Bigchunk30844;
typedef struct Intset30817 Intset30817;
typedef struct Trunk30813 Trunk30813;
typedef struct Avlnode30888 Avlnode30888;
typedef struct Gcstat51014 Gcstat51014;
typedef struct Tidobj198015 Tidobj198015;
typedef struct Ttypeseq225843 Ttypeseq225843;
typedef struct TY225944 TY225944;
typedef struct Tloc225823 Tloc225823;
typedef struct Ropeobj176009 Ropeobj176009;
typedef struct Tlib225827 Tlib225827;
typedef struct Ttabiter233119 Ttabiter233119;
typedef struct TY130408 TY130408;
typedef struct Tdocumentor384007 Tdocumentor384007;
typedef struct Tcandidate388209 Tcandidate388209;
typedef struct TY90959 TY90959;
typedef struct Tidpair225855 Tidpair225855;
typedef struct TY279254 TY279254;
typedef struct TY191420 TY191420;
typedef struct PprocHEX3Aobjecttype279233 PprocHEX3Aobjecttype279233;
typedef struct TY279273 TY279273;
typedef struct Tinstantiationpair280013 Tinstantiationpair280013;
typedef struct Tinstantiation225831 Tinstantiation225831;
typedef struct Basechunk30840 Basechunk30840;
typedef struct Freecell30832 Freecell30832;
typedef struct Rstgenerator347016 Rstgenerator347016;
typedef struct Stringtableobj145212 Stringtableobj145212;
typedef struct TY347035 TY347035;
typedef struct Table347053 Table347053;
typedef struct Keyvaluepairseq347056 Keyvaluepairseq347056;
typedef struct TY279234 TY279234;
typedef struct TY279239 TY279239;
typedef struct TY279274 TY279274;
typedef struct Vmargs279042 Vmargs279042;
typedef struct TY225932 TY225932;
typedef struct Keyvaluepairseq145210 Keyvaluepairseq145210;
typedef struct Tocentry347012 Tocentry347012;
typedef struct Rstnode332011 Rstnode332011;
typedef struct Keyvaluepair347059 Keyvaluepair347059;
typedef struct Tblock279030 Tblock279030;
typedef struct TY279214 TY279214;
typedef struct Keyvaluepair145208 Keyvaluepair145208;
typedef struct Rstnodeseq332009 Rstnodeseq332009;
typedef struct {
N_NIMCALL_PTR(void, ClPrc) (Suggest395010* result, void* ClEnv);
void* ClEnv;
} TY395020;
struct  Tlineinfo190352  {
NI16 line;
NI16 col;
NI32 fileindex;
};
struct  TGenericSeq  {
NI len;
NI reserved;
};
struct  NimStringDesc  {
  TGenericSeq Sup;
NIM_CHAR data[SEQ_DECL_SIZE];
};
struct  Tnode225809  {
Ttype225847* typ;
Tlineinfo190352 info;
NU16 flags;
NU8 kind;
union{
struct {NI64 intval;
} S1;
struct {NF floatval;
} S2;
struct {NimStringDesc* strval;
} S3;
struct {Tsym225841* sym;
} S4;
struct {Tident198021* ident;
} S5;
struct {Tnodeseq225803* sons;
} S6;
} kindU;
NimStringDesc* comment;
};
typedef N_NIMCALL_PTR(void, TY3889) (void* p, NI op);
typedef N_NIMCALL_PTR(void*, TY3894) (void* p);
struct  TNimType  {
NI size;
NU8 kind;
NU8 flags;
TNimType* base;
TNimNode* node;
void* finalizer;
TY3889 marker;
TY3894 deepcopy;
};
struct  TNimObject  {
TNimType* m_type;
};
struct  Tpasscontext277005  {
  TNimObject Sup;
NIM_BOOL fromcache;
};
struct  Intset222056  {
NI counter;
NI max;
Trunk222052* head;
Trunkseq222054* data;
};
struct  Tlinkedlist140028  {
Tlistentry140022* head;
Tlistentry140022* tail;
NI counter;
};
struct  Tidtable225859  {
NI counter;
Tidpairseq225857* data;
};
typedef N_NIMCALL_PTR(Tnode225809*, TY280074) (Tcontext280023* c, Tnode225809* n);
typedef N_NIMCALL_PTR(Tnode225809*, TY280079) (Tcontext280023* c, Tnode225809* n, NU16 flags);
typedef N_NIMCALL_PTR(Tnode225809*, TY280087) (Tcontext280023* c, Tnode225809* n, NU16 flags);
typedef N_NIMCALL_PTR(Tnode225809*, TY280095) (Tcontext280023* c, Tnode225809* n);
typedef N_NIMCALL_PTR(Tnode225809*, TY280100) (Tcontext280023* c, Tnode225809* n, NU16 flags);
typedef N_NIMCALL_PTR(Tnode225809*, TY280108) (Tcontext280023* c, Tnode225809* n);
typedef N_NIMCALL_PTR(Tnode225809*, TY280113) (Tcontext280023* c, Tnode225809* n, Tnode225809* norig, NU32 filter);
typedef N_NIMCALL_PTR(Ttype225847*, TY280120) (Tcontext280023* c, Tnode225809* n, Ttype225847* prev);
typedef struct {
N_NIMCALL_PTR(Tnode225809*, ClPrc) (Tcontext280023* c, Tidtable225859 pt, Tnode225809* n, void* ClEnv);
void* ClEnv;
} TY280126;
typedef struct {
N_NIMCALL_PTR(Tsym225841*, ClPrc) (Tcontext280023* c, Tsym225841* fn, Tidtable225859 pt, Tlineinfo190352 info, void* ClEnv);
void* ClEnv;
} TY280132;
struct  Tstrtable225813  {
NI counter;
Tsymseq225811* data;
};
typedef N_NIMCALL_PTR(Tsym225841*, TY280148) (Tcontext280023* c, Tsym225841* dc, Ttype225847* t, Tlineinfo190352 info, NU8 op);
struct  Tcontext280023  {
  Tpasscontext277005 Sup;
Tsym225841* module;
Tscope225835* currentscope;
Tscope225835* importtable;
Tscope225835* toplevelscope;
Tproccon280011* p;
Tsymseq225811* friendmodules;
NI instcounter;
Intset222056 ambiguoussymbols;
NI intypeclass;
NI ingenericcontext;
NI inunrolledcontext;
NI compilescontextid;
NI compilescontextidgenerator;
NI ingenericinst;
Tsymseq225811* converters;
Tsymseq225811* patterns;
Tlinkedlist140028 optionstack;
Tidtable225859 symmapping;
Tlinkedlist140028 libs;
TY280074 semconstexpr;
TY280079 semexpr;
TY280087 semtryexpr;
TY280095 semtryconstexpr;
TY280100 semoperand;
TY280108 semconstboolexpr;
TY280113 semoverloadedcall;
TY280120 semtypenode;
TY280126 seminferredlambda;
TY280132 semgenerateinstance;
Intset222056 includedfiles;
Tstrtable225813 userpragmas;
Tctx279048* evalcontext;
Intset222056 unknownidents;
TY280143* generics;
NI lastgenericidx;
NI hloloopdetector;
NI inparallelstmt;
TY280148 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;
} TY19211;
struct  TSafePoint  {
TSafePoint* prev;
NI status;
jmp_buf context;
NIM_BOOL hasRaiseAction;
TY19211 raiseAction;
};
struct  TNimNode  {
NU8 kind;
NI offset;
TNimType* typ;
NCSTRING name;
NI len;
TNimNode** sons;
};
struct  Cell48946  {
NI refcount;
TNimType* typ;
};
struct  Cellseq48962  {
NI len;
NI cap;
Cell48946** d;
};
struct  Cellset48958  {
NI counter;
NI max;
Pagedesc48954* head;
Pagedesc48954** data;
};
typedef Smallchunk30842* TY30905[512];
typedef Trunk30813* Trunkbuckets30815[256];
struct  Intset30817  {
Trunkbuckets30815 data;
};
struct  Memregion30890  {
NI minlargeobj;
NI maxlargeobj;
TY30905 freesmallchunks;
Llchunk30884* llmem;
NI currmem;
NI maxmem;
NI freemem;
NI lastsize;
Bigchunk30844* freechunkslist;
Intset30817 chunkstarts;
Avlnode30888* root;
Avlnode30888* deleted;
Avlnode30888* last;
Avlnode30888* freeavlnodes;
};
struct  Gcstat51014  {
NI stackscans;
NI cyclecollections;
NI maxthreshold;
NI maxstacksize;
NI maxstackcells;
NI cycletablesize;
NI64 maxpause;
};
struct  Gcheap51018  {
Gcstack51016* stack;
void* stackbottom;
NI cyclethreshold;
Cellseq48962 zct;
Cellseq48962 decstack;
Cellset48958 cycleroots;
Cellseq48962 tempstack;
NI recgclock;
Memregion30890 region;
Gcstat51014 stat;
};
struct  Tidobj198015  {
  TNimObject Sup;
NI id;
};
struct  Tloc225823  {
NU8 k;
NU8 s;
NU16 flags;
Ttype225847* t;
Ropeobj176009* r;
Ropeobj176009* heaproot;
};
struct  Tsym225841  {
  Tidobj198015 Sup;
NU8 kind;
union{
struct {Ttypeseq225843* typeinstcache;
Tscope225835* typscope;
} S1;
struct {TY225944* procinstcache;
Tsym225841* gcunsafetyreason;
} S2;
struct {TY225944* usedgenerics;
Tstrtable225813 tab;
} S3;
struct {Tsym225841* guard;
NI bitsize;
} S4;
} kindU;
NU8 magic;
Ttype225847* typ;
Tident198021* name;
Tlineinfo190352 info;
Tsym225841* owner;
NU32 flags;
Tnode225809* ast;
NU32 options;
NI position;
NI offset;
Tloc225823 loc;
Tlib225827* annex;
Tnode225809* constraint;
};
struct  Tscope225835  {
NI depthlevel;
Tstrtable225813 symbols;
Tnodeseq225803* usingsyms;
Tscope225835* parent;
};
struct  Ttabiter233119  {
NI h;
};
typedef N_CLOSURE_PTR(void, TMP2064) (Suggest395010* result);
struct  Suggest395010  {
NU8 section;
TY130408* qualifiedpath;
NimStringDesc* filepath;
NI line;
NI column;
NimStringDesc* doc;
NU8 symkind;
NimStringDesc* forth;
};
struct  Tident198021  {
  Tidobj198015 Sup;
NimStringDesc* s;
Tident198021* next;
NI h;
};
struct  Ttype225847  {
  Tidobj198015 Sup;
NU8 kind;
NU8 callconv;
NU32 flags;
Ttypeseq225843* sons;
Tnode225809* n;
Tsym225841* owner;
Tsym225841* sym;
Tsym225841* destructor;
Tsym225841* deepcopy;
Tsym225841* assignment;
NI64 size;
NI16 align;
NI16 locklevel;
Tloc225823 loc;
};
typedef struct {
N_NIMCALL_PTR(NI, ClPrc) (Tsym225841* x_396050, Tsym225841* y_396052, void* ClEnv);
void* ClEnv;
} TY396048;
typedef N_CLOSURE_PTR(NI, TMP2734) (Tsym225841* x_398037, Tsym225841* y_398039, void* ClEnv);
struct  Tcandidate388209  {
Tcontext280023* c;
NI exactmatches;
NI genericmatches;
NI subtypematches;
NI intconvmatches;
NI convmatches;
NU8 state;
Ttype225847* callee;
Tsym225841* calleesym;
NI calleescope;
Tnode225809* call;
Tidtable225859 bindings;
NIM_BOOL basetypematch;
NU8 fauxmatch;
NIM_BOOL genericconverter;
NIM_BOOL coercedistincts;
NIM_BOOL typedescmatched;
NIM_BOOL isnocall;
NI inheritancepenalty;
Tsymseq225811* errors;
};
typedef Ttype225847* TY393275[1];
struct TY90959 {
NimStringDesc* Field0;
NI Field1;
};
typedef N_CLOSURE_PTR(Tnode225809*, TMP2769) (Tcontext280023* c, Tidtable225859 pt, Tnode225809* n);
typedef N_CLOSURE_PTR(Tsym225841*, TMP2770) (Tcontext280023* c, Tsym225841* fn, Tidtable225859 pt, Tlineinfo190352 info);
typedef N_CLOSURE_PTR(Tnode225809*, TMP2773) (Tcontext280023* c, Tidtable225859 pt, Tnode225809* n);
typedef N_CLOSURE_PTR(Tsym225841*, TMP2774) (Tcontext280023* c, Tsym225841* fn, Tidtable225859 pt, Tlineinfo190352 info);
typedef N_CLOSURE_PTR(NI, TMP2784) (Tsym225841* x_396037, Tsym225841* y_396039, void* ClEnv);
typedef N_CLOSURE_PTR(Tsym225841*, TMP3638) (Tcontext280023* c, Tsym225841* fn, Tidtable225859 pt, Tlineinfo190352 info);
struct  Tproccon280011  {
Tsym225841* owner;
Tsym225841* resultsym;
NI nestedloopcounter;
NI nestedblockcounter;
NI intrystmt;
Tproccon280011* next;
NIM_BOOL wasforwarded;
Tnode225809* bracketexpr;
};
typedef NI TY30821[16];
struct  Trunk222052  {
Trunk222052* next;
NI key;
TY30821 bits;
};
struct  Tlistentry140022  {
  TNimObject Sup;
Tlistentry140022* prev;
Tlistentry140022* next;
};
struct  Tidpair225855  {
Tidobj198015* key;
TNimObject* val;
};
struct  Tctx279048  {
  Tpasscontext277005 Sup;
TY279254* code;
TY191420* debug;
Tnode225809* globals;
Tnode225809* constants;
Ttypeseq225843* types;
Tnode225809* currentexceptiona;
Tnode225809* currentexceptionb;
NI exceptioninstr;
PprocHEX3Aobjecttype279233* prc;
Tsym225841* module;
Tnode225809* callsite;
NU8 mode;
NU8 features;
NIM_BOOL traceactive;
NI loopiterations;
Tlineinfo190352 comesfromheuristic;
TY279273* callbacks;
NimStringDesc* errorflag;
};
struct  Tinstantiationpair280013  {
Tsym225841* genericsym;
Tinstantiation225831* inst;
};
struct  Gcstack51016  {
Gcstack51016* prev;
Gcstack51016* next;
void* starts;
void* pos;
NI maxstacksize;
};
struct  Pagedesc48954  {
Pagedesc48954* next;
NI key;
TY30821 bits;
};
struct  Basechunk30840  {
NI prevsize;
NI size;
NIM_BOOL used;
};
struct  Smallchunk30842  {
  Basechunk30840 Sup;
Smallchunk30842* next;
Smallchunk30842* prev;
Freecell30832* freelist;
NI free;
NI acc;
NF data;
};
struct  Llchunk30884  {
NI size;
NI acc;
Llchunk30884* next;
};
struct  Bigchunk30844  {
  Basechunk30840 Sup;
Bigchunk30844* next;
Bigchunk30844* prev;
NI align;
NF data;
};
struct  Trunk30813  {
Trunk30813* next;
NI key;
TY30821 bits;
};
typedef Avlnode30888* TY30895[2];
struct  Avlnode30888  {
TY30895 link;
NI key;
NI upperbound;
NI level;
};
struct  Ropeobj176009  {
  TNimObject Sup;
Ropeobj176009* left;
Ropeobj176009* right;
NI length;
NimStringDesc* data;
};
struct  Tlib225827  {
  Tlistentry140022 Sup;
NU8 kind;
NIM_BOOL generated;
NIM_BOOL isoverriden;
Ropeobj176009* name;
Tnode225809* path;
};
typedef N_NIMCALL_PTR(NimStringDesc*, Findfilehandler333023) (NimStringDesc* filename);
typedef N_NIMCALL_PTR(void, Msghandler333021) (NimStringDesc* filename, NI line, NI col, NU8 msgkind, NimStringDesc* arg);
typedef NimStringDesc* TY347045[5];
struct  Table347053  {
Keyvaluepairseq347056* data;
NI counter;
};
struct  Rstgenerator347016  {
  TNimObject Sup;
NU8 target;
Stringtableobj145212* config;
NI splitafter;
NI listingcounter;
TY347035* tocpart;
NIM_BOOL hastoc;
NimStringDesc* theindex;
NU8 options;
Findfilehandler333023 findfile;
Msghandler333021 msghandler;
NimStringDesc* filename;
TY347045 meta;
NimStringDesc* currentsection;
Table347053 seenindexterms;
};
typedef Ropeobj176009* Tsections384005[26];
struct  Tdocumentor384007  {
  Rstgenerator347016 Sup;
Ropeobj176009* moddesc;
NI id;
Tsections384005 toc;
Tsections384005 section;
NimStringDesc* indexvalfilename;
NimStringDesc* analytics;
Stringtableobj145212* seensymbols;
};
struct TY279239 {
NIM_BOOL Field0;
NU8 Field1;
};
typedef TY279239 TY279242[256];
struct  PprocHEX3Aobjecttype279233  {
TY279234* blocks;
Tsym225841* sym;
TY279242 slots;
NI maxslots;
};
typedef struct {
N_NIMCALL_PTR(void, ClPrc) (Vmargs279042* args, void* ClEnv);
void* ClEnv;
} Vmcallback279044;
struct TY279274 {
NimStringDesc* Field0;
Vmcallback279044 Field1;
};
struct  Tinstantiation225831  {
Tsym225841* sym;
Ttypeseq225843* concretetypes;
TY225932* usedby;
NI compilesid;
};
struct  Freecell30832  {
Freecell30832* next;
NI zerofield;
};
struct  Stringtableobj145212  {
  TNimObject Sup;
NI counter;
Keyvaluepairseq145210* data;
NU8 mode;
};
struct  Tocentry347012  {
Rstnode332011* n;
NimStringDesc* refname;
NimStringDesc* header;
};
struct Keyvaluepair347059 {
NI Field0;
NimStringDesc* Field1;
NI Field2;
};
struct  Tblock279030  {
Tsym225841* label;
TY279214* fixups;
};
struct  Vmargs279042  {
NI ra;
NI rb;
NI rc;
void* slots;
Tnode225809* currentexception;
};
struct Keyvaluepair145208 {
NimStringDesc* Field0;
NimStringDesc* Field1;
};
struct  Rstnode332011  {
NU8 kind;
NimStringDesc* text;
NI level;
Rstnodeseq332009* sons;
};
struct TY130408 {
  TGenericSeq Sup;
  NimStringDesc* data[SEQ_DECL_SIZE];
};
struct Tsymseq225811 {
  TGenericSeq Sup;
  Tsym225841* data[SEQ_DECL_SIZE];
};
struct Ttypeseq225843 {
  TGenericSeq Sup;
  Ttype225847* data[SEQ_DECL_SIZE];
};
struct Tnodeseq225803 {
  TGenericSeq Sup;
  Tnode225809* data[SEQ_DECL_SIZE];
};
struct Trunkseq222054 {
  TGenericSeq Sup;
  Trunk222052* data[SEQ_DECL_SIZE];
};
struct Tidpairseq225857 {
  TGenericSeq Sup;
  Tidpair225855 data[SEQ_DECL_SIZE];
};
struct TY280143 {
  TGenericSeq Sup;
  Tinstantiationpair280013 data[SEQ_DECL_SIZE];
};
struct TY225944 {
  TGenericSeq Sup;
  Tinstantiation225831* data[SEQ_DECL_SIZE];
};
struct TY279254 {
  TGenericSeq Sup;
  NU32 data[SEQ_DECL_SIZE];
};
struct TY191420 {
  TGenericSeq Sup;
  Tlineinfo190352 data[SEQ_DECL_SIZE];
};
struct TY279273 {
  TGenericSeq Sup;
  TY279274 data[SEQ_DECL_SIZE];
};
struct TY347035 {
  TGenericSeq Sup;
  Tocentry347012 data[SEQ_DECL_SIZE];
};
struct Keyvaluepairseq347056 {
  TGenericSeq Sup;
  Keyvaluepair347059 data[SEQ_DECL_SIZE];
};
struct TY279234 {
  TGenericSeq Sup;
  Tblock279030 data[SEQ_DECL_SIZE];
};
struct TY225932 {
  TGenericSeq Sup;
  NI32 data[SEQ_DECL_SIZE];
};
struct Keyvaluepairseq145210 {
  TGenericSeq Sup;
  Keyvaluepair145208 data[SEQ_DECL_SIZE];
};
struct TY279214 {
  TGenericSeq Sup;
  NI data[SEQ_DECL_SIZE];
};
struct Rstnodeseq332009 {
  TGenericSeq Sup;
  Rstnode332011* data[SEQ_DECL_SIZE];
};
N_NIMCALL(NU8, incheckpoint_398413)(Tlineinfo190352 current);
N_NIMCALL(Tnode225809*, findclosestdot_398420)(Tnode225809* n);
static N_INLINE(NI, safelen_226126)(Tnode225809* n);
N_NIMCALL(Tnode225809*, safesemexpr_398857)(Tcontext280023* c, Tnode225809* 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_55022)(Cell48946* c);
static N_INLINE(NIM_BOOL, canbecycleroot_52667)(Cell48946* c);
static N_INLINE(void, rtladdcycleroot_53423)(Cell48946* c);
N_NOINLINE(void, incl_49665)(Cellset48958* s, Cell48946* cell);
static N_INLINE(Cell48946*, usrtocell_52646)(void* usr);
static N_INLINE(void, decref_54604)(Cell48946* c);
static N_INLINE(void, rtladdzct_54204)(Cell48946* c);
N_NOINLINE(void, addzct_52617)(Cellseq48962* s, Cell48946* c);
N_NIMCALL(void, reraiseException)(void);
N_NIMCALL(void, suggestfieldaccess_398201)(Tcontext280023* c, Tnode225809* n, NI* outputs);
N_NIMCALL(Tsym225841*, inittabiter_233124)(Ttabiter233119* ti, Tstrtable225813 tab);
static N_INLINE(NIM_BOOL, filtersym_395427)(Tsym225841* s);
N_NIMCALL(void, suggestresult_395414)(Suggest395010* s);
N_NIMCALL(void, suggestwriteln_191453)(NimStringDesc* s);
N_NIMCALL(NimStringDesc*, HEX24_395205)(Suggest395010* suggest);
N_NIMCALL(NimStringDesc*, HEX24_168755)(NU8 c);
N_NIMCALL(NimStringDesc*, addChar)(NimStringDesc* s, NIM_CHAR c);
N_NIMCALL(NimStringDesc*, reprEnum)(NI e_86859, TNimType* typ);
static N_INLINE(void, appendString)(NimStringDesc* dest, NimStringDesc* src);
N_NIMCALL(NimStringDesc*, resizeString)(NimStringDesc* dest, NI addlen);
N_NIMCALL(NimStringDesc*, nsuJoinSep)(NimStringDesc** a, NI aLen0, NimStringDesc* sep);
N_NIMCALL(NimStringDesc*, nimIntToStr)(NI x);
N_NIMCALL(NimStringDesc*, nsuEscape)(NimStringDesc* s, NimStringDesc* prefix, NimStringDesc* suffix);
N_NIMCALL(void, symtosuggest_395404)(Tsym225841* s, NIM_BOOL islocal, NimStringDesc* section, Suggest395010* Result);
N_NIMCALL(void, symtosuggest_395027)(Tsym225841* s, NIM_BOOL islocal, NimStringDesc* section, Tlineinfo190352 li, Suggest395010* Result);
N_NIMCALL(NU8, parseidecmd_168745)(NimStringDesc* s);
N_NIMCALL(NimStringDesc*, tofullpath_191665)(NI32 fileidx);
N_NIMCALL(void, unsureAsgnRef)(void** dest, void* src);
static N_INLINE(NI, tolinenumber_191839)(Tlineinfo190352 info);
static N_INLINE(NI, tocolumn_191849)(Tlineinfo190352 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_255032)(Ttype225847* typ, NU8 prefer);
N_NIMCALL(NimStringDesc*, copyString)(NimStringDesc* src);
N_NIMCALL(NimStringDesc*, extractdoccomment_384609)(Tsym225841* s, Tdocumentor384007* d);
N_NOINLINE(void, chckNil)(void* p);
N_NIMCALL(void, genericReset)(void* dest, TNimType* mt);
N_NIMCALL(Tsym225841*, nextiter_233132)(Ttabiter233119* ti, Tstrtable225813 tab);
N_NIMCALL(void, suggesteverything_398128)(Tcontext280023* c, Tnode225809* n, NI* outputs);
N_NIMCALL(void, suggestsymlist_395667)(Tcontext280023* c, Tnode225809* list, NI* outputs);
N_NIMCALL(NI, sonslen_228387)(Tnode225809* n);
N_NIMCALL(void, suggestfield_395632)(Tcontext280023* c, Tsym225841* s, NI* outputs);
static N_INLINE(NIM_BOOL, fieldvisible_395471)(Tcontext280023* c, Tsym225841* f);
N_NIMCALL(Tsym225841*, getmodule_233243)(Tsym225841* s);
N_NIMCALL(void, suggestoperations_397636)(Tcontext280023* c, Tnode225809* n, Ttype225847* typ, NI* outputs);
static N_INLINE(void, asgnRefNoCycle)(void** dest, void* src);
N_NIMCALL(void, genericSeqAssign)(void* dest, void* src_85804, TNimType* mt);
N_NIMCALL(void, sort_396041)(Tsym225841** a, NI aLen0, TY396048 cmp, NU8 order);
N_NIMCALL(NI, HEX3Aanonymous_398030)(Tsym225841* a_397808, Tsym225841* b_397810);
N_NIMCALL(NI, cmp_6577)(NimStringDesc* x, NimStringDesc* y);
static N_INLINE(NIM_BOOL, filtersymnoopr_395443)(Tsym225841* s);
N_NIMCALL(NIM_BOOL, iskeyword_247101)(Tident198021* i);
static N_INLINE(NIM_BOOL, typefits_397542)(Tcontext280023* c, Tsym225841* s, Ttype225847* firstarg);
N_NIMCALL(NI, sonslen_228351)(Ttype225847* n);
N_NIMCALL(Ttype225847*, skiptypes_229167)(Ttype225847* t, NU64 kinds);
N_NIMCALL(Ttype225847*, elemtype_255522)(Ttype225847* t);
N_NIMCALL(NIM_BOOL, argtypematches_394817)(Tcontext280023* c, Ttype225847* f, Ttype225847* a);
N_NIMCALL(void, initcandidate_388278)(Tcontext280023* ctx, Tcandidate388209* c, Ttype225847* callee);
static N_INLINE(void, initcandidateaux_388266)(Tcontext280023* ctx, Tcandidate388209* c, Ttype225847* callee);
N_NIMCALL(void, initidtable_229057)(Tidtable225859* x);
N_NIMCALL(Tnode225809*, paramtypesmatch_393733)(Tcandidate388209* m, Ttype225847* f, Ttype225847* a, Tnode225809* arg, Tnode225809* argorig);
N_NIMCALL(Tnode225809*, paramtypesmatchaux_393191)(Tcandidate388209* m, Ttype225847* f, Ttype225847* argtype_393196, Tnode225809* argsemantized, Tnode225809* argorig);
N_NIMCALL(void, assigntype_228445)(Ttype225847* dest, Ttype225847* src);
N_NIMCALL(Tnode225809*, newnodeit_227807)(NU8 kind, Tlineinfo190352 info, Ttype225847* typ);
N_NIMCALL(Ttype225847*, maketypefromexpr_280729)(Tcontext280023* c, Tnode225809* n);
N_NIMCALL(Ttype225847*, newtypes_280221)(NU8 kind, Tcontext280023* c);
N_NIMCALL(void*, newSeqRC1)(TNimType* typ, NI len);
N_NIMCALL(NU8, typerel_389064)(Tcandidate388209* c, Ttype225847* f, Ttype225847* aorig, NIM_BOOL dobind);
static N_INLINE(void, put_388291)(Tidtable225859* t, Ttype225847* key, Ttype225847* val);
N_NIMCALL(void, idtableput_233196)(Tidtable225859* t, Tidobj198015* key, TNimObject* val);
static N_INLINE(Ttype225847*, skipintlit_274696)(Ttype225847* t);
N_NIMCALL(Ttype225847*, getsystype_274190)(NU8 kind);
N_NIMCALL(Ttype225847*, maybeskipdistinct_390517)(Ttype225847* t, Tsym225841* callee);
N_NIMCALL(NIM_BOOL, shouldskipdistinct_390425)(Tnode225809* rules, Tident198021* callident);
static N_INLINE(NI, len_226098)(Tnode225809* n);
N_NIMCALL(Tident198021*, considerquotedident_286010)(Tnode225809* n);
N_NIMCALL(Ttype225847*, base_255039)(Ttype225847* t);
N_NIMCALL(Ttype225847*, lastson_228426)(Ttype225847* n);
static N_INLINE(NIM_BOOL, sameenumtypes_260855)(Ttype225847* a, Ttype225847* b);
static N_INLINE(Tnode225809*, HEX5BHEX5D_226244)(Tnode225809* n, NI i);
N_NIMCALL(Tnode225809*, tryresolvingstaticexpr_390562)(Tcandidate388209* c, Tnode225809* n);
N_NIMCALL(Tnode225809*, replacetypesinbody_304862)(Tcontext280023* p, Tidtable225859 pt, Tnode225809* n, Tsym225841* owner);
N_NOINLINE(NU8, typerangerel_390234)(Ttype225847* f, Ttype225847* a);
N_NIMCALL(NI64, firstord_255004)(Ttype225847* t);
N_NIMCALL(NI64, lastord_255010)(Ttype225847* t);
N_NIMCALL(NIM_BOOL, isconvertibletorange_389238)(Ttype225847* f, Ttype225847* a);
N_NIMCALL(NU8, handlerange_389122)(Ttype225847* f, Ttype225847* a, NU8 min, NU8 max);
static N_INLINE(NIM_BOOL, isintlit_255327)(Ttype225847* t);
N_NIMCALL(NU8, handlefloatrange_389293)(Ttype225847* f, Ttype225847* a);
static N_INLINE(NIM_BOOL, isfloatlit_255367)(Ttype225847* t);
N_NIMCALL(TNimObject*, idtableget_233182)(Tidtable225859 t, Tidobj198015* key);
N_NIMCALL(Ttype225847*, newtypewithsons_280807)(Tcontext280023* c, NU8 kind, Ttypeseq225843* sons);
N_NIMCALL(Tnode225809*, newintnode_226608)(NU8 kind, NI64 intval);
N_NIMCALL(NI64, lengthord_255016)(Ttype225847* t);
N_NIMCALL(NI, len_228369)(Ttype225847* n);
static N_INLINE(NU8, allowsnil_389833)(Ttype225847* f);
N_NIMCALL(NIM_BOOL, isordinaltype_255093)(Ttype225847* t);
N_NIMCALL(void, internalerror_196191)(NimStringDesc* errmsg);
N_NIMCALL(NU8, recordrel_389668)(Tcandidate388209* c, Ttype225847* f, Ttype225847* a);
N_NIMCALL(NIM_BOOL, sametype_260092)(Ttype225847* a, Ttype225847* b, NU8 flags);
N_NIMCALL(NU8, minrel_389648)(NU8 a, NU8 b);
N_NIMCALL(void, internalerror_196172)(Tlineinfo190352 info, NimStringDesc* errmsg);
N_NIMCALL(NIM_BOOL, sameobjecttypes_260785)(Ttype225847* a, Ttype225847* b);
N_NIMCALL(NI, isobjectsubtype_389352)(Ttype225847* a, Ttype225847* f);
static N_INLINE(NIM_BOOL, samedistincttypes_260844)(Ttype225847* a, Ttype225847* b);
N_NIMCALL(NU8, proctyperel_389950)(Tcandidate388209* c, Ttype225847* f, Ttype225847* a);
N_NIMCALL(NU8, procparamtyperel_389891)(Tcandidate388209* c, Ttype225847* f_389895, Ttype225847* a_389896);
N_NIMCALL(NIM_BOOL, ismetatype_226821)(Ttype225847* t);
N_NIMCALL(Ttype225847*, generatetypeinstance_304894)(Tcontext280023* p, Tidtable225859 pt, Tlineinfo190352 info, Ttype225847* t);
static N_INLINE(NIM_BOOL, inconsistentvartypes_389853)(Ttype225847* f, Ttype225847* a);
N_NIMCALL(NIM_BOOL, compatibleeffects_264489)(Ttype225847* formal, Ttype225847* actual);
N_NIMCALL(Ttype225847*, skipgenericalias_261119)(Ttype225847* t);
N_NIMCALL(Ttype225847*, concretetype_389074)(Tcandidate388209* c, Ttype225847* t);
N_NIMCALL(Ttype225847*, newtype_228140)(NU8 kind, Tsym225841* owner);
N_NIMCALL(void, addsonskipintlit_274729)(Ttype225847* father, Ttype225847* son);
N_NIMCALL(NimStringDesc*, rawNewString)(NI space);
N_NIMCALL(NU8, matchusertypeclass_390249)(Tcontext280023* c, Tcandidate388209* m, Ttype225847* ff, Ttype225847* a);
N_NIMCALL(void, localerror_196139)(Tlineinfo190352 info, NimStringDesc* arg);
N_NIMCALL(NimStringDesc*, HEX24_247090)(Tnode225809* n);
N_NIMCALL(Tscope225835*, openscope_286091)(Tcontext280023* c);
N_NIMCALL(Tsym225841*, newsym_226656)(NU8 symkind, Tident198021* name, Tsym225841* owner, Tlineinfo190352 info);
N_NIMCALL(Ttype225847*, maketypedesc_280684)(Tcontext280023* c, Ttype225847* typ);
N_NIMCALL(void, adddecl_286607)(Tcontext280023* c, Tsym225841* sym);
N_NIMCALL(Ttype225847*, makevartype_280645)(Tcontext280023* c, Ttype225847* basetype);
N_NIMCALL(NimStringDesc*, HEX24_196279)(TY90959 x);
N_NIMCALL(Tnode225809*, copytree_230028)(Tnode225809* src);
N_NIMCALL(void, closescope_286111)(Tcontext280023* c);
N_NIMCALL(NIM_BOOL, HEX3DHEX3D_264739)(Ttypeseq225843* x, Ttypeseq225843* y);
N_NIMCALL(NIM_BOOL, exprstructuralequivalent_254149)(Tnode225809* a, Tnode225809* b, NIM_BOOL strictsymequality);
N_NIMCALL(void, localerror_196128)(Tlineinfo190352 info, NU16 msg, NimStringDesc* arg);
N_NIMCALL(void, incmatches_393124)(Tcandidate388209* m, NU8 r, NI convmatch);
N_NIMCALL(NIM_BOOL, isinlineiterator_393087)(Ttype225847* t);
N_NIMCALL(Tnode225809*, newsymnode_227338)(Tsym225841* sym, Tlineinfo190352 info);
N_NIMCALL(Tnode225809*, implicitconv_392849)(NU8 kind, Ttype225847* f, Tnode225809* arg, Tcandidate388209* m, Tcontext280023* c);
N_NIMCALL(Tnode225809*, newnodei_227351)(NU8 kind, Tlineinfo190352 info);
N_NIMCALL(NIM_BOOL, containsgenerictype_264310)(Ttype225847* t);
N_NIMCALL(Ttype225847*, getinstantiatedtype_392812)(Tcontext280023* c, Tnode225809* arg, Tcandidate388209* m, Ttype225847* f);
N_NIMCALL(Ttype225847*, errortype_281161)(Tcontext280023* c);
N_NIMCALL(void, addson_227819)(Tnode225809* father, Tnode225809* son);
N_NIMCALL(NIM_BOOL, isemptycontainer_264978)(Ttype225847* t);
N_NIMCALL(Tnode225809*, userconvmatch_392884)(Tcontext280023* c, Tcandidate388209* m, Ttype225847* f, Ttype225847* a, Tnode225809* arg);
N_NIMCALL(void, markused_388253)(Tlineinfo190352 info, Tsym225841* s);
N_NIMCALL(void, message_196161)(Tlineinfo190352 info, NU16 msg, NimStringDesc* arg);
static N_INLINE(void, suggestsym_398733)(Tlineinfo190352 info, Tsym225841* s);
N_NIMCALL(void, findusages_398665)(Tlineinfo190352 info, Tsym225841* s);
N_NIMCALL(NIM_BOOL, istracked_398569)(Tlineinfo190352 current, NI tokenlen);
N_NIMCALL(NIM_BOOL, HEX3DHEX3D_193255)(Tlineinfo190352 a, Tlineinfo190352 b);
N_NIMCALL(void, finddefinition_398696)(Tlineinfo190352 info, Tsym225841* s);
N_NIMCALL(void, suggestquit_191509)(void);
N_NIMCALL(Tnode225809*, newsymnode_227325)(Tsym225841* sym);
N_NIMCALL(Tnode225809*, localconvmatch_392990)(Tcontext280023* c, Tcandidate388209* m, Ttype225847* f, Ttype225847* a, Tnode225809* arg);
N_NIMCALL(void, add_226165)(Tnode225809* father, Tnode225809* son);
N_NIMCALL(void, copycandidate_388492)(Tcandidate388209* a, Tcandidate388209* b);
N_NIMCALL(void, copyidtable_227091)(Tidtable225859* dest, Tidtable225859 src);
N_NIMCALL(void, genericAssign)(void* dest, void* src, TNimType* mt);
N_NIMCALL(NI, cmpcandidates_388824)(Tcandidate388209* a, Tcandidate388209* b);
N_NIMCALL(NI, complexdisambiguation_388639)(Ttype225847* a, Ttype225847* b);
N_NIMCALL(NI, sumgeneric_388504)(Ttype225847* t_388506);
N_NIMCALL(void, suggestobject_395718)(Tcontext280023* c, Tnode225809* n, NI* outputs);
N_NIMCALL(Tnode225809*, lastson_228406)(Tnode225809* n);
N_NIMCALL(NimStringDesc*, rendertree_247059)(Tnode225809* n, NU8 renderflags);
N_NIMCALL(Tnode225809*, findclosestcall_398494)(Tnode225809* n);
N_NIMCALL(Tnode225809*, copynode_229660)(Tnode225809* src);
N_NIMCALL(void, suggestcall_395844)(Tcontext280023* c, Tnode225809* n, Tnode225809* norig, NI* outputs);
N_NIMCALL(NI, HEX3Aanonymous_396030)(Tsym225841* a_395858, Tsym225841* b_395860);
N_NIMCALL(NIM_BOOL, namefits_395792)(Tcontext280023* c, Tsym225841* s, Tnode225809* n);
N_NIMCALL(NIM_BOOL, argsfit_395821)(Tcontext280023* c, Tsym225841* candidate, Tnode225809* n, Tnode225809* norig);
N_NIMCALL(void, initcandidate_388303)(Tcontext280023* ctx, Tcandidate388209* c, Tsym225841* callee, Tnode225809* binding, NI calleescope);
N_NIMCALL(Tsym225841*, originatingmodule_230735)(Tsym225841* s);
N_NIMCALL(Tsym225841*, skipgenericowner_230694)(Tsym225841* s);
N_NIMCALL(void, partialmatch_394705)(Tcontext280023* c, Tnode225809* n, Tnode225809* norig, Tcandidate388209* m);
N_NIMCALL(void, initintset_222927)(Intset222056* Result);
N_NIMCALL(void, matchesaux_394231)(Tcontext280023* c, Tnode225809* n, Tnode225809* norig, Tcandidate388209* m, Intset222056* marker);
N_NIMCALL(Ttype225847*, arrayconstr_394148)(Tcontext280023* c, Tlineinfo190352 info);
N_NIMCALL(void, rawaddson_229498)(Ttype225847* father, Ttype225847* son);
N_NIMCALL(Ttype225847*, makerangetype_281193)(Tcontext280023* c, NI64 first, NI64 last, Tlineinfo190352 info, Ttype225847* inttype);
N_NIMCALL(void, setson_394029)(Tnode225809* father, NI at, Tnode225809* son);
N_NIMCALL(TGenericSeq*, setLengthSeq)(TGenericSeq* seq, NI elemsize, NI newlen);
N_NIMCALL(void, incrindextype_394159)(Ttype225847* t);
N_NIMCALL(void, preparenamedparam_394113)(Tnode225809* a);
N_NIMCALL(Tnode225809*, newidentnode_227313)(Tident198021* ident, Tlineinfo190352 info);
N_NIMCALL(Tsym225841*, getsymfromlist_233228)(Tnode225809* list, Tident198021* ident, NI start);
N_NIMCALL(NIM_BOOL, containsorincl_222898)(Intset222056* s, NI key);
N_NIMCALL(Tnode225809*, prepareoperand_394052)(Tcontext280023* c, Ttype225847* formal, Tnode225809* a);
N_NIMCALL(NIM_BOOL, matchnodekinds_306302)(Tnode225809* p, Tnode225809* n);
N_NIMCALL(NIM_BOOL, islvalue_306281)(Tnode225809* n);
N_NIMCALL(Ttype225847*, arrayconstr_394136)(Tcontext280023* c, Tnode225809* n);
N_NIMCALL(Tnode225809*, prepareoperand_394093)(Tcontext280023* c, Tnode225809* a);
N_NIMCALL(NimStringDesc*, argtypetostring_388916)(Tnode225809* arg, NU8 prefer);
N_NIMCALL(void, suggestexpr_398865)(Tcontext280023* c, Tnode225809* node);
STRING_LITERAL(TMP2072, ".", 1);
STRING_LITERAL(TMP2077, "\"", 1);
STRING_LITERAL(TMP2201, "", 0);
STRING_LITERAL(TMP2755, "forward type in typeRel()", 25);
STRING_LITERAL(TMP2756, "recordRel", 9);
STRING_LITERAL(TMP2759, "wrong instantiated type!", 24);
STRING_LITERAL(TMP2760, "cannot resolve type: ", 21);
STRING_LITERAL(TMP2761, " too nested for type matching", 29);
STRING_LITERAL(TMP2765, "compiler/sigmatch.nim", 21);
NIM_CONST TY90959 TMP2764 = {((NimStringDesc*) &TMP2765),
((NI) 562)}
;
NIM_CONST TY90959 TMP2767 = {((NimStringDesc*) &TMP2765),
((NI) 1058)}
;
STRING_LITERAL(TMP2768, " unknown type kind ", 19);
STRING_LITERAL(TMP2771, "getInstantiatedType", 19);
STRING_LITERAL(TMP2772, "implicitConv", 12);
STRING_LITERAL(TMP2781, "x.state is not csMatch", 22);
STRING_LITERAL(TMP2782, "expression ", 11);
STRING_LITERAL(TMP2783, " has type ", 10);
NIM_CONST TY90959 TMP2787 = {((NimStringDesc*) &TMP2765),
((NI) 124)}
;
STRING_LITERAL(TMP2789, "matches", 7);
STRING_LITERAL(TMP3135, ": ", 2);
STRING_LITERAL(TMP3136, " | ", 3);
STRING_LITERAL(TMP3137, ", ", 2);
STRING_LITERAL(TMP3637, "cannot instantiate \'deepCopy\'", 29);
TY395020 suggestionresulthook_395023;
Tsym225841* usagesym_398663;
Tlineinfo190352 lastlineinfo_398664;
extern Tlineinfo190352 gtrackpos_191901;
extern NU8 gidecmd_167119;
extern TSafePoint* exchandler_20843;
extern TNimType NTI190358; /* ERecoverableError */
extern Exception* currexception_20845;
extern Tnode225809* emptynode_226807;
extern Gcheap51018 gch_51059;
extern TNimType NTI225441; /* TSymKind */
extern NU32 gglobaloptions_167132;
extern TNimType NTI130408; /* seq[string] */
TNimType NTI395010; /* Suggest */
extern TNimType NTI167029; /* IdeCmd */
extern TNimType NTI149; /* string */
extern TNimType NTI108; /* int */
extern TNimType NTI225811; /* TSymSeq */
extern TNimType NTI225843; /* TTypeSeq */
extern TNimType NTI225262; /* TTypeKind */
TNimType NTI388209; /* TCandidate */
extern TNimType NTI280021; /* PContext */
TNimType NTI388205; /* TCandidateState */
extern TNimType NTI225805; /* PType */
extern TNimType NTI225807; /* PSym */
extern TNimType NTI225801; /* PNode */
extern TNimType NTI225859; /* TIdTable */
extern TNimType NTI138; /* bool */

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

static N_INLINE(NI, safelen_226126)(Tnode225809* 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(Tnode225809*, findclosestdot_398420)(Tnode225809* n) {
	Tnode225809* result;
{	result = 0;
	{
		NIM_BOOL LOC3;
		NU8 LOC5;
		LOC3 = 0;
		LOC3 = ((*n).kind == ((NU8) 45));
		if (!(LOC3)) goto LA4;
		LOC5 = 0;
		LOC5 = incheckpoint_398413((*n).info);
		LOC3 = (LOC5 == ((NU8) 2));
		LA4: ;
		if (!LOC3) goto LA6;
		result = n;
	}
	goto LA1;
	LA6: ;
	{
		{
			NI i_398460;
			NI HEX3Atmp_398475;
			NI LOC10;
			NI res_398478;
			i_398460 = 0;
			HEX3Atmp_398475 = 0;
			LOC10 = 0;
			LOC10 = safelen_226126(n);
			HEX3Atmp_398475 = (LOC10 - 1);
			res_398478 = ((NI) 0);
			{
				while (1) {
					if (!(res_398478 <= HEX3Atmp_398475)) goto LA12;
					i_398460 = res_398478;
					result = findclosestdot_398420((*n).kindU.S6.sons->data[i_398460]);
					{
						if (!!((result == NIM_NIL))) goto LA15;
						goto BeforeRet;
					}
					LA15: ;
					res_398478 += ((NI) 1);
				} LA12: ;
			}
		}
	}
	LA1: ;
	}BeforeRet: ;
	return result;
}

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

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

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

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

static N_INLINE(void, rtladdcycleroot_53423)(Cell48946* c) {
	{
		if (!!((((NI) ((NI)((*c).refcount & ((NI) 3)))) == ((NI) 3)))) goto LA3;
		(*c).refcount = (NI)((NI)((*c).refcount & ((NI) -4)) | ((NI) 3));
		incl_49665((&gch_51059.cycleroots), c);
	}
	LA3: ;
}

static N_INLINE(void, incref_55022)(Cell48946* c) {
	(*c).refcount = (NI)((NU32)((*c).refcount) + (NU32)(((NI) 8)));
	{
		NIM_BOOL LOC3;
		LOC3 = 0;
		LOC3 = canbecycleroot_52667(c);
		if (!LOC3) goto LA4;
		rtladdcycleroot_53423(c);
	}
	LA4: ;
}

static N_INLINE(Cell48946*, usrtocell_52646)(void* usr) {
	Cell48946* result;
	result = 0;
	result = ((Cell48946*) ((NI)((NU32)(((NI) (usr))) - (NU32)(((NI)sizeof(Cell48946))))));
	return result;
}

static N_INLINE(void, rtladdzct_54204)(Cell48946* c) {
	addzct_52617((&gch_51059.zct), c);
}

static N_INLINE(void, decref_54604)(Cell48946* c) {
	{
		(*c).refcount -= ((NI) 8);
		if (!((NU32)((*c).refcount) < (NU32)(((NI) 8)))) goto LA3;
		rtladdzct_54204(c);
	}
	goto LA1;
	LA3: ;
	{
		NIM_BOOL LOC6;
		LOC6 = 0;
		LOC6 = canbecycleroot_52667(c);
		if (!LOC6) goto LA7;
		rtladdcycleroot_53423(c);
	}
	goto LA1;
	LA7: ;
	LA1: ;
}

static N_INLINE(void, asgnRef)(void** dest, void* src) {
	{
		Cell48946* LOC5;
		if (!!((src == NIM_NIL))) goto LA3;
		LOC5 = 0;
		LOC5 = usrtocell_52646(src);
		incref_55022(LOC5);
	}
	LA3: ;
	{
		Cell48946* LOC10;
		if (!!(((*dest) == NIM_NIL))) goto LA8;
		LOC10 = 0;
		LOC10 = usrtocell_52646((*dest));
		decref_54604(LOC10);
	}
	LA8: ;
	(*dest) = src;
}

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

N_NIMCALL(Tnode225809*, safesemexpr_398857)(Tcontext280023* c, Tnode225809* n) {
	Tnode225809* volatile result;
	TSafePoint TMP2063;
	result = 0;
	pushSafePoint(&TMP2063);
	TMP2063.status = setjmp(TMP2063.context);
	if (TMP2063.status == 0) {
		result = (*c).semexpr(c, n, 0);
		popSafePoint();
	}
	else {
		popSafePoint();
		if (isObj(getCurrentException()->Sup.m_type, (&NTI190358))) {
			TMP2063.status = 0;
			result = emptynode_226807;
			popCurrentException();
		}
	}
	if (TMP2063.status != 0) reraiseException();
	return result;
}

static N_INLINE(NIM_BOOL, filtersym_395427)(Tsym225841* 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_395205)(Suggest395010* suggest) {
	NimStringDesc* result;
	NimStringDesc* LOC1;
	NimStringDesc* LOC2;
	NimStringDesc* LOC3;
	NimStringDesc* LOC4;
	result = 0;
	result = HEX24_168755((*suggest).section);
	result = addChar(result, 9);
	result = resizeString(result, reprEnum((*suggest).symkind, (&NTI225441))->Sup.len + 0);
appendString(result, reprEnum((*suggest).symkind, (&NTI225441)));
	result = addChar(result, 9);
	LOC1 = 0;
	LOC1 = nsuJoinSep((*suggest).qualifiedpath->data, (*suggest).qualifiedpath->Sup.len, ((NimStringDesc*) &TMP2072));
	result = resizeString(result, LOC1->Sup.len + 0);
appendString(result, LOC1);
	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);
	LOC2 = 0;
	LOC2 = nimIntToStr((*suggest).line);
	result = resizeString(result, LOC2->Sup.len + 0);
appendString(result, LOC2);
	result = addChar(result, 9);
	LOC3 = 0;
	LOC3 = nimIntToStr((*suggest).column);
	result = resizeString(result, LOC3->Sup.len + 0);
appendString(result, LOC3);
	result = addChar(result, 9);
	LOC4 = 0;
	LOC4 = nsuEscape((*suggest).doc, ((NimStringDesc*) &TMP2077), ((NimStringDesc*) &TMP2077));
	result = resizeString(result, LOC4->Sup.len + 0);
appendString(result, LOC4);
	return result;
}

N_NIMCALL(void, suggestresult_395414)(Suggest395010* s) {
	{
		if (!!(suggestionresulthook_395023.ClPrc == 0)) goto LA3;
		suggestionresulthook_395023.ClEnv? suggestionresulthook_395023.ClPrc(s, suggestionresulthook_395023.ClEnv):((TMP2064)(suggestionresulthook_395023.ClPrc))(s);
	}
	goto LA1;
	LA3: ;
	{
		NimStringDesc* LOC6;
		LOC6 = 0;
		LOC6 = HEX24_395205(s);
		suggestwriteln_191453(LOC6);
	}
	LA1: ;
}

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

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

static N_INLINE(void, nimGCunrefNoCycle)(void* p) {
	Cell48946* c;
	c = usrtocell_52646(p);
	{
		(*c).refcount -= ((NI) 8);
		if (!((NU32)((*c).refcount) < (NU32)(((NI) 8)))) goto LA3;
		rtladdzct_54204(c);
	}
	LA3: ;
}

N_NIMCALL(void, symtosuggest_395027)(Tsym225841* s, NIM_BOOL islocal, NimStringDesc* section, Tlineinfo190352 li, Suggest395010* Result) {
	(*Result).section = parseidecmd_168745(section);
	{
		if (!((gglobaloptions_167132 &(1<<((((NU8) 30))&31)))!=0)) goto LA3;
		(*Result).symkind = (*s).kind;
		unsureAsgnRef((void**) (&(*Result).filepath), tofullpath_191665(li.fileindex));
		(*Result).line = tolinenumber_191839(li);
		(*Result).column = tocolumn_191849(li);
	}
	goto LA1;
	LA3: ;
	{
		NimStringDesc* LOC20;
		(*Result).symkind = (*s).kind;
		unsureAsgnRef((void**) (&(*Result).qualifiedpath), (TY130408*) newSeq((&NTI130408), 0));
		{
			NIM_BOOL LOC8;
			Tsym225841* 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;
				Tsym225841* 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 = (TY130408*) 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 = (TY130408*) 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 = (TY130408*) 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_255032((*s).typ, ((NU8) 0)));
		}
		goto LA21;
		LA23: ;
		{
			unsureAsgnRef((void**) (&(*Result).forth), copyString(((NimStringDesc*) &TMP2201)));
		}
		LA21: ;
		unsureAsgnRef((void**) (&(*Result).filepath), tofullpath_191665(li.fileindex));
		(*Result).line = tolinenumber_191839(li);
		(*Result).column = tocolumn_191849(li);
		unsureAsgnRef((void**) (&(*Result).doc), extractdoccomment_384609(s, NIM_NIL));
	}
	LA1: ;
}

N_NIMCALL(void, symtosuggest_395404)(Tsym225841* s, NIM_BOOL islocal, NimStringDesc* section, Suggest395010* Result) {
	chckNil((void*)Result);
	genericReset((void*)Result, (&NTI395010));
	symtosuggest_395027(s, islocal, section, (*s).info, Result);
}

N_NIMCALL(void, suggesteverything_398128)(Tcontext280023* c, Tnode225809* n, NI* outputs) {
	NIM_BOOL islocal;
	islocal = NIM_TRUE;
	{
		Tscope225835* scope_398135;
		Tscope225835* HEX3Atmp_398176;
		Tscope225835* current_398179;
		scope_398135 = 0;
		HEX3Atmp_398176 = 0;
		HEX3Atmp_398176 = (*c).currentscope;
		current_398179 = HEX3Atmp_398176;
		{
			while (1) {
				if (!!((current_398179 == NIM_NIL))) goto LA3;
				scope_398135 = current_398179;
				{
					if (!(scope_398135 == (*c).toplevelscope)) goto LA6;
					islocal = NIM_FALSE;
				}
				LA6: ;
				{
					Tsym225841* it_398147;
					Tstrtable225813 HEX3Atmp_398170;
					Ttabiter233119 it_398173;
					Tsym225841* s_398175;
					it_398147 = 0;
					memset((void*)(&HEX3Atmp_398170), 0, sizeof(HEX3Atmp_398170));
					HEX3Atmp_398170.counter = (*scope_398135).symbols.counter;
					HEX3Atmp_398170.data = (*scope_398135).symbols.data;
					memset((void*)(&it_398173), 0, sizeof(it_398173));
					s_398175 = inittabiter_233124((&it_398173), HEX3Atmp_398170);
					{
						while (1) {
							if (!!((s_398175 == NIM_NIL))) goto LA10;
							it_398147 = s_398175;
							{
								NIM_BOOL LOC13;
								NimStringDesc* LOC16;
								Suggest395010 LOC17;
								LOC13 = 0;
								LOC13 = filtersym_395427(it_398147);
								if (!LOC13) goto LA14;
								LOC16 = 0;
								LOC16 = HEX24_168755(((NU8) 1));
								memset((void*)(&LOC17), 0, sizeof(LOC17));
								symtosuggest_395404(it_398147, islocal, LOC16, (&LOC17));
								suggestresult_395414((&LOC17));
								(*outputs) += ((NI) 1);
							}
							LA14: ;
							s_398175 = nextiter_233132((&it_398173), HEX3Atmp_398170);
						} LA10: ;
					}
				}
				{
					if (!(scope_398135 == (*c).toplevelscope)) goto LA20;
					goto LA1;
				}
				LA20: ;
				current_398179 = (*current_398179).parent;
			} LA3: ;
		}
	} LA1: ;
}

static N_INLINE(NIM_BOOL, fieldvisible_395471)(Tcontext280023* c, Tsym225841* f) {
	NIM_BOOL result;
	NI fmoduleid;
	Tsym225841* LOC1;
	NIM_BOOL LOC2;
	result = 0;
	LOC1 = 0;
	LOC1 = getmodule_233243(f);
	fmoduleid = (*LOC1).Sup.id;
	LOC2 = 0;
	LOC2 = (((*f).flags &(1<<((((NU8) 1))&31)))!=0);
	if (LOC2) goto LA3;
	LOC2 = (fmoduleid == (*(*c).module).Sup.id);
	LA3: ;
	result = LOC2;
	{
		Tsym225841* module_395611;
		Tsymseq225811* HEX3Atmp_395614;
		NI i_395617;
		NI L_395619;
		module_395611 = 0;
		HEX3Atmp_395614 = 0;
		HEX3Atmp_395614 = (*c).friendmodules;
		i_395617 = ((NI) 0);
		L_395619 = (HEX3Atmp_395614 ? HEX3Atmp_395614->Sup.len : 0);
		{
			while (1) {
				if (!(i_395617 < L_395619)) goto LA6;
				module_395611 = HEX3Atmp_395614->data[i_395617];
				{
					if (!(fmoduleid == (*module_395611).Sup.id)) goto LA9;
					result = NIM_TRUE;
					goto LA4;
				}
				LA9: ;
				i_395617 += ((NI) 1);
			} LA6: ;
		}
	} LA4: ;
	return result;
}

N_NIMCALL(void, suggestfield_395632)(Tcontext280023* c, Tsym225841* s, NI* outputs) {
	{
		NIM_BOOL LOC3;
		NimStringDesc* LOC7;
		Suggest395010 LOC8;
		LOC3 = 0;
		LOC3 = filtersym_395427(s);
		if (!(LOC3)) goto LA4;
		LOC3 = fieldvisible_395471(c, s);
		LA4: ;
		if (!LOC3) goto LA5;
		LOC7 = 0;
		LOC7 = HEX24_168755(((NU8) 1));
		memset((void*)(&LOC8), 0, sizeof(LOC8));
		symtosuggest_395404(s, NIM_TRUE, LOC7, (&LOC8));
		suggestresult_395414((&LOC8));
		(*outputs) += ((NI) 1);
	}
	LA5: ;
}

N_NIMCALL(void, suggestsymlist_395667)(Tcontext280023* c, Tnode225809* list, NI* outputs) {
	{
		NI i_395685;
		NI HEX3Atmp_395699;
		NI LOC2;
		NI res_395702;
		i_395685 = 0;
		HEX3Atmp_395699 = 0;
		LOC2 = 0;
		LOC2 = sonslen_228387(list);
		HEX3Atmp_395699 = (NI)(LOC2 - ((NI) 1));
		res_395702 = ((NI) 0);
		{
			while (1) {
				if (!(res_395702 <= HEX3Atmp_395699)) goto LA4;
				i_395685 = res_395702;
				{
					if (!((*(*list).kindU.S6.sons->data[i_395685]).kind == ((NU8) 3))) goto LA7;
					suggestfield_395632(c, (*(*list).kindU.S6.sons->data[i_395685]).kindU.S4.sym, outputs);
				}
				LA7: ;
				res_395702 += ((NI) 1);
			} LA4: ;
		}
	}
}

static N_INLINE(void, asgnRefNoCycle)(void** dest, void* src) {
	{
		Cell48946* c;
		if (!!((src == NIM_NIL))) goto LA3;
		c = usrtocell_52646(src);
		(*c).refcount += ((NI) 8);
	}
	LA3: ;
	{
		Cell48946* c;
		if (!!(((*dest) == NIM_NIL))) goto LA7;
		c = usrtocell_52646((*dest));
		{
			(*c).refcount -= ((NI) 8);
			if (!((NU32)((*c).refcount) < (NU32)(((NI) 8)))) goto LA11;
			rtladdzct_54204(c);
		}
		LA11: ;
	}
	LA7: ;
	(*dest) = src;
}

N_NIMCALL(NI, HEX3Aanonymous_398030)(Tsym225841* a_397808, Tsym225841* b_397810) {
	NI result;
{	result = 0;
	result = cmp_6577((*(*a_397808).name).s, (*(*b_397810).name).s);
	goto BeforeRet;
	}BeforeRet: ;
	return result;
}

static N_INLINE(NIM_BOOL, filtersymnoopr_395443)(Tsym225841* 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_247101((*s).name);
	LOC1 = !(LOC5);
	LA4: ;
	result = LOC1;
	return result;
}

static N_INLINE(void, initcandidateaux_388266)(Tcontext280023* ctx, Tcandidate388209* c, Ttype225847* 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_388278)(Tcontext280023* ctx, Tcandidate388209* c, Ttype225847* callee) {
	initcandidateaux_388266(ctx, c, callee);
	unsureAsgnRef((void**) (&(*c).calleesym), NIM_NIL);
	initidtable_229057((&(*c).bindings));
}

static N_INLINE(Ttype225847*, skipintlit_274696)(Ttype225847* t) {
	Ttype225847* result;
{	result = 0;
	{
		if (!!(((*t).n == NIM_NIL))) goto LA3;
		{
			if (!((*t).kind == ((NU8) 31) || (*t).kind == ((NU8) 36))) goto LA7;
			result = getsystype_274190((*t).kind);
			goto BeforeRet;
		}
		LA7: ;
	}
	LA3: ;
	result = t;
	}BeforeRet: ;
	return result;
}

static N_INLINE(void, put_388291)(Tidtable225859* t, Ttype225847* key, Ttype225847* val) {
	Tidobj198015* LOC1;
	Ttype225847* LOC2;
	TNimObject* LOC3;
	LOC1 = 0;
	LOC1 = &key->Sup;
	LOC2 = 0;
	LOC2 = skipintlit_274696(val);
	LOC3 = 0;
	LOC3 = &LOC2->Sup.Sup;
	idtableput_233196(t, LOC1, LOC3);
}

static N_INLINE(NI, len_226098)(Tnode225809* 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_390425)(Tnode225809* rules, Tident198021* callident) {
	NIM_BOOL result;
{	result = 0;
	{
		if (!((*rules).kind == ((NU8) 130))) goto LA3;
		{
			Tnode225809* r_390439;
			r_390439 = 0;
			{
				NI i_390469;
				NI HEX3Atmp_390471;
				NI LOC7;
				NI res_390473;
				i_390469 = 0;
				HEX3Atmp_390471 = 0;
				LOC7 = 0;
				LOC7 = len_226098(rules);
				HEX3Atmp_390471 = (LOC7 - 1);
				res_390473 = ((NI) 0);
				{
					while (1) {
						if (!(res_390473 <= HEX3Atmp_390471)) goto LA9;
						i_390469 = res_390473;
						r_390439 = (*rules).kindU.S6.sons->data[i_390469];
						{
							Tident198021* LOC12;
							LOC12 = 0;
							LOC12 = considerquotedident_286010(r_390439);
							if (!(LOC12 == callident)) goto LA13;
							result = NIM_TRUE;
							goto BeforeRet;
						}
						LA13: ;
						res_390473 += ((NI) 1);
					} LA9: ;
				}
			}
		}
		result = NIM_FALSE;
		goto BeforeRet;
	}
	goto LA1;
	LA3: ;
	{
		{
			Tnode225809* r_390452;
			r_390452 = 0;
			{
				NI i_390480;
				NI HEX3Atmp_390482;
				NI LOC18;
				NI res_390484;
				i_390480 = 0;
				HEX3Atmp_390482 = 0;
				LOC18 = 0;
				LOC18 = len_226098(rules);
				HEX3Atmp_390482 = (LOC18 - 1);
				res_390484 = ((NI) 0);
				{
					while (1) {
						if (!(res_390484 <= HEX3Atmp_390482)) goto LA20;
						i_390480 = res_390484;
						r_390452 = (*rules).kindU.S6.sons->data[i_390480];
						{
							Tident198021* LOC23;
							LOC23 = 0;
							LOC23 = considerquotedident_286010(r_390452);
							if (!(LOC23 == callident)) goto LA24;
							result = NIM_FALSE;
							goto BeforeRet;
						}
						LA24: ;
						res_390484 += ((NI) 1);
					} LA20: ;
				}
			}
		}
		result = NIM_TRUE;
		goto BeforeRet;
	}
	LA1: ;
	}BeforeRet: ;
	return result;
}

N_NIMCALL(Ttype225847*, maybeskipdistinct_390517)(Ttype225847* t, Tsym225841* callee) {
	Ttype225847* 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_390425((*t).n, (*callee).name);
		LA8: ;
		if (!LOC3) goto LA9;
		result = base_255039(t);
	}
	goto LA1;
	LA9: ;
	{
		result = t;
	}
	LA1: ;
	return result;
}

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

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

N_NIMCALL(Tnode225809*, tryresolvingstaticexpr_390562)(Tcandidate388209* c, Tnode225809* n) {
	Tnode225809* result;
	Tnode225809* instantiated;
	result = 0;
	instantiated = replacetypesinbody_304862((*c).c, (*c).bindings, n, NIM_NIL);
	result = (*(*c).c).semexpr((*c).c, instantiated, 0);
	return result;
}

N_NOINLINE(NU8, typerangerel_390234)(Ttype225847* f, Ttype225847* a) {
	NU8 result;
	NI64 a0;
	NI64 a1;
	NI64 f0;
	NI64 f1;
	result = 0;
	a0 = firstord_255004(a);
	a1 = lastord_255010(a);
	f0 = firstord_255004(f);
	f1 = lastord_255010(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_389238)(Ttype225847* f, Ttype225847* a) {
	NIM_BOOL result;
	result = 0;
	{
		NIM_BOOL LOC3;
		LOC3 = 0;
		LOC3 = ((*f).kind >= ((NU8) 31) && (*f).kind <= ((NU8) 35) || (*f).kind >= ((NU8) 40) && (*f).kind <= ((NU8) 44));
		if (!(LOC3)) goto LA4;
		LOC3 = ((*a).kind >= ((NU8) 31) && (*a).kind <= ((NU8) 35) || (*a).kind >= ((NU8) 40) && (*a).kind <= ((NU8) 44));
		LA4: ;
		if (!LOC3) goto LA5;
		result = NIM_TRUE;
	}
	goto LA1;
	LA5: ;
	{
		NIM_BOOL LOC8;
		LOC8 = 0;
		LOC8 = ((*f).kind >= ((NU8) 36) && (*f).kind <= ((NU8) 39));
		if (!(LOC8)) goto LA9;
		LOC8 = ((*a).kind >= ((NU8) 36) && (*a).kind <= ((NU8) 39));
		LA9: ;
		if (!LOC8) goto LA10;
		result = NIM_TRUE;
	}
	goto LA1;
	LA10: ;
	LA1: ;
	return result;
}

static N_INLINE(NIM_BOOL, isintlit_255327)(Ttype225847* 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_389122)(Ttype225847* f, Ttype225847* a, NU8 min, NU8 max) {
	NU8 result;
	result = 0;
	{
		if (!((*a).kind == (*f).kind)) goto LA3;
		result = ((NU8) 10);
	}
	goto LA1;
	LA3: ;
	{
		Ttype225847* ab;
		NU8 k;
		ab = skiptypes_229167(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 = ((*f).kind == ((NU8) 20) || (*f).kind >= ((NU8) 32) && (*f).kind <= ((NU8) 35) || (*f).kind >= ((NU8) 40) && (*f).kind <= ((NU8) 44));
			LA15: ;
			LOC13 = LOC14;
			if (!(LOC13)) goto LA16;
			LOC13 = isintlit_255327(ab);
			LA16: ;
			LOC12 = LOC13;
			if (!(LOC12)) goto LA17;
			LOC18 = 0;
			LOC18 = firstord_255004(f);
			LOC12 = (LOC18 <= (*(*ab).n).kindU.S1.intval);
			LA17: ;
			LOC11 = LOC12;
			if (!(LOC11)) goto LA19;
			LOC20 = 0;
			LOC20 = lastord_255010(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 = (k >= ((NU8) 32) && k <= ((NU8) 34));
			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;
			Tnode225809* LOC40;
			Tnode225809* LOC42;
			NI64 LOC43;
			LOC34 = 0;
			LOC35 = 0;
			LOC36 = 0;
			LOC36 = ((*a).kind == ((NU8) 20));
			if (!(LOC36)) goto LA37;
			LOC36 = ((*(*a).sons->data[((NI) 0)]).kind >= ((NU8) 31) && (*(*a).sons->data[((NI) 0)]).kind <= ((NU8) 35) || (*(*a).sons->data[((NI) 0)]).kind >= ((NU8) 41) && (*(*a).sons->data[((NI) 0)]).kind <= ((NU8) 43));
			LA37: ;
			LOC35 = LOC36;
			if (!(LOC35)) goto LA38;
			LOC39 = 0;
			LOC39 = firstord_255004(f);
			LOC40 = 0;
			LOC40 = HEX5BHEX5D_226244((*a).n, ((NI) 0));
			LOC35 = (LOC39 <= (*LOC40).kindU.S1.intval);
			LA38: ;
			LOC34 = LOC35;
			if (!(LOC34)) goto LA41;
			LOC42 = 0;
			LOC42 = HEX5BHEX5D_226244((*a).n, ((NI) 1));
			LOC43 = 0;
			LOC43 = lastord_255010(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_255367)(Ttype225847* 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_389293)(Ttype225847* f, Ttype225847* a) {
	NU8 result;
	result = 0;
	{
		if (!((*a).kind == (*f).kind)) goto LA3;
		result = ((NU8) 10);
	}
	goto LA1;
	LA3: ;
	{
		Ttype225847* ab;
		NU8 k;
		ab = skiptypes_229167(a, 1048576);
		k = (*ab).kind;
		{
			if (!(k == (*f).kind)) goto LA8;
			result = ((NU8) 4);
		}
		goto LA6;
		LA8: ;
		{
			NIM_BOOL LOC11;
			LOC11 = 0;
			LOC11 = isfloatlit_255367(ab);
			if (!LOC11) goto LA12;
			result = ((NU8) 9);
		}
		goto LA6;
		LA12: ;
		{
			NIM_BOOL LOC15;
			LOC15 = 0;
			LOC15 = isintlit_255327(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_389833)(Ttype225847* f) {
	NU8 result;
	result = 0;
	{
		if (!!((((*f).flags &(1<<((((NU8) 16))&31)))!=0))) goto LA3;
		result = ((NU8) 3);
	}
	goto LA1;
	LA3: ;
	{
		result = ((NU8) 0);
	}
	LA1: ;
	return result;
}

N_NIMCALL(NU8, minrel_389648)(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_389668)(Tcandidate388209* c, Ttype225847* f, Ttype225847* a) {
	NU8 result;
{	result = 0;
	result = ((NU8) 0);
	{
		NIM_BOOL LOC3;
		LOC3 = 0;
		LOC3 = sametype_260092(f, a, 0);
		if (!LOC3) goto LA4;
		result = ((NU8) 10);
	}
	goto LA1;
	LA4: ;
	{
		NI LOC7;
		NI LOC8;
		NI firstfield;
		LOC7 = 0;
		LOC7 = sonslen_228351(a);
		LOC8 = 0;
		LOC8 = sonslen_228351(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_389697;
			NI HEX3Atmp_389794;
			NI LOC17;
			NI res_389797;
			i_389697 = 0;
			HEX3Atmp_389794 = 0;
			LOC17 = 0;
			LOC17 = sonslen_228351(f);
			HEX3Atmp_389794 = (NI)(LOC17 - ((NI) 1));
			res_389797 = firstfield;
			{
				while (1) {
					NU8 m;
					if (!(res_389797 <= HEX3Atmp_389794)) goto LA19;
					i_389697 = res_389797;
					m = typerel_389064(c, (*f).sons->data[i_389697], (*a).sons->data[i_389697], NIM_TRUE);
					{
						if (!(m < ((NU8) 3))) goto LA22;
						result = ((NU8) 0);
						goto BeforeRet;
					}
					LA22: ;
					result = minrel_389648(result, m);
					res_389797 += ((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_389744;
				NI HEX3Atmp_389802;
				NI LOC31;
				NI res_389805;
				i_389744 = 0;
				HEX3Atmp_389802 = 0;
				LOC31 = 0;
				LOC31 = sonslen_228387((*f).n);
				HEX3Atmp_389802 = (NI)(LOC31 - ((NI) 1));
				res_389805 = ((NI) 0);
				{
					while (1) {
						if (!(res_389805 <= HEX3Atmp_389802)) goto LA33;
						i_389744 = res_389805;
						{
							if (!!(((*(*(*f).n).kindU.S6.sons->data[i_389744]).kind == ((NU8) 3)))) goto LA36;
							internalerror_196172((*(*f).n).info, ((NimStringDesc*) &TMP2756));
						}
						goto LA34;
						LA36: ;
						{
							if (!!(((*(*(*a).n).kindU.S6.sons->data[i_389744]).kind == ((NU8) 3)))) goto LA39;
							internalerror_196172((*(*a).n).info, ((NimStringDesc*) &TMP2756));
						}
						goto LA34;
						LA39: ;
						{
							Tsym225841* x;
							Tsym225841* y;
							x = (*(*(*f).n).kindU.S6.sons->data[i_389744]).kindU.S4.sym;
							y = (*(*(*a).n).kindU.S6.sons->data[i_389744]).kindU.S4.sym;
							{
								NIM_BOOL LOC44;
								NU8 LOC46;
								LOC44 = 0;
								LOC44 = ((*f).kind == ((NU8) 17));
								if (!(LOC44)) goto LA45;
								LOC46 = 0;
								LOC46 = typerel_389064(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_389805 += ((NI) 1);
					} LA33: ;
				}
			}
		}
		LA28: ;
	}
	goto LA1;
	LA9: ;
	LA1: ;
	}BeforeRet: ;
	return result;
}

N_NIMCALL(NI, isobjectsubtype_389352)(Ttype225847* a, Ttype225847* f) {
	NI result;
	Ttype225847* 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_260785(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_229167(t, 2048);
			depth += ((NI) 1);
		} LA2: ;
	} LA1: ;
	{
		if (!!((t == NIM_NIL))) goto LA12;
		result = depth;
	}
	LA12: ;
	return result;
}

static N_INLINE(NIM_BOOL, samedistincttypes_260844)(Ttype225847* a, Ttype225847* b) {
	NIM_BOOL result;
	result = 0;
	result = sameobjecttypes_260785(a, b);
	return result;
}

static N_INLINE(NIM_BOOL, inconsistentvartypes_389853)(Ttype225847* f, Ttype225847* 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_389891)(Tcandidate388209* c, Ttype225847* f_389895, Ttype225847* a_389896) {
	NU8 result;
	Ttype225847* f;
	Ttype225847* a;
{	result = 0;
	f = f_389895;
	a = a_389896;
	{
		NIM_BOOL LOC3;
		Ttype225847* aresolved;
		Tidobj198015* LOC6;
		TNimObject* LOC7;
		LOC3 = 0;
		LOC3 = ismetatype_226821(a);
		if (!LOC3) goto LA4;
		LOC6 = 0;
		LOC6 = &a->Sup;
		LOC7 = 0;
		LOC7 = idtableget_233182((*c).bindings, LOC6);
		aresolved = ((Ttype225847*) (LOC7));
		{
			if (!!((aresolved == NIM_NIL))) goto LA10;
			a = aresolved;
		}
		LA10: ;
	}
	LA4: ;
	{
		NIM_BOOL LOC14;
		NU8 reverserel;
		LOC14 = 0;
		LOC14 = ismetatype_226821(a);
		if (!LOC14) goto LA15;
		{
			NIM_BOOL LOC19;
			LOC19 = 0;
			LOC19 = ismetatype_226821(f);
			if (!LOC19) goto LA20;
			f = generatetypeinstance_304894((*c).c, (*c).bindings, (*(*c).call).info, f);
			{
				NIM_BOOL LOC24;
				LOC24 = 0;
				LOC24 = (f == NIM_NIL);
				if (LOC24) goto LA25;
				LOC24 = ismetatype_226821(f);
				LA25: ;
				if (!LOC24) goto LA26;
				result = ((NU8) 5);
				goto BeforeRet;
			}
			LA26: ;
		}
		LA20: ;
		reverserel = typerel_389064(c, a, f, NIM_TRUE);
		{
			if (!(((NU8) 8) <= reverserel)) goto LA30;
			result = ((NU8) 6);
		}
		LA30: ;
	}
	goto LA12;
	LA15: ;
	{
		result = typerel_389064(c, f, a, NIM_TRUE);
	}
	LA12: ;
	{
		NIM_BOOL LOC35;
		LOC35 = 0;
		LOC35 = (result <= ((NU8) 3));
		if (LOC35) goto LA36;
		LOC35 = inconsistentvartypes_389853(f, a);
		LA36: ;
		if (!LOC35) goto LA37;
		result = ((NU8) 0);
	}
	LA37: ;
	}BeforeRet: ;
	return result;
}

N_NIMCALL(NU8, proctyperel_389950)(Tcandidate388209* c, Ttype225847* f, Ttype225847* a) {
	NU8 result;
{	result = 0;
	switch ((*a).kind) {
	case ((NU8) 25):
	{
		{
			NI LOC4;
			NI LOC5;
			LOC4 = 0;
			LOC4 = sonslen_228351(f);
			LOC5 = 0;
			LOC5 = sonslen_228351(a);
			if (!!((LOC4 == LOC5))) goto LA6;
			goto BeforeRet;
		}
		LA6: ;
		result = ((NU8) 10);
		{
			NI i_389982;
			NI HEX3Atmp_390212;
			NI LOC9;
			NI res_390215;
			i_389982 = 0;
			HEX3Atmp_390212 = 0;
			LOC9 = 0;
			LOC9 = sonslen_228351(f);
			HEX3Atmp_390212 = (LOC9 - 1);
			res_390215 = ((NI) 1);
			{
				while (1) {
					NU8 LOC12;
					if (!(res_390215 <= HEX3Atmp_390212)) goto LA11;
					i_389982 = res_390215;
					LOC12 = 0;
					LOC12 = procparamtyperel_389891(c, (*f).sons->data[i_389982], (*a).sons->data[i_389982]);
					result = minrel_389648(result, LOC12);
					{
						if (!(result == ((NU8) 0))) goto LA15;
						goto BeforeRet;
					}
					LA15: ;
					res_390215 += ((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_389891(c, (*f).sons->data[((NI) 0)], (*a).sons->data[((NI) 0)]);
				result = minrel_389648(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 &(1<<((((NU8) 1))&31)))!=0);
			if (!(LOC36)) goto LA37;
			LOC36 = !((((*a).flags &(1<<((((NU8) 1))&31)))!=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 &(1<<((((NU8) 7))&31)))!=0);
			if (!(LOC42)) goto LA43;
			LOC42 = (((*a).flags & 130) == 0);
			LA43: ;
			LOC41 = LOC42;
			if (!(LOC41)) goto LA44;
			LOC41 = ((gglobaloptions_167132 &(1<<((((NU8) 24))&31)))!=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_264489(f, a);
			if (!!(LOC70)) goto LA71;
			result = ((NU8) 0);
			goto BeforeRet;
		}
		LA71: ;
	}
	break;
	case ((NU8) 5):
	{
		result = allowsnil_389833(f);
	}
	break;
	case ((NU8) 49):
	{
		{
			Ttype225847* LOC79;
			Ttype225847* LOC80;
			if (!(((*f).flags &(1<<((((NU8) 14))&31)))!=0)) goto LA77;
			LOC79 = 0;
			LOC79 = base_255039(f);
			LOC80 = 0;
			LOC80 = base_255039(a);
			result = typerel_389064(c, LOC79, LOC80, NIM_TRUE);
		}
		LA77: ;
	}
	break;
	default:
	{
	}
	break;
	}
	}BeforeRet: ;
	return result;
}

N_NIMCALL(Ttype225847*, concretetype_389074)(Tcandidate388209* c, Ttype225847* t) {
	Ttype225847* result;
	result = 0;
	switch ((*t).kind) {
	case ((NU8) 4):
	{
		result = newtype_228140(((NU8) 16), (*t).owner);
		addsonskipintlit_274729(result, (*t).sons->data[((NI) 0)]);
		addsonskipintlit_274729(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) {
				Tidobj198015* LOC18;
				TNimObject* LOC19;
				LOC18 = 0;
				LOC18 = &t->Sup;
				LOC19 = 0;
				LOC19 = idtableget_233182((*c).bindings, LOC18);
				result = ((Ttype225847*) (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_255032(t, ((NU8) 0));
		LOC29 = rawNewString(LOC30->Sup.len + 21);
appendString(LOC29, ((NimStringDesc*) &TMP2760));
appendString(LOC29, LOC30);
		internalerror_196191(LOC29);
		result = t;
	}
	break;
	default:
	{
		result = t;
	}
	break;
	}
	return result;
}

N_NIMCALL(NU8, matchusertypeclass_390249)(Tcontext280023* c, Tcandidate388209* m, Ttype225847* ff, Ttype225847* a) {
	NU8 volatile result;
	Ttype225847* body;
	Tscope225835* LOC9;
	TSafePoint TMP2762;
{	result = 0;
	body = skiptypes_229167(ff, IL64(9007199254740992));
	{
		Tnode225809* LOC5;
		NimStringDesc* LOC6;
		Tnode225809* LOC7;
		NimStringDesc* LOC8;
		if (!(((NI) 20) < (*c).intypeclass)) goto LA3;
		LOC5 = 0;
		LOC5 = HEX5BHEX5D_226244((*body).n, ((NI) 3));
		LOC6 = 0;
		LOC7 = 0;
		LOC7 = HEX5BHEX5D_226244((*body).n, ((NI) 3));
		LOC8 = 0;
		LOC8 = HEX24_247090(LOC7);
		LOC6 = rawNewString(LOC8->Sup.len + 29);
appendString(LOC6, LOC8);
appendString(LOC6, ((NimStringDesc*) &TMP2761));
		localerror_196139((*LOC5).info, LOC6);
		result = ((NU8) 0);
		goto BeforeRet;
	}
	LA3: ;
	LOC9 = 0;
	LOC9 = openscope_286091(c);
	(*c).intypeclass += ((NI) 1);
	pushSafePoint(&TMP2762);
	TMP2762.status = setjmp(TMP2762.context);
	if (TMP2762.status == 0) {
		Tnode225809* checkedbody;
		Tnode225809* LOC43;
		Tnode225809* LOC44;
		{
			if (!((*ff).kind == ((NU8) 53))) goto LA13;
			{
				NI i_390304;
				NI HEX3Atmp_390377;
				NI LOC16;
				NI res_390380;
				i_390304 = 0;
				HEX3Atmp_390377 = 0;
				LOC16 = 0;
				LOC16 = len_228369(ff);
				HEX3Atmp_390377 = ((NI)(LOC16 - ((NI) 1)) - 1);
				res_390380 = ((NI) 1);
				{
					while (1) {
						Tident198021* typeparamname;
						Ttype225847* LOC19;
						Ttype225847* typ;
						Tsym225841* volatile param;
						if (!(res_390380 <= HEX3Atmp_390377)) goto LA18;
						i_390304 = res_390380;
						LOC19 = 0;
						LOC19 = base_255039(ff);
						typeparamname = (*(*(*LOC19).sons->data[(NI)(i_390304 - ((NI) 1))]).sym).name;
						typ = (*ff).sons->data[i_390304];
						param = 0;
						switch ((*typ).kind) {
						case ((NU8) 59):
						{
							param = newsym_226656(((NU8) 10), typeparamname, (*body).sym, (*(*body).sym).info);
							asgnRefNoCycle((void**) (&(*param).typ), base_255039(typ));
							asgnRefNoCycle((void**) (&(*param).ast), (*typ).n);
						}
						break;
						case ((NU8) 60):
						{
							param = newsym_226656(((NU8) 8), typeparamname, (*body).sym, (*(*body).sym).info);
							asgnRefNoCycle((void**) (&(*param).typ), typ);
						}
						break;
						default:
						{
							param = newsym_226656(((NU8) 7), typeparamname, (*body).sym, (*(*body).sym).info);
							asgnRefNoCycle((void**) (&(*param).typ), maketypedesc_280684(c, typ));
						}
						break;
						}
						adddecl_286607(c, param);
						res_390380 += ((NI) 1);
					} LA18: ;
				}
			}
		}
		LA13: ;
		{
			Tnode225809* param_390320;
			Tnode225809* HEX3Atmp_390387;
			param_390320 = 0;
			HEX3Atmp_390387 = 0;
			HEX3Atmp_390387 = HEX5BHEX5D_226244((*body).n, ((NI) 0));
			{
				NI i_390391;
				NI HEX3Atmp_390393;
				NI LOC25;
				NI res_390395;
				i_390391 = 0;
				HEX3Atmp_390393 = 0;
				LOC25 = 0;
				LOC25 = len_226098(HEX3Atmp_390387);
				HEX3Atmp_390393 = (LOC25 - 1);
				res_390395 = ((NI) 0);
				{
					while (1) {
						Tnode225809* volatile dummyname;
						Ttype225847* volatile dummytype;
						Tsym225841* dummyparam;
						if (!(res_390395 <= HEX3Atmp_390393)) goto LA27;
						i_390391 = res_390395;
						param_390320 = (*HEX3Atmp_390387).kindU.S6.sons->data[i_390391];
						dummyname = 0;
						dummytype = 0;
						{
							if (!((*param_390320).kind == ((NU8) 143))) goto LA30;
							dummyname = HEX5BHEX5D_226244(param_390320, ((NI) 0));
							{
								if (!!(((*a).kind == ((NU8) 23)))) goto LA34;
								dummytype = makevartype_280645(c, a);
							}
							goto LA32;
							LA34: ;
							{
								dummytype = a;
							}
							LA32: ;
						}
						goto LA28;
						LA30: ;
						{
							dummyname = param_390320;
							dummytype = a;
						}
						LA28: ;
						{
							NimStringDesc* LOC42;
							if (!!(((*dummyname).kind == ((NU8) 2)))) goto LA40;
							LOC42 = 0;
							LOC42 = HEX24_196279(TMP2764);
							internalerror_196191(LOC42);
						}
						LA40: ;
						dummyparam = newsym_226656(((NU8) 8), (*dummyname).kindU.S5.ident, (*body).sym, (*(*body).sym).info);
						asgnRefNoCycle((void**) (&(*dummyparam).typ), dummytype);
						adddecl_286607(c, dummyparam);
						res_390395 += ((NI) 1);
					} LA27: ;
				}
			}
		}
		LOC43 = 0;
		LOC43 = HEX5BHEX5D_226244((*body).n, ((NI) 3));
		LOC44 = 0;
		LOC44 = copytree_230028(LOC43);
		checkedbody = (*c).semtryexpr(c, LOC44, 0);
		{
			if (!(checkedbody == NIM_NIL)) goto LA47;
			result = ((NU8) 0);
			popSafePoint();
			(*c).intypeclass -= ((NI) 1);
			closescope_286111(c);
			goto BeforeRet;
		}
		LA47: ;
		result = ((NU8) 8);
		popSafePoint();
		(*c).intypeclass -= ((NI) 1);
		closescope_286111(c);
		goto BeforeRet;
		popSafePoint();
	}
	else {
		popSafePoint();
	}
	{
		(*c).intypeclass -= ((NI) 1);
		closescope_286111(c);
	}
	if (TMP2762.status != 0) reraiseException();
	}BeforeRet: ;
	return result;
}

N_NIMCALL(NU8, typerel_389064)(Tcandidate388209* c, Ttype225847* f, Ttype225847* aorig, NIM_BOOL dobind) {
	NU8 result;
	Ttype225847* a;
	Ttype225847* LOC9;
{	result = 0;
	result = ((NU8) 0);
	{
		if (!((*f).kind == ((NU8) 6))) goto LA3;
		{
			if (!!((aorig == NIM_NIL))) goto LA7;
			put_388291((&(*c).bindings), f, aorig);
		}
		LA7: ;
		result = ((NU8) 8);
		goto BeforeRet;
	}
	LA3: ;
	LOC9 = 0;
	LOC9 = skiptypes_229167(aorig, IL64(576460752311812096));
	a = maybeskipdistinct_390517(LOC9, (*c).calleesym);
	{
		NIM_BOOL LOC12;
		Ttype225847* LOC14;
		Ttype225847* LOC17;
		LOC12 = 0;
		LOC12 = ((*a).kind == ((NU8) 11));
		if (!(LOC12)) goto LA13;
		LOC14 = 0;
		LOC14 = skiptypes_229167(f, 8388608);
		LOC12 = !(((*LOC14).kind >= ((NU8) 9) && (*LOC14).kind <= ((NU8) 12) || (*LOC14).kind >= ((NU8) 51) && (*LOC14).kind <= ((NU8) 58)));
		LA13: ;
		if (!LOC12) goto LA15;
		LOC17 = 0;
		LOC17 = lastson_228426(a);
		result = typerel_389064(c, f, LOC17, NIM_TRUE);
		goto BeforeRet;
	}
	LA15: ;
	switch ((*a).kind) {
	case ((NU8) 56):
	{
		result = ((NU8) 8);
		{
			Ttype225847* branch_390859;
			Ttypeseq225843* HEX3Atmp_392620;
			NI i_392623;
			NI L_392625;
			branch_390859 = 0;
			HEX3Atmp_392620 = 0;
			HEX3Atmp_392620 = (*a).sons;
			i_392623 = ((NI) 0);
			L_392625 = (HEX3Atmp_392620 ? HEX3Atmp_392620->Sup.len : 0);
			{
				while (1) {
					NU8 x;
					if (!(i_392623 < L_392625)) goto LA21;
					branch_390859 = HEX3Atmp_392620->data[i_392623];
					x = typerel_389064(c, f, branch_390859, NIM_FALSE);
					{
						if (!(x == ((NU8) 0))) goto LA24;
						result = ((NU8) 0);
						goto BeforeRet;
					}
					LA24: ;
					{
						if (!(x < result)) goto LA28;
						result = x;
					}
					LA28: ;
					i_392623 += ((NI) 1);
				} LA21: ;
			}
		}
	}
	break;
	case ((NU8) 55):
	{
		{
			Ttype225847* branch_390888;
			Ttypeseq225843* HEX3Atmp_392627;
			NI i_392630;
			NI L_392632;
			branch_390888 = 0;
			HEX3Atmp_392627 = 0;
			HEX3Atmp_392627 = (*a).sons;
			i_392630 = ((NI) 0);
			L_392632 = (HEX3Atmp_392627 ? HEX3Atmp_392627->Sup.len : 0);
			{
				while (1) {
					NU8 x;
					if (!(i_392630 < L_392632)) goto LA33;
					branch_390888 = HEX3Atmp_392627->data[i_392630];
					x = typerel_389064(c, f, branch_390888, 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_392630 += ((NI) 1);
				} LA33: ;
			}
		}
		result = ((NU8) 0);
	}
	break;
	case ((NU8) 57):
	{
		switch ((*f).kind) {
		case ((NU8) 57):
		{
			Ttype225847* LOC45;
			Ttype225847* LOC46;
			LOC45 = 0;
			LOC45 = lastson_228426(a);
			LOC46 = 0;
			LOC46 = lastson_228426(f);
			result = typerel_389064(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_389064(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_260855(f, a);
			LA69: ;
			if (!LOC68) goto LA70;
			result = ((NU8) 10);
		}
		goto LA66;
		LA70: ;
		{
			Ttype225847* LOC73;
			NIM_BOOL LOC74;
			LOC73 = 0;
			LOC73 = skiptypes_229167(a, 1048576);
			LOC74 = 0;
			LOC74 = sameenumtypes_260855(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: ;
		{
			Ttype225847* LOC83;
			LOC83 = 0;
			LOC83 = skiptypes_229167(a, 1048576);
			if (!((*LOC83).kind == (*f).kind)) goto LA84;
			result = ((NU8) 3);
		}
		goto LA78;
		LA84: ;
		LA78: ;
	}
	break;
	case ((NU8) 20):
	{
		{
			Ttype225847* LOC96;
			Ttype225847* LOC97;
			if (!((*a).kind == (*f).kind)) goto LA89;
			{
				Ttype225847* LOC93;
				LOC93 = 0;
				LOC93 = base_255039(f);
				if (!((*LOC93).kind == ((NU8) 0))) goto LA94;
				result = ((NU8) 8);
				goto BeforeRet;
			}
			LA94: ;
			LOC96 = 0;
			LOC96 = base_255039(f);
			LOC97 = 0;
			LOC97 = base_255039(a);
			result = typerel_389064(c, LOC96, LOC97, NIM_TRUE);
			{
				if (!!(((257 &(1<<((result)&15)))!=0))) goto LA100;
				{
					NI i_391004;
					NI res_392636;
					i_391004 = 0;
					res_392636 = ((NI) 0);
					{
						while (1) {
							if (!(res_392636 <= ((NI) 1))) goto LA104;
							i_391004 = res_392636;
							{
								Tnode225809* LOC107;
								Tnode225809* LOC110;
								LOC107 = 0;
								LOC107 = HEX5BHEX5D_226244((*f).n, i_391004);
								if (!((*LOC107).kind == ((NU8) 62))) goto LA108;
								LOC110 = 0;
								LOC110 = HEX5BHEX5D_226244((*f).n, i_391004);
								asgnRefNoCycle((void**) (&(*(*f).n).kindU.S6.sons->data[i_391004]), tryresolvingstaticexpr_390562(c, LOC110));
							}
							LA108: ;
							res_392636 += ((NI) 1);
						} LA104: ;
					}
				}
				result = typerangerel_390234(f, a);
			}
			LA100: ;
		}
		goto LA87;
		LA89: ;
		{
			{
				Ttype225847* LOC114;
				LOC114 = 0;
				LOC114 = skiptypes_229167(f, 1048576);
				if (!((*LOC114).kind == (*a).kind)) goto LA115;
				result = ((NU8) 2);
			}
			goto LA112;
			LA115: ;
			{
				Ttype225847* LOC118;
				NIM_BOOL LOC119;
				LOC118 = 0;
				LOC118 = skiptypes_229167(f, 1048576);
				LOC119 = 0;
				LOC119 = isconvertibletorange_389238(LOC118, a);
				if (!LOC119) goto LA120;
				result = ((NU8) 1);
			}
			goto LA112;
			LA120: ;
			LA112: ;
		}
		LA87: ;
	}
	break;
	case ((NU8) 31):
	{
		result = handlerange_389122(f, a, ((NU8) 32), ((NU8) 34));
	}
	break;
	case ((NU8) 32):
	{
		result = handlerange_389122(f, a, ((NU8) 32), ((NU8) 32));
	}
	break;
	case ((NU8) 33):
	{
		result = handlerange_389122(f, a, ((NU8) 32), ((NU8) 33));
	}
	break;
	case ((NU8) 34):
	{
		result = handlerange_389122(f, a, ((NU8) 32), ((NU8) 34));
	}
	break;
	case ((NU8) 35):
	{
		result = handlerange_389122(f, a, ((NU8) 31), ((NU8) 35));
	}
	break;
	case ((NU8) 40):
	{
		result = handlerange_389122(f, a, ((NU8) 41), ((NU8) 43));
	}
	break;
	case ((NU8) 41):
	{
		result = handlerange_389122(f, a, ((NU8) 41), ((NU8) 41));
	}
	break;
	case ((NU8) 42):
	{
		result = handlerange_389122(f, a, ((NU8) 41), ((NU8) 42));
	}
	break;
	case ((NU8) 43):
	{
		result = handlerange_389122(f, a, ((NU8) 41), ((NU8) 43));
	}
	break;
	case ((NU8) 44):
	{
		result = handlerange_389122(f, a, ((NU8) 40), ((NU8) 44));
	}
	break;
	case ((NU8) 36):
	{
		result = handlefloatrange_389293(f, a);
	}
	break;
	case ((NU8) 37):
	{
		result = handlefloatrange_389293(f, a);
	}
	break;
	case ((NU8) 38):
	{
		result = handlefloatrange_389293(f, a);
	}
	break;
	case ((NU8) 39):
	{
		result = handlefloatrange_389293(f, a);
	}
	break;
	case ((NU8) 23):
	{
		{
			Ttype225847* LOC141;
			Ttype225847* LOC142;
			if (!((*aorig).kind == ((NU8) 23))) goto LA139;
			LOC141 = 0;
			LOC141 = base_255039(f);
			LOC142 = 0;
			LOC142 = base_255039(aorig);
			result = typerel_389064(c, LOC141, LOC142, NIM_TRUE);
		}
		goto LA137;
		LA139: ;
		{
			Ttype225847* LOC144;
			LOC144 = 0;
			LOC144 = base_255039(f);
			result = typerel_389064(c, LOC144, aorig, NIM_TRUE);
		}
		LA137: ;
	}
	break;
	case ((NU8) 16):
	case ((NU8) 4):
	{
		switch ((*a).kind) {
		case ((NU8) 16):
		case ((NU8) 4):
		{
			Ttype225847* frange;
			frange = (*f).sons->data[((NI) 0)];
			{
				Ttype225847* prev;
				Tidobj198015* LOC151;
				TNimObject* LOC152;
				if (!((*frange).kind == ((NU8) 12))) goto LA149;
				LOC151 = 0;
				LOC151 = &frange->Sup;
				LOC152 = 0;
				LOC152 = idtableget_233182((*c).bindings, LOC151);
				prev = ((Ttype225847*) (LOC152));
				{
					if (!(prev == NIM_NIL)) goto LA155;
					put_388291((&(*c).bindings), frange, (*a).sons->data[((NI) 0)]);
					frange = a;
				}
				goto LA153;
				LA155: ;
				{
					frange = prev;
				}
				LA153: ;
			}
			LA149: ;
			result = typerel_389064(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;
				Tnode225809* LOC169;
				Tnode225809* len;
				Tnode225809* LOC182;
				LOC164 = 0;
				LOC165 = 0;
				LOC165 = !(((*frange).n == NIM_NIL));
				if (!(LOC165)) goto LA166;
				LOC167 = 0;
				LOC167 = len_226098((*frange).n);
				LOC165 = (((NI) 1) < LOC167);
				LA166: ;
				LOC164 = LOC165;
				if (!(LOC164)) goto LA168;
				LOC169 = 0;
				LOC169 = HEX5BHEX5D_226244((*frange).n, ((NI) 1));
				LOC164 = ((*LOC169).kind == ((NU8) 62));
				LA168: ;
				if (!LOC164) goto LA170;
				{
					Ttype225847* rangestatict;
					Tnode225809* LOC176;
					Tnode225809* LOC177;
					Tnode225809* LOC178;
					Ttype225847* replacementt;
					Ttypeseq225843* LOC179;
					TY393275 LOC180;
					NI64 inputupperbound;
					Tnode225809* LOC181;
					if (!(((*frange).flags &(1<<((((NU8) 9))&31)))!=0)) goto LA174;
					LOC176 = 0;
					LOC176 = HEX5BHEX5D_226244((*frange).n, ((NI) 1));
					LOC177 = 0;
					LOC177 = HEX5BHEX5D_226244(LOC176, ((NI) 0));
					LOC178 = 0;
					LOC178 = HEX5BHEX5D_226244(LOC177, ((NI) 1));
					rangestatict = (*LOC178).typ;
					LOC179 = 0;
					LOC179 = (Ttypeseq225843*) newSeq((&NTI225843), 1);
					memset((void*)LOC180, 0, sizeof(LOC180));
					LOC180[0] = getsystype_274190(((NU8) 31));
					asgnRefNoCycle((void**) (&LOC179->data[0]), LOC180[0]);
					replacementt = newtypewithsons_280807((*c).c, ((NU8) 59), LOC179);
					LOC181 = 0;
					LOC181 = HEX5BHEX5D_226244((*(*a).sons->data[((NI) 0)]).n, ((NI) 1));
					inputupperbound = (*LOC181).kindU.S1.intval;
					asgnRefNoCycle((void**) (&(*replacementt).n), newintnode_226608(((NU8) 6), (NI64)(inputupperbound + IL64(1))));
					put_388291((&(*c).bindings), rangestatict, replacementt);
					result = ((NU8) 8);
					goto BeforeRet;
				}
				LA174: ;
				LOC182 = 0;
				LOC182 = HEX5BHEX5D_226244((*frange).n, ((NI) 1));
				len = tryresolvingstaticexpr_390562(c, LOC182);
				{
					NIM_BOOL LOC185;
					NI64 LOC187;
					LOC185 = 0;
					LOC185 = ((*len).kind == ((NU8) 6));
					if (!(LOC185)) goto LA186;
					LOC187 = 0;
					LOC187 = lengthord_255016(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_255016(frange);
				LOC193 = 0;
				LOC193 = lengthord_255016(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 &(1<<((((NU8) 0))&31)))!=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):
		{
			Ttype225847* LOC214;
			Ttype225847* LOC215;
			LOC214 = 0;
			LOC214 = base_255039(f);
			LOC215 = 0;
			LOC215 = base_255039(a);
			result = typerel_389064(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: ;
			{
				Ttype225847* LOC228;
				NU8 LOC229;
				LOC228 = 0;
				LOC228 = base_255039(f);
				LOC229 = 0;
				LOC229 = typerel_389064(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: ;
			{
				Ttype225847* LOC240;
				NU8 LOC241;
				LOC240 = 0;
				LOC240 = base_255039(f);
				LOC241 = 0;
				LOC241 = typerel_389064(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: ;
			{
				Ttype225847* LOC252;
				NU8 LOC253;
				LOC252 = 0;
				LOC252 = base_255039(f);
				LOC253 = 0;
				LOC253 = typerel_389064(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;
					Ttype225847* LOC271;
					Ttype225847* LOC272;
					NU8 LOC273;
					LOC266 = 0;
					LOC267 = 0;
					LOC267 = ((*(*f).sons->data[((NI) 0)]).kind == ((NU8) 12));
					if (!(LOC267)) goto LA268;
					LOC269 = 0;
					LOC269 = len_228369(a);
					LOC267 = (((NI) 0) < LOC269);
					LA268: ;
					LOC266 = LOC267;
					if (!(LOC266)) goto LA270;
					LOC271 = 0;
					LOC271 = base_255039(f);
					LOC272 = 0;
					LOC272 = base_255039(a);
					LOC273 = 0;
					LOC273 = typerel_389064(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_389064(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 &(1<<((((NU8) 16))&31)))!=0);
					if (!(LOC291)) goto LA292;
					LOC291 = !((((*a).flags &(1<<((((NU8) 16))&31)))!=0));
					LA292: ;
					if (!LOC291) goto LA293;
					result = ((NU8) 1);
				}
				goto LA286;
				LA293: ;
				LA286: ;
			}
			LA279: ;
		}
		break;
		case ((NU8) 5):
		{
			result = allowsnil_389833(f);
		}
		break;
		default:
		{
		}
		break;
		}
	}
	break;
	case ((NU8) 15):
	{
		{
			NIM_BOOL LOC300;
			Ttype225847* x;
			LOC300 = 0;
			LOC300 = isordinaltype_255093(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_389064(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_196191(((NimStringDesc*) &TMP2755));
	}
	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_389668(c, f, a);
		}
		LA329: ;
	}
	break;
	case ((NU8) 17):
	{
		{
			if (!((*a).kind == ((NU8) 17))) goto LA334;
			{
				NIM_BOOL LOC338;
				LOC338 = 0;
				LOC338 = sameobjecttypes_260785(f, a);
				if (!LOC338) goto LA339;
				result = ((NU8) 10);
			}
			goto LA336;
			LA339: ;
			{
				NI depth;
				depth = isobjectsubtype_389352(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_260844(f, a);
			LA350: ;
			if (!LOC349) goto LA351;
			result = ((NU8) 10);
		}
		goto LA347;
		LA351: ;
		{
			Ttype225847* LOC356;
			if (!(*c).coercedistincts) goto LA354;
			LOC356 = 0;
			LOC356 = base_255039(f);
			result = typerel_389064(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_389064(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):
	{
		{
			Ttype225847* LOC393;
			Ttype225847* LOC394;
			if (!((*a).kind == (*f).kind)) goto LA376;
			{
				NI LOC380;
				NI LOC381;
				LOC380 = 0;
				LOC380 = len_228369(a);
				LOC381 = 0;
				LOC381 = len_228369(f);
				if (!(LOC380 < LOC381)) goto LA382;
				result = ((NU8) 0);
				goto BeforeRet;
			}
			LA382: ;
			{
				NI i_391477;
				NI HEX3Atmp_392641;
				NI LOC385;
				NI res_392644;
				i_391477 = 0;
				HEX3Atmp_392641 = 0;
				LOC385 = 0;
				LOC385 = len_228369(f);
				HEX3Atmp_392641 = (NI)(LOC385 - ((NI) 2));
				res_392644 = ((NI) 0);
				{
					while (1) {
						if (!(res_392644 <= HEX3Atmp_392641)) goto LA387;
						i_391477 = res_392644;
						{
							NU8 LOC390;
							LOC390 = 0;
							LOC390 = typerel_389064(c, (*f).sons->data[i_391477], (*a).sons->data[i_391477], NIM_TRUE);
							if (!(LOC390 == ((NU8) 0))) goto LA391;
							result = ((NU8) 0);
							goto BeforeRet;
						}
						LA391: ;
						res_392644 += ((NI) 1);
					} LA387: ;
				}
			}
			LOC393 = 0;
			LOC393 = lastson_228426(f);
			LOC394 = 0;
			LOC394 = lastson_228426(a);
			result = typerel_389064(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 &(1<<((((NU8) 16))&31)))!=0);
				if (!(LOC400)) goto LA401;
				LOC400 = !((((*a).flags &(1<<((((NU8) 16))&31)))!=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_389833(f);
		}
		goto LA374;
		LA405: ;
		{
		}
		LA374: ;
	}
	break;
	case ((NU8) 25):
	{
		result = proctyperel_389950(c, f, a);
		{
			NIM_BOOL LOC411;
			NIM_BOOL LOC412;
			LOC411 = 0;
			LOC412 = 0;
			LOC412 = !((result == ((NU8) 0)));
			if (!(LOC412)) goto LA413;
			LOC412 = (((*f).flags &(1<<((((NU8) 16))&31)))!=0);
			LA413: ;
			LOC411 = LOC412;
			if (!(LOC411)) goto LA414;
			LOC411 = !((((*a).flags &(1<<((((NU8) 16))&31)))!=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 &(1<<((((NU8) 16))&31)))!=0);
				if (!(LOC421)) goto LA422;
				LOC421 = !((((*a).flags &(1<<((((NU8) 16))&31)))!=0));
				LA422: ;
				if (!LOC421) goto LA423;
				result = ((NU8) 1);
			}
			goto LA419;
			LA423: ;
			{
				result = ((NU8) 10);
			}
			LA419: ;
		}
		break;
		case ((NU8) 5):
		{
			result = allowsnil_389833(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_228369(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 &(1<<((((NU8) 16))&31)))!=0);
				if (!(LOC444)) goto LA445;
				LOC444 = !((((*a).flags &(1<<((((NU8) 16))&31)))!=0));
				LA445: ;
				if (!LOC444) goto LA446;
				result = ((NU8) 1);
			}
			goto LA442;
			LA446: ;
			{
				result = ((NU8) 10);
			}
			LA442: ;
		}
		break;
		case ((NU8) 5):
		{
			result = allowsnil_389833(f);
		}
		break;
		default:
		{
		}
		break;
		}
	}
	break;
	case ((NU8) 29):
	{
		switch ((*a).kind) {
		case ((NU8) 29):
		{
			{
				NIM_BOOL LOC455;
				LOC455 = 0;
				LOC455 = (((*f).flags &(1<<((((NU8) 16))&31)))!=0);
				if (!(LOC455)) goto LA456;
				LOC455 = !((((*a).flags &(1<<((((NU8) 16))&31)))!=0));
				LA456: ;
				if (!LOC455) goto LA457;
				result = ((NU8) 1);
			}
			goto LA453;
			LA457: ;
			{
				result = ((NU8) 10);
			}
			LA453: ;
		}
		break;
		case ((NU8) 5):
		{
			result = allowsnil_389833(f);
		}
		break;
		case ((NU8) 28):
		{
			result = ((NU8) 1);
		}
		break;
		case ((NU8) 21):
		{
			{
				NIM_BOOL LOC465;
				NI LOC466;
				LOC465 = 0;
				LOC466 = 0;
				LOC466 = len_228369(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;
				Ttype225847* LOC477;
				LOC473 = 0;
				LOC474 = 0;
				LOC475 = 0;
				LOC475 = firstord_255004((*a).sons->data[((NI) 0)]);
				LOC474 = (LOC475 == IL64(0));
				if (!(LOC474)) goto LA476;
				LOC477 = 0;
				LOC477 = skiptypes_229167((*a).sons->data[((NI) 0)], 1048576);
				LOC474 = ((*LOC477).kind >= ((NU8) 31) && (*LOC477).kind <= ((NU8) 35));
				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):
	{
		Ttype225847* roota;
		Ttype225847* rootf;
		roota = skipgenericalias_261119(a);
		rootf = skipgenericalias_261119(f);
		{
			NIM_BOOL LOC490;
			Ttype225847* LOC492;
			Ttype225847* LOC493;
			LOC490 = 0;
			LOC490 = ((*a).kind == ((NU8) 11));
			if (!(LOC490)) goto LA491;
			LOC492 = 0;
			LOC492 = base_255039(roota);
			LOC493 = 0;
			LOC493 = base_255039(rootf);
			LOC490 = (LOC492 == LOC493);
			LA491: ;
			if (!LOC490) goto LA494;
			{
				NI i_391694;
				NI HEX3Atmp_392649;
				NI LOC497;
				NI res_392652;
				i_391694 = 0;
				HEX3Atmp_392649 = 0;
				LOC497 = 0;
				LOC497 = sonslen_228351(rootf);
				HEX3Atmp_392649 = (NI)(LOC497 - ((NI) 2));
				res_392652 = ((NI) 1);
				{
					while (1) {
						Ttype225847* ff;
						Ttype225847* aa;
						if (!(res_392652 <= HEX3Atmp_392649)) goto LA499;
						i_391694 = res_392652;
						ff = (*rootf).sons->data[i_391694];
						aa = (*roota).sons->data[i_391694];
						result = typerel_389064(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_392652 += ((NI) 1);
					} LA499: ;
				}
			}
		}
		goto LA488;
		LA494: ;
		{
			Ttype225847* LOC511;
			LOC511 = 0;
			LOC511 = lastson_228426(f);
			result = typerel_389064(c, LOC511, a, NIM_TRUE);
		}
		LA488: ;
	}
	break;
	case ((NU8) 10):
	{
		Ttype225847* prev_391725;
		Tidobj198015* LOC513;
		TNimObject* LOC514;
		LOC513 = 0;
		LOC513 = &f->Sup;
		LOC514 = 0;
		LOC514 = idtableget_233182((*c).bindings, LOC513);
		prev_391725 = ((Ttype225847*) (LOC514));
		{
			Ttype225847* ff;
			if (!(prev_391725 == 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;
				{
					Ttype225847* bound_391759;
					Ttype225847* LOC529;
					if (!dobind) goto LA527;
					LOC529 = 0;
					LOC529 = skiptypes_229167(aorig, 1048576);
					bound_391759 = skipintlit_274696(LOC529);
					{
						if (!dobind) goto LA532;
						put_388291((&(*c).bindings), f, bound_391759);
					}
					LA532: ;
				}
				LA527: ;
				result = ((NU8) 8);
				goto BeforeRet;
			}
			LA523: ;
			ff = lastson_228426(f);
			{
				if (!!((ff == NIM_NIL))) goto LA536;
				result = typerel_389064(c, ff, a, NIM_TRUE);
			}
			LA536: ;
		}
		goto LA515;
		LA517: ;
		{
			result = typerel_389064(c, prev_391725, a, NIM_TRUE);
			goto BeforeRet;
		}
		LA515: ;
	}
	break;
	case ((NU8) 9):
	{
		Ttype225847* x_391775;
		x_391775 = skipgenericalias_261119(a);
		{
			NIM_BOOL LOC542;
			LOC542 = 0;
			LOC542 = ((*x_391775).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_391775).kind == ((NU8) 11));
			if (!(LOC548)) goto LA549;
			LOC548 = ((*f).sons->data[((NI) 0)] == (*x_391775).sons->data[((NI) 0)]);
			LA549: ;
			LOC547 = LOC548;
			if (!(LOC547)) goto LA550;
			LOC551 = 0;
			LOC551 = sonslen_228351(x_391775);
			LOC552 = 0;
			LOC552 = sonslen_228351(f);
			LOC547 = ((NI)(LOC551 - ((NI) 1)) == LOC552);
			LA550: ;
			if (!LOC547) goto LA553;
			{
				NI i_391826;
				NI HEX3Atmp_392657;
				NI LOC556;
				NI res_392660;
				i_391826 = 0;
				HEX3Atmp_392657 = 0;
				LOC556 = 0;
				LOC556 = sonslen_228351(f);
				HEX3Atmp_392657 = (NI)(LOC556 - ((NI) 1));
				res_392660 = ((NI) 1);
				{
					while (1) {
						if (!(res_392660 <= HEX3Atmp_392657)) goto LA558;
						i_391826 = res_392660;
						{
							if (!((*(*x_391775).sons->data[i_391826]).kind == ((NU8) 12))) goto LA561;
							internalerror_196191(((NimStringDesc*) &TMP2759));
						}
						goto LA559;
						LA561: ;
						{
							NU8 LOC564;
							LOC564 = 0;
							LOC564 = typerel_389064(c, (*f).sons->data[i_391826], (*x_391775).sons->data[i_391826], NIM_TRUE);
							if (!(LOC564 <= ((NU8) 3))) goto LA565;
							goto BeforeRet;
						}
						goto LA559;
						LA565: ;
						LA559: ;
						res_392660 += ((NI) 1);
					} LA558: ;
				}
			}
			result = ((NU8) 8);
		}
		goto LA540;
		LA553: ;
		{
			Ttype225847* genericbody;
			genericbody = (*f).sons->data[((NI) 0)];
			result = typerel_389064(c, genericbody, x_391775, NIM_TRUE);
			{
				if (!!((result == ((NU8) 0)))) goto LA570;
				{
					NI i_391867;
					NI HEX3Atmp_392665;
					NI LOC573;
					NI res_392668;
					i_391867 = 0;
					HEX3Atmp_392665 = 0;
					LOC573 = 0;
					LOC573 = sonslen_228351(f);
					HEX3Atmp_392665 = (NI)(LOC573 - ((NI) 1));
					res_392668 = ((NI) 1);
					{
						while (1) {
							Ttype225847* x;
							Tidobj198015* LOC576;
							TNimObject* LOC577;
							if (!(res_392668 <= HEX3Atmp_392665)) goto LA575;
							i_391867 = res_392668;
							LOC576 = 0;
							LOC576 = &(*genericbody).sons->data[(NI)(i_391867 - ((NI) 1))]->Sup;
							LOC577 = 0;
							LOC577 = idtableget_233182((*c).bindings, LOC576);
							x = ((Ttype225847*) (LOC577));
							{
								if (!(x == NIM_NIL)) goto LA580;
							}
							goto LA578;
							LA580: ;
							{
								if (!((*x).kind == ((NU8) 9) || (*x).kind == ((NU8) 12))) goto LA583;
								internalerror_196191(((NimStringDesc*) &TMP2759));
							}
							goto LA578;
							LA583: ;
							{
								put_388291((&(*c).bindings), (*f).sons->data[i_391867], x);
							}
							LA578: ;
							res_392668 += ((NI) 1);
						} LA575: ;
					}
				}
			}
			LA570: ;
		}
		LA540: ;
	}
	break;
	case ((NU8) 55):
	{
		Ttype225847* prev_391894;
		Tidobj198015* LOC587;
		TNimObject* LOC588;
		LOC587 = 0;
		LOC587 = &f->Sup;
		LOC588 = 0;
		LOC588 = idtableget_233182((*c).bindings, LOC587);
		prev_391894 = ((Ttype225847*) (LOC588));
		{
			if (!(prev_391894 == NIM_NIL)) goto LA591;
			result = ((NU8) 10);
			{
				Ttype225847* branch_391916;
				Ttypeseq225843* HEX3Atmp_392673;
				NI i_392676;
				NI L_392678;
				branch_391916 = 0;
				HEX3Atmp_392673 = 0;
				HEX3Atmp_392673 = (*f).sons;
				i_392676 = ((NI) 0);
				L_392678 = (HEX3Atmp_392673 ? HEX3Atmp_392673->Sup.len : 0);
				{
					while (1) {
						NU8 x;
						if (!(i_392676 < L_392678)) goto LA595;
						branch_391916 = HEX3Atmp_392673->data[i_392676];
						x = typerel_389064(c, branch_391916, aorig, NIM_TRUE);
						{
							if (!(x < ((NU8) 3))) goto LA598;
							result = ((NU8) 0);
							goto BeforeRet;
						}
						LA598: ;
						{
							if (!(x < result)) goto LA602;
							result = x;
						}
						LA602: ;
						i_392676 += ((NI) 1);
					} LA595: ;
				}
			}
			{
				Ttype225847* bound_391937;
				Ttype225847* LOC608;
				if (!dobind) goto LA606;
				LOC608 = 0;
				LOC608 = skiptypes_229167(aorig, 1048576);
				bound_391937 = skipintlit_274696(LOC608);
				{
					if (!dobind) goto LA611;
					put_388291((&(*c).bindings), f, bound_391937);
				}
				LA611: ;
			}
			LA606: ;
			goto BeforeRet;
		}
		goto LA589;
		LA591: ;
		{
			result = typerel_389064(c, prev_391894, a, NIM_TRUE);
			goto BeforeRet;
		}
		LA589: ;
	}
	break;
	case ((NU8) 56):
	{
		Ttype225847* prev_391941;
		Tidobj198015* LOC615;
		TNimObject* LOC616;
		LOC615 = 0;
		LOC615 = &f->Sup;
		LOC616 = 0;
		LOC616 = idtableget_233182((*c).bindings, LOC615);
		prev_391941 = ((Ttype225847*) (LOC616));
		{
			if (!(prev_391941 == NIM_NIL)) goto LA619;
			result = ((NU8) 0);
			{
				Ttype225847* branch_391963;
				Ttypeseq225843* HEX3Atmp_392680;
				NI i_392683;
				NI L_392685;
				branch_391963 = 0;
				HEX3Atmp_392680 = 0;
				HEX3Atmp_392680 = (*f).sons;
				i_392683 = ((NI) 0);
				L_392685 = (HEX3Atmp_392680 ? HEX3Atmp_392680->Sup.len : 0);
				{
					while (1) {
						NU8 x;
						if (!(i_392683 < L_392685)) goto LA623;
						branch_391963 = HEX3Atmp_392680->data[i_392683];
						x = typerel_389064(c, branch_391963, aorig, NIM_TRUE);
						{
							if (!(result < x)) goto LA626;
							result = x;
						}
						LA626: ;
						i_392683 += ((NI) 1);
					} LA623: ;
				}
			}
			{
				if (!(((NU8) 3) <= result)) goto LA630;
				{
					Ttype225847* bound_391984;
					Ttype225847* LOC636;
					if (!dobind) goto LA634;
					LOC636 = 0;
					LOC636 = skiptypes_229167(aorig, 1048576);
					bound_391984 = skipintlit_274696(LOC636);
					{
						if (!dobind) goto LA639;
						put_388291((&(*c).bindings), f, bound_391984);
					}
					LA639: ;
				}
				LA634: ;
				goto BeforeRet;
			}
			goto LA628;
			LA630: ;
			{
				result = ((NU8) 0);
			}
			LA628: ;
		}
		goto LA617;
		LA619: ;
		{
			result = typerel_389064(c, prev_391941, a, NIM_TRUE);
			goto BeforeRet;
		}
		LA617: ;
	}
	break;
	case ((NU8) 57):
	{
		Ttype225847* prev_391988;
		Tidobj198015* LOC644;
		TNimObject* LOC645;
		LOC644 = 0;
		LOC644 = &f->Sup;
		LOC645 = 0;
		LOC645 = idtableget_233182((*c).bindings, LOC644);
		prev_391988 = ((Ttype225847*) (LOC645));
		{
			if (!(prev_391988 == NIM_NIL)) goto LA648;
			{
				Ttype225847* branch_392010;
				Ttypeseq225843* HEX3Atmp_392687;
				NI i_392690;
				NI L_392692;
				branch_392010 = 0;
				HEX3Atmp_392687 = 0;
				HEX3Atmp_392687 = (*f).sons;
				i_392690 = ((NI) 0);
				L_392692 = (HEX3Atmp_392687 ? HEX3Atmp_392687->Sup.len : 0);
				{
					while (1) {
						if (!(i_392690 < L_392692)) goto LA652;
						branch_392010 = HEX3Atmp_392687->data[i_392690];
						{
							NU8 LOC655;
							LOC655 = 0;
							LOC655 = typerel_389064(c, branch_392010, aorig, NIM_TRUE);
							if (!!((LOC655 == ((NU8) 0)))) goto LA656;
							result = ((NU8) 0);
							goto BeforeRet;
						}
						LA656: ;
						i_392690 += ((NI) 1);
					} LA652: ;
				}
			}
			{
				Ttype225847* bound_392021;
				Ttype225847* LOC662;
				if (!dobind) goto LA660;
				LOC662 = 0;
				LOC662 = skiptypes_229167(aorig, 1048576);
				bound_392021 = skipintlit_274696(LOC662);
				{
					if (!dobind) goto LA665;
					put_388291((&(*c).bindings), f, bound_392021);
				}
				LA665: ;
			}
			LA660: ;
			result = ((NU8) 8);
			goto BeforeRet;
		}
		goto LA646;
		LA648: ;
		{
			result = typerel_389064(c, prev_391988, a, NIM_TRUE);
			goto BeforeRet;
		}
		LA646: ;
	}
	break;
	case ((NU8) 58):
	{
		Ttype225847* prev_392025;
		Tidobj198015* LOC669;
		TNimObject* LOC670;
		LOC669 = 0;
		LOC669 = &f->Sup;
		LOC670 = 0;
		LOC670 = idtableget_233182((*c).bindings, LOC669);
		prev_392025 = ((Ttype225847*) (LOC670));
		{
			Ttype225847* concrete;
			if (!(prev_392025 == NIM_NIL)) goto LA673;
			concrete = concretetype_389074((&(*c)), a);
			{
				NIM_BOOL LOC677;
				LOC677 = 0;
				LOC677 = !((concrete == NIM_NIL));
				if (!(LOC677)) goto LA678;
				LOC677 = dobind;
				LA678: ;
				if (!LOC677) goto LA679;
				put_388291((&(*c).bindings), f, concrete);
			}
			LA679: ;
			result = ((NU8) 8);
			goto BeforeRet;
		}
		goto LA671;
		LA673: ;
		{
			result = typerel_389064(c, prev_392025, a, NIM_TRUE);
			goto BeforeRet;
		}
		LA671: ;
	}
	break;
	case ((NU8) 51):
	{
		Ttype225847* prev_392053;
		Tidobj198015* LOC683;
		TNimObject* LOC684;
		LOC683 = 0;
		LOC683 = &f->Sup;
		LOC684 = 0;
		LOC684 = idtableget_233182((*c).bindings, LOC683);
		prev_392053 = ((Ttype225847*) (LOC684));
		{
			NU8 targetkind;
			if (!(prev_392053 == NIM_NIL)) goto LA687;
			targetkind = (*(*f).sons->data[((NI) 0)]).kind;
			{
				NIM_BOOL LOC691;
				Ttype225847* LOC692;
				NIM_BOOL LOC694;
				LOC691 = 0;
				LOC692 = 0;
				LOC692 = skiptypes_229167(a, 1050624);
				LOC691 = (targetkind == (*LOC692).kind);
				if (LOC691) goto LA693;
				LOC694 = 0;
				LOC694 = (targetkind == ((NU8) 25) || targetkind == ((NU8) 26));
				if (!(LOC694)) goto LA695;
				LOC694 = ((*a).kind == ((NU8) 5));
				LA695: ;
				LOC691 = LOC694;
				LA693: ;
				if (!LOC691) goto LA696;
				put_388291((&(*c).bindings), f, a);
				result = ((NU8) 8);
				goto BeforeRet;
			}
			goto LA689;
			LA696: ;
			{
				result = ((NU8) 0);
				goto BeforeRet;
			}
			LA689: ;
		}
		goto LA685;
		LA687: ;
		{
			result = typerel_389064(c, prev_392053, a, NIM_TRUE);
			goto BeforeRet;
		}
		LA685: ;
	}
	break;
	case ((NU8) 52):
	case ((NU8) 53):
	{
		Ttype225847* prev_392099;
		Tidobj198015* LOC701;
		TNimObject* LOC702;
		LOC701 = 0;
		LOC701 = &f->Sup;
		LOC702 = 0;
		LOC702 = idtableget_233182((*c).bindings, LOC701);
		prev_392099 = ((Ttype225847*) (LOC702));
		{
			if (!(prev_392099 == NIM_NIL)) goto LA705;
			result = matchusertypeclass_390249((*c).c, c, f, aorig);
			{
				if (!(result == ((NU8) 8))) goto LA709;
				put_388291((&(*c).bindings), f, a);
			}
			LA709: ;
		}
		goto LA703;
		LA705: ;
		{
			result = typerel_389064(c, prev_392099, a, NIM_TRUE);
			goto BeforeRet;
		}
		LA703: ;
	}
	break;
	case ((NU8) 54):
	{
		Ttype225847* prev_392123;
		Tidobj198015* LOC713;
		TNimObject* LOC714;
		LOC713 = 0;
		LOC713 = &f->Sup;
		LOC714 = 0;
		LOC714 = idtableget_233182((*c).bindings, LOC713);
		prev_392123 = ((Ttype225847*) (LOC714));
		{
			if (!(prev_392123 == NIM_NIL)) goto LA717;
			{
				NU8 LOC721;
				LOC721 = 0;
				LOC721 = typerel_389064(c, (*f).sons->data[((NI) 1)], a, NIM_TRUE);
				if (!!((LOC721 == ((NU8) 0)))) goto LA722;
				put_388291((&(*c).bindings), f, a);
				result = ((NU8) 8);
				goto BeforeRet;
			}
			goto LA719;
			LA722: ;
			{
				result = ((NU8) 0);
				goto BeforeRet;
			}
			LA719: ;
		}
		goto LA715;
		LA717: ;
		{
			result = typerel_389064(c, prev_392123, a, NIM_TRUE);
			goto BeforeRet;
		}
		LA715: ;
	}
	break;
	case ((NU8) 12):
	{
		Ttype225847* x;
		Tidobj198015* LOC727;
		TNimObject* LOC728;
		LOC727 = 0;
		LOC727 = &f->Sup;
		LOC728 = 0;
		LOC728 = idtableget_233182((*c).bindings, LOC727);
		x = ((Ttype225847*) (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 &(1<<((((NU8) 25))&31)))!=0)) goto LA743;
					result = ((NU8) 8);
				}
				goto LA741;
				LA743: ;
				{
					if (!((*a).kind == ((NU8) 8))) goto LA746;
					{
						NI LOC750;
						LOC750 = 0;
						LOC750 = sonslen_228351(f);
						if (!(LOC750 == ((NI) 0))) goto LA751;
						result = ((NU8) 8);
					}
					goto LA748;
					LA751: ;
					{
						Ttype225847* aa;
						Ttype225847* LOC767;
						{
							NIM_BOOL LOC756;
							NIM_BOOL LOC757;
							NimStringDesc* LOC761;
							LOC756 = 0;
							LOC757 = 0;
							LOC757 = HEX3DHEX3D_264739((*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_196279(TMP2767);
							internalerror_196191(LOC761);
						}
						LA759: ;
						(*c).typedescmatched = NIM_TRUE;
						aa = a;
						{
							while (1) {
								NIM_BOOL LOC764;
								NI LOC766;
								LOC764 = 0;
								LOC764 = ((*aa).kind == ((NU8) 8) || (*aa).kind == ((NU8) 12));
								if (!(LOC764)) goto LA765;
								LOC766 = 0;
								LOC766 = len_228369(aa);
								LOC764 = (((NI) 0) < LOC766);
								LA765: ;
								if (!LOC764) goto LA763;
								aa = lastson_228426(aa);
							} LA763: ;
						}
						LOC767 = 0;
						LOC767 = base_255039(f);
						result = typerel_389064(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;
					Ttype225847* LOC781;
					LOC776 = 0;
					LOC777 = 0;
					LOC777 = sonslen_228351(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_228426(f);
					result = typerel_389064(c, LOC781, a, NIM_TRUE);
					{
						NIM_BOOL LOC784;
						Ttype225847* concrete;
						LOC784 = 0;
						LOC784 = dobind;
						if (!(LOC784)) goto LA785;
						LOC784 = !(((257 &(1<<((result)&15)))!=0));
						LA785: ;
						if (!LOC784) goto LA786;
						concrete = concretetype_389074((&(*c)), a);
						{
							if (!(concrete == NIM_NIL)) goto LA790;
							result = ((NU8) 0);
							goto BeforeRet;
						}
						LA790: ;
						put_388291((&(*c).bindings), f, concrete);
					}
					LA786: ;
				}
				goto LA774;
				LA779: ;
				{
					result = ((NU8) 8);
				}
				LA774: ;
			}
			LA733: ;
			{
				Ttype225847* concrete;
				if (!(result == ((NU8) 8))) goto LA795;
				concrete = a;
				{
					if (!(((*a).flags &(1<<((((NU8) 25))&31)))!=0)) goto LA799;
					(*(*a).sym).kind = ((NU8) 7);
					(*a).flags &= ~(((NU32)1) << ((((NU8) 25)) % (sizeof(NU32)*8)));
				}
				goto LA797;
				LA799: ;
				{
					concrete = concretetype_389074((&(*c)), a);
					{
						if (!(concrete == NIM_NIL)) goto LA804;
						result = ((NU8) 0);
						goto BeforeRet;
					}
					LA804: ;
				}
				LA797: ;
				{
					if (!dobind) goto LA808;
					put_388291((&(*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_389064(c, x, a, NIM_TRUE);
			{
				if (!(((NU8) 8) < result)) goto LA822;
				result = ((NU8) 8);
			}
			LA822: ;
		}
		LA729: ;
	}
	break;
	case ((NU8) 59):
	{
		Ttype225847* prev;
		Tidobj198015* LOC825;
		TNimObject* LOC826;
		LOC825 = 0;
		LOC825 = &f->Sup;
		LOC826 = 0;
		LOC826 = idtableget_233182((*c).bindings, LOC825);
		prev = ((Ttype225847*) (LOC826));
		{
			if (!(prev == NIM_NIL)) goto LA829;
			{
				Ttype225847* LOC835;
				if (!((*aorig).kind == ((NU8) 59))) goto LA833;
				LOC835 = 0;
				LOC835 = lastson_228426(f);
				result = typerel_389064(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_254149((*f).n, (*aorig).n, NIM_FALSE);
						if (!!(LOC844)) goto LA845;
						result = ((NU8) 0);
					}
					LA845: ;
				}
				LA840: ;
				{
					if (!!((result == ((NU8) 0)))) goto LA849;
					put_388291((&(*c).bindings), f, aorig);
				}
				LA849: ;
			}
			goto LA831;
			LA833: ;
			{
				result = ((NU8) 0);
			}
			LA831: ;
		}
		goto LA827;
		LA829: ;
		{
			if (!((*prev).kind == ((NU8) 59))) goto LA853;
			{
				Ttype225847* LOC859;
				if (!((*aorig).kind == ((NU8) 59))) goto LA857;
				LOC859 = 0;
				LOC859 = lastson_228426(prev);
				result = typerel_389064(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_254149((*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):
	{
		Ttype225847* prev;
		Tidobj198015* LOC874;
		TNimObject* LOC875;
		LOC874 = 0;
		LOC874 = &f->Sup;
		LOC875 = 0;
		LOC875 = idtableget_233182((*c).bindings, LOC874);
		prev = ((Ttype225847*) (LOC875));
		{
			if (!(prev == NIM_NIL)) goto LA878;
			{
				if (!!(((*a).kind == ((NU8) 8)))) goto LA882;
				result = ((NU8) 0);
				goto BeforeRet;
			}
			LA882: ;
			{
				Ttype225847* LOC886;
				LOC886 = 0;
				LOC886 = base_255039(f);
				if (!((*LOC886).kind == ((NU8) 0))) goto LA887;
				result = ((NU8) 8);
			}
			goto LA884;
			LA887: ;
			{
				Ttype225847* LOC890;
				Ttype225847* LOC891;
				LOC890 = 0;
				LOC890 = base_255039(f);
				LOC891 = 0;
				LOC891 = base_255039(a);
				result = typerel_389064(c, LOC890, LOC891, NIM_TRUE);
			}
			LA884: ;
			{
				if (!!((result == ((NU8) 0)))) goto LA894;
				put_388291((&(*c).bindings), f, a);
			}
			LA894: ;
		}
		goto LA876;
		LA878: ;
		{
			{
				Ttype225847* LOC901;
				if (!(((*f).flags &(1<<((((NU8) 9))&31)))!=0)) goto LA899;
				LOC901 = 0;
				LOC901 = base_255039(prev);
				result = typerel_389064(c, LOC901, a, NIM_TRUE);
			}
			goto LA897;
			LA899: ;
			{
				Ttype225847* LOC905;
				Ttype225847* LOC906;
				if (!((*a).kind == ((NU8) 8))) goto LA903;
				LOC905 = 0;
				LOC905 = base_255039(prev);
				LOC906 = 0;
				LOC906 = base_255039(a);
				result = typerel_389064(c, LOC905, LOC906, NIM_TRUE);
			}
			goto LA897;
			LA903: ;
			{
				result = ((NU8) 0);
			}
			LA897: ;
		}
		LA876: ;
	}
	break;
	case ((NU8) 49):
	{
		{
			NIM_BOOL LOC911;
			NIM_BOOL LOC913;
			Ttype225847* LOC917;
			Ttype225847* 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 &(1<<((((NU8) 14))&31)))!=0);
			LA914: ;
			LOC911 = LOC913;
			LA912: ;
			if (!LOC911) goto LA915;
			LOC917 = 0;
			LOC917 = base_255039(f);
			LOC918 = 0;
			LOC918 = base_255039(a);
			result = typerel_389064(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 &(1<<((((NU8) 0))&31)))!=0));
			LA924: ;
			if (!LOC923) goto LA925;
			put_388291((&(*c).bindings), f, aorig);
		}
		LA925: ;
		result = ((NU8) 8);
	}
	break;
	case ((NU8) 50):
	{
		result = ((NU8) 10);
	}
	break;
	case ((NU8) 60):
	{
		Tnode225809* 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_390562(c, (*f).n);
		switch ((*(*reevaluated).typ).kind) {
		case ((NU8) 8):
		{
			Ttype225847* LOC936;
			LOC936 = 0;
			LOC936 = base_255039((*reevaluated).typ);
			result = typerel_389064(c, a, LOC936, NIM_TRUE);
		}
		break;
		case ((NU8) 59):
		{
			Ttype225847* LOC938;
			LOC938 = 0;
			LOC938 = base_255039((*reevaluated).typ);
			result = typerel_389064(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_254149((*aorig).n, (*(*reevaluated).typ).n, NIM_FALSE);
					if (!!(LOC947)) goto LA948;
					result = ((NU8) 0);
				}
				LA948: ;
			}
			LA943: ;
		}
		break;
		default:
		{
			localerror_196128((*(*f).n).info, ((NU16) 67), ((NimStringDesc*) &TMP2201));
			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, (&NTI225262))->Sup.len + 19);
appendString(LOC957, ((NimStringDesc*) &TMP2768));
appendString(LOC957, reprEnum((*f).kind, (&NTI225262)));
		internalerror_196191(LOC957);
	}
	break;
	}
	}BeforeRet: ;
	return result;
}

N_NIMCALL(void, incmatches_393124)(Tcandidate388209* 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(NIM_BOOL, isinlineiterator_393087)(Ttype225847* t) {
	NIM_BOOL result;
	NIM_BOOL LOC1;
	NIM_BOOL LOC3;
	Ttype225847* LOC5;
	result = 0;
	LOC1 = 0;
	LOC1 = ((*t).kind == ((NU8) 49));
	if (LOC1) goto LA2;
	LOC3 = 0;
	LOC3 = ((*t).kind == ((NU8) 51));
	if (!(LOC3)) goto LA4;
	LOC5 = 0;
	LOC5 = base_255039(t);
	LOC3 = ((*LOC5).kind == ((NU8) 49));
	LA4: ;
	LOC1 = LOC3;
	LA2: ;
	result = LOC1;
	return result;
}

N_NIMCALL(Ttype225847*, getinstantiatedtype_392812)(Tcontext280023* c, Tnode225809* arg, Tcandidate388209* m, Ttype225847* f) {
	Ttype225847* result;
	Tidobj198015* LOC1;
	TNimObject* LOC2;
	result = 0;
	LOC1 = 0;
	LOC1 = &f->Sup;
	LOC2 = 0;
	LOC2 = idtableget_233182((*m).bindings, LOC1);
	result = ((Ttype225847*) (LOC2));
	{
		if (!(result == NIM_NIL)) goto LA5;
		result = generatetypeinstance_304894(c, (*m).bindings, (*arg).info, f);
	}
	LA5: ;
	{
		if (!(result == NIM_NIL)) goto LA9;
		internalerror_196172((*arg).info, ((NimStringDesc*) &TMP2771));
		result = errortype_281161(c);
	}
	LA9: ;
	return result;
}

N_NIMCALL(Tnode225809*, implicitconv_392849)(NU8 kind, Ttype225847* f, Tnode225809* arg, Tcandidate388209* m, Tcontext280023* c) {
	Tnode225809* result;
	result = 0;
	result = newnodei_227351(kind, (*arg).info);
	{
		NIM_BOOL LOC3;
		LOC3 = 0;
		LOC3 = containsgenerictype_264310(f);
		if (!LOC3) goto LA4;
		{
			if (!!(!(((*m).fauxmatch == ((NU8) 0))))) goto LA8;
			asgnRefNoCycle((void**) (&(*result).typ), getinstantiatedtype_392812(c, arg, m, f));
		}
		goto LA6;
		LA8: ;
		{
			asgnRefNoCycle((void**) (&(*result).typ), errortype_281161(c));
		}
		LA6: ;
	}
	goto LA1;
	LA4: ;
	{
		asgnRefNoCycle((void**) (&(*result).typ), f);
	}
	LA1: ;
	{
		if (!((*result).typ == NIM_NIL)) goto LA14;
		internalerror_196172((*arg).info, ((NimStringDesc*) &TMP2772));
	}
	LA14: ;
	addson_227819(result, emptynode_226807);
	addson_227819(result, arg);
	return result;
}

N_NIMCALL(NIM_BOOL, istracked_398569)(Tlineinfo190352 current, NI tokenlen) {
	NIM_BOOL result;
{	result = 0;
	{
		if (!(current.fileindex == gtrackpos_191901.fileindex)) goto LA3;
		{
			NI16 col;
			if (!(current.line == gtrackpos_191901.line)) goto LA7;
			col = gtrackpos_191901.col;
			{
				NIM_BOOL LOC11;
				LOC11 = 0;
				LOC11 = (current.col <= col);
				if (!(LOC11)) goto LA12;
				LOC11 = (((NI) (col)) <= (NI)((NI)(((NI) (current.col)) + tokenlen) - ((NI) 1)));
				LA12: ;
				if (!LOC11) goto LA13;
				result = NIM_TRUE;
				goto BeforeRet;
			}
			LA13: ;
		}
		LA7: ;
	}
	LA3: ;
	}BeforeRet: ;
	return result;
}

N_NIMCALL(void, findusages_398665)(Tlineinfo190352 info, Tsym225841* s) {
	{
		NIM_BOOL LOC3;
		NimStringDesc* LOC7;
		Suggest395010 LOC8;
		LOC3 = 0;
		LOC3 = (usagesym_398663 == NIM_NIL);
		if (!(LOC3)) goto LA4;
		LOC3 = istracked_398569(info, ((*(*s).name).s ? (*(*s).name).s->Sup.len : 0));
		LA4: ;
		if (!LOC3) goto LA5;
		asgnRefNoCycle((void**) (&usagesym_398663), s);
		LOC7 = 0;
		LOC7 = HEX24_168755(((NU8) 4));
		memset((void*)(&LOC8), 0, sizeof(LOC8));
		symtosuggest_395404(s, NIM_FALSE, LOC7, (&LOC8));
		suggestresult_395414((&LOC8));
	}
	goto LA1;
	LA5: ;
	{
		if (!(s == usagesym_398663)) goto LA10;
		{
			NIM_BOOL LOC14;
			NimStringDesc* LOC17;
			Suggest395010 LOC18;
			LOC14 = 0;
			LOC14 = HEX3DHEX3D_193255(lastlineinfo_398664, info);
			if (!!(LOC14)) goto LA15;
			LOC17 = 0;
			LOC17 = HEX24_168755(((NU8) 4));
			memset((void*)(&LOC18), 0, sizeof(LOC18));
			symtosuggest_395027(s, NIM_FALSE, LOC17, info, (&LOC18));
			suggestresult_395414((&LOC18));
		}
		LA15: ;
		lastlineinfo_398664 = info;
	}
	goto LA1;
	LA10: ;
	LA1: ;
}

N_NIMCALL(void, finddefinition_398696)(Tlineinfo190352 info, Tsym225841* s) {
{	{
		if (!s == 0) goto LA3;
		goto BeforeRet;
	}
	LA3: ;
	{
		NIM_BOOL LOC7;
		NimStringDesc* LOC10;
		Suggest395010 LOC11;
		LOC7 = 0;
		LOC7 = istracked_398569(info, ((*(*s).name).s ? (*(*s).name).s->Sup.len : 0));
		if (!LOC7) goto LA8;
		LOC10 = 0;
		LOC10 = HEX24_168755(((NU8) 3));
		memset((void*)(&LOC11), 0, sizeof(LOC11));
		symtosuggest_395404(s, NIM_FALSE, LOC10, (&LOC11));
		suggestresult_395414((&LOC11));
		suggestquit_191509();
	}
	LA8: ;
	}BeforeRet: ;
}

static N_INLINE(void, suggestsym_398733)(Tlineinfo190352 info, Tsym225841* s) {
	{
		if (!(gidecmd_167119 == ((NU8) 4))) goto LA3;
		findusages_398665(info, s);
	}
	goto LA1;
	LA3: ;
	{
		if (!(gidecmd_167119 == ((NU8) 3))) goto LA6;
		finddefinition_398696(info, s);
	}
	goto LA1;
	LA6: ;
	{
		NIM_BOOL LOC9;
		LOC9 = 0;
		LOC9 = (gidecmd_167119 == ((NU8) 5));
		if (!(LOC9)) goto LA10;
		LOC9 = !((s == NIM_NIL));
		LA10: ;
		if (!LOC9) goto LA11;
		{
			NIM_BOOL LOC15;
			NimStringDesc* LOC18;
			Suggest395010 LOC19;
			LOC15 = 0;
			LOC15 = istracked_398569(info, ((*(*s).name).s ? (*(*s).name).s->Sup.len : 0));
			if (!LOC15) goto LA16;
			LOC18 = 0;
			LOC18 = HEX24_168755(((NU8) 3));
			memset((void*)(&LOC19), 0, sizeof(LOC19));
			symtosuggest_395404(s, NIM_FALSE, LOC18, (&LOC19));
			suggestresult_395414((&LOC19));
		}
		LA16: ;
		findusages_398665(info, s);
	}
	goto LA1;
	LA11: ;
	LA1: ;
}

N_NIMCALL(void, markused_388253)(Tlineinfo190352 info, Tsym225841* s) {
	(*s).flags |= ((NU32)1)<<((((NU8) 0))%(sizeof(NU32)*8));
	{
		if (!!(((1572864 & (*s).flags) == 0))) goto LA3;
		{
			if (!(((*s).flags &(1<<((((NU8) 19))&31)))!=0)) goto LA7;
			message_196161(info, ((NU16) 241), (*(*s).name).s);
		}
		LA7: ;
		{
			if (!(((*s).flags &(1<<((((NU8) 20))&31)))!=0)) goto LA11;
			localerror_196128(info, ((NU16) 226), (*(*s).name).s);
		}
		LA11: ;
	}
	LA3: ;
	suggestsym_398733(info, s);
}

N_NIMCALL(Tnode225809*, userconvmatch_392884)(Tcontext280023* c, Tcandidate388209* m, Ttype225847* f, Ttype225847* a, Tnode225809* arg) {
	Tnode225809* result;
{	result = 0;
	result = NIM_NIL;
	{
		NI i_392913;
		NI HEX3Atmp_392965;
		NI res_392968;
		i_392913 = 0;
		HEX3Atmp_392965 = 0;
		HEX3Atmp_392965 = (NI)(((*c).converters ? (*c).converters->Sup.len : 0) - ((NI) 1));
		res_392968 = ((NI) 0);
		{
			while (1) {
				if (!(res_392968 <= HEX3Atmp_392965)) goto LA3;
				i_392913 = res_392968;
				{
					Ttype225847* src;
					Ttype225847* dest;
					NU8 srca;
					NIM_BOOL destisgeneric;
					NU8 fdest;
					src = (*(*(*c).converters->data[i_392913]).typ).sons->data[((NI) 1)];
					dest = (*(*(*c).converters->data[i_392913]).typ).sons->data[((NI) 0)];
					srca = typerel_389064(m, src, a, NIM_TRUE);
					{
						if (!!(((1280 &(1<<((srca)&15)))!=0))) goto LA7;
						goto LA4;
					}
					LA7: ;
					destisgeneric = containsgenerictype_264310(dest);
					{
						if (!destisgeneric) goto LA11;
						dest = generatetypeinstance_304894(c, (*m).bindings, (*arg).info, dest);
					}
					LA11: ;
					fdest = typerel_389064(m, f, dest, NIM_TRUE);
					{
						Tnode225809* s;
						Tnode225809* LOC17;
						NIM_BOOL LOC18;
						if (!((1280 &(1<<((fdest)&15)))!=0)) goto LA15;
						markused_388253((*arg).info, (*c).converters->data[i_392913]);
						s = newsymnode_227325((*c).converters->data[i_392913]);
						asgnRefNoCycle((void**) (&(*s).typ), (*(*c).converters->data[i_392913]).typ);
						(*s).info = (*arg).info;
						result = newnodeit_227807(((NU8) 32), (*arg).info, dest);
						addson_227819(result, s);
						LOC17 = 0;
						LOC17 = copytree_230028(arg);
						addson_227819(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_392968 += ((NI) 1);
			} LA3: ;
		}
	}
	}BeforeRet: ;
	return result;
}

N_NIMCALL(Tnode225809*, localconvmatch_392990)(Tcontext280023* c, Tcandidate388209* m, Ttype225847* f, Ttype225847* a, Tnode225809* arg) {
	Tnode225809* result;
	Tnode225809* call;
	Tnode225809* LOC11;
	Tnode225809* 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_227351(((NU8) 27), (*arg).info);
	LOC11 = 0;
	LOC11 = copytree_230028((*f).n);
	add_226165(call, LOC11);
	LOC12 = 0;
	LOC12 = copytree_230028(arg);
	add_226165(call, LOC12);
	result = (*c).semoverloadedcall(c, call, call, 520192);
	{
		NU8 r;
		if (!!((result == NIM_NIL))) goto LA15;
		r = typerel_389064(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);
		{
			Ttype225847* LOC29;
			if (!(r == ((NU8) 8))) goto LA27;
			LOC29 = 0;
			LOC29 = base_255039(f);
			asgnRefNoCycle((void**) (&(*result).typ), getinstantiatedtype_392812(c, arg, (&(*m)), LOC29));
		}
		LA27: ;
		(*m).basetypematch = NIM_TRUE;
	}
	LA15: ;
	}BeforeRet: ;
	return result;
}

N_NIMCALL(Tnode225809*, paramtypesmatchaux_393191)(Tcandidate388209* m, Ttype225847* f, Ttype225847* argtype_393196, Tnode225809* argsemantized, Tnode225809* argorig) {
	Tnode225809* result;
	Ttype225847* fmaybestatic;
	Tnode225809* arg;
	Ttype225847* argtype;
	Tcontext280023* c;
	Ttype225847* a;
	NU8 r;
	NI bothmetacounter;
	NI lastbindingslength;
{	result = 0;
	fmaybestatic = skiptypes_229167(f, 8192);
	arg = argsemantized;
	argtype = argtype_393196;
	c = (*m).c;
	{
		if (!(((*fmaybestatic).flags &(1<<((((NU8) 22))&31)))!=0)) goto LA3;
		{
			NIM_BOOL LOC7;
			LOC7 = 0;
			LOC7 = ((*argtype).kind == ((NU8) 12));
			if (!(LOC7)) goto LA8;
			LOC7 = (((*argtype).flags &(1<<((((NU8) 25))&31)))!=0);
			LA8: ;
			if (!LOC7) goto LA9;
			assigntype_228445(argtype, f);
			result = argsemantized;
			goto BeforeRet;
		}
		LA9: ;
		{
			if (!((*argtype).kind == ((NU8) 59))) goto LA13;
			{
				NIM_BOOL LOC17;
				Ttype225847* LOC21;
				LOC17 = 0;
				LOC17 = ((*(*m).callee).kind == ((NU8) 10));
				if (!(LOC17)) goto LA18;
				LOC17 = !((((*argtype).flags &(1<<((((NU8) 23))&31)))!=0));
				LA18: ;
				if (!LOC17) goto LA19;
				LOC21 = 0;
				LOC21 = maketypefromexpr_280729(c, arg);
				result = newnodeit_227807(((NU8) 4), (*argorig).info, LOC21);
				goto BeforeRet;
			}
			LA19: ;
		}
		goto LA11;
		LA13: ;
		{
			Tnode225809* evaluated;
			evaluated = (*c).semtryconstexpr(c, arg);
			{
				TY393275 LOC27;
				if (!!((evaluated == NIM_NIL))) goto LA25;
				asgnRefNoCycle((void**) (&(*arg).typ), newtypes_280221(((NU8) 59), c));
				if ((*(*arg).typ).sons) nimGCunrefNoCycle((*(*arg).typ).sons);
				(*(*arg).typ).sons = (Ttypeseq225843*) newSeqRC1((&NTI225843), 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_229167(argtype, IL64(2305843009213694208));
	}
	goto LA28;
	LA30: ;
	{
		a = argtype;
	}
	LA28: ;
	r = typerel_389064(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 = ((393216 &(1<<(((*(*m).calleesym).kind)&31)))!=0);
		LA38: ;
		if (!LOC35) goto LA39;
		incmatches_393124(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: ;
	{
		NIM_BOOL LOC54;
		Ttype225847* inlined;
		TY393275 LOC58;
		LOC54 = 0;
		LOC54 = !((r == ((NU8) 0)));
		if (!(LOC54)) goto LA55;
		LOC54 = isinlineiterator_393087(f);
		LA55: ;
		if (!LOC54) goto LA56;
		inlined = newtypes_280221(((NU8) 59), c);
		if ((*inlined).sons) nimGCunrefNoCycle((*inlined).sons);
		(*inlined).sons = (Ttypeseq225843*) newSeqRC1((&NTI225843), 1);
		memset((void*)LOC58, 0, sizeof(LOC58));
		LOC58[0] = argtype;
		asgnRefNoCycle((void**) (&(*inlined).sons->data[0]), LOC58[0]);
		asgnRefNoCycle((void**) (&(*inlined).n), argsemantized);
		put_388291((&(*m).bindings), f, inlined);
		result = argsemantized;
		goto BeforeRet;
	}
	LA56: ;
	bothmetacounter = ((NI) 0);
	lastbindingslength = ((NI) -1);
	{
		while (1) {
			NIM_BOOL LOC61;
			NIM_BOOL LOC62;
			LOC61 = 0;
			LOC62 = 0;
			LOC62 = (r == ((NU8) 5));
			if (!(LOC62)) goto LA63;
			LOC62 = !((lastbindingslength == (*m).bindings.counter));
			LA63: ;
			LOC61 = LOC62;
			if (!(LOC61)) goto LA64;
			LOC61 = (bothmetacounter < ((NI) 100));
			LA64: ;
			if (!LOC61) goto LA60;
			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 LA67;
				result = (*c).seminferredlambda.ClEnv? (*c).seminferredlambda.ClPrc(c, (*m).bindings, arg, (*c).seminferredlambda.ClEnv):((TMP2769)((*c).seminferredlambda.ClPrc))(c, (*m).bindings, arg);
			}
			goto LA65;
			LA67: ;
			{
				if (!!(((*arg).kind == ((NU8) 3)))) goto LA70;
				result = NIM_NIL;
				goto BeforeRet;
			}
			goto LA65;
			LA70: ;
			{
				Tsym225841* inferred;
				inferred = (*c).semgenerateinstance.ClEnv? (*c).semgenerateinstance.ClPrc(c, (*arg).kindU.S4.sym, (*m).bindings, (*arg).info, (*c).semgenerateinstance.ClEnv):((TMP2770)((*c).semgenerateinstance.ClPrc))(c, (*arg).kindU.S4.sym, (*m).bindings, (*arg).info);
				result = newsymnode_227338(inferred, (*arg).info);
			}
			LA65: ;
			(*m).convmatches += ((NI) 1);
			arg = result;
			r = typerel_389064(m, f, (*arg).typ, NIM_TRUE);
		} LA60: ;
	}
	switch (r) {
	case ((NU8) 1):
	{
		(*m).convmatches += ((NI) 1);
		result = implicitconv_392849(((NU8) 58), f, arg, (&(*m)), c);
	}
	break;
	case ((NU8) 2):
	{
		(*m).intconvmatches += ((NI) 1);
		result = implicitconv_392849(((NU8) 58), f, arg, (&(*m)), c);
	}
	break;
	case ((NU8) 3):
	{
		(*m).subtypematches += ((NI) 1);
		{
			if (!((*f).kind == ((NU8) 8))) goto LA78;
			result = arg;
		}
		goto LA76;
		LA78: ;
		{
			result = implicitconv_392849(((NU8) 59), f, arg, (&(*m)), c);
		}
		LA76: ;
	}
	break;
	case ((NU8) 4):
	{
		(*m).subtypematches += ((NI) 1);
		{
			if (!((*f).kind == ((NU8) 23))) goto LA84;
			result = arg;
		}
		goto LA82;
		LA84: ;
		{
			result = implicitconv_392849(((NU8) 58), f, arg, (&(*m)), c);
		}
		LA82: ;
	}
	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 LA90;
			result = (*c).seminferredlambda.ClEnv? (*c).seminferredlambda.ClPrc(c, (*m).bindings, arg, (*c).seminferredlambda.ClEnv):((TMP2773)((*c).seminferredlambda.ClPrc))(c, (*m).bindings, arg);
		}
		goto LA88;
		LA90: ;
		{
			if (!!(((*arg).kind == ((NU8) 3)))) goto LA93;
			result = NIM_NIL;
			goto BeforeRet;
		}
		goto LA88;
		LA93: ;
		{
			Tsym225841* inferred;
			inferred = (*c).semgenerateinstance.ClEnv? (*c).semgenerateinstance.ClPrc(c, (*arg).kindU.S4.sym, (*m).bindings, (*arg).info, (*c).semgenerateinstance.ClEnv):((TMP2774)((*c).semgenerateinstance.ClPrc))(c, (*arg).kindU.S4.sym, (*m).bindings, (*arg).info);
			result = newsymnode_227338(inferred, (*arg).info);
		}
		LA88: ;
		{
			if (!(r == ((NU8) 7))) goto LA98;
			(*m).convmatches += ((NI) 1);
			result = implicitconv_392849(((NU8) 58), f, result, (&(*m)), c);
		}
		goto LA96;
		LA98: ;
		{
			(*m).genericmatches += ((NI) 1);
		}
		LA96: ;
	}
	break;
	case ((NU8) 8):
	{
		(*m).genericmatches += ((NI) 1);
		{
			if (!((*arg).typ == NIM_NIL)) goto LA104;
			result = arg;
		}
		goto LA102;
		LA104: ;
		{
			Ttype225847* LOC107;
			LOC107 = 0;
			LOC107 = skiptypes_229167((*arg).typ, IL64(211106240964608));
			if (!((*LOC107).kind == ((NU8) 18))) goto LA108;
			result = implicitconv_392849(((NU8) 59), f, arg, (&(*m)), c);
		}
		goto LA102;
		LA108: ;
		{
			NIM_BOOL LOC111;
			LOC111 = 0;
			LOC111 = isemptycontainer_264978((*arg).typ);
			if (!LOC111) goto LA112;
			result = copytree_230028(arg);
			asgnRefNoCycle((void**) (&(*result).typ), getinstantiatedtype_392812(c, arg, (&(*m)), f));
		}
		goto LA102;
		LA112: ;
		{
			result = arg;
		}
		LA102: ;
	}
	break;
	case ((NU8) 5):
	{
		result = NIM_NIL;
	}
	break;
	case ((NU8) 9):
	{
		(*m).intconvmatches += ((NI) 256);
		result = implicitconv_392849(((NU8) 58), f, arg, (&(*m)), c);
	}
	break;
	case ((NU8) 10):
	{
		(*m).exactmatches += ((NI) 1);
		result = arg;
		{
			Ttype225847* LOC120;
			LOC120 = 0;
			LOC120 = skiptypes_229167(f, IL64(211106240964608));
			if (!((*LOC120).kind == ((NU8) 18))) goto LA121;
			result = implicitconv_392849(((NU8) 59), f, arg, (&(*m)), c);
		}
		LA121: ;
	}
	break;
	case ((NU8) 0):
	{
		{
			if (!((*a).kind == ((NU8) 50) || (*a).kind == ((NU8) 60))) goto LA126;
			(*m).genericmatches += ((NI) 1);
			(*m).fauxmatch = (*a).kind;
			result = arg;
			goto BeforeRet;
		}
		LA126: ;
		result = userconvmatch_392884(c, m, f, a, arg);
		{
			NIM_BOOL LOC130;
			LOC130 = 0;
			LOC130 = (result == NIM_NIL);
			if (!(LOC130)) goto LA131;
			LOC130 = ((*f).kind == ((NU8) 48));
			LA131: ;
			if (!LOC130) goto LA132;
			{
				if (!!(((*f).n == NIM_NIL))) goto LA136;
				result = localconvmatch_392990(c, m, f, a, arg);
			}
			goto LA134;
			LA136: ;
			{
				Ttype225847* LOC139;
				LOC139 = 0;
				LOC139 = base_255039(f);
				r = typerel_389064(m, LOC139, a, NIM_TRUE);
				{
					if (!(((NU8) 8) <= r)) goto LA142;
					(*m).convmatches += ((NI) 1);
					result = copytree_230028(arg);
					{
						Ttype225847* LOC148;
						if (!(r == ((NU8) 8))) goto LA146;
						LOC148 = 0;
						LOC148 = base_255039(f);
						asgnRefNoCycle((void**) (&(*result).typ), getinstantiatedtype_392812(c, arg, (&(*m)), LOC148));
					}
					LA146: ;
					(*m).basetypematch = NIM_TRUE;
				}
				goto LA140;
				LA142: ;
				{
					Ttype225847* LOC150;
					LOC150 = 0;
					LOC150 = base_255039(f);
					result = userconvmatch_392884(c, m, LOC150, a, arg);
				}
				LA140: ;
			}
			LA134: ;
		}
		LA132: ;
	}
	break;
	}
	}BeforeRet: ;
	return result;
}

N_NIMCALL(void, copycandidate_388492)(Tcandidate388209* a, Tcandidate388209* 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_230028((*b).call));
	(*a).basetypematch = (*b).basetypematch;
	copyidtable_227091((&(*a).bindings), (*b).bindings);
}

N_NIMCALL(NI, sumgeneric_388504)(Ttype225847* t_388506) {
	NI result;
	Ttype225847* t;
	NI isvar;
{	result = 0;
	t = t_388506;
	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_228426(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_228426(t);
				{
					if (!((*t).kind == ((NU8) 3))) goto LA8;
					goto LA1;
				}
				LA8: ;
				result += ((NI) 1);
			}
			break;
			case ((NU8) 9):
			case ((NU8) 18):
			{
				result += ((NI) (((*t).kind == ((NU8) 9))));
				{
					NI i_388599;
					NI HEX3Atmp_388611;
					NI LOC12;
					NI res_388614;
					i_388599 = 0;
					HEX3Atmp_388611 = 0;
					LOC12 = 0;
					LOC12 = len_228369(t);
					HEX3Atmp_388611 = (LOC12 - 1);
					res_388614 = ((NI) 0);
					{
						while (1) {
							NI LOC15;
							if (!(res_388614 <= HEX3Atmp_388611)) goto LA14;
							i_388599 = res_388614;
							LOC15 = 0;
							LOC15 = sumgeneric_388504((*t).sons->data[i_388599]);
							result += LOC15;
							res_388614 += ((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) 25):
			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_388639)(Ttype225847* a, Ttype225847* b) {
	NI result;
	NI winner;
{	result = 0;
	winner = ((NI) 0);
	{
		NI i_388667;
		NI HEX3Atmp_388802;
		NI LOC2;
		NI LOC3;
		NI res_388805;
		i_388667 = 0;
		HEX3Atmp_388802 = 0;
		LOC2 = 0;
		LOC2 = len_228369(a);
		LOC3 = 0;
		LOC3 = len_228369(b);
		HEX3Atmp_388802 = (((LOC2 <= LOC3) ? LOC2 : LOC3) - 1);
		res_388805 = ((NI) 1);
		{
			while (1) {
				NI x;
				NI y;
				if (!(res_388805 <= HEX3Atmp_388802)) goto LA5;
				i_388667 = res_388805;
				x = sumgeneric_388504((*a).sons->data[i_388667]);
				y = sumgeneric_388504((*b).sons->data[i_388667]);
				{
					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_388805 += ((NI) 1);
			} LA5: ;
		}
	}
	result = winner;
	}BeforeRet: ;
	return result;
}

N_NIMCALL(NI, cmpcandidates_388824)(Tcandidate388209* a, Tcandidate388209* 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_388639((*a).callee, (*b).callee);
	}BeforeRet: ;
	return result;
}

N_NIMCALL(Tnode225809*, paramtypesmatch_393733)(Tcandidate388209* m, Ttype225847* f, Ttype225847* a, Tnode225809* arg, Tnode225809* argorig) {
	Tnode225809* 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_393191(m, f, a, arg, argorig);
	}
	goto LA1;
	LA5: ;
	{
		Tcontext280023* c;
		Tcandidate388209 x;
		Tcandidate388209 y;
		Tcandidate388209 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_388278(c, (&x), (*m).callee);
		initcandidate_388278(c, (&y), (*m).callee);
		initcandidate_388278(c, (&z), (*m).callee);
		x.calleesym = (*m).calleesym;
		y.calleesym = (*m).calleesym;
		z.calleesym = (*m).calleesym;
		best = ((NI) -1);
		{
			NI i_393784;
			NI HEX3Atmp_394007;
			NI LOC9;
			NI res_394010;
			i_393784 = 0;
			HEX3Atmp_394007 = 0;
			LOC9 = 0;
			LOC9 = sonslen_228387(arg);
			HEX3Atmp_394007 = (NI)(LOC9 - ((NI) 1));
			res_394010 = ((NI) 0);
			{
				while (1) {
					if (!(res_394010 <= HEX3Atmp_394007)) goto LA11;
					i_393784 = res_394010;
					{
						NU8 r;
						if (!((126976 &(1<<(((*(*(*arg).kindU.S6.sons->data[i_393784]).kindU.S4.sym).kind)&31)))!=0)) goto LA14;
						copycandidate_388492((&z), (&(*m)));
						z.callee = (*(*arg).kindU.S6.sons->data[i_393784]).typ;
						z.calleesym = (*(*arg).kindU.S6.sons->data[i_393784]).kindU.S4.sym;
						r = typerel_389064((&z), f, (*(*arg).kindU.S6.sons->data[i_393784]).typ, NIM_TRUE);
						incmatches_393124((&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), (&NTI388209));
								best = i_393784;
							}
							break;
							case ((NU8) 1):
							{
								NI cmp;
								cmp = cmpcandidates_388824((&x), (&z));
								{
									if (!(cmp < ((NI) 0))) goto LA24;
									best = i_393784;
									genericAssign((void*)(&x), (void*)(&z), (&NTI388209));
								}
								goto LA22;
								LA24: ;
								{
									if (!(cmp == ((NI) 0))) goto LA27;
									genericAssign((void*)(&y), (void*)(&z), (&NTI388209));
								}
								goto LA22;
								LA27: ;
								LA22: ;
							}
							break;
							}
						}
						LA18: ;
					}
					LA14: ;
					res_394010 += ((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_388824((&x), (&y));
			LOC34 = (LOC36 == ((NI) 0));
			LA35: ;
			if (!LOC34) goto LA37;
			{
				if (!!((x.state == ((NU8) 1)))) goto LA41;
				internalerror_196172((*arg).info, ((NimStringDesc*) &TMP2781));
			}
			LA41: ;
			{
				if (!((*f).kind == ((NU8) 6))) goto LA45;
				result = arg;
			}
			goto LA43;
			LA45: ;
			{
				result = NIM_NIL;
			}
			LA43: ;
		}
		goto LA29;
		LA37: ;
		{
			markused_388253((*arg).info, (*(*arg).kindU.S6.sons->data[best]).kindU.S4.sym);
			result = paramtypesmatchaux_393191(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_394817)(Tcontext280023* c, Ttype225847* f, Ttype225847* a) {
	NIM_BOOL result;
	Tcandidate388209 m;
	Tnode225809* res;
	result = 0;
	memset((void*)(&m), 0, sizeof(m));
	initcandidate_388278(c, (&m), f);
	res = paramtypesmatch_393733((&m), f, a, emptynode_226807, NIM_NIL);
	result = !((res == NIM_NIL));
	return result;
}

static N_INLINE(NIM_BOOL, typefits_397542)(Tcontext280023* c, Tsym225841* s, Ttype225847* firstarg) {
	NIM_BOOL result;
{	result = 0;
	{
		NIM_BOOL LOC3;
		NIM_BOOL LOC4;
		NI LOC6;
		Tsym225841* m;
		LOC3 = 0;
		LOC4 = 0;
		LOC4 = !(((*s).typ == NIM_NIL));
		if (!(LOC4)) goto LA5;
		LOC6 = 0;
		LOC6 = sonslen_228351((*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_233243(s);
		{
			NIM_BOOL LOC12;
			Ttype225847* exp;
			LOC12 = 0;
			LOC12 = !((m == NIM_NIL));
			if (!(LOC12)) goto LA13;
			LOC12 = (((*m).flags &(1<<((((NU8) 13))&31)))!=0);
			LA13: ;
			if (!LOC12) goto LA14;
			{
				if (!((*s).kind == ((NU8) 7))) goto LA18;
				goto BeforeRet;
			}
			LA18: ;
			exp = skiptypes_229167((*(*s).typ).sons->data[((NI) 1)], 8390656);
			{
				if (!((*exp).kind == ((NU8) 48))) goto LA22;
				exp = elemtype_255522(exp);
			}
			LA22: ;
			{
				if (!((*exp).kind == ((NU8) 6) || (*exp).kind == ((NU8) 7) || (*exp).kind == ((NU8) 12) || (*exp).kind == ((NU8) 58))) goto LA26;
				goto BeforeRet;
			}
			LA26: ;
		}
		LA14: ;
		result = argtypematches_394817(c, (*(*s).typ).sons->data[((NI) 1)], firstarg);
	}
	LA8: ;
	}BeforeRet: ;
	return result;
}

N_NIMCALL(void, suggestoperations_397636)(Tcontext280023* c, Tnode225809* n, Ttype225847* typ, NI* outputs) {
	NIM_BOOL islocal_397802;
	islocal_397802 = NIM_TRUE;
	{
		Tscope225835* scope_397804;
		Tscope225835* HEX3Atmp_398091;
		Tscope225835* current_398094;
		scope_397804 = 0;
		HEX3Atmp_398091 = 0;
		HEX3Atmp_398091 = (*c).currentscope;
		current_398094 = HEX3Atmp_398091;
		{
			while (1) {
				Tsymseq225811* entries_397806;
				Tsymseq225811* result_397827;
				TY396048 LOC11;
				if (!!((current_398094 == NIM_NIL))) goto LA3;
				scope_397804 = current_398094;
				{
					if (!(scope_397804 == (*c).toplevelscope)) goto LA6;
					islocal_397802 = NIM_FALSE;
				}
				LA6: ;
				result_397827 = (Tsymseq225811*) newSeq((&NTI225811), 0);
				{
					Tsym225841* x_397831;
					Tstrtable225813 HEX3Atmp_398079;
					Ttabiter233119 it_398082;
					Tsym225841* s_398084;
					x_397831 = 0;
					memset((void*)(&HEX3Atmp_398079), 0, sizeof(HEX3Atmp_398079));
					HEX3Atmp_398079.counter = (*scope_397804).symbols.counter;
					HEX3Atmp_398079.data = (*scope_397804).symbols.data;
					memset((void*)(&it_398082), 0, sizeof(it_398082));
					s_398084 = inittabiter_233124((&it_398082), HEX3Atmp_398079);
					{
						while (1) {
							if (!!((s_398084 == NIM_NIL))) goto LA10;
							x_397831 = s_398084;
							result_397827 = (Tsymseq225811*) incrSeqV2(&(result_397827)->Sup, sizeof(Tsym225841*));
							asgnRefNoCycle((void**) (&result_397827->data[result_397827->Sup.len]), x_397831);
							++result_397827->Sup.len;
							s_398084 = nextiter_233132((&it_398082), HEX3Atmp_398079);
						} LA10: ;
					}
				}
				genericSeqAssign((&entries_397806), result_397827, (&NTI225811));
				memset((void*)(&LOC11), 0, sizeof(LOC11));
				LOC11.ClPrc = ((TMP2734) (HEX3Aanonymous_398030)); LOC11.ClEnv = NIM_NIL;
				sort_396041(entries_397806->data, entries_397806->Sup.len, LOC11, ((NU8) 1));
				{
					Tsym225841* item_397812;
					NI i_398088;
					NI L_398090;
					item_397812 = 0;
					i_398088 = ((NI) 0);
					L_398090 = (entries_397806 ? entries_397806->Sup.len : 0);
					{
						while (1) {
							Tsym225841* it;
							if (!(i_398088 < L_398090)) goto LA14;
							item_397812 = entries_397806->data[i_398088];
							it = item_397812;
							{
								NIM_BOOL LOC17;
								NimStringDesc* LOC21;
								Suggest395010 LOC22;
								LOC17 = 0;
								LOC17 = filtersymnoopr_395443(it);
								if (!(LOC17)) goto LA18;
								LOC17 = typefits_397542(c, it, typ);
								LA18: ;
								if (!LOC17) goto LA19;
								LOC21 = 0;
								LOC21 = HEX24_168755(((NU8) 1));
								memset((void*)(&LOC22), 0, sizeof(LOC22));
								symtosuggest_395404(it, islocal_397802, LOC21, (&LOC22));
								suggestresult_395414((&LOC22));
								(*outputs) += ((NI) 1);
							}
							LA19: ;
							i_398088 += ((NI) 1);
						} LA14: ;
					}
				}
				current_398094 = (*current_398094).parent;
			} LA3: ;
		}
	}
}

N_NIMCALL(void, suggestobject_395718)(Tcontext280023* c, Tnode225809* n, NI* outputs) {
	switch ((*n).kind) {
	case ((NU8) 138):
	{
		{
			NI i_395736;
			NI HEX3Atmp_395756;
			NI LOC3;
			NI res_395759;
			i_395736 = 0;
			HEX3Atmp_395756 = 0;
			LOC3 = 0;
			LOC3 = sonslen_228387(n);
			HEX3Atmp_395756 = (NI)(LOC3 - ((NI) 1));
			res_395759 = ((NI) 0);
			{
				while (1) {
					if (!(res_395759 <= HEX3Atmp_395756)) goto LA5;
					i_395736 = res_395759;
					suggestobject_395718(c, (*n).kindU.S6.sons->data[i_395736], outputs);
					res_395759 += ((NI) 1);
				} LA5: ;
			}
		}
	}
	break;
	case ((NU8) 139):
	{
		NI L;
		L = sonslen_228387(n);
		{
			if (!(((NI) 0) < L)) goto LA9;
			suggestobject_395718(c, (*n).kindU.S6.sons->data[((NI) 0)], outputs);
			{
				NI i_395752;
				NI HEX3Atmp_395764;
				NI res_395767;
				i_395752 = 0;
				HEX3Atmp_395764 = 0;
				HEX3Atmp_395764 = (NI)(L - ((NI) 1));
				res_395767 = ((NI) 1);
				{
					while (1) {
						Tnode225809* LOC14;
						if (!(res_395767 <= HEX3Atmp_395764)) goto LA13;
						i_395752 = res_395767;
						LOC14 = 0;
						LOC14 = lastson_228406((*n).kindU.S6.sons->data[i_395752]);
						suggestobject_395718(c, LOC14, outputs);
						res_395767 += ((NI) 1);
					} LA13: ;
				}
			}
		}
		LA9: ;
	}
	break;
	case ((NU8) 3):
	{
		suggestfield_395632(c, (*n).kindU.S4.sym, outputs);
	}
	break;
	default:
	{
	}
	break;
	}
}

N_NIMCALL(void, suggestfieldaccess_398201)(Tcontext280023* c, Tnode225809* n, NI* outputs) {
	Ttype225847* 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;
				{
					Tsym225841* it_398251;
					Tstrtable225813 HEX3Atmp_398360;
					Ttabiter233119 it_398363;
					Tsym225841* s_398365;
					it_398251 = 0;
					memset((void*)(&HEX3Atmp_398360), 0, sizeof(HEX3Atmp_398360));
					HEX3Atmp_398360.counter = (*(*c).toplevelscope).symbols.counter;
					HEX3Atmp_398360.data = (*(*c).toplevelscope).symbols.data;
					memset((void*)(&it_398363), 0, sizeof(it_398363));
					s_398365 = inittabiter_233124((&it_398363), HEX3Atmp_398360);
					{
						while (1) {
							if (!!((s_398365 == NIM_NIL))) goto LA17;
							it_398251 = s_398365;
							{
								NIM_BOOL LOC20;
								NimStringDesc* LOC23;
								Suggest395010 LOC24;
								LOC20 = 0;
								LOC20 = filtersym_395427(it_398251);
								if (!LOC20) goto LA21;
								LOC23 = 0;
								LOC23 = HEX24_168755(((NU8) 1));
								memset((void*)(&LOC24), 0, sizeof(LOC24));
								symtosuggest_395404(it_398251, NIM_FALSE, LOC23, (&LOC24));
								suggestresult_395414((&LOC24));
								(*outputs) += ((NI) 1);
							}
							LA21: ;
							s_398365 = nextiter_233132((&it_398363), HEX3Atmp_398360);
						} LA17: ;
					}
				}
			}
			goto LA11;
			LA13: ;
			{
				{
					Tsym225841* it_398263;
					Tstrtable225813 HEX3Atmp_398367;
					Ttabiter233119 it_398370;
					Tsym225841* s_398372;
					it_398263 = 0;
					memset((void*)(&HEX3Atmp_398367), 0, sizeof(HEX3Atmp_398367));
					HEX3Atmp_398367.counter = (*(*n).kindU.S4.sym).kindU.S3.tab.counter;
					HEX3Atmp_398367.data = (*(*n).kindU.S4.sym).kindU.S3.tab.data;
					memset((void*)(&it_398370), 0, sizeof(it_398370));
					s_398372 = inittabiter_233124((&it_398370), HEX3Atmp_398367);
					{
						while (1) {
							if (!!((s_398372 == NIM_NIL))) goto LA28;
							it_398263 = s_398372;
							{
								NIM_BOOL LOC31;
								NimStringDesc* LOC34;
								Suggest395010 LOC35;
								LOC31 = 0;
								LOC31 = filtersym_395427(it_398263);
								if (!LOC31) goto LA32;
								LOC34 = 0;
								LOC34 = HEX24_168755(((NU8) 1));
								memset((void*)(&LOC35), 0, sizeof(LOC35));
								symtosuggest_395404(it_398263, NIM_FALSE, LOC34, (&LOC35));
								suggestresult_395414((&LOC35));
								(*outputs) += ((NI) 1);
							}
							LA32: ;
							s_398372 = nextiter_233132((&it_398370), HEX3Atmp_398367);
						} LA28: ;
					}
				}
			}
			LA11: ;
		}
		goto LA5;
		LA9: ;
		{
			suggesteverything_398128(c, n, outputs);
		}
		LA5: ;
	}
	goto LA1;
	LA3: ;
	{
		NIM_BOOL LOC38;
		NIM_BOOL LOC39;
		Ttype225847* 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_395667(c, (*t).n, outputs);
				t = (*t).sons->data[((NI) 0)];
			} LA45: ;
		}
		suggestoperations_397636(c, n, typ, outputs);
	}
	goto LA1;
	LA42: ;
	{
		typ = skiptypes_229167(typ, 14682112);
		{
			Ttype225847* t;
			if (!((*typ).kind == ((NU8) 17))) goto LA49;
			t = typ;
			{
				while (1) {
					suggestobject_395718(c, (*t).n, outputs);
					{
						if (!((*t).sons->data[((NI) 0)] == NIM_NIL)) goto LA55;
						goto LA51;
					}
					LA55: ;
					t = skiptypes_229167((*t).sons->data[((NI) 0)], 2048);
				}
			} LA51: ;
			suggestoperations_397636(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_395667(c, (*typ).n, outputs);
			suggestoperations_397636(c, n, typ, outputs);
		}
		goto LA47;
		LA60: ;
		{
			suggestoperations_397636(c, n, typ, outputs);
		}
		LA47: ;
	}
	LA1: ;
}

N_NIMCALL(Tnode225809*, findclosestcall_398494)(Tnode225809* n) {
	Tnode225809* 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_398413((*n).info);
		LOC3 = (LOC5 == ((NU8) 2));
		LA4: ;
		if (!LOC3) goto LA6;
		result = n;
	}
	goto LA1;
	LA6: ;
	{
		{
			NI i_398535;
			NI HEX3Atmp_398550;
			NI LOC10;
			NI res_398553;
			i_398535 = 0;
			HEX3Atmp_398550 = 0;
			LOC10 = 0;
			LOC10 = safelen_226126(n);
			HEX3Atmp_398550 = (LOC10 - 1);
			res_398553 = ((NI) 0);
			{
				while (1) {
					if (!(res_398553 <= HEX3Atmp_398550)) goto LA12;
					i_398535 = res_398553;
					result = findclosestcall_398494((*n).kindU.S6.sons->data[i_398535]);
					{
						if (!!((result == NIM_NIL))) goto LA15;
						goto BeforeRet;
					}
					LA15: ;
					res_398553 += ((NI) 1);
				} LA12: ;
			}
		}
	}
	LA1: ;
	}BeforeRet: ;
	return result;
}

N_NIMCALL(NI, HEX3Aanonymous_396030)(Tsym225841* a_395858, Tsym225841* b_395860) {
	NI result;
{	result = 0;
	result = cmp_6577((*(*a_395858).name).s, (*(*b_395860).name).s);
	goto BeforeRet;
	}BeforeRet: ;
	return result;
}

N_NIMCALL(NIM_BOOL, namefits_395792)(Tcontext280023* c, Tsym225841* s, Tnode225809* n) {
	NIM_BOOL result;
	Tnode225809* op;
	Tident198021* 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_388303)(Tcontext280023* ctx, Tcandidate388209* c, Tsym225841* callee, Tnode225809* binding, NI calleescope) {
	initcandidateaux_388266(ctx, c, (*callee).typ);
	unsureAsgnRef((void**) (&(*c).calleesym), callee);
	{
		NIM_BOOL LOC3;
		LOC3 = 0;
		LOC3 = ((520192 &(1<<(((*callee).kind)&31)))!=0);
		if (!(LOC3)) goto LA4;
		LOC3 = (calleescope == ((NI) -1));
		LA4: ;
		if (!LOC3) goto LA5;
		{
			Tsym225841* LOC9;
			Tsym225841* owner;
			LOC9 = 0;
			LOC9 = originatingmodule_230735(callee);
			if (!(LOC9 == (*ctx).module)) goto LA10;
			(*c).calleescope = ((NI) 2);
			owner = callee;
			{
				while (1) {
					owner = skipgenericowner_230694(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_229057((&(*c).bindings));
	genericSeqAssign((&(*c).errors), NIM_NIL, (&NTI225811));
	{
		NIM_BOOL LOC22;
		Tnode225809* typeparams;
		LOC22 = 0;
		LOC22 = !((binding == NIM_NIL));
		if (!(LOC22)) goto LA23;
		LOC22 = ((520192 &(1<<(((*callee).kind)&31)))!=0);
		LA23: ;
		if (!LOC22) goto LA24;
		typeparams = HEX5BHEX5D_226244((*callee).ast, ((NI) 2));
		{
			NI i_388393;
			NI HEX3Atmp_388438;
			NI LOC27;
			NI LOC28;
			NI res_388441;
			i_388393 = 0;
			HEX3Atmp_388438 = 0;
			LOC27 = 0;
			LOC27 = sonslen_228387(typeparams);
			LOC28 = 0;
			LOC28 = sonslen_228387(binding);
			HEX3Atmp_388438 = ((LOC27 <= (NI)(LOC28 - ((NI) 1))) ? LOC27 : (NI)(LOC28 - ((NI) 1)));
			res_388441 = ((NI) 1);
			{
				while (1) {
					Ttype225847* formaltypeparam;
					Ttype225847* bound;
					Tnode225809* LOC31;
					if (!(res_388441 <= HEX3Atmp_388438)) goto LA30;
					i_388393 = res_388441;
					formaltypeparam = (*(*typeparams).kindU.S6.sons->data[(NI)(i_388393 - ((NI) 1))]).typ;
					LOC31 = 0;
					LOC31 = HEX5BHEX5D_226244(binding, i_388393);
					bound = (*LOC31).typ;
					{
						NimStringDesc* LOC36;
						if (!!(!((bound == NIM_NIL)))) goto LA34;
						LOC36 = 0;
						LOC36 = HEX24_196279(TMP2787);
						internalerror_196191(LOC36);
					}
					LA34: ;
					{
						if (!((*formaltypeparam).kind == ((NU8) 8))) goto LA39;
						{
							if (!!(((*bound).kind == ((NU8) 8)))) goto LA43;
							bound = maketypedesc_280684(ctx, bound);
						}
						LA43: ;
					}
					goto LA37;
					LA39: ;
					{
						bound = skiptypes_229167(bound, 256);
					}
					LA37: ;
					put_388291((&(*c).bindings), formaltypeparam, bound);
					res_388441 += ((NI) 1);
				} LA30: ;
			}
		}
	}
	LA24: ;
}

N_NIMCALL(Ttype225847*, arrayconstr_394148)(Tcontext280023* c, Tlineinfo190352 info) {
	Ttype225847* result;
	Ttype225847* LOC1;
	Ttype225847* LOC2;
	Ttype225847* LOC3;
	result = 0;
	result = newtypes_280221(((NU8) 4), c);
	LOC1 = 0;
	LOC1 = getsystype_274190(((NU8) 31));
	LOC2 = 0;
	LOC2 = makerangetype_281193(c, IL64(0), IL64(-1), info, LOC1);
	rawaddson_229498(result, LOC2);
	LOC3 = 0;
	LOC3 = newtypes_280221(((NU8) 3), c);
	rawaddson_229498(result, LOC3);
	return result;
}

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

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

N_NIMCALL(void, preparenamedparam_394113)(Tnode225809* a) {
	{
		Tlineinfo190352 info;
		Tident198021* 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_286010((*a).kindU.S6.sons->data[((NI) 0)]);
		asgnRefNoCycle((void**) (&(*a).kindU.S6.sons->data[((NI) 0)]), newidentnode_227313(LOC5, info));
	}
	LA3: ;
}

N_NIMCALL(Tnode225809*, prepareoperand_394052)(Tcontext280023* c, Ttype225847* formal, Tnode225809* a) {
	Tnode225809* result;
	result = 0;
	{
		NIM_BOOL LOC3;
		NI LOC5;
		LOC3 = 0;
		LOC3 = ((*formal).kind == ((NU8) 6));
		if (!(LOC3)) goto LA4;
		LOC5 = 0;
		LOC5 = len_228369(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(Ttype225847*, arrayconstr_394136)(Tcontext280023* c, Tnode225809* n) {
	Ttype225847* result;
	Ttype225847* LOC1;
	Ttype225847* LOC2;
	Ttype225847* LOC3;
	result = 0;
	result = newtypes_280221(((NU8) 4), c);
	LOC1 = 0;
	LOC1 = getsystype_274190(((NU8) 31));
	LOC2 = 0;
	LOC2 = makerangetype_281193(c, IL64(0), IL64(0), (*n).info, LOC1);
	rawaddson_229498(result, LOC2);
	LOC3 = 0;
	LOC3 = skiptypes_229167((*n).typ, 8423424);
	addsonskipintlit_274729(result, LOC3);
	return result;
}

N_NIMCALL(Tnode225809*, prepareoperand_394093)(Tcontext280023* c, Tnode225809* a) {
	Tnode225809* 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_394231)(Tcontext280023* c, Tnode225809* n, Tnode225809* norig, Tcandidate388209* m, Intset222056* marker) {
	NI f;
	NI a;
	NI formallen;
	Tnode225809* LOC6;
	Tnode225809* container;
	Tsym225841* 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_227351((*n).kind, (*n).info));
	asgnRefNoCycle((void**) (&(*(*m).call).typ), base_255039((*m).callee));
	formallen = len_226098((*(*m).callee).n);
	LOC6 = 0;
	LOC6 = copytree_230028((*n).kindU.S6.sons->data[((NI) 0)]);
	addson_227819((*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_226098(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 &(1<<((((NU8) 0))&31)))!=0));
				LA24: ;
				LOC17 = LOC21;
				LA20: ;
				if (!LOC17) goto LA25;
				{
					Ttype225847* LOC31;
					if (!container == 0) goto LA29;
					LOC31 = 0;
					LOC31 = arrayconstr_394148(c, (*n).info);
					container = newnodeit_227807(((NU8) 41), (*(*n).kindU.S6.sons->data[a]).info, LOC31);
					setson_394029((*m).call, (NI)((*formal).position + ((NI) 1)), container);
				}
				goto LA27;
				LA29: ;
				{
					incrindextype_394159((*container).typ);
				}
				LA27: ;
				addson_227819(container, (*n).kindU.S6.sons->data[a]);
			}
			goto LA15;
			LA25: ;
			{
				Tnode225809* arg;
				if (!((*(*n).kindU.S6.sons->data[a]).kind == ((NU8) 33))) goto LA34;
				preparenamedparam_394113((*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_196128((*(*n).kindU.S6.sons->data[a]).info, ((NU16) 163), ((NimStringDesc*) &TMP2201));
					(*m).state = ((NU8) 2);
					goto BeforeRet;
				}
				LA38: ;
				formal = getsymfromlist_233228((*(*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_222898(marker, (*formal).position);
					if (!LOC46) goto LA47;
					localerror_196128((*(*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_394052(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_393733(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_306302((*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_306281((*(*n).kindU.S6.sons->data[a]).kindU.S6.sons->data[((NI) 1)]);
						if (!!(LOC69)) goto LA70;
						(*m).state = ((NU8) 2);
						goto BeforeRet;
					}
					LA70: ;
				}
				LA65: ;
				{
					Ttype225847* LOC76;
					if (!(*m).basetypematch) goto LA74;
					LOC76 = 0;
					LOC76 = arrayconstr_394136(c, arg);
					container = newnodeit_227807(((NU8) 41), (*(*n).kindU.S6.sons->data[a]).info, LOC76);
					addson_227819(container, arg);
					setson_394029((*m).call, (NI)((*formal).position + ((NI) 1)), container);
					{
						if (!!((f == (NI)(formallen - ((NI) 1))))) goto LA79;
						container = NIM_NIL;
					}
					LA79: ;
				}
				goto LA72;
				LA74: ;
				{
					setson_394029((*m).call, (NI)((*formal).position + ((NI) 1)), arg);
				}
				LA72: ;
				f += ((NI) 1);
			}
			goto LA15;
			LA34: ;
			{
				{
					if (!(formallen <= f)) goto LA85;
					{
						if (!(((*(*m).callee).flags &(1<<((((NU8) 0))&31)))!=0)) goto LA89;
						asgnRefNoCycle((void**) (&(*n).kindU.S6.sons->data[a]), prepareoperand_394093(c, (*n).kindU.S6.sons->data[a]));
						{
							Ttype225847* LOC93;
							Ttype225847* LOC96;
							Tnode225809* LOC97;
							Tnode225809* LOC98;
							LOC93 = 0;
							LOC93 = skiptypes_229167((*(*n).kindU.S6.sons->data[a]).typ, IL64(211106240964608));
							if (!((*LOC93).kind == ((NU8) 28))) goto LA94;
							LOC96 = 0;
							LOC96 = getsystype_274190(((NU8) 29));
							LOC97 = 0;
							LOC97 = copytree_230028((*n).kindU.S6.sons->data[a]);
							LOC98 = 0;
							LOC98 = implicitconv_392849(((NU8) 58), LOC96, LOC97, (&(*m)), c);
							addson_227819((*m).call, LOC98);
						}
						goto LA91;
						LA94: ;
						{
							Tnode225809* LOC100;
							LOC100 = 0;
							LOC100 = copytree_230028((*n).kindU.S6.sons->data[a]);
							addson_227819((*m).call, LOC100);
						}
						LA91: ;
					}
					goto LA87;
					LA89: ;
					{
						NIM_BOOL LOC102;
						Tnode225809* 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_394052(c, (*formal).typ, (*n).kindU.S6.sons->data[a]));
						arg = paramtypesmatch_393733(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_227819(container, arg);
							incrindextype_394159((*container).typ);
						}
						goto LA106;
						LA112: ;
						{
							(*m).state = ((NU8) 2);
							goto BeforeRet;
						}
						LA106: ;
					}
					goto LA87;
					LA104: ;
					{
						(*m).state = ((NU8) 2);
						goto BeforeRet;
					}
					LA87: ;
				}
				goto LA83;
				LA85: ;
				{
					Tnode225809* arg;
					{
						if (!!(((*(*(*(*m).callee).n).kindU.S6.sons->data[f]).kind == ((NU8) 3)))) goto LA119;
						internalerror_196172((*(*n).kindU.S6.sons->data[a]).info, ((NimStringDesc*) &TMP2789));
						goto BeforeRet;
					}
					LA119: ;
					formal = (*(*(*(*m).callee).n).kindU.S6.sons->data[f]).kindU.S4.sym;
					{
						NIM_BOOL LOC123;
						LOC123 = 0;
						LOC123 = containsorincl_222898(marker, (*formal).position);
						if (!(LOC123)) goto LA124;
						LOC123 = container == 0;
						LA124: ;
						if (!LOC123) goto LA125;
						localerror_196128((*(*n).kindU.S6.sons->data[a]).info, ((NU16) 147), (*(*formal).name).s);
						(*m).state = ((NU8) 2);
						goto BeforeRet;
					}
					LA125: ;
					(*m).basetypematch = NIM_FALSE;
					asgnRefNoCycle((void**) (&(*n).kindU.S6.sons->data[a]), prepareoperand_394052(c, (*formal).typ, (*n).kindU.S6.sons->data[a]));
					arg = paramtypesmatch_393733(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 LA129;
						(*m).state = ((NU8) 2);
						goto BeforeRet;
					}
					LA129: ;
					{
						Tnode225809* LOC141;
						NI LOC142;
						if (!(*m).basetypematch) goto LA133;
						{
							Ttype225847* LOC139;
							if (!container == 0) goto LA137;
							LOC139 = 0;
							LOC139 = arrayconstr_394136(c, arg);
							container = newnodeit_227807(((NU8) 41), (*(*n).kindU.S6.sons->data[a]).info, LOC139);
						}
						goto LA135;
						LA137: ;
						{
							incrindextype_394159((*container).typ);
						}
						LA135: ;
						addson_227819(container, arg);
						LOC141 = 0;
						LOC141 = implicitconv_392849(((NU8) 58), (*formal).typ, container, (&(*m)), c);
						setson_394029((*m).call, (NI)((*formal).position + ((NI) 1)), LOC141);
						LOC142 = 0;
						LOC142 = len_226098(n);
						f = ((f >= (NI)((NI)((NI)(formallen - LOC142) + a) + ((NI) 1))) ? f : (NI)((NI)((NI)(formallen - LOC142) + a) + ((NI) 1)));
					}
					goto LA131;
					LA133: ;
					{
						setson_394029((*m).call, (NI)((*formal).position + ((NI) 1)), arg);
						f += ((NI) 1);
						container = NIM_NIL;
					}
					LA131: ;
				}
				LA83: ;
				{
					if (!!((*formal).constraint == 0)) goto LA146;
					{
						NIM_BOOL LOC150;
						LOC150 = 0;
						LOC150 = matchnodekinds_306302((*formal).constraint, (*n).kindU.S6.sons->data[a]);
						if (!LOC150) goto LA151;
						(*m).genericmatches += ((NI) 100);
					}
					goto LA148;
					LA151: ;
					{
						(*m).state = ((NU8) 2);
						goto BeforeRet;
					}
					LA148: ;
				}
				LA146: ;
				{
					if (!((*(*formal).typ).kind == ((NU8) 23))) goto LA156;
					{
						NIM_BOOL LOC160;
						LOC160 = 0;
						LOC160 = islvalue_306281((*n).kindU.S6.sons->data[a]);
						if (!!(LOC160)) goto LA161;
						(*m).state = ((NU8) 2);
						goto BeforeRet;
					}
					LA161: ;
				}
				LA156: ;
			}
			LA15: ;
			a += ((NI) 1);
		} LA13: ;
	}
	}BeforeRet: ;
}

N_NIMCALL(void, partialmatch_394705)(Tcontext280023* c, Tnode225809* n, Tnode225809* norig, Tcandidate388209* m) {
	Intset222056 marker;
	memset((void*)(&marker), 0, sizeof(marker));
	chckNil((void*)(&marker));
	memset((void*)(&marker), 0, sizeof(marker));
	initintset_222927((&marker));
	matchesaux_394231(c, n, norig, m, (&marker));
}

N_NIMCALL(NIM_BOOL, argsfit_395821)(Tcontext280023* c, Tsym225841* candidate, Tnode225809* n, Tnode225809* norig) {
	NIM_BOOL result;
	result = 0;
	switch ((*candidate).kind) {
	case ((NU8) 12):
	case ((NU8) 13):
	case ((NU8) 14):
	case ((NU8) 15):
	case ((NU8) 16):
	case ((NU8) 6):
	case ((NU8) 18):
	case ((NU8) 17):
	{
		Tcandidate388209 m;
		memset((void*)(&m), 0, sizeof(m));
		initcandidate_388303(c, (&m), candidate, NIM_NIL, ((NI) -1));
		partialmatch_394705(c, n, norig, (&m));
		result = !((m.state == ((NU8) 2)));
	}
	break;
	default:
	{
		result = NIM_FALSE;
	}
	break;
	}
	return result;
}

N_NIMCALL(void, suggestcall_395844)(Tcontext280023* c, Tnode225809* n, Tnode225809* norig, NI* outputs) {
	NIM_BOOL islocal_395852;
	islocal_395852 = NIM_TRUE;
	{
		Tscope225835* scope_395854;
		Tscope225835* HEX3Atmp_397505;
		Tscope225835* current_397508;
		scope_395854 = 0;
		HEX3Atmp_397505 = 0;
		HEX3Atmp_397505 = (*c).currentscope;
		current_397508 = HEX3Atmp_397505;
		{
			while (1) {
				Tsymseq225811* entries_395856;
				Tsymseq225811* result_395877;
				TY396048 LOC11;
				if (!!((current_397508 == NIM_NIL))) goto LA3;
				scope_395854 = current_397508;
				{
					if (!(scope_395854 == (*c).toplevelscope)) goto LA6;
					islocal_395852 = NIM_FALSE;
				}
				LA6: ;
				result_395877 = (Tsymseq225811*) newSeq((&NTI225811), 0);
				{
					Tsym225841* x_395881;
					Tstrtable225813 HEX3Atmp_397493;
					Ttabiter233119 it_397496;
					Tsym225841* s_397498;
					x_395881 = 0;
					memset((void*)(&HEX3Atmp_397493), 0, sizeof(HEX3Atmp_397493));
					HEX3Atmp_397493.counter = (*scope_395854).symbols.counter;
					HEX3Atmp_397493.data = (*scope_395854).symbols.data;
					memset((void*)(&it_397496), 0, sizeof(it_397496));
					s_397498 = inittabiter_233124((&it_397496), HEX3Atmp_397493);
					{
						while (1) {
							if (!!((s_397498 == NIM_NIL))) goto LA10;
							x_395881 = s_397498;
							result_395877 = (Tsymseq225811*) incrSeqV2(&(result_395877)->Sup, sizeof(Tsym225841*));
							asgnRefNoCycle((void**) (&result_395877->data[result_395877->Sup.len]), x_395881);
							++result_395877->Sup.len;
							s_397498 = nextiter_233132((&it_397496), HEX3Atmp_397493);
						} LA10: ;
					}
				}
				genericSeqAssign((&entries_395856), result_395877, (&NTI225811));
				memset((void*)(&LOC11), 0, sizeof(LOC11));
				LOC11.ClPrc = ((TMP2784) (HEX3Aanonymous_396030)); LOC11.ClEnv = NIM_NIL;
				sort_396041(entries_395856->data, entries_395856->Sup.len, LOC11, ((NU8) 1));
				{
					Tsym225841* item_395862;
					NI i_397502;
					NI L_397504;
					item_395862 = 0;
					i_397502 = ((NI) 0);
					L_397504 = (entries_395856 ? entries_395856->Sup.len : 0);
					{
						while (1) {
							Tsym225841* it;
							if (!(i_397502 < L_397504)) goto LA14;
							item_395862 = entries_395856->data[i_397502];
							it = item_395862;
							{
								NIM_BOOL LOC17;
								NIM_BOOL LOC18;
								NimStringDesc* LOC23;
								Suggest395010 LOC24;
								LOC17 = 0;
								LOC18 = 0;
								LOC18 = filtersym_395427(it);
								if (!(LOC18)) goto LA19;
								LOC18 = namefits_395792(c, it, n);
								LA19: ;
								LOC17 = LOC18;
								if (!(LOC17)) goto LA20;
								LOC17 = argsfit_395821(c, it, n, norig);
								LA20: ;
								if (!LOC17) goto LA21;
								LOC23 = 0;
								LOC23 = HEX24_168755(((NU8) 2));
								memset((void*)(&LOC24), 0, sizeof(LOC24));
								symtosuggest_395404(it, islocal_395852, LOC23, (&LOC24));
								suggestresult_395414((&LOC24));
								(*outputs) += ((NI) 1);
							}
							LA21: ;
							i_397502 += ((NI) 1);
						} LA14: ;
					}
				}
				current_397508 = (*current_397508).parent;
			} LA3: ;
		}
	}
}

N_NIMCALL(void, suggestexpr_398865)(Tcontext280023* c, Tnode225809* node) {
	NI outputs;
{	{
		NU8 cp;
		if (!!((((*node).flags &(1<<((((NU8) 14))&15)))!=0))) goto LA3;
		{
			if (!(gtrackpos_191901.line < ((NI16) 0))) goto LA7;
			goto BeforeRet;
		}
		LA7: ;
		cp = incheckpoint_398413((*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);
	{
		Tnode225809* n;
		if (!(gidecmd_167119 == ((NU8) 1))) goto LA19;
		{
			if (!(((*node).flags &(1<<((((NU8) 14))&15)))!=0)) goto LA23;
			n = node;
		}
		goto LA21;
		LA23: ;
		{
			n = findclosestdot_398420(node);
		}
		LA21: ;
		{
			if (!(n == NIM_NIL)) goto LA28;
			n = node;
		}
		LA28: ;
		{
			Tnode225809* obj;
			if (!((*n).kind == ((NU8) 45))) goto LA32;
			obj = safesemexpr_398857(c, (*n).kindU.S6.sons->data[((NI) 0)]);
			suggestfieldaccess_398201(c, obj, (&outputs));
			{
				NimStringDesc* LOC38;
				NimStringDesc* LOC39;
				if (!((gglobaloptions_167132 &(1<<((((NU8) 29))&31)))!=0)) goto LA36;
				LOC38 = 0;
				LOC38 = rendertree_247059(obj, 0);
				LOC39 = 0;
				LOC39 = typetostring_255032((*obj).typ, ((NU8) 0));
				printf("%s%s%s%s\012", ((NimStringDesc*) &TMP2782)? (((NimStringDesc*) &TMP2782))->data:"nil", LOC38? (LOC38)->data:"nil", ((NimStringDesc*) &TMP2783)? (((NimStringDesc*) &TMP2783))->data:"nil", LOC39? (LOC39)->data:"nil");
			}
			LA36: ;
		}
		goto LA30;
		LA32: ;
		{
			suggesteverything_398128(c, n, (&outputs));
		}
		LA30: ;
	}
	goto LA17;
	LA19: ;
	{
		Tnode225809* n;
		if (!(gidecmd_167119 == ((NU8) 2))) goto LA42;
		{
			if (!(((*node).flags &(1<<((((NU8) 14))&15)))!=0)) goto LA46;
			n = node;
		}
		goto LA44;
		LA46: ;
		{
			n = findclosestcall_398494(node);
		}
		LA44: ;
		{
			if (!(n == NIM_NIL)) goto LA51;
			n = node;
		}
		LA51: ;
		{
			Tnode225809* a;
			Tnode225809* x_399000;
			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 LA55;
			a = copynode_229660(n);
			x_399000 = safesemexpr_398857(c, (*n).kindU.S6.sons->data[((NI) 0)]);
			{
				NIM_BOOL LOC59;
				LOC59 = 0;
				LOC59 = ((*x_399000).kind == ((NU8) 1));
				if (LOC59) goto LA60;
				LOC59 = ((*x_399000).typ == NIM_NIL);
				LA60: ;
				if (!LOC59) goto LA61;
				x_399000 = (*n).kindU.S6.sons->data[((NI) 0)];
			}
			LA61: ;
			addson_227819(a, x_399000);
			{
				NI i_399033;
				NI HEX3Atmp_399079;
				NI LOC64;
				NI res_399082;
				i_399033 = 0;
				HEX3Atmp_399079 = 0;
				LOC64 = 0;
				LOC64 = sonslen_228387(n);
				HEX3Atmp_399079 = (NI)(LOC64 - ((NI) 1));
				res_399082 = ((NI) 1);
				{
					while (1) {
						Tnode225809* x;
						if (!(res_399082 <= HEX3Atmp_399079)) goto LA66;
						i_399033 = res_399082;
						x = safesemexpr_398857(c, (*n).kindU.S6.sons->data[i_399033]);
						{
							NIM_BOOL LOC69;
							LOC69 = 0;
							LOC69 = ((*x).kind == ((NU8) 1));
							if (LOC69) goto LA70;
							LOC69 = ((*x).typ == NIM_NIL);
							LA70: ;
							if (!LOC69) goto LA71;
							goto LA63;
						}
						LA71: ;
						addson_227819(a, x);
						res_399082 += ((NI) 1);
					} LA66: ;
				}
			} LA63: ;
			suggestcall_395844(c, a, n, (&outputs));
		}
		LA55: ;
	}
	goto LA17;
	LA42: ;
	LA17: ;
	(*c).compilescontextid -= ((NI) 1);
	{
		NIM_BOOL LOC75;
		LOC75 = 0;
		LOC75 = (((NI) 0) < outputs);
		if (!(LOC75)) goto LA76;
		LOC75 = !(((48 &(1<<((gidecmd_167119)&7)))!=0));
		LA76: ;
		if (!LOC75) goto LA77;
		suggestquit_191509();
	}
	LA77: ;
	}BeforeRet: ;
}

N_NIMCALL(void, newcandidate_388480)(Tcontext280023* ctx, Ttype225847* callee, Tcandidate388209* Result) {
	initcandidate_388278(ctx, Result, callee);
}

N_NIMCALL(void, matches_394720)(Tcontext280023* c, Tnode225809* n, Tnode225809* norig, Tcandidate388209* m) {
	Intset222056 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_222927((&marker));
	matchesaux_394231(c, n, norig, m, (&marker));
	{
		if (!((*m).state == ((NU8) 2))) goto LA9;
		goto BeforeRet;
	}
	LA9: ;
	f = ((NI) 1);
	{
		while (1) {
			NI LOC13;
			Tsym225841* formal;
			LOC13 = 0;
			LOC13 = sonslen_228387((*(*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_222898((&marker), (*formal).position);
				if (!!(LOC16)) goto LA17;
				{
					if (!((*formal).ast == NIM_NIL)) goto LA21;
					{
						Tnode225809* container;
						Ttype225847* LOC27;
						Tnode225809* LOC28;
						if (!((*(*formal).typ).kind == ((NU8) 48))) goto LA25;
						LOC27 = 0;
						LOC27 = arrayconstr_394148(c, (*n).info);
						container = newnodeit_227807(((NU8) 41), (*n).info, LOC27);
						LOC28 = 0;
						LOC28 = implicitconv_392849(((NU8) 58), (*formal).typ, container, (&(*m)), c);
						addson_227819((*m).call, LOC28);
					}
					goto LA23;
					LA25: ;
					{
						(*m).state = ((NU8) 2);
						goto LA11;
					}
					LA23: ;
				}
				goto LA19;
				LA21: ;
				{
					Tnode225809* LOC31;
					LOC31 = 0;
					LOC31 = copytree_230028((*formal).ast);
					setson_394029((*m).call, (NI)((*formal).position + ((NI) 1)), LOC31);
				}
				LA19: ;
			}
			LA17: ;
			f += ((NI) 1);
		} LA12: ;
	} LA11: ;
	}BeforeRet: ;
}

N_NIMCALL(NimStringDesc*, argtypetostring_388916)(Tnode225809* arg, NU8 prefer) {
	NimStringDesc* result;
	result = 0;
	{
		Tnode225809* LOC5;
		if (!((*arg).kind == ((NU8) 56) || (*arg).kind == ((NU8) 57))) goto LA3;
		LOC5 = 0;
		LOC5 = HEX5BHEX5D_226244(arg, ((NI) 0));
		result = typetostring_255032((*LOC5).typ, prefer);
		{
			NI i_388950;
			NI HEX3Atmp_388952;
			NI LOC7;
			NI res_388955;
			i_388950 = 0;
			HEX3Atmp_388952 = 0;
			LOC7 = 0;
			LOC7 = len_226098(arg);
			HEX3Atmp_388952 = (LOC7 - 1);
			res_388955 = ((NI) 1);
			{
				while (1) {
					Tnode225809* LOC10;
					NimStringDesc* LOC11;
					if (!(res_388955 <= HEX3Atmp_388952)) goto LA9;
					i_388950 = res_388955;
					result = resizeString(result, 3);
appendString(result, ((NimStringDesc*) &TMP3136));
					LOC10 = 0;
					LOC10 = HEX5BHEX5D_226244(arg, i_388950);
					LOC11 = 0;
					LOC11 = typetostring_255032((*LOC10).typ, prefer);
					result = resizeString(result, LOC11->Sup.len + 0);
appendString(result, LOC11);
					res_388955 += ((NI) 1);
				} LA9: ;
			}
		}
	}
	goto LA1;
	LA3: ;
	{
		result = typetostring_255032((*arg).typ, prefer);
	}
	LA1: ;
	return result;
}

N_NIMCALL(NimStringDesc*, describeargs_388974)(Tcontext280023* c, Tnode225809* n, NI startidx, NU8 prefer) {
	NimStringDesc* result;
{	result = 0;
	result = copyString(((NimStringDesc*) &TMP2201));
	{
		NI i_388994;
		NI HEX3Atmp_389042;
		NI LOC2;
		NI res_389045;
		i_388994 = 0;
		HEX3Atmp_389042 = 0;
		LOC2 = 0;
		LOC2 = len_226098(n);
		HEX3Atmp_389042 = (NI)(LOC2 - ((NI) 1));
		res_389045 = startidx;
		{
			while (1) {
				Tnode225809* arg;
				NimStringDesc* LOC23;
				if (!(res_389045 <= HEX3Atmp_389042)) goto LA4;
				i_388994 = res_389045;
				arg = (*n).kindU.S6.sons->data[i_388994];
				{
					NimStringDesc* LOC9;
					if (!((*(*n).kindU.S6.sons->data[i_388994]).kind == ((NU8) 33))) goto LA7;
					LOC9 = 0;
					LOC9 = rendertree_247059((*(*n).kindU.S6.sons->data[i_388994]).kindU.S6.sons->data[((NI) 0)], 0);
					result = resizeString(result, LOC9->Sup.len + 0);
appendString(result, LOC9);
					result = resizeString(result, 2);
appendString(result, ((NimStringDesc*) &TMP3135));
					{
						if (!(*arg).typ == 0) goto LA12;
						arg = (*c).semoperand(c, (*(*n).kindU.S6.sons->data[i_388994]).kindU.S6.sons->data[((NI) 1)], 0);
						asgnRefNoCycle((void**) (&(*(*n).kindU.S6.sons->data[i_388994]).typ), (*arg).typ);
						asgnRefNoCycle((void**) (&(*(*n).kindU.S6.sons->data[i_388994]).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_388994], 0);
						asgnRefNoCycle((void**) (&(*n).kindU.S6.sons->data[i_388994]), arg);
					}
					LA17: ;
				}
				LA5: ;
				{
					if (!((*(*arg).typ).kind == ((NU8) 50))) goto LA21;
					goto BeforeRet;
				}
				LA21: ;
				LOC23 = 0;
				LOC23 = argtypetostring_388916(arg, prefer);
				result = resizeString(result, LOC23->Sup.len + 0);
appendString(result, LOC23);
				{
					NI LOC26;
					LOC26 = 0;
					LOC26 = sonslen_228387(n);
					if (!!((i_388994 == (NI)(LOC26 - ((NI) 1))))) goto LA27;
					result = resizeString(result, 2);
appendString(result, ((NimStringDesc*) &TMP3137));
				}
				LA27: ;
				res_389045 += ((NI) 1);
			} LA4: ;
		}
	}
	}BeforeRet: ;
	return result;
}

N_NIMCALL(Tnode225809*, usesym_398850)(Tsym225841* sym) {
	Tnode225809* result;
	result = 0;
	result = newsymnode_227325(sym);
	markused_388253((*result).info, sym);
	return result;
}

N_NIMCALL(void, semfinishoperands_394656)(Tcontext280023* c, Tnode225809* n) {
	{
		NI i_394679;
		NI HEX3Atmp_394683;
		NI LOC2;
		NI res_394686;
		i_394679 = 0;
		HEX3Atmp_394683 = 0;
		LOC2 = 0;
		LOC2 = len_226098(n);
		HEX3Atmp_394683 = (LOC2 - 1);
		res_394686 = ((NI) 1);
		{
			while (1) {
				if (!(res_394686 <= HEX3Atmp_394683)) goto LA4;
				i_394679 = res_394686;
				asgnRefNoCycle((void**) (&(*n).kindU.S6.sons->data[i_394679]), prepareoperand_394093(c, (*n).kindU.S6.sons->data[i_394679]));
				res_394686 += ((NI) 1);
			} LA4: ;
		}
	}
}

N_NIMCALL(NU8, cmptypes_392796)(Tcontext280023* c, Ttype225847* f, Ttype225847* a) {
	NU8 result;
	Tcandidate388209 m;
	result = 0;
	memset((void*)(&m), 0, sizeof(m));
	initcandidate_388278(c, (&m), f);
	result = typerel_389064((&m), f, a, NIM_TRUE);
	return result;
}

N_NIMCALL(void, suggeststmt_399098)(Tcontext280023* c, Tnode225809* n) {
	suggestexpr_398865(c, n);
}

N_NIMCALL(Tsym225841*, insttypeboundop_394846)(Tcontext280023* c, Tsym225841* dc, Ttype225847* t, Tlineinfo190352 info, NU8 op) {
	Tsym225841* result;
	Tcandidate388209 m;
	Ttype225847* f;
	result = 0;
	memset((void*)(&m), 0, sizeof(m));
	initcandidate_388278(c, (&m), (*dc).typ);
	f = (*(*dc).typ).sons->data[((NI) 1)];
	{
		if (!(op == ((NU8) 1))) goto LA3;
		{
			if (!((*f).kind == ((NU8) 22) || (*f).kind == ((NU8) 21))) goto LA7;
			f = lastson_228426(f);
		}
		LA7: ;
	}
	goto LA1;
	LA3: ;
	{
		{
			if (!((*f).kind == ((NU8) 23))) goto LA12;
			f = lastson_228426(f);
		}
		LA12: ;
	}
	LA1: ;
	{
		NU8 LOC16;
		LOC16 = 0;
		LOC16 = typerel_389064((&m), f, t, NIM_TRUE);
		if (!(LOC16 == ((NU8) 0))) goto LA17;
		localerror_196128(info, ((NU16) 4), ((NimStringDesc*) &TMP3637));
	}
	goto LA14;
	LA17: ;
	{
		result = (*c).semgenerateinstance.ClEnv? (*c).semgenerateinstance.ClPrc(c, dc, m.bindings, info, (*c).semgenerateinstance.ClEnv):((TMP3638)((*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* TMP2728[8];
static TNimNode* TMP2777[20];
static TNimNode* TMP2778[3];
NI TMP2780;
static char* NIM_CONST TMP2779[3] = {
"csEmpty", 
"csMatch", 
"csNoMatch"};
static TNimNode TMP955[34];
NTI395010.size = sizeof(Suggest395010);
NTI395010.kind = 18;
NTI395010.base = 0;
NTI395010.flags = 2;
TMP2728[0] = &TMP955[1];
TMP955[1].kind = 1;
TMP955[1].offset = offsetof(Suggest395010, section);
TMP955[1].typ = (&NTI167029);
TMP955[1].name = "section";
TMP2728[1] = &TMP955[2];
TMP955[2].kind = 1;
TMP955[2].offset = offsetof(Suggest395010, qualifiedpath);
TMP955[2].typ = (&NTI130408);
TMP955[2].name = "qualifiedPath";
TMP2728[2] = &TMP955[3];
TMP955[3].kind = 1;
TMP955[3].offset = offsetof(Suggest395010, filepath);
TMP955[3].typ = (&NTI149);
TMP955[3].name = "filePath";
TMP2728[3] = &TMP955[4];
TMP955[4].kind = 1;
TMP955[4].offset = offsetof(Suggest395010, line);
TMP955[4].typ = (&NTI108);
TMP955[4].name = "line";
TMP2728[4] = &TMP955[5];
TMP955[5].kind = 1;
TMP955[5].offset = offsetof(Suggest395010, column);
TMP955[5].typ = (&NTI108);
TMP955[5].name = "column";
TMP2728[5] = &TMP955[6];
TMP955[6].kind = 1;
TMP955[6].offset = offsetof(Suggest395010, doc);
TMP955[6].typ = (&NTI149);
TMP955[6].name = "doc";
TMP2728[6] = &TMP955[7];
TMP955[7].kind = 1;
TMP955[7].offset = offsetof(Suggest395010, symkind);
TMP955[7].typ = (&NTI225441);
TMP955[7].name = "symkind";
TMP2728[7] = &TMP955[8];
TMP955[8].kind = 1;
TMP955[8].offset = offsetof(Suggest395010, forth);
TMP955[8].typ = (&NTI149);
TMP955[8].name = "forth";
TMP955[0].len = 8; TMP955[0].kind = 2; TMP955[0].sons = &TMP2728[0];
NTI395010.node = &TMP955[0];
NTI388209.size = sizeof(Tcandidate388209);
NTI388209.kind = 18;
NTI388209.base = 0;
TMP2777[0] = &TMP955[10];
TMP955[10].kind = 1;
TMP955[10].offset = offsetof(Tcandidate388209, c);
TMP955[10].typ = (&NTI280021);
TMP955[10].name = "c";
TMP2777[1] = &TMP955[11];
TMP955[11].kind = 1;
TMP955[11].offset = offsetof(Tcandidate388209, exactmatches);
TMP955[11].typ = (&NTI108);
TMP955[11].name = "exactMatches";
TMP2777[2] = &TMP955[12];
TMP955[12].kind = 1;
TMP955[12].offset = offsetof(Tcandidate388209, genericmatches);
TMP955[12].typ = (&NTI108);
TMP955[12].name = "genericMatches";
TMP2777[3] = &TMP955[13];
TMP955[13].kind = 1;
TMP955[13].offset = offsetof(Tcandidate388209, subtypematches);
TMP955[13].typ = (&NTI108);
TMP955[13].name = "subtypeMatches";
TMP2777[4] = &TMP955[14];
TMP955[14].kind = 1;
TMP955[14].offset = offsetof(Tcandidate388209, intconvmatches);
TMP955[14].typ = (&NTI108);
TMP955[14].name = "intConvMatches";
TMP2777[5] = &TMP955[15];
TMP955[15].kind = 1;
TMP955[15].offset = offsetof(Tcandidate388209, convmatches);
TMP955[15].typ = (&NTI108);
TMP955[15].name = "convMatches";
TMP2777[6] = &TMP955[16];
NTI388205.size = sizeof(NU8);
NTI388205.kind = 14;
NTI388205.base = 0;
NTI388205.flags = 3;
for (TMP2780 = 0; TMP2780 < 3; TMP2780++) {
TMP955[TMP2780+17].kind = 1;
TMP955[TMP2780+17].offset = TMP2780;
TMP955[TMP2780+17].name = TMP2779[TMP2780];
TMP2778[TMP2780] = &TMP955[TMP2780+17];
}
TMP955[20].len = 3; TMP955[20].kind = 2; TMP955[20].sons = &TMP2778[0];
NTI388205.node = &TMP955[20];
TMP955[16].kind = 1;
TMP955[16].offset = offsetof(Tcandidate388209, state);
TMP955[16].typ = (&NTI388205);
TMP955[16].name = "state";
TMP2777[7] = &TMP955[21];
TMP955[21].kind = 1;
TMP955[21].offset = offsetof(Tcandidate388209, callee);
TMP955[21].typ = (&NTI225805);
TMP955[21].name = "callee";
TMP2777[8] = &TMP955[22];
TMP955[22].kind = 1;
TMP955[22].offset = offsetof(Tcandidate388209, calleesym);
TMP955[22].typ = (&NTI225807);
TMP955[22].name = "calleeSym";
TMP2777[9] = &TMP955[23];
TMP955[23].kind = 1;
TMP955[23].offset = offsetof(Tcandidate388209, calleescope);
TMP955[23].typ = (&NTI108);
TMP955[23].name = "calleeScope";
TMP2777[10] = &TMP955[24];
TMP955[24].kind = 1;
TMP955[24].offset = offsetof(Tcandidate388209, call);
TMP955[24].typ = (&NTI225801);
TMP955[24].name = "call";
TMP2777[11] = &TMP955[25];
TMP955[25].kind = 1;
TMP955[25].offset = offsetof(Tcandidate388209, bindings);
TMP955[25].typ = (&NTI225859);
TMP955[25].name = "bindings";
TMP2777[12] = &TMP955[26];
TMP955[26].kind = 1;
TMP955[26].offset = offsetof(Tcandidate388209, basetypematch);
TMP955[26].typ = (&NTI138);
TMP955[26].name = "baseTypeMatch";
TMP2777[13] = &TMP955[27];
TMP955[27].kind = 1;
TMP955[27].offset = offsetof(Tcandidate388209, fauxmatch);
TMP955[27].typ = (&NTI225262);
TMP955[27].name = "fauxMatch";
TMP2777[14] = &TMP955[28];
TMP955[28].kind = 1;
TMP955[28].offset = offsetof(Tcandidate388209, genericconverter);
TMP955[28].typ = (&NTI138);
TMP955[28].name = "genericConverter";
TMP2777[15] = &TMP955[29];
TMP955[29].kind = 1;
TMP955[29].offset = offsetof(Tcandidate388209, coercedistincts);
TMP955[29].typ = (&NTI138);
TMP955[29].name = "coerceDistincts";
TMP2777[16] = &TMP955[30];
TMP955[30].kind = 1;
TMP955[30].offset = offsetof(Tcandidate388209, typedescmatched);
TMP955[30].typ = (&NTI138);
TMP955[30].name = "typedescMatched";
TMP2777[17] = &TMP955[31];
TMP955[31].kind = 1;
TMP955[31].offset = offsetof(Tcandidate388209, isnocall);
TMP955[31].typ = (&NTI138);
TMP955[31].name = "isNoCall";
TMP2777[18] = &TMP955[32];
TMP955[32].kind = 1;
TMP955[32].offset = offsetof(Tcandidate388209, inheritancepenalty);
TMP955[32].typ = (&NTI108);
TMP955[32].name = "inheritancePenalty";
TMP2777[19] = &TMP955[33];
TMP955[33].kind = 1;
TMP955[33].offset = offsetof(Tcandidate388209, errors);
TMP955[33].typ = (&NTI225811);
TMP955[33].name = "errors";
TMP955[9].len = 20; TMP955[9].kind = 2; TMP955[9].sons = &TMP2777[0];
NTI388209.node = &TMP955[9];
}

