/* Generated by Nimrod Compiler v0.9.5 */
/*   (c) 2014 Andreas Rumpf */
/* The generated code is subject to the original license. */
/* Compiled for: Linux, i386, gcc */
/* Command for C compiler:
   gcc -c  -w -O3 -fno-strict-aliasing  -I/build/nimrod/src/nimrod/lib -o compiler/nimcache/parampatterns.o compiler/nimcache/parampatterns.c */
#define NIM_INTBITS 32
#include "nimbase.h"

#include <string.h>
typedef struct tnode188803 tnode188803;
typedef struct NimStringDesc NimStringDesc;
typedef struct TGenericSeq TGenericSeq;
typedef struct ttype188837 ttype188837;
typedef struct tlineinfo163527 tlineinfo163527;
typedef struct tsym188833 tsym188833;
typedef struct tident167019 tident167019;
typedef struct tnodeseq188797 tnodeseq188797;
typedef struct tidobj167013 tidobj167013;
typedef struct TNimObject TNimObject;
typedef struct TNimType TNimType;
typedef struct TNimNode TNimNode;
typedef struct ttypeseq188835 ttypeseq188835;
typedef struct tscope188827 tscope188827;
typedef struct TY188933 TY188933;
typedef struct tinstantiation188823 tinstantiation188823;
typedef struct tstrtable188807 tstrtable188807;
typedef struct tsymseq188805 tsymseq188805;
typedef struct tloc188817 tloc188817;
typedef struct trope145007 trope145007;
typedef struct tlib188821 tlib188821;
typedef struct tcell41090 tcell41090;
typedef struct tcellseq41106 tcellseq41106;
typedef struct tgcheap43016 tgcheap43016;
typedef struct tcellset41102 tcellset41102;
typedef struct tpagedesc41098 tpagedesc41098;
typedef struct tmemregion23410 tmemregion23410;
typedef struct tsmallchunk22638 tsmallchunk22638;
typedef struct tllchunk23404 tllchunk23404;
typedef struct tbigchunk22640 tbigchunk22640;
typedef struct tintset22615 tintset22615;
typedef struct ttrunk22611 ttrunk22611;
typedef struct tavlnode23408 tavlnode23408;
typedef struct tgcstat43014 tgcstat43014;
typedef struct TY79484 TY79484;
typedef struct TY188922 TY188922;
typedef struct tlistentry118017 tlistentry118017;
typedef struct tbasechunk22636 tbasechunk22636;
typedef struct tfreecell22628 tfreecell22628;
typedef NIM_BOOL TY277317[65];
struct  TGenericSeq  {
NI len;
NI reserved;
};
struct  NimStringDesc  {
  TGenericSeq Sup;
NIM_CHAR data[SEQ_DECL_SIZE];
};
struct  tlineinfo163527  {
NI16 Line;
NI16 Col;
NI32 Fileindex;
};
struct  tnode188803  {
ttype188837* Typ;
tlineinfo163527 Info;
NU16 Flags;
NU8 Kind;
union {
struct {NI64 Intval;
} S1;
struct {NF Floatval;
} S2;
struct {NimStringDesc* Strval;
} S3;
struct {tsym188833* Sym;
} S4;
struct {tident167019* Ident;
} S5;
struct {tnodeseq188797* Sons;
} S6;
} kindU;
NimStringDesc* Comment;
};
typedef N_NIMCALL_PTR(void, TY2289) (void* p, NI op);
struct  TNimType  {
NI size;
NU8 kind;
NU8 flags;
TNimType* base;
TNimNode* node;
void* finalizer;
TY2289 marker;
};
struct  TNimObject  {
TNimType* m_type;
};
struct  tidobj167013  {
  TNimObject Sup;
NI Id;
};
struct  tstrtable188807  {
NI Counter;
tsymseq188805* Data;
};
struct  tloc188817  {
NU8 K;
NU8 S;
NU8 Flags;
ttype188837* T;
trope145007* R;
trope145007* Heaproot;
NI A;
};
struct  tsym188833  {
  tidobj167013 Sup;
NU8 Kind;
union {
struct {ttypeseq188835* Typeinstcache;
tscope188827* Typscope;
} S1;
struct {TY188933* Procinstcache;
tscope188827* Scope;
} S2;
struct {TY188933* Usedgenerics;
tstrtable188807 Tab;
} S3;
} kindU;
NU16 Magic;
ttype188837* Typ;
tident167019* Name;
tlineinfo163527 Info;
tsym188833* Owner;
NU32 Flags;
tnode188803* Ast;
NU32 Options;
NI Position;
NI Offset;
tloc188817 Loc;
tlib188821* Annex;
tnode188803* Constraint;
};
struct  ttype188837  {
  tidobj167013 Sup;
NU8 Kind;
NU8 Callconv;
NU32 Flags;
ttypeseq188835* Sons;
tnode188803* N;
tsym188833* Destructor;
tsym188833* Owner;
tsym188833* Sym;
NI64 Size;
NI Align;
tloc188817 Loc;
};
struct  tcell41090  {
NI Refcount;
TNimType* Typ;
};
struct  tcellseq41106  {
NI Len;
NI Cap;
tcell41090** D;
};
struct  tcellset41102  {
NI Counter;
NI Max;
tpagedesc41098* Head;
tpagedesc41098** Data;
};
typedef tsmallchunk22638* TY23422[512];
typedef ttrunk22611* ttrunkbuckets22613[256];
struct  tintset22615  {
ttrunkbuckets22613 Data;
};
struct  tmemregion23410  {
NI Minlargeobj;
NI Maxlargeobj;
TY23422 Freesmallchunks;
tllchunk23404* Llmem;
NI Currmem;
NI Maxmem;
NI Freemem;
NI Lastsize;
tbigchunk22640* Freechunkslist;
tintset22615 Chunkstarts;
tavlnode23408* Root;
tavlnode23408* Deleted;
tavlnode23408* Last;
tavlnode23408* Freeavlnodes;
};
struct  tgcstat43014  {
NI Stackscans;
NI Cyclecollections;
NI Maxthreshold;
NI Maxstacksize;
NI Maxstackcells;
NI Cycletablesize;
NI64 Maxpause;
};
struct  tgcheap43016  {
void* Stackbottom;
NI Cyclethreshold;
tcellseq41106 Zct;
tcellseq41106 Decstack;
tcellset41102 Cycleroots;
tcellseq41106 Tempstack;
NI Recgclock;
tmemregion23410 Region;
tgcstat43014 Stat;
};
struct  tident167019  {
  tidobj167013 Sup;
NimStringDesc* S;
tident167019* Next;
NI H;
};
struct TY79484 {
NimStringDesc* Field0;
NI Field1;
};
struct  TNimNode  {
NU8 kind;
NI offset;
TNimType* typ;
NCSTRING name;
NI len;
TNimNode** sons;
};
struct  tscope188827  {
NI Depthlevel;
tstrtable188807 Symbols;
tnodeseq188797* Usingsyms;
tscope188827* Parent;
};
struct  tinstantiation188823  {
tsym188833* Sym;
ttypeseq188835* Concretetypes;
TY188922* Usedby;
};
struct  trope145007  {
  TNimObject Sup;
trope145007* Left;
trope145007* Right;
NI Length;
NimStringDesc* Data;
};
struct  tlistentry118017  {
  TNimObject Sup;
tlistentry118017* Prev;
tlistentry118017* Next;
};
struct  tlib188821  {
  tlistentry118017 Sup;
NU8 Kind;
NIM_BOOL Generated;
NIM_BOOL Isoverriden;
trope145007* Name;
tnode188803* Path;
};
typedef NI TY22618[16];
struct  tpagedesc41098  {
tpagedesc41098* Next;
NI Key;
TY22618 Bits;
};
struct  tbasechunk22636  {
NI Prevsize;
NI Size;
NIM_BOOL Used;
};
struct  tsmallchunk22638  {
  tbasechunk22636 Sup;
tsmallchunk22638* Next;
tsmallchunk22638* Prev;
tfreecell22628* Freelist;
NI Free;
NI Acc;
NF Data;
};
struct  tllchunk23404  {
NI Size;
NI Acc;
tllchunk23404* Next;
};
struct  tbigchunk22640  {
  tbasechunk22636 Sup;
tbigchunk22640* Next;
tbigchunk22640* Prev;
NI Align;
NF Data;
};
struct  ttrunk22611  {
ttrunk22611* Next;
NI Key;
TY22618 Bits;
};
typedef tavlnode23408* TY23414[2];
struct  tavlnode23408  {
TY23414 Link;
NI Key;
NI Upperbound;
NI Level;
};
struct  tfreecell22628  {
tfreecell22628* Next;
NI Zerofield;
};
struct tnodeseq188797 {
  TGenericSeq Sup;
  tnode188803* data[SEQ_DECL_SIZE];
};
struct ttypeseq188835 {
  TGenericSeq Sup;
  ttype188837* data[SEQ_DECL_SIZE];
};
struct TY188933 {
  TGenericSeq Sup;
  tinstantiation188823* data[SEQ_DECL_SIZE];
};
struct tsymseq188805 {
  TGenericSeq Sup;
  tsym188833* data[SEQ_DECL_SIZE];
};
struct TY188922 {
  TGenericSeq Sup;
  NI32 data[SEQ_DECL_SIZE];
};
static N_INLINE(NIM_BOOL, isatom_195186)(tnode188803* n);
N_NIMCALL(NU8, isassignable_276961)(tsym188833* owner, tnode188803* n);
N_NIMCALL(ttype188837*, skiptypes_192793)(ttype188837* t, NU64 kinds);
N_NIMCALL(NIM_BOOL, comparetypes_230547)(ttype188837* x, ttype188837* y, NU8 cmp, NU8 flags);
N_NIMCALL(NU8, checkforsideeffects_276731)(tnode188803* n);
static N_INLINE(NIM_BOOL, isroutine_195040)(tsym188833* s);
static N_INLINE(NI, len_189264)(tnode188803* n);
N_NIMCALL(tnode188803*, newnodei_189099)(NU8 kind, tlineinfo163527 info);
N_NIMCALL(NimStringDesc*, rawNewString)(NI space);
N_NIMCALL(NimStringDesc*, rawNewString)(NI cap);
static N_INLINE(void, asgnRefNoCycle)(void** dest, void* src);
static N_INLINE(tcell41090*, usrtocell_44443)(void* usr);
static N_INLINE(void, rtladdzct_46002)(tcell41090* c);
N_NOINLINE(void, addzct_44418)(tcellseq41106* s, tcell41090* c);
N_NIMCALL(NimStringDesc*, addChar)(NimStringDesc* s, NIM_CHAR c);
N_NIMCALL(void, compileconstraints_276106)(tnode188803* p, NimStringDesc** result);
N_NIMCALL(void, patternerror_276040)(tnode188803* n);
N_NIMCALL(void, localerror_165571)(tlineinfo163527 info, NU16 msg, NimStringDesc* arg);
N_NIMCALL(NimStringDesc*, rendertree_211051)(tnode188803* n, NU8 renderflags);
static N_INLINE(NIM_BOOL, eqStrings)(NimStringDesc* a, NimStringDesc* b);
static N_INLINE(void, add_276046)(NimStringDesc** code, NU8 op);
N_NIMCALL(NimStringDesc*, nsuNormalize)(NimStringDesc* s);
N_NIMCALL(NI, hashString)(NimStringDesc* s);
N_NIMCALL(void, internalerror_165606)(NimStringDesc* errmsg);
N_NIMCALL(NimStringDesc*, HEX24_165714)(TY79484 x_165718);
N_NIMCALL(NI, nsuCmpIgnoreStyle)(NimStringDesc* a, NimStringDesc* b);
N_NIMCALL(NimStringDesc*, copyStr)(NimStringDesc* s, NI start);
N_NIMCALL(NimStringDesc*, copyStr)(NimStringDesc* s, NI first);
N_NIMCALL(NimStringDesc*, reprEnum)(NI e_75880, TNimType* typ);
N_NIMCALL(void, internalerror_165591)(tlineinfo163527 info, NimStringDesc* errmsg);
STRING_LITERAL(TMP2822, "|", 1);
STRING_LITERAL(TMP2823, "&", 1);
STRING_LITERAL(TMP2824, "~", 1);
STRING_LITERAL(TMP2825, "atom", 4);
STRING_LITERAL(TMP2826, "lit", 3);
STRING_LITERAL(TMP2827, "sym", 3);
STRING_LITERAL(TMP2828, "ident", 5);
STRING_LITERAL(TMP2829, "call", 4);
STRING_LITERAL(TMP2830, "alias", 5);
STRING_LITERAL(TMP2831, "noalias", 7);
STRING_LITERAL(TMP2832, "lvalue", 6);
STRING_LITERAL(TMP2833, "local", 5);
STRING_LITERAL(TMP2834, "sideeffect", 10);
STRING_LITERAL(TMP2835, "nosideeffect", 12);
STRING_LITERAL(TMP2837, "compiler/parampatterns.nim", 26);
NIM_CONST TY79484 TMP2836 = {((NimStringDesc*) &TMP2837),
100}
;
NIM_CONST TY79484 TMP2838 = {((NimStringDesc*) &TMP2837),
107}
;
STRING_LITERAL(TMP2839, "parameter pattern too complex", 29);
extern tgcheap43016 gch_43044;
extern TNimType NTI188441; /* TSymKind */
extern TNimType NTI188023; /* TNodeKind */

