/* 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/pretty.o compiler/nimcache/pretty.c */
#define NIM_INTBITS 32
#include "nimbase.h"

#include <stdio.h>

#include <string.h>

#include <setjmp.h>
typedef struct TY355021 TY355021;
typedef struct tsourcefile355014 tsourcefile355014;
typedef struct TY110805 TY110805;
typedef struct NimStringDesc NimStringDesc;
typedef struct TGenericSeq TGenericSeq;
typedef struct TNimType TNimType;
typedef struct TNimNode TNimNode;
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 tstringtable121810 tstringtable121810;
typedef struct tnode188803 tnode188803;
typedef struct tsym188833 tsym188833;
typedef struct ttype188837 ttype188837;
typedef struct tlineinfo163527 tlineinfo163527;
typedef struct tident167019 tident167019;
typedef struct tnodeseq188797 tnodeseq188797;
typedef struct tidobj167013 tidobj167013;
typedef struct TNimObject TNimObject;
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 tslice78892 tslice78892;
typedef struct tpasscontext246003 tpasscontext246003;
typedef struct tgen355010 tgen355010;
typedef struct E_Base E_Base;
typedef struct TSafePoint TSafePoint;
typedef struct tbasechunk22636 tbasechunk22636;
typedef struct tfreecell22628 tfreecell22628;
typedef struct tkeyvaluepairseq121808 tkeyvaluepairseq121808;
typedef struct tkeyvaluepair121806 tkeyvaluepair121806;
typedef struct TY188922 TY188922;
typedef struct tlistentry118017 tlistentry118017;
struct  TGenericSeq  {
NI len;
NI reserved;
};
struct  NimStringDesc  {
  TGenericSeq Sup;
NIM_CHAR data[SEQ_DECL_SIZE];
};
struct  tsourcefile355014  {
TY110805* Lines;
NIM_BOOL Dirty;
NimStringDesc* Fullpath;
};
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  TNimNode  {
NU8 kind;
NI offset;
TNimType* typ;
NCSTRING name;
NI len;
TNimNode** sons;
};
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  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;
};
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  tident167019  {
  tidobj167013 Sup;
NimStringDesc* S;
tident167019* Next;
NI H;
};
struct  tslice78892  {
NI A;
NI B;
};
typedef NU8 TY90161[32];
typedef NimStringDesc* TY355403[33];
struct  tpasscontext246003  {
  TNimObject Sup;
NIM_BOOL Fromcache;
};
struct  tgen355010  {
  tpasscontext246003 Sup;
tsym188833* Module;
};
struct  E_Base  {
  TNimObject Sup;
E_Base* parent;
NCSTRING name;
NimStringDesc* message;
NimStringDesc* trace;
};
typedef struct {
N_NIMCALL_PTR(NIM_BOOL, ClPrc) (E_Base* e, void* ClEnv);
void* ClEnv;
} TY11626;
struct  TSafePoint  {
TSafePoint* prev;
NI status;
jmp_buf context;
NIM_BOOL hasRaiseAction;
TY11626 raiseAction;
};
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 tkeyvaluepair121806 {
NimStringDesc* Field0;
NimStringDesc* Field1;
};
struct  tstringtable121810  {
  TNimObject Sup;
NI Counter;
tkeyvaluepairseq121808* Data;
NU8 Mode;
};
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  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;
};
struct  tfreecell22628  {
tfreecell22628* Next;
NI Zerofield;
};
struct TY110805 {
  TGenericSeq Sup;
  NimStringDesc* data[SEQ_DECL_SIZE];
};
struct TY355021 {
  TGenericSeq Sup;
  tsourcefile355014 data[SEQ_DECL_SIZE];
};
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 tkeyvaluepairseq121808 {
  TGenericSeq Sup;
  tkeyvaluepair121806 data[SEQ_DECL_SIZE];
};
struct TY188922 {
  TGenericSeq Sup;
  NI32 data[SEQ_DECL_SIZE];
};
N_NIMCALL(void, nimGCvisit)(void* d, NI op);
N_NIMCALL(void, TMP906)(void* p, NI op);
static N_INLINE(void, nimGCunrefNoCycle)(void* p);
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(void*, newSeqRC1)(TNimType* typ, NI len);
N_NIMCALL(void, loadfile_355049)(tlineinfo163527 info);
N_NIMCALL(TGenericSeq*, setLengthSeq)(TGenericSeq* seq, NI elemsize, NI newlen);
N_NIMCALL(NimStringDesc*, tofullpath_164788)(NI32 fileidx);
N_NIMCALL(NimStringDesc*, copyStringRC1)(NimStringDesc* src);
N_NIMCALL(FILE*, open_10217)(NimStringDesc* filename, NU8 mode, NI bufsize);
N_NIMCALL(NimStringDesc*, rawNewString)(NI space);
N_NIMCALL(NimStringDesc*, rawNewString)(NI cap);
N_NIMCALL(NIM_BOOL, readline_10487)(FILE* f, NimStringDesc** line);
N_NIMCALL(TGenericSeq*, incrSeq)(TGenericSeq* seq, NI elemsize);
N_NIMCALL(NI, identlen_355499)(NimStringDesc* line, NI start);
N_NIMCALL(NIM_BOOL, differ_355537)(NimStringDesc* line, NI a, NI b, NimStringDesc* x);
static N_INLINE(NimStringDesc*, HEX5BHEX5D_78885)(NimStringDesc* s, tslice78892 x);
N_NIMCALL(NimStringDesc*, copyStrLast)(NimStringDesc* s, NI start_70624, NI last);
N_NIMCALL(NimStringDesc*, copyStrLast)(NimStringDesc* s, NI first, NI last);
static N_INLINE(tslice78892, HEX2EHEX2E_86221)(NI a_86225, NI b_86227);
N_NIMCALL(NI, nsuCmpIgnoreStyle)(NimStringDesc* a, NimStringDesc* b);
static N_INLINE(NIM_BOOL, eqStrings)(NimStringDesc* a, NimStringDesc* b);
static N_INLINE(void, appendString)(NimStringDesc* dest, NimStringDesc* src);
N_NIMCALL(NimStringDesc*, copyStr)(NimStringDesc* s, NI start);
N_NIMCALL(NimStringDesc*, copyStr)(NimStringDesc* s, NI first);
static N_INLINE(void, asgnRefNoCycle)(void** dest, void* src);
N_NIMCALL(void, checkstyle_355488)(tlineinfo163527 info, NimStringDesc* s, NU8 k);
N_NIMCALL(NimStringDesc*, beautifyname_355213)(NimStringDesc* s, NU8 k);
N_NIMCALL(NIM_BOOL, allcharsinset_89836)(NimStringDesc* s, TY90161 theset);
N_NIMCALL(NimStringDesc*, copyString)(NimStringDesc* src);
N_NIMCALL(NIM_BOOL, HEX3DHEX7E_355190)(NimStringDesc* s, NimStringDesc** a, NI aLen0);
N_NIMCALL(NIM_BOOL, nsuStartsWith)(NimStringDesc* s, NimStringDesc* prefix);
N_NIMCALL(NimStringDesc*, addChar)(NimStringDesc* s, NIM_CHAR c);
N_NIMCALL(NIM_CHAR, nsuToUpperChar)(NIM_CHAR c);
N_NIMCALL(NIM_BOOL, contains_90244)(NimStringDesc* s, NIM_CHAR c);
N_NIMCALL(NIM_CHAR, nsuToLowerChar)(NIM_CHAR c);
N_NIMCALL(void, message_165584)(tlineinfo163527 info, NU16 msg, NimStringDesc* arg);
N_NIMCALL(void, TMP4318)(void* p, NI op);
N_NIMCALL(void*, newObj)(TNimType* typ, NI size);
N_NIMCALL(NimStringDesc*, nsuNormalize)(NimStringDesc* s);
N_NIMCALL(NimStringDesc*, getconfigvar_137311)(NimStringDesc* key);
N_NIMCALL(tstringtable121810*, nstnewStringTable)(NU8 mode);
static N_INLINE(void, asgnRef)(void** dest, void* src);
static N_INLINE(void, incref_46827)(tcell41090* c);
static N_INLINE(NIM_BOOL, canbecycleroot_44462)(tcell41090* c);
static N_INLINE(void, rtladdcycleroot_45235)(tcell41090* c);
N_NOINLINE(void, incl_41855)(tcellset41102* s, tcell41090* cell);
static N_INLINE(void, decref_46402)(tcell41090* c);
N_NIMCALL(void, check_356201)(tgen355010* c, tnode188803* n);
N_NIMCALL(void, checkuse_355729)(tnode188803* n, tsym188833* s);
N_NIMCALL(void, checkdef_355700)(tgen355010* c, tnode188803* n);
N_NIMCALL(void, checkdef_355603)(tnode188803* n, tsym188833* s);
static N_INLINE(tnode188803*, HEX5BHEX5D_189694)(tnode188803* n, NI i);
static N_INLINE(NI, len_189264)(tnode188803* n);
N_NIMCALL(void, checkminsonslen_251215)(tnode188803* n, NI length);
static N_INLINE(NI, sonslen_189181)(tnode188803* n);
N_NIMCALL(void, checksonslen_251209)(tnode188803* n, NI length);
static N_INLINE(NI, safelen_189320)(tnode188803* n);
N_NIMCALL(NimStringDesc*, noschangeFileExt)(NimStringDesc* filename, NimStringDesc* ext);
static N_INLINE(void, pushSafePoint)(TSafePoint* s);
N_NIMCALL(void, write_10463)(FILE* f, NimStringDesc* s);
N_NIMCALL(NimStringDesc*, nsuStrip)(NimStringDesc* s, NIM_BOOL leading, NIM_BOOL trailing);
static N_INLINE(void, popSafePoint)(void);
N_NIMCALL(NIM_BOOL, isObj)(TNimType* obj, TNimType* subclass);
static N_INLINE(E_Base*, getCurrentException)(void);
N_NIMCALL(void, rawmessage_165386)(NU16 msg, NimStringDesc* arg);
static N_INLINE(void, popCurrentException)(void);
N_NIMCALL(void, reraiseException)(void);
static NIM_CONST TY90161 TMP2784 = {
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xFF, 0x03,
0xFE, 0xFF, 0xFF, 0x87, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}
;
STRING_LITERAL(TMP2786, "int", 3);
STRING_LITERAL(TMP2787, "uint", 4);
STRING_LITERAL(TMP2788, "cint", 4);
STRING_LITERAL(TMP2789, "cuint", 5);
STRING_LITERAL(TMP2790, "clong", 5);
STRING_LITERAL(TMP2791, "cstring", 7);
STRING_LITERAL(TMP2792, "string", 6);
STRING_LITERAL(TMP2793, "char", 4);
STRING_LITERAL(TMP2794, "byte", 4);
STRING_LITERAL(TMP2795, "bool", 4);
STRING_LITERAL(TMP2796, "openArray", 9);
STRING_LITERAL(TMP2797, "seq", 3);
STRING_LITERAL(TMP2798, "array", 5);
STRING_LITERAL(TMP2799, "void", 4);
STRING_LITERAL(TMP2800, "pointer", 7);
STRING_LITERAL(TMP2801, "float", 5);
STRING_LITERAL(TMP2802, "csize", 5);
STRING_LITERAL(TMP2803, "cdouble", 7);
STRING_LITERAL(TMP2804, "cchar", 5);
STRING_LITERAL(TMP2805, "cschar", 6);
STRING_LITERAL(TMP2806, "cshort", 6);
STRING_LITERAL(TMP2807, "cu", 2);
STRING_LITERAL(TMP2808, "nil", 3);
STRING_LITERAL(TMP2809, "expr", 4);
STRING_LITERAL(TMP2810, "stmt", 4);
STRING_LITERAL(TMP2811, "typedesc", 8);
STRING_LITERAL(TMP2812, "auto", 4);
STRING_LITERAL(TMP2813, "any", 3);
STRING_LITERAL(TMP2814, "range", 5);
STRING_LITERAL(TMP2815, "openarray", 9);
STRING_LITERAL(TMP2816, "varargs", 7);
STRING_LITERAL(TMP2817, "set", 3);
STRING_LITERAL(TMP2818, "cfloat", 6);
NIM_CONST TY355403 TMP2785 = {((NimStringDesc*) &TMP2786),
((NimStringDesc*) &TMP2787),
((NimStringDesc*) &TMP2788),
((NimStringDesc*) &TMP2789),
((NimStringDesc*) &TMP2790),
((NimStringDesc*) &TMP2791),
((NimStringDesc*) &TMP2792),
((NimStringDesc*) &TMP2793),
((NimStringDesc*) &TMP2794),
((NimStringDesc*) &TMP2795),
((NimStringDesc*) &TMP2796),
((NimStringDesc*) &TMP2797),
((NimStringDesc*) &TMP2798),
((NimStringDesc*) &TMP2799),
((NimStringDesc*) &TMP2800),
((NimStringDesc*) &TMP2801),
((NimStringDesc*) &TMP2802),
((NimStringDesc*) &TMP2803),
((NimStringDesc*) &TMP2804),
((NimStringDesc*) &TMP2805),
((NimStringDesc*) &TMP2806),
((NimStringDesc*) &TMP2807),
((NimStringDesc*) &TMP2808),
((NimStringDesc*) &TMP2809),
((NimStringDesc*) &TMP2810),
((NimStringDesc*) &TMP2811),
((NimStringDesc*) &TMP2812),
((NimStringDesc*) &TMP2813),
((NimStringDesc*) &TMP2814),
((NimStringDesc*) &TMP2815),
((NimStringDesc*) &TMP2816),
((NimStringDesc*) &TMP2817),
((NimStringDesc*) &TMP2818)}
;
STRING_LITERAL(TMP2819, "name should be: ", 16);
STRING_LITERAL(TMP4319, "pretty.checkextern", 18);
STRING_LITERAL(TMP4320, "on", 2);
STRING_LITERAL(TMP4321, "pretty.overwrite", 16);
STRING_LITERAL(TMP4322, "pretty.strip", 12);
STRING_LITERAL(TMP4323, ".pretty.nim", 11);
STRING_LITERAL(TMP4325, "\012", 1);
TY355021* gsourcefiles_355042;
TNimType NTI355014; /* TSourceFile */
extern TNimType NTI110805; /* seq[string] */
extern TNimType NTI134; /* bool */
extern TNimType NTI143; /* string */
TNimType NTI355021; /* seq[TSourceFile] */
extern tgcheap43016 gch_43044;
NIM_BOOL gcheckextern_355043;
tstringtable121810* rules_355044;
extern TNimType NTI246003; /* TPassContext */
TNimType NTI355010; /* TGen */
extern TNimType NTI188801; /* PSym */
TNimType NTI355012; /* PGen */
extern TSafePoint* exchandler_13039;
extern TNimType NTI2433; /* EIO */
extern E_Base* currexception_13041;
N_NIMCALL(void, TMP906)(void* p, NI op) {
	TY355021* a;
	NI LOC1;
	a = (TY355021*)p;
	LOC1 = 0;
	for (LOC1 = 0; LOC1 < a->Sup.len; LOC1++) {
	nimGCvisit((void*)a->data[LOC1].Lines, op);
	nimGCvisit((void*)a->data[LOC1].Fullpath, op);
	}
}

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, nimGCunrefNoCycle)(void* p) {
	tcell41090* c;
	c = usrtocell_44443(p);
	{
		(*c).Refcount -= 8;
		if (!((NU32)((*c).Refcount) < (NU32)(8))) goto LA3;
		rtladdzct_46002(c);
	}
	LA3: ;
}

N_NIMCALL(void, loadfile_355049)(tlineinfo163527 info) {
	NI32 i;
	i = info.Fileindex;
	{
		if (!(gsourcefiles_355042->Sup.len <= ((NI) (i)))) goto LA3;
		gsourcefiles_355042 = (TY355021*) setLengthSeq(&(gsourcefiles_355042)->Sup, sizeof(tsourcefile355014), ((NI) ((NI32)(i + ((NI32) 1)))));
	}
	LA3: ;
	{
		NimStringDesc* path;
		NimStringDesc* LOC9;
		NimStringDesc* line_355112;
		FILE* f_355132;
		NimStringDesc* res_355134;
		if (!gsourcefiles_355042->data[i].Lines == 0) goto LA7;
		if (gsourcefiles_355042->data[i].Lines) nimGCunrefNoCycle(gsourcefiles_355042->data[i].Lines);
		gsourcefiles_355042->data[i].Lines = (TY110805*) newSeqRC1((&NTI110805), 0);
		path = tofullpath_164788(info.Fileindex);
		LOC9 = 0;
		LOC9 = gsourcefiles_355042->data[i].Fullpath; gsourcefiles_355042->data[i].Fullpath = copyStringRC1(path);
		if (LOC9) nimGCunrefNoCycle(LOC9);
		line_355112 = 0;
		f_355132 = open_10217(path, ((NU8) 0), 8000);
		res_355134 = rawNewString(80);
		while (1) {
			NIM_BOOL LOC11;
			NimStringDesc* LOC12;
			LOC11 = 0;
			LOC11 = readline_10487(f_355132, &res_355134);
			if (!LOC11) goto LA10;
			line_355112 = res_355134;
			gsourcefiles_355042->data[i].Lines = (TY110805*) incrSeq(&(gsourcefiles_355042->data[i].Lines)->Sup, sizeof(NimStringDesc*));
			LOC12 = 0;
			LOC12 = gsourcefiles_355042->data[i].Lines->data[gsourcefiles_355042->data[i].Lines->Sup.len-1]; gsourcefiles_355042->data[i].Lines->data[gsourcefiles_355042->data[i].Lines->Sup.len-1] = copyStringRC1(line_355112);
			if (LOC12) nimGCunrefNoCycle(LOC12);
		} LA10: ;
		fclose(f_355132);
	}
	LA7: ;
}