static N_INLINE(NIM_BOOL, isatom_195186)(tnode188803* n) {
	NIM_BOOL result;
	NIM_BOOL LOC1;
	result = 0;
	LOC1 = 0;
	LOC1 = (((NU8) 0) <= (*n).Kind);
	if (!(LOC1)) goto LA2;
	LOC1 = ((*n).Kind <= ((NU8) 23));
	LA2: ;
	result = LOC1;
	return result;
}

N_NIMCALL(NU8, isassignable_276961)(tsym188833* owner, tnode188803* n) {
	NU8 result;
	result = 0;
	result = ((NU8) 0);
	switch ((*n).Kind) {
	case ((NU8) 3):
	{
		{
			if (!((2336 &(1<<(((*(*n).kindU.S4.Sym).Kind)&31)))!=0)) goto LA4;
			{
				NIM_BOOL LOC8;
				NIM_BOOL LOC9;
				LOC8 = 0;
				LOC9 = 0;
				LOC9 = !((owner == NIM_NIL));
				if (!(LOC9)) goto LA10;
				LOC9 = ((*owner).Sup.Id == (*(*(*n).kindU.S4.Sym).Owner).Sup.Id);
				LA10: ;
				LOC8 = LOC9;
				if (!(LOC8)) goto LA11;
				LOC8 = !((((*(*n).kindU.S4.Sym).Flags &(1<<((((NU8) 3))&31)))!=0));
				LA11: ;
				if (!LOC8) goto LA12;
				result = ((NU8) 2);
			}
			goto LA6;
			LA12: ;
			{
				result = ((NU8) 1);
			}
			LA6: ;
		}
		LA4: ;
	}
	break;
	case ((NU8) 45):
	{
		{
			ttype188837* LOC18;
			LOC18 = 0;
			LOC18 = skiptypes_192793((*(*n).kindU.S6.Sons->data[0]).Typ, IL64(211106232576000));
			if (!((*LOC18).Kind == ((NU8) 23) || (*LOC18).Kind == ((NU8) 21) || (*LOC18).Kind == ((NU8) 22))) goto LA19;
			result = ((NU8) 1);
		}
		goto LA16;
		LA19: ;
		{
			result = isassignable_276961(owner, (*n).kindU.S6.Sons->data[0]);
		}
		LA16: ;
		{
			NIM_BOOL LOC24;
			LOC24 = 0;
			LOC24 = !((result == ((NU8) 0)));
			if (!(LOC24)) goto LA25;
			LOC24 = (((*(*(*n).kindU.S6.Sons->data[1]).kindU.S4.Sym).Flags &(1<<((((NU8) 18))&31)))!=0);
			LA25: ;
			if (!LOC24) goto LA26;
			result = ((NU8) 3);
		}
		LA26: ;
	}
	break;
	case ((NU8) 42):
	{
		{
			ttype188837* LOC31;
			LOC31 = 0;
			LOC31 = skiptypes_192793((*(*n).kindU.S6.Sons->data[0]).Typ, IL64(211106232576000));
			if (!((*LOC31).Kind == ((NU8) 23) || (*LOC31).Kind == ((NU8) 21) || (*LOC31).Kind == ((NU8) 22))) goto LA32;
			result = ((NU8) 1);
		}
		goto LA29;
		LA32: ;
		{
			result = isassignable_276961(owner, (*n).kindU.S6.Sons->data[0]);
		}
		LA29: ;
	}
	break;
	case ((NU8) 58):
	case ((NU8) 59):
	case ((NU8) 60):
	{
		{
			ttype188837* LOC38;
			LOC38 = 0;
			LOC38 = skiptypes_192793((*n).Typ, IL64(211106247256064));
			if (!((*LOC38).Kind == ((NU8) 27) || (*LOC38).Kind == ((NU8) 18) || (*LOC38).Kind == ((NU8) 17))) goto LA39;
			result = isassignable_276961(owner, (*n).kindU.S6.Sons->data[1]);
		}
		goto LA36;
		LA39: ;
		{
			NIM_BOOL LOC42;
			LOC42 = 0;
			LOC42 = comparetypes_230547((*n).Typ, (*(*n).kindU.S6.Sons->data[1]).Typ, ((NU8) 1), 0);
			if (!LOC42) goto LA43;
			result = isassignable_276961(owner, (*n).kindU.S6.Sons->data[1]);
		}
		goto LA36;
		LA43: ;
		LA36: ;
	}
	break;
	case ((NU8) 65):
	case ((NU8) 47):
	{
		result = ((NU8) 1);
	}
	break;
	case ((NU8) 67):
	case ((NU8) 66):
	case ((NU8) 46):
	{
		result = isassignable_276961(owner, (*n).kindU.S6.Sons->data[0]);
	}
	break;
	default:
	{
	}
	break;
	}
	return result;
}

static N_INLINE(NIM_BOOL, isroutine_195040)(tsym188833* s) {
	NIM_BOOL result;
	result = 0;
	result = ((520192 &(1<<(((*s).Kind)&31)))!=0);
	return result;
}

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

N_NIMCALL(NU8, checkforsideeffects_276731)(tnode188803* n) {
	NU8 result;
	result = 0;
	switch ((*n).Kind) {
	case ((NU8) 27):
	case ((NU8) 29):
	case ((NU8) 30):
	case ((NU8) 31):
	case ((NU8) 26):
	case ((NU8) 28):
	case ((NU8) 32):
	{
		tnode188803* op;
		NI i_276835;
		NI HEX3Atmp_276942;
		NI LOC16;
		NI res_276944;
		op = (*n).kindU.S6.Sons->data[0];
		{
			NIM_BOOL LOC4;
			tsym188833* s;
			LOC4 = 0;
			LOC4 = ((*op).Kind == ((NU8) 3));
			if (!(LOC4)) goto LA5;
			LOC4 = isroutine_195040((*op).kindU.S4.Sym);
			LA5: ;
			if (!LOC4) goto LA6;
			s = (*op).kindU.S4.Sym;
			{
				if (!(((*s).Flags &(1<<((((NU8) 11))&31)))!=0)) goto LA10;
				result = ((NU8) 1);
				goto BeforeRet;
			}
			LA10: ;
			result = ((NU8) 2);
		}
		goto LA2;
		LA6: ;
		{
			if (!(((*(*op).Typ).Flags &(1<<((((NU8) 1))&31)))!=0)) goto LA13;
			result = ((NU8) 2);
		}
		goto LA2;
		LA13: ;
		{
			result = ((NU8) 1);
			goto BeforeRet;
		}
		LA2: ;
		i_276835 = 0;
		HEX3Atmp_276942 = 0;
		LOC16 = 0;
		LOC16 = len_189264(n);
		HEX3Atmp_276942 = LOC16 - 1;
		res_276944 = 0;
		while (1) {
			NU8 ret;
			if (!(res_276944 <= HEX3Atmp_276942)) goto LA17;
			i_276835 = res_276944;
			ret = checkforsideeffects_276731((*n).kindU.S6.Sons->data[i_276835]);
			{
				if (!(ret == ((NU8) 1))) goto LA20;
				result = ret;
				goto BeforeRet;
			}
			goto LA18;
			LA20: ;
			{
				NIM_BOOL LOC23;
				LOC23 = 0;
				LOC23 = (ret == ((NU8) 0));
				if (!(LOC23)) goto LA24;
				LOC23 = (result == ((NU8) 2));
				LA24: ;
				if (!LOC23) goto LA25;
				result = ((NU8) 0);
			}
			goto LA18;
			LA25: ;
			LA18: ;
			res_276944 += 1;
		} LA17: ;
	}
	break;
	case ((NU8) 0) ... ((NU8) 23):
	{
		result = ((NU8) 2);
	}
	break;
	default:
	{
		NI i_276899;
		NI HEX3Atmp_276946;
		NI LOC29;
		NI res_276948;
		i_276899 = 0;
		HEX3Atmp_276946 = 0;
		LOC29 = 0;
		LOC29 = len_189264(n);
		HEX3Atmp_276946 = LOC29 - 1;
		res_276948 = 0;
		while (1) {
			NU8 ret;
			if (!(res_276948 <= HEX3Atmp_276946)) goto LA30;
			i_276899 = res_276948;
			ret = checkforsideeffects_276731((*n).kindU.S6.Sons->data[i_276899]);
			{
				if (!(ret == ((NU8) 1))) goto LA33;
				result = ret;
				goto BeforeRet;
			}
			goto LA31;
			LA33: ;
			{
				NIM_BOOL LOC36;
				LOC36 = 0;
				LOC36 = (ret == ((NU8) 0));
				if (!(LOC36)) goto LA37;
				LOC36 = (result == ((NU8) 2));
				LA37: ;
				if (!LOC36) goto LA38;
				result = ((NU8) 0);
			}
			goto LA31;
			LA38: ;
			LA31: ;
			res_276948 += 1;
		} LA30: ;
	}
	break;
	}
	BeforeRet: ;
	return result;
}