N_NIMCALL(NI, identlen_355499)(NimStringDesc* line, NI start) {
	NI result;
	result = 0;
	while (1) {
		NIM_BOOL LOC2;
		LOC2 = 0;
		LOC2 = ((NI32)(start + result) < line->Sup.len);
		if (!(LOC2)) goto LA3;
		LOC2 = (((NU8)(line->data[(NI32)(start + result)])) >= ((NU8)(97)) && ((NU8)(line->data[(NI32)(start + result)])) <= ((NU8)(122)) || ((NU8)(line->data[(NI32)(start + result)])) >= ((NU8)(65)) && ((NU8)(line->data[(NI32)(start + result)])) <= ((NU8)(90)) || ((NU8)(line->data[(NI32)(start + result)])) >= ((NU8)(48)) && ((NU8)(line->data[(NI32)(start + result)])) <= ((NU8)(57)) || ((NU8)(line->data[(NI32)(start + result)])) >= ((NU8)(128)) && ((NU8)(line->data[(NI32)(start + result)])) <= ((NU8)(255)) || ((NU8)(line->data[(NI32)(start + result)])) == ((NU8)(95)));
		LA3: ;
		if (!LOC2) goto LA1;
		result += 1;
	} LA1: ;
	return result;
}

static N_INLINE(NimStringDesc*, HEX5BHEX5D_78885)(NimStringDesc* s, tslice78892 x) {
	NimStringDesc* result;
	NI LOC1;
	NI LOC7;
	result = 0;
	LOC1 = 0;
	{
		if (!(0 <= x.A)) goto LA4;
		LOC1 = x.A;
	}
	goto LA2;
	LA4: ;
	{
		LOC1 = (NI32)(s->Sup.len + x.A);
	}
	LA2: ;
	LOC7 = 0;
	{
		if (!(0 <= x.B)) goto LA10;
		LOC7 = x.B;
	}
	goto LA8;
	LA10: ;
	{
		LOC7 = (NI32)(s->Sup.len + x.B);
	}
	LA8: ;
	result = copyStrLast(s, LOC1, LOC7);
	return result;
}