N_NIMCALL(NIM_BOOL, matchnodekinds_277312)(tnode188803* p, tnode188803* n) {
	NIM_BOOL result;
	TY277317 stack;
	NI sp;
	NimStringDesc* code;
	NI pc;
	result = 0;
	stack[(0)- 0] = NIM_TRUE;
	sp = 1;
	code = (*p).kindU.S3.Strval;
	pc = 1;
	while (1) {
		switch (((NU8) (((NU8)(code->data[pc]))))) {
		case ((NU8) 1):
		{
			goto LA1;
		}
		break;
		case ((NU8) 2):
		{
			NIM_BOOL LOC4;
			LOC4 = 0;
			LOC4 = stack[((NI32)(sp - 1))- 0];
			if (LOC4) goto LA5;
			LOC4 = stack[((NI32)(sp - 2))- 0];
			LA5: ;
			stack[((NI32)(sp - 2))- 0] = LOC4;
			sp -= 1;
		}
		break;
		case ((NU8) 3):
		{
			NIM_BOOL LOC7;
			LOC7 = 0;
			LOC7 = stack[((NI32)(sp - 1))- 0];
			if (!(LOC7)) goto LA8;
			LOC7 = stack[((NI32)(sp - 2))- 0];
			LA8: ;
			stack[((NI32)(sp - 2))- 0] = LOC7;
			sp -= 1;
		}
		break;
		case ((NU8) 4):
		{
			stack[((NI32)(sp - 1))- 0] = !(stack[((NI32)(sp - 1))- 0]);
		}
		break;
		case ((NU8) 5):
		{
			stack[(sp)- 0] = ((*n).Kind == ((NU8) 3));
			sp += 1;
		}
		break;
		case ((NU8) 6):
		{
			stack[(sp)- 0] = isatom_195186(n);
			sp += 1;
		}
		break;
		case ((NU8) 7):
		{
			stack[(sp)- 0] = ((*n).Kind >= ((NU8) 5) && (*n).Kind <= ((NU8) 23));
			sp += 1;
		}
		break;
		case ((NU8) 8):
		{
			stack[(sp)- 0] = ((*n).Kind == ((NU8) 2));
			sp += 1;
		}
		break;
		case ((NU8) 9):
		{
			stack[(sp)- 0] = ((*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));
			sp += 1;
		}
		break;
		case ((NU8) 10):
		{
			NU8 kind;
			NIM_BOOL LOC16;
			kind = ((NU8) (((NU8)(code->data[(NI32)(pc + 1)]))));
			LOC16 = 0;
			LOC16 = ((*n).Kind == ((NU8) 3));
			if (!(LOC16)) goto LA17;
			LOC16 = ((*(*n).kindU.S4.Sym).Kind == kind);
			LA17: ;
			stack[(sp)- 0] = LOC16;
			sp += 1;
			pc += 1;
		}
		break;
		case ((NU8) 11):
		{
			NU8 kind;
			kind = ((NU8) (((NU8)(code->data[(NI32)(pc + 1)]))));
			stack[(sp)- 0] = ((*n).Kind == kind);
			sp += 1;
			pc += 1;
		}
		break;
		case ((NU8) 12):
		{
			NU8 LOC20;
			LOC20 = 0;
			LOC20 = isassignable_276961(NIM_NIL, n);
			stack[(sp)- 0] = ((6 &(1<<((LOC20)&7)))!=0);
			sp += 1;
		}
		break;
		case ((NU8) 13):
		{
			NU8 LOC22;
			LOC22 = 0;
			LOC22 = isassignable_276961(NIM_NIL, n);
			stack[(sp)- 0] = (LOC22 == ((NU8) 2));
			sp += 1;
		}
		break;
		case ((NU8) 14):
		{
			NU8 LOC24;
			LOC24 = 0;
			LOC24 = checkforsideeffects_276731(n);
			stack[(sp)- 0] = (LOC24 == ((NU8) 1));
			sp += 1;
		}
		break;
		case ((NU8) 15):
		{
			NU8 LOC26;
			LOC26 = 0;
			LOC26 = checkforsideeffects_276731(n);
			stack[(sp)- 0] = !((LOC26 == ((NU8) 1)));
			sp += 1;
		}
		break;
		}
		pc += 1;
	} LA1: ;
	result = stack[((NI32)(sp - 1))- 0];
	return result;
}

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