static N_INLINE(tslice78892, HEX2EHEX2E_86221)(NI a_86225, NI b_86227) {
	tslice78892 result;
	memset((void*)&result, 0, sizeof(result));
	result.A = a_86225;
	result.B = b_86227;
	return result;
}

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;
}

N_NIMCALL(NIM_BOOL, differ_355537)(NimStringDesc* line, NI a, NI b, NimStringDesc* x) {
	NIM_BOOL result;
	NimStringDesc* y;
	tslice78892 LOC1;
	NIM_BOOL LOC2;
	NI LOC3;
	result = 0;
	LOC1 = HEX2EHEX2E_86221(a, b);
	y = HEX5BHEX5D_78885(line, LOC1);
	LOC2 = 0;
	LOC3 = 0;
	LOC3 = nsuCmpIgnoreStyle(y, x);
	LOC2 = (LOC3 == 0);
	if (!(LOC2)) goto LA4;
	LOC2 = !(eqStrings(y, x));
	LA4: ;
	result = LOC2;
	return result;
}

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

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, checkuse_355729)(tnode188803* n, tsym188833* s) {
	NimStringDesc* newname;
	NimStringDesc* line;
	NI first;
	NI last;
	NI LOC32;
	{
		if (!((*n).Info.Fileindex < ((NI32) 0))) goto LA3;
		goto BeforeRet;
	}
	LA3: ;
	{
		NIM_BOOL LOC7;
		LOC7 = 0;
		LOC7 = ((2080 &(1<<(((*s).Kind)&31)))!=0);
		if (LOC7) goto LA8;
		LOC7 = !((((NU8)((*(*s).Name).S->data[0])) >= ((NU8)(97)) && ((NU8)((*(*s).Name).S->data[0])) <= ((NU8)(122)) || ((NU8)((*(*s).Name).S->data[0])) >= ((NU8)(65)) && ((NU8)((*(*s).Name).S->data[0])) <= ((NU8)(90)) || ((NU8)((*(*s).Name).S->data[0])) >= ((NU8)(48)) && ((NU8)((*(*s).Name).S->data[0])) <= ((NU8)(57)) || ((NU8)((*(*s).Name).S->data[0])) >= ((NU8)(128)) && ((NU8)((*(*s).Name).S->data[0])) <= ((NU8)(255)) || ((NU8)((*(*s).Name).S->data[0])) == ((NU8)(95))));
		LA8: ;
		if (!LOC7) goto LA9;
		goto BeforeRet;
	}
	LA9: ;
	{
		NIM_BOOL LOC13;
		LOC13 = 0;
		LOC13 = ((144 &(1<<(((*s).Kind)&31)))!=0);
		if (!(LOC13)) goto LA14;
		LOC13 = (((*s).Flags &(1<<((((NU8) 29))&31)))!=0);
		LA14: ;
		if (!LOC13) goto LA15;
		goto BeforeRet;
	}
	LA15: ;
	newname = (*(*s).Name).S;
	loadfile_355049((*n).Info);
	line = gsourcefiles_355042->data[(*n).Info.Fileindex].Lines->data[(NI16)((*n).Info.Line - ((NI16) 1))];
	first = ((((NI) ((*n).Info.Col)) <= line->Sup.len) ? ((NI) ((*n).Info.Col)) : line->Sup.len);
	{
		if (!(first < 0)) goto LA19;
		goto BeforeRet;
	}
	LA19: ;
	while (1) {
		NIM_BOOL LOC22;
		LOC22 = 0;
		LOC22 = (0 < first);
		if (!(LOC22)) goto LA23;
		LOC22 = (((NU8)(line->data[(NI32)(first - 1)])) >= ((NU8)(97)) && ((NU8)(line->data[(NI32)(first - 1)])) <= ((NU8)(122)) || ((NU8)(line->data[(NI32)(first - 1)])) >= ((NU8)(65)) && ((NU8)(line->data[(NI32)(first - 1)])) <= ((NU8)(90)) || ((NU8)(line->data[(NI32)(first - 1)])) >= ((NU8)(48)) && ((NU8)(line->data[(NI32)(first - 1)])) <= ((NU8)(57)) || ((NU8)(line->data[(NI32)(first - 1)])) >= ((NU8)(128)) && ((NU8)(line->data[(NI32)(first - 1)])) <= ((NU8)(255)) || ((NU8)(line->data[(NI32)(first - 1)])) == ((NU8)(95)));
		LA23: ;
		if (!LOC22) goto LA21;
		first -= 1;
	} LA21: ;
	{
		if (!(first < 0)) goto LA26;
		goto BeforeRet;
	}
	LA26: ;
	{
		if (!((NU8)(line->data[first]) == (NU8)(96))) goto LA30;
		first += 1;
	}
	LA30: ;
	LOC32 = 0;
	LOC32 = identlen_355499(line, first);
	last = (NI32)((NI32)(first + LOC32) - 1);
	{
		NIM_BOOL LOC35;
		NimStringDesc* x;
		NimStringDesc* LOC38;
		NimStringDesc* LOC39;
		NimStringDesc* LOC40;
		LOC35 = 0;
		LOC35 = differ_355537(line, first, last, newname);
		if (!LOC35) goto LA36;
		LOC38 = 0;
		LOC39 = 0;
		LOC39 = copyStrLast(line, 0, (NI32)(first - 1));
		LOC40 = 0;
		LOC40 = copyStr(line, (NI32)(last + 1));
		LOC38 = rawNewString(LOC39->Sup.len + newname->Sup.len + LOC40->Sup.len + 0);
appendString(LOC38, LOC39);
appendString(LOC38, newname);
appendString(LOC38, LOC40);
		x = LOC38;
		asgnRefNoCycle((void**) &gsourcefiles_355042->data[(*n).Info.Fileindex].Lines->data[(NI16)((*n).Info.Line - ((NI16) 1))], x);
		gsourcefiles_355042->data[(*n).Info.Fileindex].Dirty = NIM_TRUE;
	}
	LA36: ;
	BeforeRet: ;
}