static N_INLINE(void, rtladdzct_46002)(tcell41090* c) {
	addzct_44418(&gch_43044.Zct, c);
}

static N_INLINE(void, asgnRefNoCycle)(void** dest, void* src) {
	{
		tcell41090* c;
		if (!!((src == NIM_NIL))) goto LA3;
		c = usrtocell_44443(src);
		(*c).Refcount += 8;
	}
	LA3: ;
	{
		tcell41090* c;
		if (!!(((*dest) == NIM_NIL))) goto LA7;
		c = usrtocell_44443((*dest));
		{
			(*c).Refcount -= 8;
			if (!((NU32)((*c).Refcount) < (NU32)(8))) goto LA11;
			rtladdzct_46002(c);
		}
		LA11: ;
	}
	LA7: ;
	(*dest) = src;
}

N_NIMCALL(void, patternerror_276040)(tnode188803* n) {
	NimStringDesc* LOC1;
	LOC1 = 0;
	LOC1 = rendertree_211051(n, 4);
	localerror_165571((*n).Info, ((NU16) 1), LOC1);
}

static N_INLINE(NIM_BOOL, eqStrings)(NimStringDesc* a, NimStringDesc* b) {
	NIM_BOOL result;
	NIM_BOOL LOC11;
	int LOC13;
	result = 0;
	{
		if (!(a == b)) goto LA3;
		result = NIM_TRUE;
		goto BeforeRet;
	}
	LA3: ;
	{
		NIM_BOOL LOC7;
		LOC7 = 0;
		LOC7 = (a == NIM_NIL);
		if (LOC7) goto LA8;
		LOC7 = (b == NIM_NIL);
		LA8: ;
		if (!LOC7) goto LA9;
		result = NIM_FALSE;
		goto BeforeRet;
	}
	LA9: ;
	LOC11 = 0;
	LOC11 = ((*a).Sup.len == (*b).Sup.len);
	if (!(LOC11)) goto LA12;
	LOC13 = 0;
	LOC13 = memcmp(((NCSTRING) ((*a).data)), ((NCSTRING) ((*b).data)), (NI32)((*a).Sup.len * 1));
	LOC11 = (LOC13 == ((NI32) 0));
	LA12: ;
	result = LOC11;
	goto BeforeRet;
	BeforeRet: ;
	return result;
}