N_NIMCALL(NIM_BOOL, HEX3DHEX7E_355190)(NimStringDesc* s, NimStringDesc** a, NI aLen0) {
	NIM_BOOL result;
	NimStringDesc* x_355207;
	NI i_355209;
	result = 0;
	x_355207 = 0;
	i_355209 = 0;
	while (1) {
		if (!(i_355209 < aLen0)) goto LA1;
		x_355207 = a[i_355209];
		{
			NIM_BOOL LOC4;
			LOC4 = 0;
			LOC4 = nsuStartsWith(s, x_355207);
			if (!LOC4) goto LA5;
			result = NIM_TRUE;
			goto BeforeRet;
		}
		LA5: ;
		i_355209 += 1;
	} LA1: ;
	BeforeRet: ;
	return result;
}

N_NIMCALL(NimStringDesc*, beautifyname_355213)(NimStringDesc* s, NU8 k) {
	NimStringDesc* result;
	NIM_BOOL allupper;
	NI i;
	result = 0;
	allupper = allcharsinset_89836(s, TMP2784);
	{
		NIM_BOOL LOC3;
		LOC3 = 0;
		LOC3 = allupper;
		if (!(LOC3)) goto LA4;
		LOC3 = ((1049728 &(1<<((k)&31)))!=0);
		LA4: ;
		if (!LOC3) goto LA5;
		result = copyString(s);
		goto BeforeRet;
	}
	LA5: ;
	result = rawNewString(s->Sup.len);
	i = 0;
	switch (k) {
	case ((NU8) 7):
	case ((NU8) 4):
	{
		{
			NIM_BOOL LOC10;
			LOC10 = 0;
			LOC10 = HEX3DHEX7E_355190(s, TMP2785, 33);
			if (!LOC10) goto LA11;
			result = addChar(result, s->data[i]);
		}
		goto LA8;
		LA11: ;
		{
			NIM_CHAR LOC14;
			LOC14 = 0;
			LOC14 = nsuToUpperChar(s->data[i]);
			result = addChar(result, LOC14);
		}
		LA8: ;
	}
	break;
	case ((NU8) 10):
	case ((NU8) 20):
	{
		result = addChar(result, s->data[0]);
	}
	break;
	default:
	{
		{
			NIM_BOOL LOC19;
			LOC19 = 0;
			LOC19 = (s->Sup.len == 1);
			if (!(LOC19)) goto LA20;
			LOC19 = ((NU8)(s->data[0]) == (NU8)(76));
			LA20: ;
			if (!LOC19) goto LA21;
			result = addChar(result, 76);
		}
		goto LA17;
		LA21: ;
		{
			NIM_BOOL LOC24;
			LOC24 = 0;
			LOC24 = contains_90244(s, 95);
			if (!LOC24) goto LA25;
			result = addChar(result, s->data[i]);
		}
		goto LA17;
		LA25: ;
		{
			NIM_CHAR LOC28;
			LOC28 = 0;
			LOC28 = nsuToLowerChar(s->data[0]);
			result = addChar(result, LOC28);
		}
		LA17: ;
	}
	break;
	}
	i += 1;
	while (1) {
		if (!(i < s->Sup.len)) goto LA29;
		{
			if (!((NU8)(s->data[i]) == (NU8)(95))) goto LA32;
			{
				NIM_BOOL LOC36;
				LOC36 = 0;
				LOC36 = (0 < i);
				if (!(LOC36)) goto LA37;
				LOC36 = (((NU8)(s->data[(NI32)(i - 1)])) >= ((NU8)(65)) && ((NU8)(s->data[(NI32)(i - 1)])) <= ((NU8)(90)));
				LA37: ;
				if (!LOC36) goto LA38;
				result = addChar(result, 95);
				i += 1;
				result = addChar(result, s->data[i]);
			}
			goto LA34;
			LA38: ;
			{
				NIM_CHAR LOC41;
				i += 1;
				LOC41 = 0;
				LOC41 = nsuToUpperChar(s->data[i]);
				result = addChar(result, LOC41);
			}
			LA34: ;
		}
		goto LA30;
		LA32: ;
		{
			NIM_CHAR LOC45;
			if (!allupper) goto LA43;
			LOC45 = 0;
			LOC45 = nsuToLowerChar(s->data[i]);
			result = addChar(result, LOC45);
		}
		goto LA30;
		LA43: ;
		{
			result = addChar(result, s->data[i]);
		}
		LA30: ;
		i += 1;
	} LA29: ;
	BeforeRet: ;
	return result;
}