static N_INLINE(void, add_276046)(NimStringDesc** code, NU8 op) {
	(*code) = addChar((*code), ((NIM_CHAR) (((NI) (op)))));
}

N_NIMCALL(void, compileconstraints_276106)(tnode188803* p, NimStringDesc** result) {
	switch ((*p).Kind) {
	case ((NU8) 27):
	case ((NU8) 29):
	case ((NU8) 30):
	case ((NU8) 31):
	case ((NU8) 26):
	case ((NU8) 28):
	case ((NU8) 32):
	{
		tident167019* op;
		{
			if (!!(((*(*p).kindU.S6.Sons->data[0]).Kind == ((NU8) 2)))) goto LA4;
			patternerror_276040((*p).kindU.S6.Sons->data[0]);
			goto BeforeRet;
		}
		LA4: ;
		op = (*(*p).kindU.S6.Sons->data[0]).kindU.S5.Ident;
		{
			NI LOC8;
			LOC8 = 0;
			LOC8 = len_189264(p);
			if (!(LOC8 == 3)) goto LA9;
			{
				NIM_BOOL LOC13;
				LOC13 = 0;
				LOC13 = eqStrings((*op).S, ((NimStringDesc*) &TMP2822));
				if (LOC13) goto LA14;
				LOC13 = ((*op).Sup.Id == 47);
				LA14: ;
				if (!LOC13) goto LA15;
				compileconstraints_276106((*p).kindU.S6.Sons->data[1], result);
				compileconstraints_276106((*p).kindU.S6.Sons->data[2], result);
				add_276046(result, ((NU8) 2));
			}
			goto LA11;
			LA15: ;
			{
				NIM_BOOL LOC18;
				LOC18 = 0;
				LOC18 = eqStrings((*op).S, ((NimStringDesc*) &TMP2823));
				if (LOC18) goto LA19;
				LOC18 = ((*op).Sup.Id == 2);
				LA19: ;
				if (!LOC18) goto LA20;
				compileconstraints_276106((*p).kindU.S6.Sons->data[1], result);
				compileconstraints_276106((*p).kindU.S6.Sons->data[2], result);
				add_276046(result, ((NU8) 3));
			}
			goto LA11;
			LA20: ;
			{
				patternerror_276040(p);
			}
			LA11: ;
		}
		goto LA6;
		LA9: ;
		{
			NIM_BOOL LOC24;
			NI LOC25;
			NIM_BOOL LOC27;
			LOC24 = 0;
			LOC25 = 0;
			LOC25 = len_189264(p);
			LOC24 = (LOC25 == 2);
			if (!(LOC24)) goto LA26;
			LOC27 = 0;
			LOC27 = eqStrings((*op).S, ((NimStringDesc*) &TMP2824));
			if (LOC27) goto LA28;
			LOC27 = ((*op).Sup.Id == 43);
			LA28: ;
			LOC24 = LOC27;
			LA26: ;
			if (!LOC24) goto LA29;
			compileconstraints_276106((*p).kindU.S6.Sons->data[1], result);
			add_276046(result, ((NU8) 4));
		}
		goto LA6;
		LA29: ;
		{
			patternerror_276040(p);
		}
		LA6: ;
	}
	break;
	case ((NU8) 53):
	case ((NU8) 37):
	{
		{
			NI LOC35;
			LOC35 = 0;
			LOC35 = len_189264(p);
			if (!(LOC35 == 1)) goto LA36;
			compileconstraints_276106((*p).kindU.S6.Sons->data[0], result);
		}
		goto LA33;
		LA36: ;
		{
			patternerror_276040(p);
		}
		LA33: ;
	}
	break;
	case ((NU8) 2):
	{
		NimStringDesc* spec;
		spec = nsuNormalize((*(*p).kindU.S5.Ident).S);
		switch (hashString(spec) & 15) {
		case 1: 
if (eqStrings(spec, ((NimStringDesc*) &TMP2835))) goto LA50;
break;
		case 3: 
if (eqStrings(spec, ((NimStringDesc*) &TMP2831))) goto LA46;
if (eqStrings(spec, ((NimStringDesc*) &TMP2832))) goto LA47;
if (eqStrings(spec, ((NimStringDesc*) &TMP2834))) goto LA49;
break;
		case 4: 
if (eqStrings(spec, ((NimStringDesc*) &TMP2827))) goto LA42;
break;
		case 6: 
if (eqStrings(spec, ((NimStringDesc*) &TMP2828))) goto LA43;
if (eqStrings(spec, ((NimStringDesc*) &TMP2833))) goto LA48;
break;
		case 11: 
if (eqStrings(spec, ((NimStringDesc*) &TMP2825))) goto LA40;
break;
		case 12: 
if (eqStrings(spec, ((NimStringDesc*) &TMP2826))) goto LA41;
break;
		case 13: 
if (eqStrings(spec, ((NimStringDesc*) &TMP2829))) goto LA44;
break;
		case 14: 
if (eqStrings(spec, ((NimStringDesc*) &TMP2830))) goto LA45;
break;
		}
		goto LA51;
		LA40: ;
		{
			add_276046(result, ((NU8) 6));
		}
		goto LA52;
		LA41: ;
		{
			add_276046(result, ((NU8) 7));
		}
		goto LA52;
		LA42: ;
		{
			add_276046(result, ((NU8) 5));
		}
		goto LA52;
		LA43: ;
		{
			add_276046(result, ((NU8) 8));
		}
		goto LA52;
		LA44: ;
		{
			add_276046(result, ((NU8) 9));
		}
		goto LA52;
		LA45: ;
		{
			(*result)->data[0] = 2;
		}
		goto LA52;
		LA46: ;
		{
			(*result)->data[0] = 3;
		}
		goto LA52;
		LA47: ;
		{
			add_276046(result, ((NU8) 12));
		}
		goto LA52;
		LA48: ;
		{
			add_276046(result, ((NU8) 13));
		}
		goto LA52;
		LA49: ;
		{
			add_276046(result, ((NU8) 14));
		}
		goto LA52;
		LA50: ;
		{
			add_276046(result, ((NU8) 15));
		}
		goto LA52;
		LA51: ;
		{
			NU8 i_276371;
			NU8 res_276461;
			NU8 i_276442;
			NU8 res_276466;
			{
				NimStringDesc* LOC69;
				if (!NIM_FALSE) goto LA67;
				LOC69 = 0;
				LOC69 = HEX24_165714(TMP2836);
				internalerror_165606(LOC69);
			}
			LA67: ;
			i_276371 = 0;
			res_276461 = ((NU8) 0);
			while (1) {
				if (!(res_276461 <= ((NU8) 24))) goto LA70;
				i_276371 = res_276461;
				{
					NimStringDesc* LOC73;
					NI LOC74;
					LOC73 = 0;
					LOC73 = copyStr(reprEnum(i_276371, (&NTI188441)), 2);
					LOC74 = 0;
					LOC74 = nsuCmpIgnoreStyle(LOC73, spec);
					if (!(LOC74 == 0)) goto LA75;
					add_276046(result, ((NU8) 10));
					(*result) = addChar((*result), ((NIM_CHAR) (((NI) (i_276371)))));
					goto BeforeRet;
				}
				LA75: ;
				res_276461 += 1;
			} LA70: ;
			{
				NimStringDesc* LOC81;
				if (!NIM_FALSE) goto LA79;
				LOC81 = 0;
				LOC81 = HEX24_165714(TMP2838);
				internalerror_165606(LOC81);
			}
			LA79: ;
			i_276442 = 0;
			res_276466 = ((NU8) 0);
			while (1) {
				if (!(res_276466 <= ((NU8) 156))) goto LA82;
				i_276442 = res_276466;
				{
					NI LOC85;
					LOC85 = 0;
					LOC85 = nsuCmpIgnoreStyle(reprEnum(i_276442, (&NTI188023)), spec);
					if (!(LOC85 == 0)) goto LA86;
					add_276046(result, ((NU8) 11));
					(*result) = addChar((*result), ((NIM_CHAR) (((NI) (i_276442)))));
					goto BeforeRet;
				}
				LA86: ;
				res_276466 += 1;
			} LA82: ;
			patternerror_276040(p);
		}
		LA52: ;
	}
	break;
	default:
	{
		patternerror_276040(p);
	}
	break;
	}
	BeforeRet: ;
}

N_NIMCALL(tnode188803*, semnodekindconstraints_276472)(tnode188803* p) {
	tnode188803* result;
	result = 0;
	result = newnodei_189099(((NU8) 20), (*p).Info);
	asgnRefNoCycle((void**) &(*result).kindU.S3.Strval, rawNewString(10));
	(*result).kindU.S3.Strval = addChar((*result).kindU.S3.Strval, 1);
	{
		NI LOC3;
		NI i_276658;
		NI HEX3Atmp_276718;
		NI LOC6;
		NI res_276720;
		LOC3 = 0;
		LOC3 = len_189264(p);
		if (!(2 <= LOC3)) goto LA4;
		i_276658 = 0;
		HEX3Atmp_276718 = 0;
		LOC6 = 0;
		LOC6 = len_189264(p);
		HEX3Atmp_276718 = LOC6 - 1;
		res_276720 = 1;
		while (1) {
			if (!(res_276720 <= HEX3Atmp_276718)) goto LA7;
			i_276658 = res_276720;
			compileconstraints_276106((*p).kindU.S6.Sons->data[i_276658], &(*result).kindU.S3.Strval);
			res_276720 += 1;
		} LA7: ;
		{
			if (!(63 < (*result).kindU.S3.Strval->Sup.len)) goto LA10;
			internalerror_165591((*p).Info, ((NimStringDesc*) &TMP2839));
		}
		LA10: ;
	}
	goto LA1;
	LA4: ;
	{
		patternerror_276040(p);
	}
	LA1: ;
	add_276046(&(*result).kindU.S3.Strval, ((NU8) 1));
	return result;
}

N_NIMCALL(NU8, whichalias_276061)(tsym188833* p) {
	NU8 result;
	result = 0;
	{
		if (!!(((*p).Constraint == NIM_NIL))) goto LA3;
		result = ((NU8) (((NU8)((*(*p).Constraint).kindU.S3.Strval->data[0]))));
	}
	goto LA1;
	LA3: ;
	{
		result = ((NU8) 1);
	}
	LA1: ;
	return result;
}
N_NOINLINE(void, parampatternsInit)(void) {
}

N_NOINLINE(void, parampatternsDatInit)(void) {
}