N_NIMCALL(void, checkstyle_355488)(tlineinfo163527 info, NimStringDesc* s, NU8 k) {
	NimStringDesc* beau;
	beau = beautifyname_355213(s, k);
	{
		NimStringDesc* LOC5;
		if (!!(eqStrings(s, beau))) goto LA3;
		LOC5 = 0;
		LOC5 = rawNewString(beau->Sup.len + 16);
appendString(LOC5, ((NimStringDesc*) &TMP2819));
appendString(LOC5, beau);
		message_165584(info, ((NU16) 4), LOC5);
	}
	LA3: ;
}

N_NIMCALL(void, checkdef_355603)(tnode188803* n, tsym188833* s) {
	{
		NIM_BOOL LOC3;
		LOC3 = 0;
		LOC3 = ((2080 &(1<<(((*s).Kind)&31)))!=0);
		if (LOC3) goto LA4;
		LOC3 = !((((NU8)((*(*s).Name).S->data[0])) >= ((NU8)(97)) && ((NU8)((*(*s).Name).S->data[0])) <= ((NU8)(122)) || ((NU8)((*(*s).Name).S->data[0])) >= ((NU8)(65)) && ((NU8)((*(*s).Name).S->data[0])) <= ((NU8)(90)) || ((NU8)((*(*s).Name).S->data[0])) >= ((NU8)(48)) && ((NU8)((*(*s).Name).S->data[0])) <= ((NU8)(57)) || ((NU8)((*(*s).Name).S->data[0])) >= ((NU8)(128)) && ((NU8)((*(*s).Name).S->data[0])) <= ((NU8)(255)) || ((NU8)((*(*s).Name).S->data[0])) == ((NU8)(95))));
		LA4: ;
		if (!LOC3) goto LA5;
		goto BeforeRet;
	}
	LA5: ;
	{
		NIM_BOOL LOC9;
		LOC9 = 0;
		LOC9 = ((144 &(1<<(((*s).Kind)&31)))!=0);
		if (!(LOC9)) goto LA10;
		LOC9 = (((*s).Flags &(1<<((((NU8) 29))&31)))!=0);
		LA10: ;
		if (!LOC9) goto LA11;
		goto BeforeRet;
	}
	LA11: ;
	{
		NIM_BOOL LOC15;
		LOC15 = 0;
		LOC15 = ((96 & (*s).Flags) == 0);
		if (LOC15) goto LA16;
		LOC15 = gcheckextern_355043;
		LA16: ;
		if (!LOC15) goto LA17;
		checkstyle_355488((*n).Info, (*(*s).Name).S, (*s).Kind);
	}
	LA17: ;
	BeforeRet: ;
}
N_NIMCALL(void, TMP4318)(void* p, NI op) {
	tgen355010* a;
	a = (tgen355010*)p;
	nimGCvisit((void*)(*a).Module, op);
}

static N_INLINE(NIM_BOOL, canbecycleroot_44462)(tcell41090* c) {
	NIM_BOOL result;
	result = 0;
	result = !((((*(*c).Typ).flags &(1<<((((NU8) 1))&7)))!=0));
	return result;
}

static N_INLINE(void, rtladdcycleroot_45235)(tcell41090* c) {
	{
		if (!!((((NI) ((NI)((*c).Refcount & 3))) == 3))) goto LA3;
		(*c).Refcount = (NI)((NI)((*c).Refcount & -4) | 3);
		incl_41855(&gch_43044.Cycleroots, c);
	}
	LA3: ;
}

static N_INLINE(void, incref_46827)(tcell41090* c) {
	(*c).Refcount = (NI)((NU32)((*c).Refcount) + (NU32)(8));
	{
		NIM_BOOL LOC3;
		LOC3 = 0;
		LOC3 = canbecycleroot_44462(c);
		if (!LOC3) goto LA4;
		rtladdcycleroot_45235(c);
	}
	LA4: ;
}

static N_INLINE(void, decref_46402)(tcell41090* c) {
	{
		(*c).Refcount -= 8;
		if (!((NU32)((*c).Refcount) < (NU32)(8))) goto LA3;
		rtladdzct_46002(c);
	}
	goto LA1;
	LA3: ;
	{
		NIM_BOOL LOC6;
		LOC6 = 0;
		LOC6 = canbecycleroot_44462(c);
		if (!LOC6) goto LA7;
		rtladdcycleroot_45235(c);
	}
	goto LA1;
	LA7: ;
	LA1: ;
}

static N_INLINE(void, asgnRef)(void** dest, void* src) {
	{
		tcell41090* LOC5;
		if (!!((src == NIM_NIL))) goto LA3;
		LOC5 = 0;
		LOC5 = usrtocell_44443(src);
		incref_46827(LOC5);
	}
	LA3: ;
	{
		tcell41090* LOC10;
		if (!!(((*dest) == NIM_NIL))) goto LA8;
		LOC10 = 0;
		LOC10 = usrtocell_44443((*dest));
		decref_46402(LOC10);
	}
	LA8: ;
	(*dest) = src;
}

N_NIMCALL(tpasscontext246003*, myopen_356491)(tsym188833* module) {
	tpasscontext246003* result;
	tgen355010* g;
	NimStringDesc* LOC1;
	NimStringDesc* LOC2;
	result = 0;
	g = 0;
	g = (tgen355010*) newObj((&NTI355012), sizeof(tgen355010));
	(*g).Sup.Sup.m_type = (&NTI355010);
	asgnRefNoCycle((void**) &(*g).Module, module);
	LOC1 = 0;
	LOC1 = getconfigvar_137311(((NimStringDesc*) &TMP4319));
	LOC2 = 0;
	LOC2 = nsuNormalize(LOC1);
	gcheckextern_355043 = eqStrings(LOC2, ((NimStringDesc*) &TMP4320));
	result = &g->Sup;
	{
		if (!rules_355044 == 0) goto LA5;
		asgnRef((void**) &rules_355044, nstnewStringTable(((NU8) 2)));
	}
	LA5: ;
	return result;
}

N_NIMCALL(void, checkdef_355700)(tgen355010* c, tnode188803* n) {
	{
		if (!!(((*n).Kind == ((NU8) 3)))) goto LA3;
		goto BeforeRet;
	}
	LA3: ;
	checkdef_355603(n, (*n).kindU.S4.Sym);
	BeforeRet: ;
}

static N_INLINE(tnode188803*, HEX5BHEX5D_189694)(tnode188803* n, NI i) {
	tnode188803* result;
	result = 0;
	result = (*n).kindU.S6.Sons->data[i];
	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;
}

static N_INLINE(NI, sonslen_189181)(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;
}

static N_INLINE(NI, safelen_189320)(tnode188803* 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 = 0;
	}
	goto LA1;
	LA5: ;
	{
		result = (*n).kindU.S6.Sons->Sup.len;
	}
	LA1: ;
	return result;
}

N_NIMCALL(void, check_356201)(tgen355010* c, tnode188803* n) {
	switch ((*n).Kind) {
	case ((NU8) 3):
	{
		checkuse_355729(n, (*n).kindU.S4.Sym);
	}
	break;
	case ((NU8) 111):
	case ((NU8) 126):
	case ((NU8) 128):
	{
		tnode188803* LOC3;
		LOC3 = 0;
		LOC3 = HEX5BHEX5D_189694(n, 0);
		checkdef_355700(c, LOC3);
		check_356201(c, (*n).kindU.S6.Sons->data[1]);
	}
	break;
	case ((NU8) 94):
	case ((NU8) 95):
	{
		NI l;
		NI i_356246;
		NI HEX3Atmp_356455;
		NI res_356457;
		tnode188803* LOC7;
		tnode188803* LOC8;
		l = len_189264(n);
		i_356246 = 0;
		HEX3Atmp_356455 = 0;
		HEX3Atmp_356455 = (NI32)(l - 3);
		res_356457 = 0;
		while (1) {
			tnode188803* LOC6;
			if (!(res_356457 <= HEX3Atmp_356455)) goto LA5;
			i_356246 = res_356457;
			LOC6 = 0;
			LOC6 = HEX5BHEX5D_189694(n, i_356246);
			checkdef_355700(c, LOC6);
			res_356457 += 1;
		} LA5: ;
		LOC7 = 0;
		LOC7 = HEX5BHEX5D_189694(n, (NI32)(l - 2));
		check_356201(c, LOC7);
		LOC8 = 0;
		LOC8 = HEX5BHEX5D_189694(n, (NI32)(l - 1));
		check_356201(c, LOC8);
	}
	break;
	case ((NU8) 79):
	case ((NU8) 51):
	case ((NU8) 80):
	case ((NU8) 84):
	case ((NU8) 83):
	case ((NU8) 82):
	case ((NU8) 81):
	case ((NU8) 52):
	{
		tnode188803* LOC10;
		NI i_356268;
		NI HEX3Atmp_356459;
		NI LOC11;
		NI res_356461;
		LOC10 = 0;
		LOC10 = HEX5BHEX5D_189694(n, 0);
		checkdef_355700(c, LOC10);
		i_356268 = 0;
		HEX3Atmp_356459 = 0;
		LOC11 = 0;
		LOC11 = len_189264(n);
		HEX3Atmp_356459 = LOC11 - 1;
		res_356461 = 1;
		while (1) {
			if (!(res_356461 <= HEX3Atmp_356459)) goto LA12;
			i_356268 = res_356461;
			check_356201(c, (*n).kindU.S6.Sons->data[i_356268]);
			res_356461 += 1;
		} LA12: ;
	}
	break;
	case ((NU8) 35):
	case ((NU8) 36):
	{
		tnode188803* a;
		NI l;
		NI j_356297;
		NI HEX3Atmp_356463;
		NI res_356465;
		a = n;
		checkminsonslen_251215(a, 3);
		l = len_189264(a);
		j_356297 = 0;
		HEX3Atmp_356463 = 0;
		HEX3Atmp_356463 = (NI32)(l - 3);
		res_356465 = 0;
		while (1) {
			if (!(res_356465 <= HEX3Atmp_356463)) goto LA14;
			j_356297 = res_356465;
			checkdef_355700(c, (*a).kindU.S6.Sons->data[j_356297]);
			res_356465 += 1;
		} LA14: ;
		check_356201(c, (*a).kindU.S6.Sons->data[(NI32)(l - 2)]);
		check_356201(c, (*a).kindU.S6.Sons->data[(NI32)(l - 1)]);
	}
	break;
	case ((NU8) 98):
	case ((NU8) 101):
	{
		NI i_356352;
		NI HEX3Atmp_356468;
		NI LOC16;
		NI res_356470;
		i_356352 = 0;
		HEX3Atmp_356468 = 0;
		LOC16 = 0;
		LOC16 = sonslen_189181(n);
		HEX3Atmp_356468 = (NI32)(LOC16 - 1);
		res_356470 = 0;
		while (1) {
			if (!(res_356470 <= HEX3Atmp_356468)) goto LA17;
			i_356352 = res_356470;
			{
				tnode188803* a;
				a = (*n).kindU.S6.Sons->data[i_356352];
				{
					if (!((*a).Kind == ((NU8) 124))) goto LA21;
					goto LA18;
				}
				LA21: ;
				checksonslen_251209(a, 3);
				checkdef_355700(c, (*a).kindU.S6.Sons->data[0]);
				check_356201(c, (*a).kindU.S6.Sons->data[1]);
				check_356201(c, (*a).kindU.S6.Sons->data[2]);
			} LA18: ;
			res_356470 += 1;
		} LA17: ;
	}
	break;
	default:
	{
		NI i_356440;
		NI HEX3Atmp_356472;
		NI LOC24;
		NI res_356474;
		i_356440 = 0;
		HEX3Atmp_356472 = 0;
		LOC24 = 0;
		LOC24 = safelen_189320(n);
		HEX3Atmp_356472 = LOC24 - 1;
		res_356474 = 0;
		while (1) {
			if (!(res_356474 <= HEX3Atmp_356472)) goto LA25;
			i_356440 = res_356474;
			check_356201(c, (*n).kindU.S6.Sons->data[i_356440]);
			res_356474 += 1;
		} LA25: ;
	}
	break;
	}
}

N_NIMCALL(tnode188803*, processsym_356484)(tpasscontext246003* c, tnode188803* n) {
	tnode188803* result;
	result = 0;
	result = n;
	check_356201(((tgen355010*) (c)), n);
	return result;
}

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

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

static N_INLINE(E_Base*, getCurrentException)(void) {
	E_Base* result;
	result = 0;
	result = currexception_13041;
	return result;
}

static N_INLINE(void, popCurrentException)(void) {
	asgnRef((void**) &currexception_13041, (*currexception_13041).parent);
}

N_NIMCALL(void, overwritefiles_355139)(void) {
	NIM_BOOL overwrite;
	NimStringDesc* LOC1;
	NimStringDesc* LOC2;
	NIM_BOOL dostrip;
	NimStringDesc* LOC3;
	NimStringDesc* LOC4;
	NI i_355153;
	NI HEX3Atmp_355181;
	NI res_355183;
	LOC1 = 0;
	LOC1 = getconfigvar_137311(((NimStringDesc*) &TMP4321));
	LOC2 = 0;
	LOC2 = nsuNormalize(LOC1);
	overwrite = eqStrings(LOC2, ((NimStringDesc*) &TMP4320));
	LOC3 = 0;
	LOC3 = getconfigvar_137311(((NimStringDesc*) &TMP4322));
	LOC4 = 0;
	LOC4 = nsuNormalize(LOC3);
	dostrip = eqStrings(LOC4, ((NimStringDesc*) &TMP4320));
	i_355153 = 0;
	HEX3Atmp_355181 = 0;
	HEX3Atmp_355181 = (gsourcefiles_355042->Sup.len-1);
	res_355183 = 0;
	while (1) {
		if (!(res_355183 <= HEX3Atmp_355181)) goto LA5;
		i_355153 = res_355183;
		{
			NimStringDesc* newfile;
			TSafePoint TMP4324;
			{
				if (!!(gsourcefiles_355042->data[i_355153].Dirty)) goto LA9;
				goto LA6;
			}
			LA9: ;
			{
				if (!overwrite) goto LA13;
				newfile = gsourcefiles_355042->data[i_355153].Fullpath;
			}
			goto LA11;
			LA13: ;
			{
				newfile = noschangeFileExt(gsourcefiles_355042->data[i_355153].Fullpath, ((NimStringDesc*) &TMP4323));
			}
			LA11: ;
			pushSafePoint(&TMP4324);
			TMP4324.status = setjmp(TMP4324.context);
			if (TMP4324.status == 0) {
				FILE* volatile f;
				NimStringDesc* volatile line_355168;
				TY110805* volatile HEX3Atmp_355176;
				NI volatile i_355178;
				NI volatile l_355180;
				f = open_10217(newfile, ((NU8) 1), -1);
				line_355168 = 0;
				HEX3Atmp_355176 = 0;
				HEX3Atmp_355176 = gsourcefiles_355042->data[i_355153].Lines;
				i_355178 = 0;
				l_355180 = HEX3Atmp_355176->Sup.len;
				while (1) {
					if (!(i_355178 < l_355180)) goto LA17;
					line_355168 = HEX3Atmp_355176->data[i_355178];
					{
						NimStringDesc* LOC22;
						if (!dostrip) goto LA20;
						LOC22 = 0;
						LOC22 = nsuStrip(line_355168, NIM_FALSE, NIM_TRUE);
						write_10463(f, LOC22);
					}
					goto LA18;
					LA20: ;
					{
						write_10463(f, line_355168);
					}
					LA18: ;
					write_10463(f, ((NimStringDesc*) &TMP4325));
					i_355178 += 1;
				} LA17: ;
				fclose(f);
				popSafePoint();
			}
			else {
				popSafePoint();
				if (isObj(getCurrentException()->Sup.m_type, (&NTI2433))) {
					TMP4324.status = 0;
					rawmessage_165386(((NU16) 3), newfile);
					popCurrentException();
				}
			}
			if (TMP4324.status != 0) reraiseException();
		} LA6: ;
		res_355183 += 1;
	} LA5: ;
}
N_NOINLINE(void, prettyInit)(void) {
	if (gsourcefiles_355042) nimGCunrefNoCycle(gsourcefiles_355042);
	gsourcefiles_355042 = (TY355021*) newSeqRC1((&NTI355021), 0);
}

N_NOINLINE(void, prettyDatInit)(void) {
static TNimNode* TMP905[3];
static TNimNode TMP903[5];
NTI355014.size = sizeof(tsourcefile355014);
NTI355014.kind = 18;
NTI355014.base = 0;
NTI355014.flags = 2;
TMP905[0] = &TMP903[1];
TMP903[1].kind = 1;
TMP903[1].offset = offsetof(tsourcefile355014, Lines);
TMP903[1].typ = (&NTI110805);
TMP903[1].name = "lines";
TMP905[1] = &TMP903[2];
TMP903[2].kind = 1;
TMP903[2].offset = offsetof(tsourcefile355014, Dirty);
TMP903[2].typ = (&NTI134);
TMP903[2].name = "dirty";
TMP905[2] = &TMP903[3];
TMP903[3].kind = 1;
TMP903[3].offset = offsetof(tsourcefile355014, Fullpath);
TMP903[3].typ = (&NTI143);
TMP903[3].name = "fullpath";
TMP903[0].len = 3; TMP903[0].kind = 2; TMP903[0].sons = &TMP905[0];
NTI355014.node = &TMP903[0];
NTI355021.size = sizeof(TY355021*);
NTI355021.kind = 24;
NTI355021.base = (&NTI355014);
NTI355021.flags = 2;
NTI355021.marker = TMP906;
NTI355010.size = sizeof(tgen355010);
NTI355010.kind = 17;
NTI355010.base = (&NTI246003);
TMP903[4].kind = 1;
TMP903[4].offset = offsetof(tgen355010, Module);
TMP903[4].typ = (&NTI188801);
TMP903[4].name = "module";
NTI355010.node = &TMP903[4];
NTI355012.size = sizeof(tgen355010*);
NTI355012.kind = 22;
NTI355012.base = (&NTI355010);
NTI355012.marker = TMP4318;
}

