/* 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 <string.h>
#include <stdio.h>
typedef struct NimStringDesc NimStringDesc;
typedef struct TGenericSeq TGenericSeq;
typedef struct Rstnode332011 Rstnode332011;
typedef struct Rstnodeseq332009 Rstnodeseq332009;
typedef struct Rstparser333587 Rstparser333587;
typedef struct TNimObject TNimObject;
typedef struct TNimType TNimType;
typedef struct TNimNode TNimNode;
typedef struct Tokenseq333143 Tokenseq333143;
typedef struct Sharedstate333583 Sharedstate333583;
typedef struct TY333608 TY333608;
typedef struct Token333141 Token333141;
typedef struct TY333597 TY333597;
typedef struct Substitution333581 Substitution333581;
typedef struct Cell48947 Cell48947;
typedef struct Cellseq48963 Cellseq48963;
typedef struct Gcheap51018 Gcheap51018;
typedef struct Gcstack51016 Gcstack51016;
typedef struct Cellset48959 Cellset48959;
typedef struct Pagedesc48955 Pagedesc48955;
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 Eparseerror333589 Eparseerror333589;
typedef struct Valueerror4049 Valueerror4049;
typedef struct Exception Exception;
typedef struct Lexer333145 Lexer333145;
typedef struct Keyvaluepair145208 Keyvaluepair145208;
typedef struct TY130408 TY130408;
typedef struct Basechunk30840 Basechunk30840;
typedef struct Freecell30832 Freecell30832;
struct  TGenericSeq  {
NI len;
NI reserved;
};
struct  NimStringDesc  {
  TGenericSeq Sup;
NIM_CHAR data[SEQ_DECL_SIZE];
};
struct  Rstnode332011  {
NU8 kind;
NimStringDesc* text;
NI level;
Rstnodeseq332009* sons;
};
typedef NU8 TY213407[32];
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 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  Rstparser333587  {
  TNimObject Sup;
NI idx;
Tokenseq333143* tok;
Sharedstate333583* s;
TY333608* indentstack;
NimStringDesc* filename;
NI line;
NI col;
NIM_BOOL hastoc;
};
struct  TNimNode  {
NU8 kind;
NI offset;
TNimType* typ;
NCSTRING name;
NI len;
TNimNode** sons;
};
struct  Token333141  {
NU8 kind;
NI ival;
NimStringDesc* symbol;
NI line;
NI col;
};
typedef NI Skiptable103393[256];
struct  Sharedstate333583  {
NU8 options;
NI ulevel;
NI olevel;
TY333597* subs;
TY333597* refs;
Skiptable103393 underlinetolevel;
Skiptable103393 overlinetolevel;
Msghandler333021 msghandler;
Findfilehandler333023 findfile;
};
struct  Substitution333581  {
NimStringDesc* key;
Rstnode332011* value;
};
struct  Cell48947  {
NI refcount;
TNimType* typ;
};
struct  Cellseq48963  {
NI len;
NI cap;
Cell48947** d;
};
struct  Cellset48959  {
NI counter;
NI max;
Pagedesc48955* head;
Pagedesc48955** 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;
Cellseq48963 zct;
Cellseq48963 decstack;
Cellset48959 cycleroots;
Cellseq48963 tempstack;
NI recgclock;
Memregion30890 region;
Gcstat51014 stat;
};
typedef NimStringDesc* TY333061[10];
typedef NimStringDesc* TY333816[5];
struct  Exception  {
  TNimObject Sup;
Exception* parent;
NCSTRING name;
NimStringDesc* message;
NimStringDesc* trace;
};
struct  Valueerror4049  {
  Exception Sup;
};
struct  Eparseerror333589  {
  Valueerror4049 Sup;
};
typedef NimStringDesc* TY192421[1];
struct  Lexer333145  {
  TNimObject Sup;
NCSTRING buf;
NI bufpos;
NI line;
NI col;
NI baseindent;
NIM_BOOL skippounds;
};
typedef NimStringDesc* TY336092[13];
typedef N_NIMCALL_PTR(Rstnode332011*, Sectionparser339212) (Rstparser333587* p);
struct Keyvaluepair145208 {
NimStringDesc* Field0;
NimStringDesc* Field1;
};
typedef Keyvaluepair145208 TY333099[34];
typedef NimStringDesc* TY338829[3];
typedef NI TY338834[3];
struct  Gcstack51016  {
Gcstack51016* prev;
Gcstack51016* next;
void* starts;
void* pos;
NI maxstacksize;
};
typedef NI TY30821[16];
struct  Pagedesc48955  {
Pagedesc48955* 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  Freecell30832  {
Freecell30832* next;
NI zerofield;
};
struct Tokenseq333143 {
  TGenericSeq Sup;
  Token333141 data[SEQ_DECL_SIZE];
};
struct TY333597 {
  TGenericSeq Sup;
  Substitution333581 data[SEQ_DECL_SIZE];
};
struct TY333608 {
  TGenericSeq Sup;
  NI data[SEQ_DECL_SIZE];
};
struct TY130408 {
  TGenericSeq Sup;
  NimStringDesc* data[SEQ_DECL_SIZE];
};
struct Rstnodeseq332009 {
  TGenericSeq Sup;
  Rstnode332011* data[SEQ_DECL_SIZE];
};
N_NIMCALL(NimStringDesc*, copyString)(NimStringDesc* src);
N_NIMCALL(void, rstnodetorefnameaux_334169)(Rstnode332011* n, NimStringDesc** r, NIM_BOOL* b);
N_NIMCALL(NimStringDesc*, addChar)(NimStringDesc* s, NIM_CHAR c);
N_NIMCALL(NI, len_332090)(Rstnode332011* n);
N_NIMCALL(void, addnodesaux_334108)(Rstnode332011* n, NimStringDesc** result);
static N_INLINE(void, appendString)(NimStringDesc* dest, NimStringDesc* src);
N_NIMCALL(NimStringDesc*, resizeString)(NimStringDesc* dest, NI addlen);
N_NIMCALL(NI, nsuCmpIgnoreStyle)(NimStringDesc* a, NimStringDesc* b);
N_NIMCALL(NimStringDesc*, addnodes_333073)(Rstnode332011* n);
N_NIMCALL(NimStringDesc*, nsuStrip)(NimStringDesc* s, NIM_BOOL leading, NIM_BOOL trailing, TY213407 chars);
N_NIMCALL(void, nimGCvisit)(void* d, NI op);
N_NIMCALL(void, TMP2556)(void* p, NI op);
N_NIMCALL(void, TMP2568)(void* p, NI op);
N_NIMCALL(void, TMP2569)(void* p, NI op);
N_NIMCALL(void, TMP2570)(void* p, NI op);
N_NIMCALL(void, initparser_334068)(Rstparser333587* p, Sharedstate333583* sharedstate);
N_NIMCALL(void, genericSeqAssign)(void* dest, void* src_85804, TNimType* mt);
N_NIMCALL(void*, newSeq)(TNimType* typ, NI len);
N_NIMCALL(void, unsureAsgnRef)(void** dest, void* src);
N_NIMCALL(Sharedstate333583*, newsharedstate_333877)(NU8 options, Findfilehandler333023 findfile, Msghandler333021 msghandler);
N_NIMCALL(void*, newObj)(TNimType* typ, NI size);
static N_INLINE(void, nimGCunrefNoCycle)(void* p);
static N_INLINE(Cell48947*, usrtocell_52646)(void* usr);
static N_INLINE(void, rtladdzct_54204)(Cell48947* c);
N_NOINLINE(void, addzct_52617)(Cellseq48963* s, Cell48947* c);
N_NIMCALL(void*, newSeqRC1)(TNimType* typ, NI len);
N_NIMCALL(void, defaultmsghandler_333807)(NimStringDesc* filename, NI line, NI col, NU8 msgkind, NimStringDesc* arg);
N_NIMCALL(NU8, whichmsgclass_333627)(NU8 k);
N_NIMCALL(NimStringDesc*, reprEnum)(NI e_86859, TNimType* typ);
N_NIMCALL(NimStringDesc*, nsuFormatSingleElem)(NimStringDesc* formatstr, NimStringDesc* a);
N_NIMCALL(NimStringDesc*, nsuFormatOpenArray)(NimStringDesc* formatstr, NimStringDesc** a, NI aLen0);
N_NIMCALL(NimStringDesc*, nimIntToStr)(NI x);
N_NIMCALL(void, TMP2590)(void* p, NI op);
N_NIMCALL(NimStringDesc*, copyStringRC1)(NimStringDesc* src);
N_NIMCALL(void, raiseException)(Exception* e, NCSTRING ename);
static N_INLINE(void, writeline_168405)(FILE* f, NimStringDesc** x, NI xLen0);
N_NIMCALL(void, write_16895)(FILE* f, NimStringDesc* s);
N_NIMCALL(NimStringDesc*, defaultfindfile_333867)(NimStringDesc* filename);
N_NIMCALL(NIM_BOOL, nosexistsFile)(NimStringDesc* filename);
N_NIMCALL(NI, gettokens_333429)(NimStringDesc* buffer, NIM_BOOL skippounds, Tokenseq333143** tokens);
N_NIMCALL(TGenericSeq*, setLengthSeq)(TGenericSeq* seq, NI elemsize, NI newlen);
N_NIMCALL(void, rawgettok_333382)(Lexer333145* L, Token333141* tok);
N_NIMCALL(void, getthing_333174)(Lexer333145* L, Token333141* tok, TY213407 s);
N_NIMCALL(void, getindent_333357)(Lexer333145* L, Token333141* tok);
N_NIMCALL(NI, getindentaux_333263)(Lexer333145* L, NI start);
N_NIMCALL(NimStringDesc*, nsuRepeatChar)(NIM_CHAR c, NI count);
N_NIMCALL(NimStringDesc*, rawNewString)(NI space);
N_NIMCALL(void, getadornment_333224)(Lexer333145* L, Token333141* tok);
N_NIMCALL(Rstnode332011*, resolvesubs_340250)(Rstparser333587* p, Rstnode332011* n);
N_NIMCALL(NI, findsub_334292)(Rstparser333587* p, Rstnode332011* n);
static N_INLINE(NIM_BOOL, eqStrings)(NimStringDesc* a, NimStringDesc* b);
N_NIMCALL(NimStringDesc*, getenv_131044)(NimStringDesc* key);
N_NIMCALL(Rstnode332011*, newrstnode_332142)(NU8 kind, NimStringDesc* s);
N_NIMCALL(void, rstmessage_333943)(Rstparser333587* p, NU8 msgkind, NimStringDesc* arg);
N_NIMCALL(Rstnode332011*, findref_334487)(Rstparser333587* p, NimStringDesc* key);
N_NIMCALL(NimStringDesc*, rstnodetorefname_333067)(Rstnode332011* n);
N_NIMCALL(Rstnode332011*, newrstnode_332108)(NU8 kind);
N_NIMCALL(void, add_332171)(Rstnode332011* father, Rstnode332011* son);
static N_INLINE(void, asgnRefNoCycle)(void** dest, void* src);
N_NIMCALL(Rstnode332011*, parsedoc_338069)(Rstparser333587* p);
N_NIMCALL(Rstnode332011*, parsesectionwrapper_339109)(Rstparser333587* p);
N_NIMCALL(void, parsesection_336217)(Rstparser333587* p, Rstnode332011* result);
N_NIMCALL(NI, currind_334001)(Rstparser333587* p);
N_NIMCALL(void, pushind_334011)(Rstparser333587* p, NI ind);
N_NIMCALL(TGenericSeq*, incrSeqV2)(TGenericSeq* seq, NI elemsize);
N_NIMCALL(void, popind_334032)(Rstparser333587* p);
N_NIMCALL(NU8, whichsection_337302)(Rstparser333587* p);
N_NIMCALL(NIM_BOOL, match_334727)(Rstparser333587* p, NI start, NimStringDesc* expr);
N_NIMCALL(NIM_BOOL, allcharsinset_103130)(NimStringDesc* s, TY213407 theset);
N_NIMCALL(NI, tokenafternewline_337205)(Rstparser333587* p);
N_NIMCALL(NIM_BOOL, prednl_337251)(Rstparser333587* p);
N_NIMCALL(NIM_BOOL, islineblock_337240)(Rstparser333587* p);
N_NIMCALL(void, rstmessage_333967)(Rstparser333587* p, NU8 msgkind);
N_NIMCALL(NIM_BOOL, isdeflist_337270)(Rstparser333587* p);
N_NIMCALL(NIM_BOOL, isoptionlist_337292)(Rstparser333587* p);
N_NIMCALL(Rstnode332011*, parseliteralblock_337099)(Rstparser333587* p);
N_NIMCALL(Rstnode332011*, parsebulletlist_338565)(Rstparser333587* p);
N_NIMCALL(Rstnode332011*, parselineblock_337321)(Rstparser333587* p);
N_NIMCALL(Rstnode332011*, parsedotdot_337092)(Rstparser333587* p);
N_NIMCALL(NimStringDesc*, getdirective_335866)(Rstparser333587* p);
N_NIMCALL(NU8, getdirkind_336098)(NimStringDesc* s);
static N_INLINE(NI, find_336103)(TY336092 a, NimStringDesc* item);
N_NIMCALL(Rstnode332011*, dirinclude_339405)(Rstparser333587* p);
N_NIMCALL(Rstnode332011*, parsedirective_339372)(Rstparser333587* p, NU8 flags, Sectionparser339212 contentparser);
N_NIMCALL(Rstnode332011*, parsedirective_339229)(Rstparser333587* p, NU8 flags);
N_NIMCALL(Rstnode332011*, newleaf_334529)(Rstparser333587* p);
N_NIMCALL(void, parseline_336181)(Rstparser333587* p, Rstnode332011* father);
N_NIMCALL(void, parseinline_335752)(Rstparser333587* p, Rstnode332011* father);
N_NIMCALL(NIM_BOOL, isinlinemarkupstart_334680)(Rstparser333587* p, NimStringDesc* markup);
N_NIMCALL(void, parseuntil_335601)(Rstparser333587* p, Rstnode332011* father, NimStringDesc* postfix, NIM_BOOL interpretbackslash);
N_NIMCALL(NIM_BOOL, isinlinemarkupend_334636)(Rstparser333587* p, NimStringDesc* markup);
N_NIMCALL(void, parsebackslash_335330)(Rstparser333587* p, Rstnode332011* father);
N_NIMCALL(void, rstmessage_333954)(Rstparser333587* p, NU8 msgkind, NimStringDesc* arg, NI line, NI col);
N_NIMCALL(Rstnode332011*, parsemarkdowncodeblock_335686)(Rstparser333587* p);
N_NIMCALL(Rstnode332011*, parsepostfix_334992)(Rstparser333587* p, Rstnode332011* n);
N_NIMCALL(void, fixupembeddedref_334889)(Rstnode332011* n, Rstnode332011* a, Rstnode332011* b);
N_NIMCALL(void, setref_334426)(Rstparser333587* p, NimStringDesc* key, Rstnode332011* value);
N_NIMCALL(Rstnode332011*, parsesmiley_335079)(Rstparser333587* p);
N_NIMCALL(NI, matchverbatim_335033)(Rstparser333587* p, NI start, NimStringDesc* expr);
N_NIMCALL(NIM_BOOL, nsuContinuesWith)(NimStringDesc* s, NimStringDesc* substr, NI start);
N_NIMCALL(void, parseurl_335281)(Rstparser333587* p, Rstnode332011* father);
N_NIMCALL(NIM_BOOL, isurl_335201)(Rstparser333587* p, NI i);
static N_INLINE(NIM_BOOL, contains_335219)(NimStringDesc** a, NI aLen0, NimStringDesc* item);
static N_INLINE(NI, find_335229)(NimStringDesc** a, NI aLen0, NimStringDesc* item);
N_NIMCALL(Rstnode332011*, parsefields_336258)(Rstparser333587* p);
N_NIMCALL(Rstnode332011*, parsefield_336225)(Rstparser333587* p);
N_NIMCALL(NIM_BOOL, indfollows_339353)(Rstparser333587* p);
N_NIMCALL(NimStringDesc*, getfieldvalue_333079)(Rstnode332011* n, NimStringDesc* fieldname);
N_NIMCALL(NimStringDesc*, readfile_16872)(NimStringDesc* filename);
N_NIMCALL(Rstnode332011*, dirimage_340007)(Rstparser333587* p);
N_NIMCALL(Rstnode332011*, dirfigure_340019)(Rstparser333587* p);
N_NIMCALL(Rstnode332011*, dirtitle_340031)(Rstparser333587* p);
N_NIMCALL(Rstnode332011*, dircontainer_339608)(Rstparser333587* p);
N_NIMCALL(Rstnode332011*, dircontents_340043)(Rstparser333587* p);
N_NIMCALL(Rstnode332011*, dirraw_340085)(Rstparser333587* p);
N_NIMCALL(NI, nsuCmpIgnoreCase)(NimStringDesc* a, NimStringDesc* b);
N_NIMCALL(void, dirrawaux_340068)(Rstparser333587* p, Rstnode332011** result, NU8 kind, Sectionparser339212 contentparser);
N_NIMCALL(Rstnode332011*, parsedirbody_339393)(Rstparser333587* p, Sectionparser339212 contentparser);
N_NIMCALL(Rstnode332011*, dircodeblock_339434)(Rstparser333587* p, NIM_BOOL nimrodextension);
N_NIMCALL(Rstnode332011*, dirindex_340055)(Rstparser333587* p);
N_NIMCALL(Rstnode332011*, getreferencename_334540)(Rstparser333587* p, NimStringDesc* endstr);
N_NIMCALL(Rstnode332011*, untileol_334578)(Rstparser333587* p);
N_NIMCALL(void, expect_334616)(Rstparser333587* p, NimStringDesc* tok);
N_NIMCALL(void, setsub_334365)(Rstparser333587* p, NimStringDesc* key, Rstnode332011* value);
N_NIMCALL(Rstnode332011*, parsecomment_335986)(Rstparser333587* p);
N_NIMCALL(Rstnode332011*, parseenumlist_338822)(Rstparser333587* p);
N_NIMCALL(Rstnode332011*, parsedefinitionlist_338734)(Rstparser333587* p);
N_NIMCALL(Rstnode332011*, parsetransition_338425)(Rstparser333587* p);
N_NIMCALL(Rstnode332011*, parseheadline_337449)(Rstparser333587* p);
N_NIMCALL(void, parseuntilnewline_336199)(Rstparser333587* p, Rstnode332011* father);
N_NIMCALL(NI, getlevel_337182)(NI* map, NI* lvl, NIM_CHAR c);
N_NIMCALL(Rstnode332011*, parseoverline_338481)(Rstparser333587* p);
N_NIMCALL(Rstnode332011*, parsesimpletable_338076)(Rstparser333587* p);
N_NIMCALL(void, getcolumns_337838)(Rstparser333587* p, TY333608** cols);
N_NIMCALL(NI, tokend_337828)(Rstparser333587* p);
N_NIMCALL(Rstnode332011*, parseoptionlist_338631)(Rstparser333587* p);
N_NIMCALL(void, parseparagraph_337386)(Rstparser333587* p, Rstnode332011* result);
N_NIMCALL(void, addifnotnil_332191)(Rstnode332011* father, Rstnode332011* son);
N_NIMCALL(NU8, sonkind_338906)(Rstnode332011* father, NI i);
STRING_LITERAL(TMP2205, "", 0);
STRING_LITERAL(TMP2295, "\001\001", 2);
static NIM_CONST TY213407 TMP2316 = {
0x00, 0x3E, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}
;
NIM_CONST struct {
  TGenericSeq Sup;
  NI data[1];
} CNSTSEQ2573 = {{1, 1}, {((NI) 0)}};
NIM_CONST TY333608* TMP2571 = ((TY333608*)&CNSTSEQ2573);
STRING_LITERAL(TMP2576, "cannot open \'$1\'", 16);
STRING_LITERAL(TMP2577, "\'$1\' expected", 13);
STRING_LITERAL(TMP2578, "grid table is not implemented", 29);
STRING_LITERAL(TMP2579, "new section expected", 20);
STRING_LITERAL(TMP2580, "general parse error", 19);
STRING_LITERAL(TMP2581, "invalid directive: \'$1\'", 23);
STRING_LITERAL(TMP2582, "redefinition of label \'$1\'", 26);
STRING_LITERAL(TMP2583, "unknown substitution \'$1\'", 25);
STRING_LITERAL(TMP2584, "language \'$1\' not supported", 27);
STRING_LITERAL(TMP2585, "field \'$1\' not supported", 24);
NIM_CONST TY333061 messages_333058 = {((NimStringDesc*) &TMP2576),
((NimStringDesc*) &TMP2577),
((NimStringDesc*) &TMP2578),
((NimStringDesc*) &TMP2579),
((NimStringDesc*) &TMP2580),
((NimStringDesc*) &TMP2581),
((NimStringDesc*) &TMP2582),
((NimStringDesc*) &TMP2583),
((NimStringDesc*) &TMP2584),
((NimStringDesc*) &TMP2585)}
;
STRING_LITERAL(TMP2586, "$1($2, $3) $4: $5", 17);
STRING_LITERAL(TMP2591, "\012", 1);
static NIM_CONST TY213407 TMP2593 = {
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xFF, 0x03,
0xFE, 0xFF, 0xFF, 0x07, 0xFE, 0xFF, 0xFF, 0x07,
0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF,
0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF}
;
static NIM_CONST TY213407 TMP2594 = {
0x00, 0x02, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}
;
STRING_LITERAL(TMP2595, "#", 1);
static NIM_CONST TY213407 TMP2596 = {
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xFF, 0x03,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}
;
STRING_LITERAL(TMP2597, "ii", 2);
STRING_LITERAL(TMP2598, " a", 2);
STRING_LITERAL(TMP2599, "i", 1);
STRING_LITERAL(TMP2600, "ai", 2);
STRING_LITERAL(TMP2601, "::", 2);
STRING_LITERAL(TMP2602, "+", 1);
STRING_LITERAL(TMP2603, "*", 1);
STRING_LITERAL(TMP2604, "-", 1);
STRING_LITERAL(TMP2605, "|", 1);
STRING_LITERAL(TMP2606, "..", 2);
STRING_LITERAL(TMP2607, ":w:", 3);
STRING_LITERAL(TMP2608, "(e) ", 4);
STRING_LITERAL(TMP2609, "+a+", 3);
STRING_LITERAL(TMP2610, "-w", 2);
STRING_LITERAL(TMP2611, "--w", 3);
STRING_LITERAL(TMP2612, "/w", 2);
STRING_LITERAL(TMP2613, "//w", 3);
STRING_LITERAL(TMP2614, "e) ", 3);
STRING_LITERAL(TMP2615, "e. ", 3);
STRING_LITERAL(TMP2616, "author", 6);
STRING_LITERAL(TMP2617, "authors", 7);
STRING_LITERAL(TMP2618, "code", 4);
STRING_LITERAL(TMP2619, "code-block", 10);
STRING_LITERAL(TMP2620, "container", 9);
STRING_LITERAL(TMP2621, "contents", 8);
STRING_LITERAL(TMP2622, "figure", 6);
STRING_LITERAL(TMP2623, "image", 5);
STRING_LITERAL(TMP2624, "include", 7);
STRING_LITERAL(TMP2625, "index", 5);
STRING_LITERAL(TMP2626, "raw", 3);
STRING_LITERAL(TMP2627, "title", 5);
NIM_CONST TY336092 Dirids_336090 = {((NimStringDesc*) &TMP2205),
((NimStringDesc*) &TMP2616),
((NimStringDesc*) &TMP2617),
((NimStringDesc*) &TMP2618),
((NimStringDesc*) &TMP2619),
((NimStringDesc*) &TMP2620),
((NimStringDesc*) &TMP2621),
((NimStringDesc*) &TMP2622),
((NimStringDesc*) &TMP2623),
((NimStringDesc*) &TMP2624),
((NimStringDesc*) &TMP2625),
((NimStringDesc*) &TMP2626),
((NimStringDesc*) &TMP2627)}
;
static NIM_CONST TY213407 TMP2628 = {
0x00, 0x00, 0x00, 0x00, 0x84, 0xA1, 0x00, 0x14,
0x00, 0x00, 0x00, 0x88, 0x00, 0x00, 0x00, 0x08,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}
;
STRING_LITERAL(TMP2629, "\\", 1);
STRING_LITERAL(TMP2630, "***", 3);
static NIM_CONST TY213407 TMP2631 = {
0x00, 0x00, 0x00, 0x00, 0x86, 0xF2, 0x00, 0xCC,
0x00, 0x00, 0x00, 0xB0, 0x00, 0x00, 0x00, 0x20,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}
;
STRING_LITERAL(TMP2632, "``", 2);
STRING_LITERAL(TMP2633, "\\\\", 2);
STRING_LITERAL(TMP2634, " ", 1);
STRING_LITERAL(TMP2635, "**", 2);
STRING_LITERAL(TMP2636, "```", 3);
STRING_LITERAL(TMP2637, "`", 1);
STRING_LITERAL(TMP2638, "_", 1);
STRING_LITERAL(TMP2639, "__", 2);
STRING_LITERAL(TMP2640, ">", 1);
STRING_LITERAL(TMP2641, "<", 1);
STRING_LITERAL(TMP2642, "idx", 3);
STRING_LITERAL(TMP2643, "literal", 7);
STRING_LITERAL(TMP2644, "strong", 6);
STRING_LITERAL(TMP2645, "emphasis", 8);
STRING_LITERAL(TMP2646, "sub", 3);
STRING_LITERAL(TMP2647, "subscript", 9);
STRING_LITERAL(TMP2648, "sup", 3);
STRING_LITERAL(TMP2649, "supscript", 9);
STRING_LITERAL(TMP2650, ":D", 2);
STRING_LITERAL(TMP2651, "icon_e_biggrin", 14);
STRING_LITERAL(TMP2652, ":-D", 3);
STRING_LITERAL(TMP2653, ":)", 2);
STRING_LITERAL(TMP2654, "icon_e_smile", 12);
STRING_LITERAL(TMP2655, ":-)", 3);
STRING_LITERAL(TMP2656, ";)", 2);
STRING_LITERAL(TMP2657, "icon_e_wink", 11);
STRING_LITERAL(TMP2658, ";-)", 3);
STRING_LITERAL(TMP2659, ":(", 2);
STRING_LITERAL(TMP2660, "icon_e_sad", 10);
STRING_LITERAL(TMP2661, ":-(", 3);
STRING_LITERAL(TMP2662, ":o", 2);
STRING_LITERAL(TMP2663, "icon_e_surprised", 16);
STRING_LITERAL(TMP2664, ":-o", 3);
STRING_LITERAL(TMP2665, ":shock:", 7);
STRING_LITERAL(TMP2666, "icon_eek", 8);
STRING_LITERAL(TMP2667, ":?", 2);
STRING_LITERAL(TMP2668, "icon_e_confused", 15);
STRING_LITERAL(TMP2669, ":-?", 3);
STRING_LITERAL(TMP2670, ":-/", 3);
STRING_LITERAL(TMP2671, "8-)", 3);
STRING_LITERAL(TMP2672, "icon_cool", 9);
STRING_LITERAL(TMP2673, ":lol:", 5);
STRING_LITERAL(TMP2674, "icon_lol", 8);
STRING_LITERAL(TMP2675, ":x", 2);
STRING_LITERAL(TMP2676, "icon_mad", 8);
STRING_LITERAL(TMP2677, ":-x", 3);
STRING_LITERAL(TMP2678, ":P", 2);
STRING_LITERAL(TMP2679, "icon_razz", 9);
STRING_LITERAL(TMP2680, ":-P", 3);
STRING_LITERAL(TMP2681, ":oops:", 6);
STRING_LITERAL(TMP2682, "icon_redface", 12);
STRING_LITERAL(TMP2683, ":cry:", 5);
STRING_LITERAL(TMP2684, "icon_cry", 8);
STRING_LITERAL(TMP2685, ":evil:", 6);
STRING_LITERAL(TMP2686, "icon_evil", 9);
STRING_LITERAL(TMP2687, ":twisted:", 9);
STRING_LITERAL(TMP2688, "icon_twisted", 12);
STRING_LITERAL(TMP2689, ":roll:", 6);
STRING_LITERAL(TMP2690, "icon_rolleyes", 13);
STRING_LITERAL(TMP2691, ":!:", 3);
STRING_LITERAL(TMP2692, "icon_exclaim", 12);
STRING_LITERAL(TMP2693, ":?:", 3);
STRING_LITERAL(TMP2694, "icon_question", 13);
STRING_LITERAL(TMP2695, ":idea:", 6);
STRING_LITERAL(TMP2696, "icon_idea", 9);
STRING_LITERAL(TMP2697, ":arrow:", 7);
STRING_LITERAL(TMP2698, "icon_arrow", 10);
STRING_LITERAL(TMP2699, ":|", 2);
STRING_LITERAL(TMP2700, "icon_neutral", 12);
STRING_LITERAL(TMP2701, ":-|", 3);
STRING_LITERAL(TMP2702, ":mrgreen:", 9);
STRING_LITERAL(TMP2703, "icon_mrgreen", 12);
STRING_LITERAL(TMP2704, ":geek:", 6);
STRING_LITERAL(TMP2705, "icon_e_geek", 11);
STRING_LITERAL(TMP2706, ":ugeek:", 7);
STRING_LITERAL(TMP2707, "icon_e_ugeek", 12);
NIM_CONST TY333099 Smilies_333098 = {{((NimStringDesc*) &TMP2650),
((NimStringDesc*) &TMP2651)}
,
{((NimStringDesc*) &TMP2652),
((NimStringDesc*) &TMP2651)}
,
{((NimStringDesc*) &TMP2653),
((NimStringDesc*) &TMP2654)}
,
{((NimStringDesc*) &TMP2655),
((NimStringDesc*) &TMP2654)}
,
{((NimStringDesc*) &TMP2656),
((NimStringDesc*) &TMP2657)}
,
{((NimStringDesc*) &TMP2658),
((NimStringDesc*) &TMP2657)}
,
{((NimStringDesc*) &TMP2659),
((NimStringDesc*) &TMP2660)}
,
{((NimStringDesc*) &TMP2661),
((NimStringDesc*) &TMP2660)}
,
{((NimStringDesc*) &TMP2662),
((NimStringDesc*) &TMP2663)}
,
{((NimStringDesc*) &TMP2664),
((NimStringDesc*) &TMP2663)}
,
{((NimStringDesc*) &TMP2665),
((NimStringDesc*) &TMP2666)}
,
{((NimStringDesc*) &TMP2667),
((NimStringDesc*) &TMP2668)}
,
{((NimStringDesc*) &TMP2669),
((NimStringDesc*) &TMP2668)}
,
{((NimStringDesc*) &TMP2670),
((NimStringDesc*) &TMP2668)}
,
{((NimStringDesc*) &TMP2671),
((NimStringDesc*) &TMP2672)}
,
{((NimStringDesc*) &TMP2673),
((NimStringDesc*) &TMP2674)}
,
{((NimStringDesc*) &TMP2675),
((NimStringDesc*) &TMP2676)}
,
{((NimStringDesc*) &TMP2677),
((NimStringDesc*) &TMP2676)}
,
{((NimStringDesc*) &TMP2678),
((NimStringDesc*) &TMP2679)}
,
{((NimStringDesc*) &TMP2680),
((NimStringDesc*) &TMP2679)}
,
{((NimStringDesc*) &TMP2681),
((NimStringDesc*) &TMP2682)}
,
{((NimStringDesc*) &TMP2683),
((NimStringDesc*) &TMP2684)}
,
{((NimStringDesc*) &TMP2685),
((NimStringDesc*) &TMP2686)}
,
{((NimStringDesc*) &TMP2687),
((NimStringDesc*) &TMP2688)}
,
{((NimStringDesc*) &TMP2689),
((NimStringDesc*) &TMP2690)}
,
{((NimStringDesc*) &TMP2691),
((NimStringDesc*) &TMP2692)}
,
{((NimStringDesc*) &TMP2693),
((NimStringDesc*) &TMP2694)}
,
{((NimStringDesc*) &TMP2695),
((NimStringDesc*) &TMP2696)}
,
{((NimStringDesc*) &TMP2697),
((NimStringDesc*) &TMP2698)}
,
{((NimStringDesc*) &TMP2699),
((NimStringDesc*) &TMP2700)}
,
{((NimStringDesc*) &TMP2701),
((NimStringDesc*) &TMP2700)}
,
{((NimStringDesc*) &TMP2702),
((NimStringDesc*) &TMP2703)}
,
{((NimStringDesc*) &TMP2704),
((NimStringDesc*) &TMP2705)}
,
{((NimStringDesc*) &TMP2706),
((NimStringDesc*) &TMP2707)}
}
;
STRING_LITERAL(TMP2708, ":", 1);
STRING_LITERAL(TMP2709, "//", 2);
STRING_LITERAL(TMP2711, "http", 4);
STRING_LITERAL(TMP2712, "https", 5);
STRING_LITERAL(TMP2713, "ftp", 3);
STRING_LITERAL(TMP2714, "telnet", 6);
STRING_LITERAL(TMP2715, "file", 4);
NIM_CONST TY333816 TMP2710 = {((NimStringDesc*) &TMP2711),
((NimStringDesc*) &TMP2712),
((NimStringDesc*) &TMP2713),
((NimStringDesc*) &TMP2714),
((NimStringDesc*) &TMP2715)}
;
STRING_LITERAL(TMP2716, "html", 4);
STRING_LITERAL(TMP2717, "latex", 5);
STRING_LITERAL(TMP2718, "default-language", 16);
STRING_LITERAL(TMP2719, "Nimrod", 6);
STRING_LITERAL(TMP2720, " _", 2);
STRING_LITERAL(TMP2721, " |", 2);
STRING_LITERAL(TMP2722, "replace", 7);
STRING_LITERAL(TMP2723, " [", 2);
STRING_LITERAL(TMP2724, "]", 1);
NIM_CONST TY338829 wildcards_338827 = {((NimStringDesc*) &TMP2608),
((NimStringDesc*) &TMP2614),
((NimStringDesc*) &TMP2615)}
;
NIM_CONST TY338834 wildpos_338832 = {((NI) 1),
((NI) 0),
((NI) 0)}
;
extern TNimType NTI4011; /* RootObj */
TNimType NTI333587; /* RstParser */
extern TNimType NTI108; /* int */
TNimType NTI333141; /* Token */
TNimType NTI333139; /* TokType */
extern TNimType NTI149; /* string */
TNimType NTI333143; /* TokenSeq */
TNimType NTI333583; /* SharedState */
TNimType NTI333013; /* RstParseOption */
TNimType NTI333015; /* RstParseOptions */
TNimType NTI333581; /* Substitution */
extern TNimType NTI332007; /* PRstNode */
TNimType NTI333597; /* seq[Substitution] */
extern TNimType NTI103393; /* SkipTable */
TNimType NTI333021; /* MsgHandler */
TNimType NTI333023; /* FindFileHandler */
TNimType NTI333585; /* PSharedState */
TNimType NTI333608; /* seq[int] */
extern TNimType NTI138; /* bool */
extern Gcheap51018 gch_51059;
TNimType NTI333019; /* MsgKind */
TNimType NTI333017; /* MsgClass */
extern TNimType NTI4049; /* ValueError */
TNimType NTI333589; /* EParseError */
TNimType NTI333839; /* ref EParseError */
TNimType NTI333145; /* Lexer */
extern TNimType NTI151; /* cstring */
extern TNimType NTI130408; /* seq[string] */

N_NIMCALL(void, rstnodetorefnameaux_334169)(Rstnode332011* n, NimStringDesc** r, NIM_BOOL* b) {
	{
		if (!((*n).kind == ((NU8) 64))) goto LA3;
		{
			NI i_334197;
			NI HEX3Atmp_334240;
			NI res_334243;
			i_334197 = 0;
			HEX3Atmp_334240 = 0;
			HEX3Atmp_334240 = (NI)(((*n).text ? (*n).text->Sup.len : 0) - ((NI) 1));
			res_334243 = ((NI) 0);
			{
				while (1) {
					if (!(res_334243 <= HEX3Atmp_334240)) goto LA7;
					i_334197 = res_334243;
					switch (((NU8)((*n).text->data[i_334197]))) {
					case 48 ... 57:
					{
						{
							if (!(*b)) goto LA11;
							(*r) = addChar((*r), 45);
							(*b) = NIM_FALSE;
						}
						LA11: ;
						{
							if (!(((*r) ? (*r)->Sup.len : 0) == ((NI) 0))) goto LA15;
							(*r) = addChar((*r), 90);
						}
						LA15: ;
						(*r) = addChar((*r), (*n).text->data[i_334197]);
					}
					break;
					case 97 ... 122:
					{
						{
							if (!(*b)) goto LA20;
							(*r) = addChar((*r), 45);
							(*b) = NIM_FALSE;
						}
						LA20: ;
						(*r) = addChar((*r), (*n).text->data[i_334197]);
					}
					break;
					case 65 ... 90:
					{
						{
							if (!(*b)) goto LA25;
							(*r) = addChar((*r), 45);
							(*b) = NIM_FALSE;
						}
						LA25: ;
						(*r) = addChar((*r), ((NIM_CHAR) (((NI) ((NI)(((NI) ((NI)(((NI) (((NU8)((*n).text->data[i_334197])))) - ((NI) 65)))) + ((NI) 97)))))));
					}
					break;
					default:
					{
						{
							if (!(((NI) 0) < ((*r) ? (*r)->Sup.len : 0))) goto LA30;
							(*b) = NIM_TRUE;
						}
						LA30: ;
					}
					break;
					}
					res_334243 += ((NI) 1);
				} LA7: ;
			}
		}
	}
	goto LA1;
	LA3: ;
	{
		{
			NI i_334238;
			NI HEX3Atmp_334248;
			NI LOC34;
			NI res_334251;
			i_334238 = 0;
			HEX3Atmp_334248 = 0;
			LOC34 = 0;
			LOC34 = len_332090(n);
			HEX3Atmp_334248 = (NI)(LOC34 - ((NI) 1));
			res_334251 = ((NI) 0);
			{
				while (1) {
					if (!(res_334251 <= HEX3Atmp_334248)) goto LA36;
					i_334238 = res_334251;
					rstnodetorefnameaux_334169((*n).sons->data[i_334238], r, b);
					res_334251 += ((NI) 1);
				} LA36: ;
			}
		}
	}
	LA1: ;
}

N_NIMCALL(NimStringDesc*, rstnodetorefname_333067)(Rstnode332011* n) {
	NimStringDesc* result;
	NIM_BOOL b;
	result = 0;
	result = copyString(((NimStringDesc*) &TMP2205));
	b = NIM_FALSE;
	rstnodetorefnameaux_334169(n, (&result), (&b));
	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(void, addnodesaux_334108)(Rstnode332011* n, NimStringDesc** result) {
	{
		if (!((*n).kind == ((NU8) 64))) goto LA3;
		(*result) = resizeString((*result), (*n).text->Sup.len + 0);
appendString((*result), (*n).text);
	}
	goto LA1;
	LA3: ;
	{
		{
			NI i_334134;
			NI HEX3Atmp_334136;
			NI LOC7;
			NI res_334139;
			i_334134 = 0;
			HEX3Atmp_334136 = 0;
			LOC7 = 0;
			LOC7 = len_332090(n);
			HEX3Atmp_334136 = (NI)(LOC7 - ((NI) 1));
			res_334139 = ((NI) 0);
			{
				while (1) {
					if (!(res_334139 <= HEX3Atmp_334136)) goto LA9;
					i_334134 = res_334139;
					addnodesaux_334108((*n).sons->data[i_334134], result);
					res_334139 += ((NI) 1);
				} LA9: ;
			}
		}
	}
	LA1: ;
}

N_NIMCALL(NimStringDesc*, addnodes_333073)(Rstnode332011* n) {
	NimStringDesc* result;
	result = 0;
	result = copyString(((NimStringDesc*) &TMP2205));
	addnodesaux_334108(n, (&result));
	return result;
}

N_NIMCALL(NimStringDesc*, getfieldvalue_333079)(Rstnode332011* n, NimStringDesc* fieldname) {
	NimStringDesc* result;
{	result = 0;
	result = copyString(((NimStringDesc*) &TMP2205));
	{
		if (!((*n).sons->data[((NI) 1)] == NIM_NIL)) goto LA3;
		goto BeforeRet;
	}
	LA3: ;
	{
		if (!!(((*(*n).sons->data[((NI) 1)]).kind == ((NU8) 13)))) goto LA7;
		goto BeforeRet;
	}
	LA7: ;
	{
		NI i_337045;
		NI HEX3Atmp_337048;
		NI LOC10;
		NI res_337051;
		i_337045 = 0;
		HEX3Atmp_337048 = 0;
		LOC10 = 0;
		LOC10 = len_332090((*n).sons->data[((NI) 1)]);
		HEX3Atmp_337048 = (NI)(LOC10 - ((NI) 1));
		res_337051 = ((NI) 0);
		{
			while (1) {
				Rstnode332011* f;
				if (!(res_337051 <= HEX3Atmp_337048)) goto LA12;
				i_337045 = res_337051;
				f = (*(*n).sons->data[((NI) 1)]).sons->data[i_337045];
				{
					NimStringDesc* LOC15;
					NI LOC16;
					LOC15 = 0;
					LOC15 = addnodes_333073((*f).sons->data[((NI) 0)]);
					LOC16 = 0;
					LOC16 = nsuCmpIgnoreStyle(LOC15, fieldname);
					if (!(LOC16 == ((NI) 0))) goto LA17;
					result = addnodes_333073((*f).sons->data[((NI) 1)]);
					{
						if (!((result) && (result)->Sup.len == 0)) goto LA21;
						result = copyString(((NimStringDesc*) &TMP2295));
					}
					LA21: ;
					goto BeforeRet;
				}
				LA17: ;
				res_337051 += ((NI) 1);
			} LA12: ;
		}
	}
	}BeforeRet: ;
	return result;
}

N_NIMCALL(NimStringDesc*, getargument_333086)(Rstnode332011* n) {
	NimStringDesc* result;
	result = 0;
	{
		if (!((*n).sons->data[((NI) 0)] == NIM_NIL)) goto LA3;
		result = copyString(((NimStringDesc*) &TMP2205));
	}
	goto LA1;
	LA3: ;
	{
		result = addnodes_333073((*n).sons->data[((NI) 0)]);
	}
	LA1: ;
	return result;
}

N_NIMCALL(NimStringDesc*, getfieldvalue_336314)(Rstnode332011* n) {
	NimStringDesc* result;
	NimStringDesc* LOC1;
	result = 0;
	LOC1 = 0;
	LOC1 = addnodes_333073((*n).sons->data[((NI) 1)]);
	result = nsuStrip(LOC1, NIM_TRUE, NIM_TRUE, TMP2316);
	return result;
}
N_NIMCALL(void, TMP2556)(void* p, NI op) {
	Tokenseq333143* a;
	NI LOC1;
	a = (Tokenseq333143*)p;
	LOC1 = 0;
	for (LOC1 = 0; LOC1 < a->Sup.len; LOC1++) {
	nimGCvisit((void*)a->data[LOC1].symbol, op);
	}
}
N_NIMCALL(void, TMP2568)(void* p, NI op) {
	TY333597* a;
	NI LOC1;
	a = (TY333597*)p;
	LOC1 = 0;
	for (LOC1 = 0; LOC1 < a->Sup.len; LOC1++) {
	nimGCvisit((void*)a->data[LOC1].key, op);
	nimGCvisit((void*)a->data[LOC1].value, op);
	}
}
N_NIMCALL(void, TMP2569)(void* p, NI op) {
	Sharedstate333583* a;
	NI LOC1;
	NI LOC2;
	a = (Sharedstate333583*)p;
	nimGCvisit((void*)(*a).subs, op);
	nimGCvisit((void*)(*a).refs, op);
	LOC1 = 0;
	for (LOC1 = 0; LOC1 < 256; LOC1++) {
	}
	LOC2 = 0;
	for (LOC2 = 0; LOC2 < 256; LOC2++) {
	}
}
N_NIMCALL(void, TMP2570)(void* p, NI op) {
	TY333608* a;
	NI LOC1;
	a = (TY333608*)p;
	LOC1 = 0;
	for (LOC1 = 0; LOC1 < a->Sup.len; LOC1++) {
	}
}

N_NIMCALL(void, initparser_334068)(Rstparser333587* p, Sharedstate333583* sharedstate) {
	genericSeqAssign((&(*p).indentstack), TMP2571, (&NTI333608));
	unsureAsgnRef((void**) (&(*p).tok), (Tokenseq333143*) newSeq((&NTI333143), 0));
	(*p).idx = ((NI) 0);
	unsureAsgnRef((void**) (&(*p).filename), copyString(((NimStringDesc*) &TMP2205)));
	(*p).hastoc = NIM_FALSE;
	(*p).col = ((NI) 0);
	(*p).line = ((NI) 1);
	unsureAsgnRef((void**) (&(*p).s), sharedstate);
}

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

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

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

N_NIMCALL(NU8, whichmsgclass_333627)(NU8 k) {
	NU8 result;
	result = 0;
	switch (((NU8)(reprEnum(k, (&NTI333019))->data[((NI) 1)]))) {
	case 101:
	case 69:
	{
		result = ((NU8) 2);
	}
	break;
	case 119:
	case 87:
	{
		result = ((NU8) 1);
	}
	break;
	case 104:
	case 72:
	{
		result = ((NU8) 0);
	}
	break;
	default:
	{
	}
	break;
	}
	return result;
}
N_NIMCALL(void, TMP2590)(void* p, NI op) {
	Eparseerror333589* a;
	a = (Eparseerror333589*)p;
	nimGCvisit((void*)(*a).Sup.Sup.parent, op);
	nimGCvisit((void*)(*a).Sup.Sup.message, op);
	nimGCvisit((void*)(*a).Sup.Sup.trace, op);
}

static N_INLINE(void, writeline_168405)(FILE* f, NimStringDesc** x, NI xLen0) {
	{
		NimStringDesc* i_168421;
		NI i_168429;
		i_168421 = 0;
		i_168429 = ((NI) 0);
		{
			while (1) {
				if (!(i_168429 < xLen0)) goto LA3;
				i_168421 = x[i_168429];
				write_16895(f, i_168421);
				i_168429 += ((NI) 1);
			} LA3: ;
		}
	}
	write_16895(f, ((NimStringDesc*) &TMP2591));
}

N_NIMCALL(void, defaultmsghandler_333807)(NimStringDesc* filename, NI line, NI col, NU8 msgkind, NimStringDesc* arg) {
	NU8 mc;
	NimStringDesc* a;
	NimStringDesc* message;
	TY333816 LOC1;
	mc = whichmsgclass_333627(msgkind);
	a = nsuFormatSingleElem(messages_333058[(msgkind)- 0], arg);
	memset((void*)LOC1, 0, sizeof(LOC1));
	LOC1[0] = copyString(filename);
	LOC1[1] = nimIntToStr(line);
	LOC1[2] = nimIntToStr(col);
	LOC1[3] = copyString(reprEnum(mc, (&NTI333017)));
	LOC1[4] = copyString(a);
	message = nsuFormatOpenArray(((NimStringDesc*) &TMP2586), LOC1, 5);
	{
		Eparseerror333589* e_333838;
		NimStringDesc* LOC6;
		if (!(mc == ((NU8) 2))) goto LA4;
		e_333838 = 0;
		e_333838 = (Eparseerror333589*) newObj((&NTI333839), sizeof(Eparseerror333589));
		(*e_333838).Sup.Sup.Sup.m_type = (&NTI333589);
		LOC6 = 0;
		LOC6 = (*e_333838).Sup.Sup.message; (*e_333838).Sup.Sup.message = copyStringRC1(message);
		if (LOC6) nimGCunrefNoCycle(LOC6);
		raiseException((Exception*)e_333838, "EParseError");
	}
	goto LA2;
	LA4: ;
	{
		TY192421 LOC8;
		memset((void*)LOC8, 0, sizeof(LOC8));
		LOC8[0] = copyString(message);
		writeline_168405(stdout, LOC8, 1);
	}
	LA2: ;
}

N_NIMCALL(NimStringDesc*, defaultfindfile_333867)(NimStringDesc* filename) {
	NimStringDesc* result;
	result = 0;
	{
		NIM_BOOL LOC3;
		LOC3 = 0;
		LOC3 = nosexistsFile(filename);
		if (!LOC3) goto LA4;
		result = copyString(filename);
	}
	goto LA1;
	LA4: ;
	{
		result = copyString(((NimStringDesc*) &TMP2205));
	}
	LA1: ;
	return result;
}

N_NIMCALL(Sharedstate333583*, newsharedstate_333877)(NU8 options, Findfilehandler333023 findfile, Msghandler333021 msghandler) {
	Sharedstate333583* result;
	result = 0;
	result = (Sharedstate333583*) newObj((&NTI333585), sizeof(Sharedstate333583));
	if ((*result).subs) nimGCunrefNoCycle((*result).subs);
	(*result).subs = (TY333597*) newSeqRC1((&NTI333597), 0);
	if ((*result).refs) nimGCunrefNoCycle((*result).refs);
	(*result).refs = (TY333597*) newSeqRC1((&NTI333597), 0);
	(*result).options = options;
	{
		if (!!(msghandler == 0)) goto LA3;
		(*result).msghandler = msghandler;
	}
	goto LA1;
	LA3: ;
	{
		(*result).msghandler = defaultmsghandler_333807;
	}
	LA1: ;
	{
		if (!!(findfile == 0)) goto LA8;
		(*result).findfile = findfile;
	}
	goto LA6;
	LA8: ;
	{
		(*result).findfile = defaultfindfile_333867;
	}
	LA6: ;
	return result;
}

N_NIMCALL(void, getthing_333174)(Lexer333145* L, Token333141* tok, TY213407 s) {
	NI pos;
	(*tok).kind = ((NU8) 3);
	(*tok).line = (*L).line;
	(*tok).col = (*L).col;
	pos = (*L).bufpos;
	{
		while (1) {
			(*tok).symbol = addChar((*tok).symbol, (*L).buf[pos]);
			pos += ((NI) 1);
			{
				if (!!(((s[((NU8)((*L).buf[pos]))/8] &(1<<(((NU8)((*L).buf[pos]))%8)))!=0))) goto LA5;
				goto LA1;
			}
			LA5: ;
		}
	} LA1: ;
	(*L).col += (NI)(pos - (*L).bufpos);
	(*L).bufpos = pos;
}

N_NIMCALL(NI, getindentaux_333263)(Lexer333145* L, NI start) {
	NI result;
	NI pos;
	NCSTRING buf;
	result = 0;
	pos = start;
	buf = (*L).buf;
	{
		if (!((NU8)(buf[pos]) == (NU8)(13))) goto LA3;
		{
			if (!((NU8)(buf[(NI)(pos + ((NI) 1))]) == (NU8)(10))) goto LA7;
			pos += ((NI) 2);
		}
		goto LA5;
		LA7: ;
		{
			pos += ((NI) 1);
		}
		LA5: ;
	}
	goto LA1;
	LA3: ;
	{
		if (!((NU8)(buf[pos]) == (NU8)(10))) goto LA11;
		pos += ((NI) 1);
	}
	goto LA1;
	LA11: ;
	LA1: ;
	{
		if (!(*L).skippounds) goto LA15;
		{
			if (!((NU8)(buf[pos]) == (NU8)(35))) goto LA19;
			pos += ((NI) 1);
		}
		LA19: ;
		{
			if (!((NU8)(buf[pos]) == (NU8)(35))) goto LA23;
			pos += ((NI) 1);
		}
		LA23: ;
	}
	LA15: ;
	{
		while (1) {
			switch (((NU8)(buf[pos]))) {
			case 32:
			case 11:
			case 12:
			{
				pos += ((NI) 1);
				result += ((NI) 1);
			}
			break;
			case 9:
			{
				pos += ((NI) 1);
				result = (NI)((NI)(result - ((NI) ((NI)(result % ((NI) 8))))) + ((NI) 8));
			}
			break;
			default:
			{
				goto LA25;
			}
			break;
			}
		}
	} LA25: ;
	{
		if (!((NU8)(buf[pos]) == (NU8)(0))) goto LA32;
		result = ((NI) 0);
	}
	goto LA30;
	LA32: ;
	{
		NIM_BOOL LOC35;
		LOC35 = 0;
		LOC35 = ((NU8)(buf[pos]) == (NU8)(10));
		if (LOC35) goto LA36;
		LOC35 = ((NU8)(buf[pos]) == (NU8)(13));
		LA36: ;
		if (!LOC35) goto LA37;
		result = getindentaux_333263(L, pos);
	}
	goto LA30;
	LA37: ;
	LA30: ;
	(*L).bufpos = pos;
	return result;
}

N_NIMCALL(void, getindent_333357)(Lexer333145* L, Token333141* tok) {
	NimStringDesc* LOC1;
	NimStringDesc* LOC2;
	(*tok).col = ((NI) 0);
	(*tok).kind = ((NU8) 1);
	(*tok).ival = getindentaux_333263(L, (*L).bufpos);
	(*L).line += ((NI) 1);
	(*tok).line = (*L).line;
	(*L).col = (*tok).ival;
	(*tok).ival = (((NI)((*tok).ival - (*L).baseindent) >= ((NI) 0)) ? (NI)((*tok).ival - (*L).baseindent) : ((NI) 0));
	LOC1 = 0;
	LOC2 = 0;
	LOC2 = nsuRepeatChar(32, ((NI) ((*tok).ival)));
	LOC1 = rawNewString(LOC2->Sup.len + 1);
appendString(LOC1, ((NimStringDesc*) &TMP2591));
appendString(LOC1, LOC2);
	unsureAsgnRef((void**) (&(*tok).symbol), LOC1);
}

N_NIMCALL(void, getadornment_333224)(Lexer333145* L, Token333141* tok) {
	NI pos;
	NIM_CHAR c;
	(*tok).kind = ((NU8) 4);
	(*tok).line = (*L).line;
	(*tok).col = (*L).col;
	pos = (*L).bufpos;
	c = (*L).buf[pos];
	{
		while (1) {
			(*tok).symbol = addChar((*tok).symbol, (*L).buf[pos]);
			pos += ((NI) 1);
			{
				if (!!(((NU8)((*L).buf[pos]) == (NU8)(c)))) goto LA5;
				goto LA1;
			}
			LA5: ;
		}
	} LA1: ;
	(*L).col += (NI)(pos - (*L).bufpos);
	(*L).bufpos = pos;
}

N_NIMCALL(void, rawgettok_333382)(Lexer333145* L, Token333141* tok) {
	NIM_CHAR c;
	unsureAsgnRef((void**) (&(*tok).symbol), copyString(((NimStringDesc*) &TMP2205)));
	(*tok).ival = ((NI) 0);
	c = (*L).buf[(*L).bufpos];
	switch (((NU8)(c))) {
	case 97 ... 122:
	case 65 ... 90:
	case 128 ... 255:
	case 48 ... 57:
	{
		getthing_333174(L, tok, TMP2593);
	}
	break;
	case 32:
	case 9:
	case 11:
	case 12:
	{
		getthing_333174(L, tok, TMP2594);
		(*tok).kind = ((NU8) 2);
		{
			if (!(((NU8)((*L).buf[(*L).bufpos])) == ((NU8)(13)) || ((NU8)((*L).buf[(*L).bufpos])) == ((NU8)(10)))) goto LA5;
			rawgettok_333382(L, tok);
		}
		LA5: ;
	}
	break;
	case 13:
	case 10:
	{
		getindent_333357(L, tok);
	}
	break;
	case 33:
	case 34:
	case 35:
	case 36:
	case 37:
	case 38:
	case 39:
	case 40:
	case 41:
	case 42:
	case 43:
	case 44:
	case 45:
	case 46:
	case 47:
	case 58:
	case 59:
	case 60:
	case 61:
	case 62:
	case 63:
	case 64:
	case 91:
	case 92:
	case 93:
	case 94:
	case 95:
	case 96:
	case 123:
	case 124:
	case 125:
	case 126:
	{
		getadornment_333224(L, tok);
		{
			if (!(((*tok).symbol ? (*tok).symbol->Sup.len : 0) <= ((NI) 3))) goto LA11;
			(*tok).kind = ((NU8) 5);
		}
		LA11: ;
	}
	break;
	default:
	{
		(*tok).line = (*L).line;
		(*tok).col = (*L).col;
		{
			if (!((NU8)(c) == (NU8)(0))) goto LA16;
			(*tok).kind = ((NU8) 0);
		}
		goto LA14;
		LA16: ;
		{
			(*tok).kind = ((NU8) 6);
			(*tok).symbol = addChar((*tok).symbol, c);
			(*L).bufpos += ((NI) 1);
			(*L).col += ((NI) 1);
		}
		LA14: ;
	}
	break;
	}
	(*tok).col = (((NI)((*tok).col - (*L).baseindent) >= ((NI) 0)) ? (NI)((*tok).col - (*L).baseindent) : ((NI) 0));
}

N_NIMCALL(NI, gettokens_333429)(NimStringDesc* buffer, NIM_BOOL skippounds, Tokenseq333143** tokens) {
	NI result;
	Lexer333145 L;
	NI length;
	result = 0;
	memset((void*)(&L), 0, sizeof(L));
	L.Sup.m_type = (&NTI333145);
	length = ((*tokens) ? (*tokens)->Sup.len : 0);
	L.buf = buffer->data;
	L.line = ((NI) 0);
	{
		NIM_BOOL LOC3;
		NIM_BOOL LOC4;
		LOC3 = 0;
		LOC4 = 0;
		LOC4 = ((NU8)(L.buf[((NI) 0)]) == (NU8)(239));
		if (!(LOC4)) goto LA5;
		LOC4 = ((NU8)(L.buf[((NI) 1)]) == (NU8)(187));
		LA5: ;
		LOC3 = LOC4;
		if (!(LOC3)) goto LA6;
		LOC3 = ((NU8)(L.buf[((NI) 2)]) == (NU8)(191));
		LA6: ;
		if (!LOC3) goto LA7;
		L.bufpos += ((NI) 3);
	}
	LA7: ;
	L.skippounds = skippounds;
	{
		if (!skippounds) goto LA11;
		{
			if (!((NU8)(L.buf[L.bufpos]) == (NU8)(35))) goto LA15;
			L.bufpos += ((NI) 1);
			result += ((NI) 1);
		}
		LA15: ;
		{
			if (!((NU8)(L.buf[L.bufpos]) == (NU8)(35))) goto LA19;
			L.bufpos += ((NI) 1);
			result += ((NI) 1);
		}
		LA19: ;
		L.baseindent = ((NI) 0);
		{
			while (1) {
				if (!((NU8)(L.buf[L.bufpos]) == (NU8)(32))) goto LA22;
				L.bufpos += ((NI) 1);
				L.baseindent += ((NI) 1);
				result += ((NI) 1);
			} LA22: ;
		}
	}
	LA11: ;
	{
		while (1) {
			length += ((NI) 1);
			(*tokens) = (Tokenseq333143*) setLengthSeq(&((*tokens))->Sup, sizeof(Token333141), ((NI) (length)));
			rawgettok_333382((&L), (&(*tokens)->data[(NI)(length - ((NI) 1))]));
			{
				if (!((*tokens)->data[(NI)(length - ((NI) 1))].kind == ((NU8) 0))) goto LA27;
				goto LA23;
			}
			LA27: ;
		}
	} LA23: ;
	{
		if (!((*tokens)->data[((NI) 0)].kind == ((NU8) 2))) goto LA31;
		(*tokens)->data[((NI) 0)].ival = ((*tokens)->data[((NI) 0)].symbol ? (*tokens)->data[((NI) 0)].symbol->Sup.len : 0);
		(*tokens)->data[((NI) 0)].kind = ((NU8) 1);
	}
	LA31: ;
	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)), (*a).Sup.len);
	LOC11 = (LOC13 == ((NI32) 0));
	LA12: ;
	result = LOC11;
	goto BeforeRet;
	}BeforeRet: ;
	return result;
}

N_NIMCALL(NI, findsub_334292)(Rstparser333587* p, Rstnode332011* n) {
	NI result;
	NimStringDesc* key;
{	result = 0;
	key = addnodes_333073(n);
	{
		NI i_334311;
		NI HEX3Atmp_334326;
		NI res_334329;
		i_334311 = 0;
		HEX3Atmp_334326 = 0;
		HEX3Atmp_334326 = ((*(*p).s).subs ? ((*(*p).s).subs->Sup.len-1) : -1);
		res_334329 = ((NI) 0);
		{
			while (1) {
				if (!(res_334329 <= HEX3Atmp_334326)) goto LA3;
				i_334311 = res_334329;
				{
					if (!eqStrings(key, (*(*p).s).subs->data[i_334311].key)) goto LA6;
					result = i_334311;
					goto BeforeRet;
				}
				LA6: ;
				res_334329 += ((NI) 1);
			} LA3: ;
		}
	}
	{
		NI i_334324;
		NI HEX3Atmp_334334;
		NI res_334337;
		i_334324 = 0;
		HEX3Atmp_334334 = 0;
		HEX3Atmp_334334 = ((*(*p).s).subs ? ((*(*p).s).subs->Sup.len-1) : -1);
		res_334337 = ((NI) 0);
		{
			while (1) {
				if (!(res_334337 <= HEX3Atmp_334334)) goto LA10;
				i_334324 = res_334337;
				{
					NI LOC13;
					LOC13 = 0;
					LOC13 = nsuCmpIgnoreStyle(key, (*(*p).s).subs->data[i_334324].key);
					if (!(LOC13 == ((NI) 0))) goto LA14;
					result = i_334324;
					goto BeforeRet;
				}
				LA14: ;
				res_334337 += ((NI) 1);
			} LA10: ;
		}
	}
	result = ((NI) -1);
	}BeforeRet: ;
	return result;
}

N_NIMCALL(void, rstmessage_333943)(Rstparser333587* p, NU8 msgkind, NimStringDesc* arg) {
	(*(*p).s).msghandler((*p).filename, (NI)((*p).line + (*p).tok->data[(*p).idx].line), (NI)((*p).col + (*p).tok->data[(*p).idx].col), msgkind, arg);
}

N_NIMCALL(Rstnode332011*, findref_334487)(Rstparser333587* p, NimStringDesc* key) {
	Rstnode332011* result;
{	result = 0;
	{
		NI i_334505;
		NI HEX3Atmp_334507;
		NI res_334510;
		i_334505 = 0;
		HEX3Atmp_334507 = 0;
		HEX3Atmp_334507 = ((*(*p).s).refs ? ((*(*p).s).refs->Sup.len-1) : -1);
		res_334510 = ((NI) 0);
		{
			while (1) {
				if (!(res_334510 <= HEX3Atmp_334507)) goto LA3;
				i_334505 = res_334510;
				{
					if (!eqStrings(key, (*(*p).s).refs->data[i_334505].key)) goto LA6;
					result = (*(*p).s).refs->data[i_334505].value;
					goto BeforeRet;
				}
				LA6: ;
				res_334510 += ((NI) 1);
			} LA3: ;
		}
	}
	}BeforeRet: ;
	return result;
}

static N_INLINE(void, asgnRefNoCycle)(void** dest, void* src) {
	{
		Cell48947* c;
		if (!!((src == NIM_NIL))) goto LA3;
		c = usrtocell_52646(src);
		(*c).refcount += ((NI) 8);
	}
	LA3: ;
	{
		Cell48947* 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(Rstnode332011*, resolvesubs_340250)(Rstparser333587* p, Rstnode332011* n) {
	Rstnode332011* result;
{	result = 0;
	result = n;
	{
		if (!(n == NIM_NIL)) goto LA3;
		goto BeforeRet;
	}
	LA3: ;
	switch ((*n).kind) {
	case ((NU8) 62):
	{
		NI x;
		x = findsub_334292(p, n);
		{
			if (!(((NI) 0) <= x)) goto LA8;
			result = (*(*p).s).subs->data[x].value;
		}
		goto LA6;
		LA8: ;
		{
			NimStringDesc* key;
			NimStringDesc* e;
			key = addnodes_333073(n);
			e = getenv_131044(key);
			{
				if (!!(((e) && (e)->Sup.len == 0))) goto LA13;
				result = newrstnode_332142(((NU8) 64), e);
			}
			goto LA11;
			LA13: ;
			{
				rstmessage_333943((&(*p)), ((NU8) 7), key);
			}
			LA11: ;
		}
		LA6: ;
	}
	break;
	case ((NU8) 39):
	{
		Rstnode332011* y;
		NimStringDesc* LOC17;
		LOC17 = 0;
		LOC17 = rstnodetorefname_333067(n);
		y = findref_334487(p, LOC17);
		{
			if (!!((y == NIM_NIL))) goto LA20;
			result = newrstnode_332108(((NU8) 38));
			(*n).kind = ((NU8) 0);
			add_332171(result, n);
			add_332171(result, y);
		}
		LA20: ;
	}
	break;
	case ((NU8) 64):
	{
	}
	break;
	case ((NU8) 44):
	{
		(*p).hastoc = NIM_TRUE;
	}
	break;
	default:
	{
		{
			NI i_340296;
			NI HEX3Atmp_340298;
			NI LOC26;
			NI res_340301;
			i_340296 = 0;
			HEX3Atmp_340298 = 0;
			LOC26 = 0;
			LOC26 = len_332090(n);
			HEX3Atmp_340298 = (NI)(LOC26 - ((NI) 1));
			res_340301 = ((NI) 0);
			{
				while (1) {
					if (!(res_340301 <= HEX3Atmp_340298)) goto LA28;
					i_340296 = res_340301;
					asgnRefNoCycle((void**) (&(*n).sons->data[i_340296]), resolvesubs_340250(p, (*n).sons->data[i_340296]));
					res_340301 += ((NI) 1);
				} LA28: ;
			}
		}
	}
	break;
	}
	}BeforeRet: ;
	return result;
}

N_NIMCALL(NI, currind_334001)(Rstparser333587* p) {
	NI result;
	result = 0;
	result = (*p).indentstack->data[((*p).indentstack ? ((*p).indentstack->Sup.len-1) : -1)];
	return result;
}

N_NIMCALL(void, pushind_334011)(Rstparser333587* p, NI ind) {
	(*p).indentstack = (TY333608*) incrSeqV2(&((*p).indentstack)->Sup, sizeof(NI));
	(*p).indentstack->data[(*p).indentstack->Sup.len] = ind;
	++(*p).indentstack->Sup.len;
}

N_NIMCALL(void, popind_334032)(Rstparser333587* p) {
	{
		if (!(((NI) 1) < ((*p).indentstack ? (*p).indentstack->Sup.len : 0))) goto LA3;
		(*p).indentstack = (TY333608*) setLengthSeq(&((*p).indentstack)->Sup, sizeof(NI), ((NI) ((NI)(((*p).indentstack ? (*p).indentstack->Sup.len : 0) - ((NI) 1)))));
	}
	LA3: ;
}

N_NIMCALL(NIM_BOOL, match_334727)(Rstparser333587* p, NI start, NimStringDesc* expr) {
	NIM_BOOL result;
	NI i;
	NI j;
	NI last;
{	result = 0;
	i = ((NI) 0);
	j = start;
	last = (NI)((expr ? expr->Sup.len : 0) - ((NI) 1));
	{
		while (1) {
			if (!(i <= last)) goto LA2;
			switch (((NU8)(expr->data[i]))) {
			case 119:
			{
				result = ((*p).tok->data[j].kind == ((NU8) 3));
			}
			break;
			case 32:
			{
				result = ((*p).tok->data[j].kind == ((NU8) 2));
			}
			break;
			case 105:
			{
				result = ((*p).tok->data[j].kind == ((NU8) 1));
			}
			break;
			case 112:
			{
				result = ((*p).tok->data[j].kind == ((NU8) 5));
			}
			break;
			case 97:
			{
				result = ((*p).tok->data[j].kind == ((NU8) 4));
			}
			break;
			case 111:
			{
				result = ((*p).tok->data[j].kind == ((NU8) 6));
			}
			break;
			case 84:
			{
				result = NIM_TRUE;
			}
			break;
			case 69:
			{
				result = ((7 &(1<<(((*p).tok->data[j].kind)&7)))!=0);
			}
			break;
			case 101:
			{
				NIM_BOOL LOC12;
				LOC12 = 0;
				LOC12 = ((*p).tok->data[j].kind == ((NU8) 3));
				if (LOC12) goto LA13;
				LOC12 = eqStrings((*p).tok->data[j].symbol, ((NimStringDesc*) &TMP2595));
				LA13: ;
				result = LOC12;
				{
					if (!result) goto LA16;
					switch (((NU8)((*p).tok->data[j].symbol->data[((NI) 0)]))) {
					case 97 ... 122:
					case 65 ... 90:
					{
						result = (((*p).tok->data[j].symbol ? (*p).tok->data[j].symbol->Sup.len : 0) == ((NI) 1));
					}
					break;
					case 48 ... 57:
					{
						result = allcharsinset_103130((*p).tok->data[j].symbol, TMP2596);
					}
					break;
					default:
					{
					}
					break;
					}
				}
				LA16: ;
			}
			break;
			default:
			{
				NIM_CHAR c;
				NI length;
				NIM_BOOL LOC26;
				NIM_BOOL LOC27;
				c = expr->data[i];
				length = ((NI) 0);
				{
					while (1) {
						NIM_BOOL LOC24;
						LOC24 = 0;
						LOC24 = (i <= last);
						if (!(LOC24)) goto LA25;
						LOC24 = ((NU8)(expr->data[i]) == (NU8)(c));
						LA25: ;
						if (!LOC24) goto LA23;
						i += ((NI) 1);
						length += ((NI) 1);
					} LA23: ;
				}
				i -= ((NI) 1);
				LOC26 = 0;
				LOC27 = 0;
				LOC27 = ((48 &(1<<(((*p).tok->data[j].kind)&7)))!=0);
				if (!(LOC27)) goto LA28;
				LOC27 = (((*p).tok->data[j].symbol ? (*p).tok->data[j].symbol->Sup.len : 0) == length);
				LA28: ;
				LOC26 = LOC27;
				if (!(LOC26)) goto LA29;
				LOC26 = ((NU8)((*p).tok->data[j].symbol->data[((NI) 0)]) == (NU8)(c));
				LA29: ;
				result = LOC26;
			}
			break;
			}
			{
				if (!!(result)) goto LA32;
				goto BeforeRet;
			}
			LA32: ;
			j += ((NI) 1);
			i += ((NI) 1);
		} LA2: ;
	}
	result = NIM_TRUE;
	}BeforeRet: ;
	return result;
}

N_NIMCALL(NI, tokenafternewline_337205)(Rstparser333587* p) {
	NI result;
	result = 0;
	result = (*p).idx;
	{
		while (1) {
			switch ((*p).tok->data[result].kind) {
			case ((NU8) 0):
			{
				goto LA1;
			}
			break;
			case ((NU8) 1):
			{
				result += ((NI) 1);
				goto LA1;
			}
			break;
			default:
			{
				result += ((NI) 1);
			}
			break;
			}
		}
	} LA1: ;
	return result;
}

N_NIMCALL(NIM_BOOL, prednl_337251)(Rstparser333587* p) {
	NIM_BOOL result;
	result = 0;
	result = NIM_TRUE;
	{
		NIM_BOOL LOC5;
		NI LOC7;
		if (!(((NI) 0) < (*p).idx)) goto LA3;
		LOC5 = 0;
		LOC5 = ((*p).tok->data[(NI)((*p).idx - ((NI) 1))].kind == ((NU8) 1));
		if (!(LOC5)) goto LA6;
		LOC7 = 0;
		LOC7 = currind_334001(p);
		LOC5 = ((*p).tok->data[(NI)((*p).idx - ((NI) 1))].ival == LOC7);
		LA6: ;
		result = LOC5;
	}
	LA3: ;
	return result;
}

N_NIMCALL(NIM_BOOL, islineblock_337240)(Rstparser333587* p) {
	NIM_BOOL result;
	NI j;
	NIM_BOOL LOC1;
	NIM_BOOL LOC2;
	result = 0;
	j = tokenafternewline_337205(p);
	LOC1 = 0;
	LOC2 = 0;
	LOC2 = ((*p).tok->data[(*p).idx].col == (*p).tok->data[j].col);
	if (!(LOC2)) goto LA3;
	LOC2 = eqStrings((*p).tok->data[j].symbol, ((NimStringDesc*) &TMP2605));
	LA3: ;
	LOC1 = LOC2;
	if (LOC1) goto LA4;
	LOC1 = ((*p).tok->data[(*p).idx].col < (*p).tok->data[j].col);
	LA4: ;
	result = LOC1;
	return result;
}

N_NIMCALL(void, rstmessage_333967)(Rstparser333587* p, NU8 msgkind) {
	(*(*p).s).msghandler((*p).filename, (NI)((*p).line + (*p).tok->data[(*p).idx].line), (NI)((*p).col + (*p).tok->data[(*p).idx].col), msgkind, (*p).tok->data[(*p).idx].symbol);
}

N_NIMCALL(NIM_BOOL, isdeflist_337270)(Rstparser333587* p) {
	NIM_BOOL result;
	NI j;
	NIM_BOOL LOC1;
	NIM_BOOL LOC2;
	result = 0;
	j = tokenafternewline_337205(p);
	LOC1 = 0;
	LOC2 = 0;
	LOC2 = ((*p).tok->data[(*p).idx].col < (*p).tok->data[j].col);
	if (!(LOC2)) goto LA3;
	LOC2 = ((104 &(1<<(((*p).tok->data[j].kind)&7)))!=0);
	LA3: ;
	LOC1 = LOC2;
	if (!(LOC1)) goto LA4;
	LOC1 = !(eqStrings((*p).tok->data[(NI)(j - ((NI) 2))].symbol, ((NimStringDesc*) &TMP2601)));
	LA4: ;
	result = LOC1;
	return result;
}

N_NIMCALL(NIM_BOOL, isoptionlist_337292)(Rstparser333587* p) {
	NIM_BOOL result;
	NIM_BOOL LOC1;
	NIM_BOOL LOC2;
	NIM_BOOL LOC3;
	result = 0;
	LOC1 = 0;
	LOC2 = 0;
	LOC3 = 0;
	LOC3 = match_334727(p, (*p).idx, ((NimStringDesc*) &TMP2610));
	if (LOC3) goto LA4;
	LOC3 = match_334727(p, (*p).idx, ((NimStringDesc*) &TMP2611));
	LA4: ;
	LOC2 = LOC3;
	if (LOC2) goto LA5;
	LOC2 = match_334727(p, (*p).idx, ((NimStringDesc*) &TMP2612));
	LA5: ;
	LOC1 = LOC2;
	if (LOC1) goto LA6;
	LOC1 = match_334727(p, (*p).idx, ((NimStringDesc*) &TMP2613));
	LA6: ;
	result = LOC1;
	return result;
}

N_NIMCALL(NU8, whichsection_337302)(Rstparser333587* p) {
	NU8 result;
	result = 0;
	switch ((*p).tok->data[(*p).idx].kind) {
	case ((NU8) 4):
	{
		{
			NIM_BOOL LOC4;
			LOC4 = 0;
			LOC4 = match_334727(p, (NI)((*p).idx + ((NI) 1)), ((NimStringDesc*) &TMP2597));
			if (!LOC4) goto LA5;
			result = ((NU8) 3);
		}
		goto LA2;
		LA5: ;
		{
			NIM_BOOL LOC8;
			LOC8 = 0;
			LOC8 = match_334727(p, (NI)((*p).idx + ((NI) 1)), ((NimStringDesc*) &TMP2598));
			if (!LOC8) goto LA9;
			result = ((NU8) 29);
		}
		goto LA2;
		LA9: ;
		{
			NIM_BOOL LOC12;
			LOC12 = 0;
			LOC12 = match_334727(p, (NI)((*p).idx + ((NI) 1)), ((NimStringDesc*) &TMP2599));
			if (!LOC12) goto LA13;
			result = ((NU8) 2);
		}
		goto LA2;
		LA13: ;
		{
			result = ((NU8) 64);
		}
		LA2: ;
	}
	break;
	case ((NU8) 5):
	{
		{
			NI LOC19;
			NIM_BOOL LOC20;
			LOC19 = 0;
			LOC19 = tokenafternewline_337205(p);
			LOC20 = 0;
			LOC20 = match_334727(p, LOC19, ((NimStringDesc*) &TMP2600));
			if (!LOC20) goto LA21;
			result = ((NU8) 1);
		}
		goto LA17;
		LA21: ;
		{
			if (!eqStrings((*p).tok->data[(*p).idx].symbol, ((NimStringDesc*) &TMP2601))) goto LA24;
			result = ((NU8) 24);
		}
		goto LA17;
		LA24: ;
		{
			NIM_BOOL LOC27;
			NIM_BOOL LOC28;
			NIM_BOOL LOC30;
			NIM_BOOL LOC31;
			LOC27 = 0;
			LOC28 = 0;
			LOC28 = prednl_337251(p);
			if (!(LOC28)) goto LA29;
			LOC30 = 0;
			LOC31 = 0;
			LOC31 = eqStrings((*p).tok->data[(*p).idx].symbol, ((NimStringDesc*) &TMP2602));
			if (LOC31) goto LA32;
			LOC31 = eqStrings((*p).tok->data[(*p).idx].symbol, ((NimStringDesc*) &TMP2603));
			LA32: ;
			LOC30 = LOC31;
			if (LOC30) goto LA33;
			LOC30 = eqStrings((*p).tok->data[(*p).idx].symbol, ((NimStringDesc*) &TMP2604));
			LA33: ;
			LOC28 = LOC30;
			LA29: ;
			LOC27 = LOC28;
			if (!(LOC27)) goto LA34;
			LOC27 = ((*p).tok->data[(NI)((*p).idx + ((NI) 1))].kind == ((NU8) 2));
			LA34: ;
			if (!LOC27) goto LA35;
			result = ((NU8) 5);
		}
		goto LA17;
		LA35: ;
		{
			NIM_BOOL LOC38;
			LOC38 = 0;
			LOC38 = eqStrings((*p).tok->data[(*p).idx].symbol, ((NimStringDesc*) &TMP2605));
			if (!(LOC38)) goto LA39;
			LOC38 = islineblock_337240(p);
			LA39: ;
			if (!LOC38) goto LA40;
			result = ((NU8) 26);
		}
		goto LA17;
		LA40: ;
		{
			NIM_BOOL LOC43;
			LOC43 = 0;
			LOC43 = eqStrings((*p).tok->data[(*p).idx].symbol, ((NimStringDesc*) &TMP2606));
			if (!(LOC43)) goto LA44;
			LOC43 = prednl_337251(p);
			LA44: ;
			if (!LOC43) goto LA45;
			result = ((NU8) 40);
		}
		goto LA17;
		LA45: ;
		{
			NIM_BOOL LOC48;
			LOC48 = 0;
			LOC48 = match_334727(p, (*p).idx, ((NimStringDesc*) &TMP2607));
			if (!(LOC48)) goto LA49;
			LOC48 = prednl_337251(p);
			LA49: ;
			if (!LOC48) goto LA50;
			result = ((NU8) 13);
		}
		goto LA17;
		LA50: ;
		{
			NIM_BOOL LOC53;
			LOC53 = 0;
			LOC53 = match_334727(p, (*p).idx, ((NimStringDesc*) &TMP2608));
			if (!LOC53) goto LA54;
			result = ((NU8) 7);
		}
		goto LA17;
		LA54: ;
		{
			NIM_BOOL LOC57;
			LOC57 = 0;
			LOC57 = match_334727(p, (*p).idx, ((NimStringDesc*) &TMP2609));
			if (!LOC57) goto LA58;
			result = ((NU8) 30);
			rstmessage_333967(p, ((NU8) 2));
		}
		goto LA17;
		LA58: ;
		{
			NIM_BOOL LOC61;
			LOC61 = 0;
			LOC61 = isdeflist_337270(p);
			if (!LOC61) goto LA62;
			result = ((NU8) 9);
		}
		goto LA17;
		LA62: ;
		{
			NIM_BOOL LOC65;
			LOC65 = 0;
			LOC65 = isoptionlist_337292(p);
			if (!LOC65) goto LA66;
			result = ((NU8) 17);
		}
		goto LA17;
		LA66: ;
		{
			result = ((NU8) 4);
		}
		LA17: ;
	}
	break;
	case ((NU8) 3):
	case ((NU8) 6):
	case ((NU8) 2):
	{
		{
			NI LOC72;
			NIM_BOOL LOC73;
			LOC72 = 0;
			LOC72 = tokenafternewline_337205(p);
			LOC73 = 0;
			LOC73 = match_334727(p, LOC72, ((NimStringDesc*) &TMP2600));
			if (!LOC73) goto LA74;
			result = ((NU8) 1);
		}
		goto LA70;
		LA74: ;
		{
			NIM_BOOL LOC77;
			LOC77 = 0;
			LOC77 = match_334727(p, (*p).idx, ((NimStringDesc*) &TMP2614));
			if (LOC77) goto LA78;
			LOC77 = match_334727(p, (*p).idx, ((NimStringDesc*) &TMP2615));
			LA78: ;
			if (!LOC77) goto LA79;
			result = ((NU8) 7);
		}
		goto LA70;
		LA79: ;
		{
			NIM_BOOL LOC82;
			LOC82 = 0;
			LOC82 = isdeflist_337270(p);
			if (!LOC82) goto LA83;
			result = ((NU8) 9);
		}
		goto LA70;
		LA83: ;
		{
			result = ((NU8) 4);
		}
		LA70: ;
	}
	break;
	default:
	{
		result = ((NU8) 64);
	}
	break;
	}
	return result;
}

N_NIMCALL(Rstnode332011*, parseliteralblock_337099)(Rstparser333587* p) {
	Rstnode332011* result;
	Rstnode332011* n;
	result = 0;
	result = newrstnode_332108(((NU8) 24));
	n = newrstnode_332142(((NU8) 64), ((NimStringDesc*) &TMP2205));
	{
		NI indent;
		if (!((*p).tok->data[(*p).idx].kind == ((NU8) 1))) goto LA3;
		indent = (*p).tok->data[(*p).idx].ival;
		(*p).idx += ((NI) 1);
		{
			while (1) {
				switch ((*p).tok->data[(*p).idx].kind) {
				case ((NU8) 0):
				{
					goto LA5;
				}
				break;
				case ((NU8) 1):
				{
					{
						if (!((*p).tok->data[(*p).idx].ival < indent)) goto LA11;
						goto LA5;
					}
					goto LA9;
					LA11: ;
					{
						NimStringDesc* LOC14;
						(*n).text = resizeString((*n).text, 1);
appendString((*n).text, ((NimStringDesc*) &TMP2591));
						LOC14 = 0;
						LOC14 = nsuRepeatChar(32, ((NI) ((NI)((*p).tok->data[(*p).idx].ival - indent))));
						(*n).text = resizeString((*n).text, LOC14->Sup.len + 0);
appendString((*n).text, LOC14);
						(*p).idx += ((NI) 1);
					}
					LA9: ;
				}
				break;
				default:
				{
					(*n).text = resizeString((*n).text, (*p).tok->data[(*p).idx].symbol->Sup.len + 0);
appendString((*n).text, (*p).tok->data[(*p).idx].symbol);
					(*p).idx += ((NI) 1);
				}
				break;
				}
			}
		} LA5: ;
	}
	goto LA1;
	LA3: ;
	{
		{
			while (1) {
				if (!!(((3 &(1<<(((*p).tok->data[(*p).idx].kind)&7)))!=0))) goto LA18;
				(*n).text = resizeString((*n).text, (*p).tok->data[(*p).idx].symbol->Sup.len + 0);
appendString((*n).text, (*p).tok->data[(*p).idx].symbol);
				(*p).idx += ((NI) 1);
			} LA18: ;
		}
	}
	LA1: ;
	add_332171(result, n);
	return result;
}

N_NIMCALL(Rstnode332011*, parsebulletlist_338565)(Rstparser333587* p) {
	Rstnode332011* result;
	result = 0;
	result = NIM_NIL;
	{
		NimStringDesc* bullet;
		NI col;
		if (!((*p).tok->data[(NI)((*p).idx + ((NI) 1))].kind == ((NU8) 2))) goto LA3;
		bullet = copyString((*p).tok->data[(*p).idx].symbol);
		col = (*p).tok->data[(*p).idx].col;
		result = newrstnode_332108(((NU8) 5));
		pushind_334011(p, (*p).tok->data[(NI)((*p).idx + ((NI) 2))].col);
		(*p).idx += ((NI) 2);
		{
			while (1) {
				Rstnode332011* item;
				item = newrstnode_332108(((NU8) 6));
				parsesection_336217(p, item);
				add_332171(result, item);
				{
					NIM_BOOL LOC9;
					NIM_BOOL LOC10;
					NIM_BOOL LOC11;
					LOC9 = 0;
					LOC10 = 0;
					LOC11 = 0;
					LOC11 = ((*p).tok->data[(*p).idx].kind == ((NU8) 1));
					if (!(LOC11)) goto LA12;
					LOC11 = ((*p).tok->data[(*p).idx].ival == col);
					LA12: ;
					LOC10 = LOC11;
					if (!(LOC10)) goto LA13;
					LOC10 = eqStrings((*p).tok->data[(NI)((*p).idx + ((NI) 1))].symbol, bullet);
					LA13: ;
					LOC9 = LOC10;
					if (!(LOC9)) goto LA14;
					LOC9 = ((*p).tok->data[(NI)((*p).idx + ((NI) 2))].kind == ((NU8) 2));
					LA14: ;
					if (!LOC9) goto LA15;
					(*p).idx += ((NI) 3);
				}
				goto LA7;
				LA15: ;
				{
					goto LA5;
				}
				LA7: ;
			}
		} LA5: ;
		popind_334032(p);
	}
	LA3: ;
	return result;
}

N_NIMCALL(Rstnode332011*, parselineblock_337321)(Rstparser333587* p) {
	Rstnode332011* result;
	result = 0;
	result = NIM_NIL;
	{
		NI col;
		if (!((*p).tok->data[(NI)((*p).idx + ((NI) 1))].kind == ((NU8) 2))) goto LA3;
		col = (*p).tok->data[(*p).idx].col;
		result = newrstnode_332108(((NU8) 26));
		pushind_334011(p, (*p).tok->data[(NI)((*p).idx + ((NI) 2))].col);
		(*p).idx += ((NI) 2);
		{
			while (1) {
				Rstnode332011* item;
				item = newrstnode_332108(((NU8) 27));
				parsesection_336217(p, item);
				add_332171(result, item);
				{
					NIM_BOOL LOC9;
					NIM_BOOL LOC10;
					NIM_BOOL LOC11;
					LOC9 = 0;
					LOC10 = 0;
					LOC11 = 0;
					LOC11 = ((*p).tok->data[(*p).idx].kind == ((NU8) 1));
					if (!(LOC11)) goto LA12;
					LOC11 = ((*p).tok->data[(*p).idx].ival == col);
					LA12: ;
					LOC10 = LOC11;
					if (!(LOC10)) goto LA13;
					LOC10 = eqStrings((*p).tok->data[(NI)((*p).idx + ((NI) 1))].symbol, ((NimStringDesc*) &TMP2605));
					LA13: ;
					LOC9 = LOC10;
					if (!(LOC9)) goto LA14;
					LOC9 = ((*p).tok->data[(NI)((*p).idx + ((NI) 2))].kind == ((NU8) 2));
					LA14: ;
					if (!LOC9) goto LA15;
					(*p).idx += ((NI) 3);
				}
				goto LA7;
				LA15: ;
				{
					goto LA5;
				}
				LA7: ;
			}
		} LA5: ;
		popind_334032(p);
	}
	LA3: ;
	return result;
}

N_NIMCALL(NimStringDesc*, getdirective_335866)(Rstparser333587* p) {
	NimStringDesc* result;
	result = 0;
	{
		NIM_BOOL LOC3;
		NI j;
		LOC3 = 0;
		LOC3 = ((*p).tok->data[(*p).idx].kind == ((NU8) 2));
		if (!(LOC3)) goto LA4;
		LOC3 = ((*p).tok->data[(NI)((*p).idx + ((NI) 1))].kind == ((NU8) 3));
		LA4: ;
		if (!LOC3) goto LA5;
		j = (*p).idx;
		(*p).idx += ((NI) 1);
		result = copyString((*p).tok->data[(*p).idx].symbol);
		(*p).idx += ((NI) 1);
		{
			while (1) {
				if (!((120 &(1<<(((*p).tok->data[(*p).idx].kind)&7)))!=0)) goto LA8;
				{
					if (!eqStrings((*p).tok->data[(*p).idx].symbol, ((NimStringDesc*) &TMP2601))) goto LA11;
					goto LA7;
				}
				LA11: ;
				result = resizeString(result, (*p).tok->data[(*p).idx].symbol->Sup.len + 0);
appendString(result, (*p).tok->data[(*p).idx].symbol);
				(*p).idx += ((NI) 1);
			} LA8: ;
		} LA7: ;
		{
			if (!((*p).tok->data[(*p).idx].kind == ((NU8) 2))) goto LA15;
			(*p).idx += ((NI) 1);
		}
		LA15: ;
		{
			if (!eqStrings((*p).tok->data[(*p).idx].symbol, ((NimStringDesc*) &TMP2601))) goto LA19;
			(*p).idx += ((NI) 1);
			{
				if (!((*p).tok->data[(*p).idx].kind == ((NU8) 2))) goto LA23;
				(*p).idx += ((NI) 1);
			}
			LA23: ;
		}
		goto LA17;
		LA19: ;
		{
			(*p).idx = j;
			result = copyString(((NimStringDesc*) &TMP2205));
		}
		LA17: ;
	}
	goto LA1;
	LA5: ;
	{
		result = copyString(((NimStringDesc*) &TMP2205));
	}
	LA1: ;
	return result;
}

static N_INLINE(NI, find_336103)(TY336092 a, NimStringDesc* item) {
	NI result;
{	result = 0;
	{
		NimStringDesc* i_336148;
		NI i_336161;
		i_336148 = 0;
		i_336161 = ((NI) 0);
		{
			if (!(((NI) (i_336161)) <= ((NI) 12))) goto LA4;
			{
				while (1) {
					i_336148 = a[(i_336161)- 0];
					{
						if (!eqStrings(i_336148, item)) goto LA10;
						goto BeforeRet;
					}
					LA10: ;
					result += ((NI) 1);
					{
						if (!(((NI) 12) <= ((NI) (i_336161)))) goto LA14;
						goto LA6;
					}
					LA14: ;
					i_336161 += ((NI) 1);
				}
			} LA6: ;
		}
		LA4: ;
	}
	result = ((NI) -1);
	}BeforeRet: ;
	return result;
}

N_NIMCALL(NU8, getdirkind_336098)(NimStringDesc* s) {
	NU8 result;
	NI i;
	result = 0;
	i = find_336103(Dirids_336090, s);
	{
		if (!(((NI) 0) <= i)) goto LA3;
		result = ((NU8) (i));
	}
	goto LA1;
	LA3: ;
	{
		result = ((NU8) 0);
	}
	LA1: ;
	return result;
}

N_NIMCALL(Rstnode332011*, newleaf_334529)(Rstparser333587* p) {
	Rstnode332011* result;
	result = 0;
	result = newrstnode_332142(((NU8) 64), (*p).tok->data[(*p).idx].symbol);
	return result;
}

N_NIMCALL(NIM_BOOL, isinlinemarkupstart_334680)(Rstparser333587* p, NimStringDesc* markup) {
	NIM_BOOL result;
	NIM_CHAR d;
	NIM_BOOL LOC5;
	NIM_BOOL LOC6;
{	result = 0;
	d = 0;
	result = eqStrings((*p).tok->data[(*p).idx].symbol, markup);
	{
		if (!!(result)) goto LA3;
		goto BeforeRet;
	}
	LA3: ;
	LOC5 = 0;
	LOC6 = 0;
	LOC6 = ((*p).idx == ((NI) 0));
	if (LOC6) goto LA7;
	LOC6 = ((6 &(1<<(((*p).tok->data[(NI)((*p).idx - ((NI) 1))].kind)&7)))!=0);
	LA7: ;
	LOC5 = LOC6;
	if (LOC5) goto LA8;
	LOC5 = ((TMP2628[((NU8)((*p).tok->data[(NI)((*p).idx - ((NI) 1))].symbol->data[((NI) 0)]))/8] &(1<<(((NU8)((*p).tok->data[(NI)((*p).idx - ((NI) 1))].symbol->data[((NI) 0)]))%8)))!=0);
	LA8: ;
	result = LOC5;
	{
		if (!!(result)) goto LA11;
		goto BeforeRet;
	}
	LA11: ;
	result = !(((7 &(1<<(((*p).tok->data[(NI)((*p).idx + ((NI) 1))].kind)&7)))!=0));
	{
		if (!!(result)) goto LA15;
		goto BeforeRet;
	}
	LA15: ;
	{
		if (!(((NI) 0) < (*p).idx)) goto LA19;
		{
			if (!eqStrings((*p).tok->data[(NI)((*p).idx - ((NI) 1))].symbol, ((NimStringDesc*) &TMP2629))) goto LA23;
			result = NIM_FALSE;
		}
		goto LA21;
		LA23: ;
		{
			NIM_CHAR c;
			c = (*p).tok->data[(NI)((*p).idx - ((NI) 1))].symbol->data[((NI) 0)];
			switch (((NU8)(c))) {
			case 39:
			case 34:
			{
				d = c;
			}
			break;
			case 40:
			{
				d = 41;
			}
			break;
			case 91:
			{
				d = 93;
			}
			break;
			case 123:
			{
				d = 125;
			}
			break;
			case 60:
			{
				d = 62;
			}
			break;
			default:
			{
				d = 0;
			}
			break;
			}
			{
				if (!!(((NU8)(d) == (NU8)(0)))) goto LA34;
				result = !(((NU8)((*p).tok->data[(NI)((*p).idx + ((NI) 1))].symbol->data[((NI) 0)]) == (NU8)(d)));
			}
			LA34: ;
		}
		LA21: ;
	}
	LA19: ;
	}BeforeRet: ;
	return result;
}

N_NIMCALL(NIM_BOOL, isinlinemarkupend_334636)(Rstparser333587* p, NimStringDesc* markup) {
	NIM_BOOL result;
	NIM_BOOL LOC9;
{	result = 0;
	result = eqStrings((*p).tok->data[(*p).idx].symbol, markup);
	{
		if (!!(result)) goto LA3;
		goto BeforeRet;
	}
	LA3: ;
	result = !(((6 &(1<<(((*p).tok->data[(NI)((*p).idx - ((NI) 1))].kind)&7)))!=0));
	{
		if (!!(result)) goto LA7;
		goto BeforeRet;
	}
	LA7: ;
	LOC9 = 0;
	LOC9 = ((7 &(1<<(((*p).tok->data[(NI)((*p).idx + ((NI) 1))].kind)&7)))!=0);
	if (LOC9) goto LA10;
	LOC9 = ((TMP2631[((NU8)((*p).tok->data[(NI)((*p).idx + ((NI) 1))].symbol->data[((NI) 0)]))/8] &(1<<(((NU8)((*p).tok->data[(NI)((*p).idx + ((NI) 1))].symbol->data[((NI) 0)]))%8)))!=0);
	LA10: ;
	result = LOC9;
	{
		if (!!(result)) goto LA13;
		goto BeforeRet;
	}
	LA13: ;
	{
		if (!(((NI) 0) < (*p).idx)) goto LA17;
		{
			NIM_BOOL LOC21;
			LOC21 = 0;
			LOC21 = !(eqStrings(markup, ((NimStringDesc*) &TMP2632)));
			if (!(LOC21)) goto LA22;
			LOC21 = eqStrings((*p).tok->data[(NI)((*p).idx - ((NI) 1))].symbol, ((NimStringDesc*) &TMP2629));
			LA22: ;
			if (!LOC21) goto LA23;
			result = NIM_FALSE;
		}
		LA23: ;
	}
	LA17: ;
	}BeforeRet: ;
	return result;
}

N_NIMCALL(void, parsebackslash_335330)(Rstparser333587* p, Rstnode332011* father) {
	{
		Rstnode332011* LOC5;
		if (!eqStrings((*p).tok->data[(*p).idx].symbol, ((NimStringDesc*) &TMP2633))) goto LA3;
		LOC5 = 0;
		LOC5 = newrstnode_332142(((NU8) 64), ((NimStringDesc*) &TMP2629));
		add_332171(father, LOC5);
		(*p).idx += ((NI) 1);
	}
	goto LA1;
	LA3: ;
	{
		if (!eqStrings((*p).tok->data[(*p).idx].symbol, ((NimStringDesc*) &TMP2629))) goto LA7;
		(*p).idx += ((NI) 1);
		{
			Rstnode332011* LOC13;
			if (!!(((*p).tok->data[(*p).idx].kind == ((NU8) 2)))) goto LA11;
			LOC13 = 0;
			LOC13 = newleaf_334529(p);
			add_332171(father, LOC13);
		}
		LA11: ;
		{
			if (!!(((*p).tok->data[(*p).idx].kind == ((NU8) 0)))) goto LA16;
			(*p).idx += ((NI) 1);
		}
		LA16: ;
	}
	goto LA1;
	LA7: ;
	{
		Rstnode332011* LOC19;
		LOC19 = 0;
		LOC19 = newleaf_334529(p);
		add_332171(father, LOC19);
		(*p).idx += ((NI) 1);
	}
	LA1: ;
}

N_NIMCALL(void, rstmessage_333954)(Rstparser333587* p, NU8 msgkind, NimStringDesc* arg, NI line, NI col) {
	(*(*p).s).msghandler((*p).filename, (NI)((*p).line + line), (NI)((*p).col + col), msgkind, arg);
}

N_NIMCALL(void, parseuntil_335601)(Rstparser333587* p, Rstnode332011* father, NimStringDesc* postfix, NIM_BOOL interpretbackslash) {
	NI line;
	NI col;
	line = (*p).tok->data[(*p).idx].line;
	col = (*p).tok->data[(*p).idx].col;
	(*p).idx += ((NI) 1);
	{
		while (1) {
			switch ((*p).tok->data[(*p).idx].kind) {
			case ((NU8) 5):
			{
				{
					NIM_BOOL LOC6;
					LOC6 = 0;
					LOC6 = isinlinemarkupend_334636((&(*p)), postfix);
					if (!LOC6) goto LA7;
					(*p).idx += ((NI) 1);
					goto LA1;
				}
				goto LA4;
				LA7: ;
				{
					if (!interpretbackslash) goto LA10;
					parsebackslash_335330(p, father);
				}
				goto LA4;
				LA10: ;
				{
					Rstnode332011* LOC13;
					LOC13 = 0;
					LOC13 = newleaf_334529(p);
					add_332171(father, LOC13);
					(*p).idx += ((NI) 1);
				}
				LA4: ;
			}
			break;
			case ((NU8) 4):
			case ((NU8) 3):
			case ((NU8) 6):
			{
				Rstnode332011* LOC15;
				LOC15 = 0;
				LOC15 = newleaf_334529(p);
				add_332171(father, LOC15);
				(*p).idx += ((NI) 1);
			}
			break;
			case ((NU8) 1):
			{
				Rstnode332011* LOC17;
				LOC17 = 0;
				LOC17 = newrstnode_332142(((NU8) 64), ((NimStringDesc*) &TMP2634));
				add_332171(father, LOC17);
				(*p).idx += ((NI) 1);
				{
					if (!((*p).tok->data[(*p).idx].kind == ((NU8) 1))) goto LA20;
					rstmessage_333954((&(*p)), ((NU8) 1), postfix, line, col);
					goto LA1;
				}
				LA20: ;
			}
			break;
			case ((NU8) 2):
			{
				Rstnode332011* LOC23;
				LOC23 = 0;
				LOC23 = newrstnode_332142(((NU8) 64), ((NimStringDesc*) &TMP2634));
				add_332171(father, LOC23);
				(*p).idx += ((NI) 1);
			}
			break;
			default:
			{
				rstmessage_333954((&(*p)), ((NU8) 1), postfix, line, col);
			}
			break;
			}
		}
	} LA1: ;
}

N_NIMCALL(Rstnode332011*, parsemarkdowncodeblock_335686)(Rstparser333587* p) {
	Rstnode332011* result;
	Rstnode332011* args;
	Rstnode332011* n;
	Rstnode332011* lb;
	result = 0;
	args = newrstnode_332108(((NU8) 41));
	{
		Rstnode332011* LOC5;
		if (!((*p).tok->data[(*p).idx].kind == ((NU8) 3))) goto LA3;
		LOC5 = 0;
		LOC5 = newleaf_334529(p);
		add_332171(args, LOC5);
		(*p).idx += ((NI) 1);
	}
	goto LA1;
	LA3: ;
	{
		args = NIM_NIL;
	}
	LA1: ;
	n = newrstnode_332142(((NU8) 64), ((NimStringDesc*) &TMP2205));
	{
		while (1) {
			switch ((*p).tok->data[(*p).idx].kind) {
			case ((NU8) 0):
			{
				rstmessage_333943((&(*p)), ((NU8) 1), ((NimStringDesc*) &TMP2636));
				goto LA7;
			}
			break;
			case ((NU8) 5):
			{
				{
					if (!eqStrings((*p).tok->data[(*p).idx].symbol, ((NimStringDesc*) &TMP2636))) goto LA13;
					(*p).idx += ((NI) 1);
					goto LA7;
				}
				goto LA11;
				LA13: ;
				{
					(*n).text = resizeString((*n).text, (*p).tok->data[(*p).idx].symbol->Sup.len + 0);
appendString((*n).text, (*p).tok->data[(*p).idx].symbol);
					(*p).idx += ((NI) 1);
				}
				LA11: ;
			}
			break;
			default:
			{
				(*n).text = resizeString((*n).text, (*p).tok->data[(*p).idx].symbol->Sup.len + 0);
appendString((*n).text, (*p).tok->data[(*p).idx].symbol);
				(*p).idx += ((NI) 1);
			}
			break;
			}
		}
	} LA7: ;
	lb = newrstnode_332108(((NU8) 24));
	add_332171(lb, n);
	result = newrstnode_332108(((NU8) 47));
	add_332171(result, args);
	add_332171(result, NIM_NIL);
	add_332171(result, lb);
	return result;
}

N_NIMCALL(void, fixupembeddedref_334889)(Rstnode332011* n, Rstnode332011* a, Rstnode332011* b) {
	NI sep;
	NI incr;
	sep = ((NI) -1);
	{
		NI i_334906;
		NI HEX3Atmp_334935;
		NI LOC2;
		NI res_334938;
		i_334906 = 0;
		HEX3Atmp_334935 = 0;
		LOC2 = 0;
		LOC2 = len_332090(n);
		HEX3Atmp_334935 = (NI)(LOC2 - ((NI) 2));
		res_334938 = HEX3Atmp_334935;
		{
			while (1) {
				if (!(((NI) 0) <= res_334938)) goto LA4;
				i_334906 = res_334938;
				{
					if (!eqStrings((*(*n).sons->data[i_334906]).text, ((NimStringDesc*) &TMP2641))) goto LA7;
					sep = i_334906;
					goto LA1;
				}
				LA7: ;
				res_334938 -= ((NI) 1);
			} LA4: ;
		}
	} LA1: ;
	{
		NIM_BOOL LOC11;
		LOC11 = 0;
		LOC11 = (((NI) 0) < sep);
		if (!(LOC11)) goto LA12;
		LOC11 = ((NU8)((*(*n).sons->data[(NI)(sep - ((NI) 1))]).text->data[((NI) 0)]) == (NU8)(32));
		LA12: ;
		if (!LOC11) goto LA13;
		incr = ((NI) 2);
	}
	goto LA9;
	LA13: ;
	{
		incr = ((NI) 1);
	}
	LA9: ;
	{
		NI i_334920;
		NI HEX3Atmp_334943;
		NI res_334946;
		i_334920 = 0;
		HEX3Atmp_334943 = 0;
		HEX3Atmp_334943 = (NI)(sep - incr);
		res_334946 = ((NI) 0);
		{
			while (1) {
				if (!(res_334946 <= HEX3Atmp_334943)) goto LA18;
				i_334920 = res_334946;
				add_332171(a, (*n).sons->data[i_334920]);
				res_334946 += ((NI) 1);
			} LA18: ;
		}
	}
	{
		NI i_334933;
		NI HEX3Atmp_334951;
		NI HEX3Atmp_334952;
		NI LOC20;
		NI res_334955;
		i_334933 = 0;
		HEX3Atmp_334951 = 0;
		HEX3Atmp_334952 = 0;
		HEX3Atmp_334951 = (NI)(sep + ((NI) 1));
		LOC20 = 0;
		LOC20 = len_332090(n);
		HEX3Atmp_334952 = (NI)(LOC20 - ((NI) 2));
		res_334955 = HEX3Atmp_334951;
		{
			while (1) {
				if (!(res_334955 <= HEX3Atmp_334952)) goto LA22;
				i_334933 = res_334955;
				add_332171(b, (*n).sons->data[i_334933]);
				res_334955 += ((NI) 1);
			} LA22: ;
		}
	}
}

N_NIMCALL(void, setref_334426)(Rstparser333587* p, NimStringDesc* key, Rstnode332011* value) {
	NI length;
	NimStringDesc* LOC14;
{	length = ((*(*p).s).refs ? (*(*p).s).refs->Sup.len : 0);
	{
		NI i_334453;
		NI HEX3Atmp_334465;
		NI res_334468;
		i_334453 = 0;
		HEX3Atmp_334465 = 0;
		HEX3Atmp_334465 = (NI)(length - ((NI) 1));
		res_334468 = ((NI) 0);
		{
			while (1) {
				if (!(res_334468 <= HEX3Atmp_334465)) goto LA3;
				i_334453 = res_334468;
				{
					if (!eqStrings(key, (*(*p).s).refs->data[i_334453].key)) goto LA6;
					{
						NimStringDesc* LOC10;
						NimStringDesc* LOC11;
						LOC10 = 0;
						LOC10 = addnodes_333073((*(*p).s).refs->data[i_334453].value);
						LOC11 = 0;
						LOC11 = addnodes_333073(value);
						if (!!(eqStrings(LOC10, LOC11))) goto LA12;
						rstmessage_333943((&(*p)), ((NU8) 6), key);
					}
					LA12: ;
					asgnRefNoCycle((void**) (&(*(*p).s).refs->data[i_334453].value), value);
					goto BeforeRet;
				}
				LA6: ;
				res_334468 += ((NI) 1);
			} LA3: ;
		}
	}
	(*(*p).s).refs = (TY333597*) setLengthSeq(&((*(*p).s).refs)->Sup, sizeof(Substitution333581), ((NI) ((NI)(length + ((NI) 1)))));
	LOC14 = 0;
	LOC14 = (*(*p).s).refs->data[length].key; (*(*p).s).refs->data[length].key = copyStringRC1(key);
	if (LOC14) nimGCunrefNoCycle(LOC14);
	asgnRefNoCycle((void**) (&(*(*p).s).refs->data[length].value), value);
	}BeforeRet: ;
}

N_NIMCALL(Rstnode332011*, parsepostfix_334992)(Rstparser333587* p, Rstnode332011* n) {
	Rstnode332011* result;
	result = 0;
	result = n;
	{
		NIM_BOOL LOC3;
		LOC3 = 0;
		LOC3 = isinlinemarkupend_334636((&(*p)), ((NimStringDesc*) &TMP2638));
		if (LOC3) goto LA4;
		LOC3 = isinlinemarkupend_334636((&(*p)), ((NimStringDesc*) &TMP2639));
		LA4: ;
		if (!LOC3) goto LA5;
		(*p).idx += ((NI) 1);
		{
			NIM_BOOL LOC9;
			Rstnode332011* a;
			Rstnode332011* b;
			LOC9 = 0;
			LOC9 = eqStrings((*p).tok->data[(NI)((*p).idx - ((NI) 2))].symbol, ((NimStringDesc*) &TMP2637));
			if (!(LOC9)) goto LA10;
			LOC9 = eqStrings((*p).tok->data[(NI)((*p).idx - ((NI) 3))].symbol, ((NimStringDesc*) &TMP2640));
			LA10: ;
			if (!LOC9) goto LA11;
			a = newrstnode_332108(((NU8) 0));
			b = newrstnode_332108(((NU8) 0));
			fixupembeddedref_334889(n, a, b);
			{
				NI LOC15;
				LOC15 = 0;
				LOC15 = len_332090(a);
				if (!(LOC15 == ((NI) 0))) goto LA16;
				result = newrstnode_332108(((NU8) 37));
				add_332171(result, b);
			}
			goto LA13;
			LA16: ;
			{
				NimStringDesc* LOC19;
				result = newrstnode_332108(((NU8) 38));
				add_332171(result, a);
				add_332171(result, b);
				LOC19 = 0;
				LOC19 = rstnodetorefname_333067(a);
				setref_334426(p, LOC19, b);
			}
			LA13: ;
		}
		goto LA7;
		LA11: ;
		{
			if (!((*n).kind == ((NU8) 60))) goto LA21;
			(*n).kind = ((NU8) 39);
		}
		goto LA7;
		LA21: ;
		{
			result = newrstnode_332108(((NU8) 39));
			add_332171(result, n);
		}
		LA7: ;
	}
	goto LA1;
	LA5: ;
	{
		NIM_BOOL LOC25;
		LOC25 = 0;
		LOC25 = match_334727((&(*p)), (*p).idx, ((NimStringDesc*) &TMP2607));
		if (!LOC25) goto LA26;
		{
			if (!eqStrings((*p).tok->data[(NI)((*p).idx + ((NI) 1))].symbol, ((NimStringDesc*) &TMP2642))) goto LA30;
			(*n).kind = ((NU8) 56);
		}
		goto LA28;
		LA30: ;
		{
			if (!eqStrings((*p).tok->data[(NI)((*p).idx + ((NI) 1))].symbol, ((NimStringDesc*) &TMP2643))) goto LA33;
			(*n).kind = ((NU8) 61);
		}
		goto LA28;
		LA33: ;
		{
			if (!eqStrings((*p).tok->data[(NI)((*p).idx + ((NI) 1))].symbol, ((NimStringDesc*) &TMP2644))) goto LA36;
			(*n).kind = ((NU8) 58);
		}
		goto LA28;
		LA36: ;
		{
			if (!eqStrings((*p).tok->data[(NI)((*p).idx + ((NI) 1))].symbol, ((NimStringDesc*) &TMP2645))) goto LA39;
			(*n).kind = ((NU8) 57);
		}
		goto LA28;
		LA39: ;
		{
			NIM_BOOL LOC42;
			LOC42 = 0;
			LOC42 = eqStrings((*p).tok->data[(NI)((*p).idx + ((NI) 1))].symbol, ((NimStringDesc*) &TMP2646));
			if (LOC42) goto LA43;
			LOC42 = eqStrings((*p).tok->data[(NI)((*p).idx + ((NI) 1))].symbol, ((NimStringDesc*) &TMP2647));
			LA43: ;
			if (!LOC42) goto LA44;
			(*n).kind = ((NU8) 54);
		}
		goto LA28;
		LA44: ;
		{
			NIM_BOOL LOC47;
			LOC47 = 0;
			LOC47 = eqStrings((*p).tok->data[(NI)((*p).idx + ((NI) 1))].symbol, ((NimStringDesc*) &TMP2648));
			if (LOC47) goto LA48;
			LOC47 = eqStrings((*p).tok->data[(NI)((*p).idx + ((NI) 1))].symbol, ((NimStringDesc*) &TMP2649));
			LA48: ;
			if (!LOC47) goto LA49;
			(*n).kind = ((NU8) 55);
		}
		goto LA28;
		LA49: ;
		{
			Rstnode332011* LOC52;
			result = newrstnode_332108(((NU8) 53));
			(*n).kind = ((NU8) 0);
			add_332171(result, n);
			LOC52 = 0;
			LOC52 = newrstnode_332142(((NU8) 64), (*p).tok->data[(NI)((*p).idx + ((NI) 1))].symbol);
			add_332171(result, LOC52);
		}
		LA28: ;
		(*p).idx += ((NI) 3);
	}
	goto LA1;
	LA26: ;
	LA1: ;
	return result;
}

N_NIMCALL(NI, matchverbatim_335033)(Rstparser333587* p, NI start, NimStringDesc* expr) {
	NI result;
	NI j;
	result = 0;
	result = start;
	j = ((NI) 0);
	{
		while (1) {
			NIM_BOOL LOC3;
			NIM_BOOL LOC4;
			LOC3 = 0;
			LOC4 = 0;
			LOC4 = (j < (expr ? expr->Sup.len : 0));
			if (!(LOC4)) goto LA5;
			LOC4 = (result < ((*p).tok ? (*p).tok->Sup.len : 0));
			LA5: ;
			LOC3 = LOC4;
			if (!(LOC3)) goto LA6;
			LOC3 = nsuContinuesWith(expr, (*p).tok->data[result].symbol, ((NI) (j)));
			LA6: ;
			if (!LOC3) goto LA2;
			j += ((*p).tok->data[result].symbol ? (*p).tok->data[result].symbol->Sup.len : 0);
			result += ((NI) 1);
		} LA2: ;
	}
	{
		if (!(j < (expr ? expr->Sup.len : 0))) goto LA9;
		result = ((NI) 0);
	}
	LA9: ;
	return result;
}

N_NIMCALL(Rstnode332011*, parsesmiley_335079)(Rstparser333587* p) {
	Rstnode332011* result;
{	result = 0;
	{
		if (!!((((NU8)((*p).tok->data[(*p).idx].symbol->data[((NI) 0)])) == ((NU8)(58)) || ((NU8)((*p).tok->data[(*p).idx].symbol->data[((NI) 0)])) == ((NU8)(59)) || ((NU8)((*p).tok->data[(*p).idx].symbol->data[((NI) 0)])) == ((NU8)(56))))) goto LA3;
		goto BeforeRet;
	}
	LA3: ;
	{
		NimStringDesc* key_335131;
		NimStringDesc* val_335132;
		NI i_335137;
		key_335131 = 0;
		val_335132 = 0;
		i_335137 = ((NI) 0);
		{
			if (!(((NI) (i_335137)) <= ((NI) 33))) goto LA8;
			{
				while (1) {
					NI m;
					key_335131 = copyString(Smilies_333098[(i_335137)- 0].Field0);
					val_335132 = copyString(Smilies_333098[(i_335137)- 0].Field1);
					m = matchverbatim_335033((&(*p)), (*p).idx, key_335131);
					{
						NimStringDesc* LOC16;
						if (!(((NI) 0) < m)) goto LA14;
						(*p).idx = m;
						result = newrstnode_332108(((NU8) 63));
						LOC16 = 0;
						LOC16 = (*result).text; (*result).text = copyStringRC1(val_335132);
						if (LOC16) nimGCunrefNoCycle(LOC16);
						goto BeforeRet;
					}
					LA14: ;
					{
						if (!(((NI) 33) <= ((NI) (i_335137)))) goto LA19;
						goto LA10;
					}
					LA19: ;
					i_335137 += ((NI) 1);
				}
			} LA10: ;
		}
		LA8: ;
	}
	}BeforeRet: ;
	return result;
}

static N_INLINE(NI, find_335229)(NimStringDesc** a, NI aLen0, NimStringDesc* item) {
	NI result;
{	result = 0;
	{
		NimStringDesc* i_335246;
		NI i_335259;
		i_335246 = 0;
		i_335259 = ((NI) 0);
		{
			while (1) {
				if (!(i_335259 < aLen0)) goto LA3;
				i_335246 = a[i_335259];
				{
					if (!eqStrings(i_335246, item)) goto LA6;
					goto BeforeRet;
				}
				LA6: ;
				result += ((NI) 1);
				i_335259 += ((NI) 1);
			} LA3: ;
		}
	}
	result = ((NI) -1);
	}BeforeRet: ;
	return result;
}

static N_INLINE(NIM_BOOL, contains_335219)(NimStringDesc** a, NI aLen0, NimStringDesc* item) {
	NIM_BOOL result;
	NI LOC1;
{	result = 0;
	LOC1 = 0;
	LOC1 = find_335229(a, aLen0, item);
	result = (((NI) 0) <= LOC1);
	goto BeforeRet;
	}BeforeRet: ;
	return result;
}

N_NIMCALL(NIM_BOOL, isurl_335201)(Rstparser333587* p, NI i) {
	NIM_BOOL result;
	NIM_BOOL LOC1;
	NIM_BOOL LOC2;
	NIM_BOOL LOC3;
	result = 0;
	LOC1 = 0;
	LOC2 = 0;
	LOC3 = 0;
	LOC3 = eqStrings((*p).tok->data[(NI)(i + ((NI) 1))].symbol, ((NimStringDesc*) &TMP2708));
	if (!(LOC3)) goto LA4;
	LOC3 = eqStrings((*p).tok->data[(NI)(i + ((NI) 2))].symbol, ((NimStringDesc*) &TMP2709));
	LA4: ;
	LOC2 = LOC3;
	if (!(LOC2)) goto LA5;
	LOC2 = ((*p).tok->data[(NI)(i + ((NI) 3))].kind == ((NU8) 3));
	LA5: ;
	LOC1 = LOC2;
	if (!(LOC1)) goto LA6;
	LOC1 = contains_335219(TMP2710, 5, (*p).tok->data[i].symbol);
	LA6: ;
	result = LOC1;
	return result;
}

N_NIMCALL(void, parseurl_335281)(Rstparser333587* p, Rstnode332011* father) {
	{
		NIM_BOOL LOC3;
		Rstnode332011* n;
		LOC3 = 0;
		LOC3 = isurl_335201((&(*p)), (*p).idx);
		if (!LOC3) goto LA4;
		n = newrstnode_332108(((NU8) 37));
		{
			while (1) {
				Rstnode332011* LOC15;
				switch ((*p).tok->data[(*p).idx].kind) {
				case ((NU8) 3):
				case ((NU8) 4):
				case ((NU8) 6):
				{
				}
				break;
				case ((NU8) 5):
				{
					{
						if (!!(((120 &(1<<(((*p).tok->data[(NI)((*p).idx + ((NI) 1))].kind)&7)))!=0))) goto LA12;
						goto LA6;
					}
					LA12: ;
				}
				break;
				default:
				{
					goto LA6;
				}
				break;
				}
				LOC15 = 0;
				LOC15 = newleaf_334529(p);
				add_332171(n, LOC15);
				(*p).idx += ((NI) 1);
			}
		} LA6: ;
		add_332171(father, n);
	}
	goto LA1;
	LA4: ;
	{
		Rstnode332011* n;
		n = newleaf_334529(p);
		(*p).idx += ((NI) 1);
		{
			if (!eqStrings((*p).tok->data[(*p).idx].symbol, ((NimStringDesc*) &TMP2638))) goto LA19;
			n = parsepostfix_334992(p, n);
		}
		LA19: ;
		add_332171(father, n);
	}
	LA1: ;
}

N_NIMCALL(void, parseinline_335752)(Rstparser333587* p, Rstnode332011* father) {
{	switch ((*p).tok->data[(*p).idx].kind) {
	case ((NU8) 5):
	{
		{
			NIM_BOOL LOC4;
			Rstnode332011* n;
			LOC4 = 0;
			LOC4 = isinlinemarkupstart_334680((&(*p)), ((NimStringDesc*) &TMP2630));
			if (!LOC4) goto LA5;
			n = newrstnode_332108(((NU8) 59));
			parseuntil_335601(p, n, ((NimStringDesc*) &TMP2630), NIM_TRUE);
			add_332171(father, n);
		}
		goto LA2;
		LA5: ;
		{
			NIM_BOOL LOC8;
			Rstnode332011* n;
			LOC8 = 0;
			LOC8 = isinlinemarkupstart_334680((&(*p)), ((NimStringDesc*) &TMP2635));
			if (!LOC8) goto LA9;
			n = newrstnode_332108(((NU8) 58));
			parseuntil_335601(p, n, ((NimStringDesc*) &TMP2635), NIM_TRUE);
			add_332171(father, n);
		}
		goto LA2;
		LA9: ;
		{
			NIM_BOOL LOC12;
			Rstnode332011* n;
			LOC12 = 0;
			LOC12 = isinlinemarkupstart_334680((&(*p)), ((NimStringDesc*) &TMP2603));
			if (!LOC12) goto LA13;
			n = newrstnode_332108(((NU8) 57));
			parseuntil_335601(p, n, ((NimStringDesc*) &TMP2603), NIM_TRUE);
			add_332171(father, n);
		}
		goto LA2;
		LA13: ;
		{
			NIM_BOOL LOC16;
			Rstnode332011* LOC20;
			LOC16 = 0;
			LOC16 = (((*(*p).s).options &(1<<((((NU8) 3))&7)))!=0);
			if (!(LOC16)) goto LA17;
			LOC16 = eqStrings((*p).tok->data[(*p).idx].symbol, ((NimStringDesc*) &TMP2636));
			LA17: ;
			if (!LOC16) goto LA18;
			(*p).idx += ((NI) 1);
			LOC20 = 0;
			LOC20 = parsemarkdowncodeblock_335686(p);
			add_332171(father, LOC20);
		}
		goto LA2;
		LA18: ;
		{
			NIM_BOOL LOC22;
			Rstnode332011* n;
			LOC22 = 0;
			LOC22 = isinlinemarkupstart_334680((&(*p)), ((NimStringDesc*) &TMP2632));
			if (!LOC22) goto LA23;
			n = newrstnode_332108(((NU8) 61));
			parseuntil_335601(p, n, ((NimStringDesc*) &TMP2632), NIM_FALSE);
			add_332171(father, n);
		}
		goto LA2;
		LA23: ;
		{
			NIM_BOOL LOC26;
			Rstnode332011* n;
			LOC26 = 0;
			LOC26 = isinlinemarkupstart_334680((&(*p)), ((NimStringDesc*) &TMP2637));
			if (!LOC26) goto LA27;
			n = newrstnode_332108(((NU8) 60));
			parseuntil_335601(p, n, ((NimStringDesc*) &TMP2637), NIM_TRUE);
			n = parsepostfix_334992(p, n);
			add_332171(father, n);
		}
		goto LA2;
		LA27: ;
		{
			NIM_BOOL LOC30;
			Rstnode332011* n;
			LOC30 = 0;
			LOC30 = isinlinemarkupstart_334680((&(*p)), ((NimStringDesc*) &TMP2605));
			if (!LOC30) goto LA31;
			n = newrstnode_332108(((NU8) 62));
			parseuntil_335601(p, n, ((NimStringDesc*) &TMP2605), NIM_FALSE);
			add_332171(father, n);
		}
		goto LA2;
		LA31: ;
		{
			{
				Rstnode332011* n;
				if (!(((*(*p).s).options &(1<<((((NU8) 1))&7)))!=0)) goto LA36;
				n = parsesmiley_335079(p);
				{
					if (!!((n == NIM_NIL))) goto LA40;
					add_332171(father, n);
					goto BeforeRet;
				}
				LA40: ;
			}
			LA36: ;
			parsebackslash_335330(p, father);
		}
		LA2: ;
	}
	break;
	case ((NU8) 3):
	{
		{
			Rstnode332011* n;
			if (!(((*(*p).s).options &(1<<((((NU8) 1))&7)))!=0)) goto LA45;
			n = parsesmiley_335079(p);
			{
				if (!!((n == NIM_NIL))) goto LA49;
				add_332171(father, n);
				goto BeforeRet;
			}
			LA49: ;
		}
		LA45: ;
		parseurl_335281(p, father);
	}
	break;
	case ((NU8) 4):
	case ((NU8) 6):
	case ((NU8) 2):
	{
		Rstnode332011* LOC60;
		{
			Rstnode332011* n;
			if (!(((*(*p).s).options &(1<<((((NU8) 1))&7)))!=0)) goto LA54;
			n = parsesmiley_335079(p);
			{
				if (!!((n == NIM_NIL))) goto LA58;
				add_332171(father, n);
				goto BeforeRet;
			}
			LA58: ;
		}
		LA54: ;
		LOC60 = 0;
		LOC60 = newleaf_334529(p);
		add_332171(father, LOC60);
		(*p).idx += ((NI) 1);
	}
	break;
	default:
	{
	}
	break;
	}
	}BeforeRet: ;
}

N_NIMCALL(void, parseline_336181)(Rstparser333587* p, Rstnode332011* father) {
	{
		while (1) {
			switch ((*p).tok->data[(*p).idx].kind) {
			case ((NU8) 2):
			case ((NU8) 3):
			case ((NU8) 6):
			case ((NU8) 5):
			{
				parseinline_335752(p, father);
			}
			break;
			default:
			{
				goto LA1;
			}
			break;
			}
		}
	} LA1: ;
}

N_NIMCALL(Rstnode332011*, parsefield_336225)(Rstparser333587* p) {
	Rstnode332011* result;
	NI col;
	Rstnode332011* fieldname;
	Rstnode332011* fieldbody;
	result = 0;
	result = newrstnode_332108(((NU8) 14));
	col = (*p).tok->data[(*p).idx].col;
	fieldname = newrstnode_332108(((NU8) 15));
	parseuntil_335601(p, fieldname, ((NimStringDesc*) &TMP2708), NIM_FALSE);
	fieldbody = newrstnode_332108(((NU8) 16));
	{
		if (!!(((*p).tok->data[(*p).idx].kind == ((NU8) 1)))) goto LA3;
		parseline_336181(p, fieldbody);
	}
	LA3: ;
	{
		NI indent;
		if (!((*p).tok->data[(*p).idx].kind == ((NU8) 1))) goto LA7;
		indent = (*p).tok->data[(*p).idx].ival;
		{
			if (!(col < indent)) goto LA11;
			pushind_334011(p, indent);
			parsesection_336217(p, fieldbody);
			popind_334032(p);
		}
		LA11: ;
	}
	LA7: ;
	add_332171(result, fieldname);
	add_332171(result, fieldbody);
	return result;
}

N_NIMCALL(Rstnode332011*, parsefields_336258)(Rstparser333587* p) {
	Rstnode332011* result;
	NIM_BOOL atstart;
	NIM_BOOL LOC1;
	result = 0;
	result = NIM_NIL;
	LOC1 = 0;
	LOC1 = ((*p).idx == ((NI) 0));
	if (!(LOC1)) goto LA2;
	LOC1 = eqStrings((*p).tok->data[((NI) 0)].symbol, ((NimStringDesc*) &TMP2708));
	LA2: ;
	atstart = LOC1;
	{
		NIM_BOOL LOC5;
		NIM_BOOL LOC6;
		NI col;
		LOC5 = 0;
		LOC6 = 0;
		LOC6 = ((*p).tok->data[(*p).idx].kind == ((NU8) 1));
		if (!(LOC6)) goto LA7;
		LOC6 = eqStrings((*p).tok->data[(NI)((*p).idx + ((NI) 1))].symbol, ((NimStringDesc*) &TMP2708));
		LA7: ;
		LOC5 = LOC6;
		if (LOC5) goto LA8;
		LOC5 = atstart;
		LA8: ;
		if (!LOC5) goto LA9;
		{
			if (!atstart) goto LA13;
			col = (*p).tok->data[(*p).idx].col;
		}
		goto LA11;
		LA13: ;
		{
			col = (*p).tok->data[(*p).idx].ival;
		}
		LA11: ;
		result = newrstnode_332108(((NU8) 13));
		{
			if (!!(atstart)) goto LA18;
			(*p).idx += ((NI) 1);
		}
		LA18: ;
		{
			while (1) {
				Rstnode332011* LOC22;
				LOC22 = 0;
				LOC22 = parsefield_336225(p);
				add_332171(result, LOC22);
				{
					NIM_BOOL LOC25;
					NIM_BOOL LOC26;
					LOC25 = 0;
					LOC26 = 0;
					LOC26 = ((*p).tok->data[(*p).idx].kind == ((NU8) 1));
					if (!(LOC26)) goto LA27;
					LOC26 = ((*p).tok->data[(*p).idx].ival == col);
					LA27: ;
					LOC25 = LOC26;
					if (!(LOC25)) goto LA28;
					LOC25 = eqStrings((*p).tok->data[(NI)((*p).idx + ((NI) 1))].symbol, ((NimStringDesc*) &TMP2708));
					LA28: ;
					if (!LOC25) goto LA29;
					(*p).idx += ((NI) 1);
				}
				goto LA23;
				LA29: ;
				{
					goto LA20;
				}
				LA23: ;
			}
		} LA20: ;
	}
	LA9: ;
	return result;
}

N_NIMCALL(Rstnode332011*, parsedirective_339229)(Rstparser333587* p, NU8 flags) {
	Rstnode332011* result;
	Rstnode332011* args;
	Rstnode332011* options;
	result = 0;
	result = newrstnode_332108(((NU8) 40));
	args = NIM_NIL;
	options = NIM_NIL;
	{
		if (!((flags &(1<<((((NU8) 0))&7)))!=0)) goto LA3;
		args = newrstnode_332108(((NU8) 41));
		{
			if (!((flags &(1<<((((NU8) 2))&7)))!=0)) goto LA7;
			{
				while (1) {
					switch ((*p).tok->data[(*p).idx].kind) {
					case ((NU8) 3):
					case ((NU8) 6):
					case ((NU8) 5):
					case ((NU8) 4):
					{
						Rstnode332011* LOC12;
						LOC12 = 0;
						LOC12 = newleaf_334529(p);
						add_332171(args, LOC12);
						(*p).idx += ((NI) 1);
					}
					break;
					default:
					{
						goto LA9;
					}
					break;
					}
				}
			} LA9: ;
		}
		goto LA5;
		LA7: ;
		{
			if (!((flags &(1<<((((NU8) 3))&7)))!=0)) goto LA15;
			{
				while (1) {
					if (!((*p).tok->data[(*p).idx].kind == ((NU8) 2))) goto LA18;
					(*p).idx += ((NI) 1);
				} LA18: ;
			}
			{
				Rstnode332011* LOC23;
				if (!((*p).tok->data[(*p).idx].kind == ((NU8) 3))) goto LA21;
				LOC23 = 0;
				LOC23 = newleaf_334529(p);
				add_332171(args, LOC23);
				(*p).idx += ((NI) 1);
			}
			goto LA19;
			LA21: ;
			{
				args = NIM_NIL;
			}
			LA19: ;
		}
		goto LA5;
		LA15: ;
		{
			parseline_336181(p, args);
		}
		LA5: ;
	}
	LA3: ;
	add_332171(result, args);
	{
		if (!((flags &(1<<((((NU8) 1))&7)))!=0)) goto LA28;
		{
			NIM_BOOL LOC32;
			NIM_BOOL LOC33;
			LOC32 = 0;
			LOC33 = 0;
			LOC33 = ((*p).tok->data[(*p).idx].kind == ((NU8) 1));
			if (!(LOC33)) goto LA34;
			LOC33 = (((NI) 3) <= (*p).tok->data[(*p).idx].ival);
			LA34: ;
			LOC32 = LOC33;
			if (!(LOC32)) goto LA35;
			LOC32 = eqStrings((*p).tok->data[(NI)((*p).idx + ((NI) 1))].symbol, ((NimStringDesc*) &TMP2708));
			LA35: ;
			if (!LOC32) goto LA36;
			options = parsefields_336258(p);
		}
		LA36: ;
	}
	LA28: ;
	add_332171(result, options);
	return result;
}

N_NIMCALL(NIM_BOOL, indfollows_339353)(Rstparser333587* p) {
	NIM_BOOL result;
	NIM_BOOL LOC1;
	NI LOC3;
	result = 0;
	LOC1 = 0;
	LOC1 = ((*p).tok->data[(*p).idx].kind == ((NU8) 1));
	if (!(LOC1)) goto LA2;
	LOC3 = 0;
	LOC3 = currind_334001(p);
	LOC1 = (LOC3 < (*p).tok->data[(*p).idx].ival);
	LA2: ;
	result = LOC1;
	return result;
}

N_NIMCALL(Rstnode332011*, parsedirective_339372)(Rstparser333587* p, NU8 flags, Sectionparser339212 contentparser) {
	Rstnode332011* result;
	result = 0;
	result = parsedirective_339229(p, flags);
	{
		NIM_BOOL LOC3;
		Rstnode332011* content;
		LOC3 = 0;
		LOC3 = !(contentparser == 0);
		if (!(LOC3)) goto LA4;
		LOC3 = indfollows_339353((&(*p)));
		LA4: ;
		if (!LOC3) goto LA5;
		pushind_334011(p, (*p).tok->data[(*p).idx].ival);
		content = contentparser(p);
		popind_334032(p);
		add_332171(result, content);
	}
	goto LA1;
	LA5: ;
	{
		add_332171(result, NIM_NIL);
	}
	LA1: ;
	return result;
}

N_NIMCALL(Rstnode332011*, dirinclude_339405)(Rstparser333587* p) {
	Rstnode332011* result;
	Rstnode332011* n;
	NimStringDesc* filename;
	NimStringDesc* LOC1;
	NimStringDesc* path;
	result = 0;
	result = NIM_NIL;
	n = parsedirective_339372(p, 7, NIM_NIL);
	LOC1 = 0;
	LOC1 = addnodes_333073((*n).sons->data[((NI) 0)]);
	filename = nsuStrip(LOC1, NIM_TRUE, NIM_TRUE, TMP2316);
	path = (*(*p).s).findfile(filename);
	{
		if (!((path) && (path)->Sup.len == 0)) goto LA4;
		rstmessage_333943((&(*p)), ((NU8) 0), filename);
	}
	goto LA2;
	LA4: ;
	{
		{
			NimStringDesc* LOC9;
			NimStringDesc* LOC12;
			Rstnode332011* LOC13;
			LOC9 = 0;
			LOC9 = getfieldvalue_333079(n, ((NimStringDesc*) &TMP2643));
			if (!!(((LOC9) && (LOC9)->Sup.len == 0))) goto LA10;
			result = newrstnode_332108(((NU8) 24));
			LOC12 = 0;
			LOC12 = readfile_16872(path);
			LOC13 = 0;
			LOC13 = newrstnode_332142(((NU8) 64), LOC12);
			add_332171(result, LOC13);
		}
		goto LA7;
		LA10: ;
		{
			Rstparser333587 q;
			NimStringDesc* LOC15;
			NI LOC16;
			memset((void*)(&q), 0, sizeof(q));
			q.Sup.m_type = (&NTI333587);
			initparser_334068((&q), (*p).s);
			q.filename = copyString(filename);
			LOC15 = 0;
			LOC15 = readfile_16872(path);
			LOC16 = 0;
			LOC16 = gettokens_333429(LOC15, NIM_FALSE, (&q.tok));
			q.col += LOC16;
			result = parsedoc_338069((&q));
		}
		LA7: ;
	}
	LA2: ;
	return result;
}

N_NIMCALL(Rstnode332011*, dirimage_340007)(Rstparser333587* p) {
	Rstnode332011* result;
	result = 0;
	result = parsedirective_339372(p, 7, NIM_NIL);
	(*result).kind = ((NU8) 45);
	return result;
}

N_NIMCALL(Rstnode332011*, dirfigure_340019)(Rstparser333587* p) {
	Rstnode332011* result;
	result = 0;
	result = parsedirective_339372(p, 7, parsesectionwrapper_339109);
	(*result).kind = ((NU8) 46);
	return result;
}

N_NIMCALL(Rstnode332011*, dirtitle_340031)(Rstparser333587* p) {
	Rstnode332011* result;
	result = 0;
	result = parsedirective_339372(p, 1, NIM_NIL);
	(*result).kind = ((NU8) 43);
	return result;
}

N_NIMCALL(Rstnode332011*, dircontainer_339608)(Rstparser333587* p) {
	Rstnode332011* result;
	result = 0;
	result = parsedirective_339372(p, 1, parsesectionwrapper_339109);
	(*result).kind = ((NU8) 50);
	return result;
}

N_NIMCALL(Rstnode332011*, dircontents_340043)(Rstparser333587* p) {
	Rstnode332011* result;
	result = 0;
	result = parsedirective_339372(p, 1, NIM_NIL);
	(*result).kind = ((NU8) 44);
	return result;
}

N_NIMCALL(Rstnode332011*, parsedirbody_339393)(Rstparser333587* p, Sectionparser339212 contentparser) {
	Rstnode332011* result;
	result = 0;
	{
		NIM_BOOL LOC3;
		LOC3 = 0;
		LOC3 = indfollows_339353((&(*p)));
		if (!LOC3) goto LA4;
		pushind_334011(p, (*p).tok->data[(*p).idx].ival);
		result = contentparser(p);
		popind_334032(p);
	}
	LA4: ;
	return result;
}

N_NIMCALL(void, dirrawaux_340068)(Rstparser333587* p, Rstnode332011** result, NU8 kind, Sectionparser339212 contentparser) {
	NimStringDesc* filename;
	filename = getfieldvalue_333079((*result), ((NimStringDesc*) &TMP2715));
	{
		NimStringDesc* path;
		if (!(((NI) 0) < (filename ? filename->Sup.len : 0))) goto LA3;
		path = (*(*p).s).findfile(filename);
		{
			if (!((path ? path->Sup.len : 0) == ((NI) 0))) goto LA7;
			rstmessage_333943((&(*p)), ((NU8) 0), filename);
		}
		goto LA5;
		LA7: ;
		{
			NimStringDesc* f;
			Rstnode332011* LOC10;
			f = readfile_16872(path);
			unsureAsgnRef((void**) (&(*result)), newrstnode_332108(kind));
			LOC10 = 0;
			LOC10 = newrstnode_332142(((NU8) 64), f);
			add_332171((*result), LOC10);
		}
		LA5: ;
	}
	goto LA1;
	LA3: ;
	{
		Rstnode332011* LOC12;
		(*(*result)).kind = kind;
		LOC12 = 0;
		LOC12 = parsedirbody_339393(p, contentparser);
		add_332171((*result), LOC12);
	}
	LA1: ;
}

N_NIMCALL(Rstnode332011*, dirraw_340085)(Rstparser333587* p) {
	Rstnode332011* result;
	result = 0;
	result = parsedirective_339229(p, 11);
	{
		if (!!(((*result).sons->data[((NI) 0)] == NIM_NIL))) goto LA3;
		{
			NI LOC7;
			LOC7 = 0;
			LOC7 = nsuCmpIgnoreCase((*(*(*result).sons->data[((NI) 0)]).sons->data[((NI) 0)]).text, ((NimStringDesc*) &TMP2716));
			if (!(LOC7 == ((NI) 0))) goto LA8;
			dirrawaux_340068(p, &result, ((NU8) 48), parseliteralblock_337099);
		}
		goto LA5;
		LA8: ;
		{
			NI LOC11;
			LOC11 = 0;
			LOC11 = nsuCmpIgnoreCase((*(*(*result).sons->data[((NI) 0)]).sons->data[((NI) 0)]).text, ((NimStringDesc*) &TMP2717));
			if (!(LOC11 == ((NI) 0))) goto LA12;
			dirrawaux_340068(p, &result, ((NU8) 49), parseliteralblock_337099);
		}
		goto LA5;
		LA12: ;
		{
			rstmessage_333943((&(*p)), ((NU8) 5), (*(*(*result).sons->data[((NI) 0)]).sons->data[((NI) 0)]).text);
		}
		LA5: ;
	}
	goto LA1;
	LA3: ;
	{
		dirrawaux_340068(p, &result, ((NU8) 42), parsesectionwrapper_339109);
	}
	LA1: ;
	return result;
}

N_NIMCALL(Rstnode332011*, dircodeblock_339434)(Rstparser333587* p, NIM_BOOL nimrodextension) {
	Rstnode332011* result;
	NimStringDesc* filename;
	NimStringDesc* LOC1;
	result = 0;
	result = parsedirective_339372(p, 3, parseliteralblock_337099);
	LOC1 = 0;
	LOC1 = getfieldvalue_333079(result, ((NimStringDesc*) &TMP2715));
	filename = nsuStrip(LOC1, NIM_TRUE, NIM_TRUE, TMP2316);
	{
		NimStringDesc* path;
		Rstnode332011* n;
		NimStringDesc* LOC10;
		Rstnode332011* LOC11;
		if (!!(((filename) && (filename)->Sup.len == 0))) goto LA4;
		path = (*(*p).s).findfile(filename);
		{
			if (!((path) && (path)->Sup.len == 0)) goto LA8;
			rstmessage_333943((&(*p)), ((NU8) 0), filename);
		}
		LA8: ;
		n = newrstnode_332108(((NU8) 24));
		LOC10 = 0;
		LOC10 = readfile_16872(path);
		LOC11 = 0;
		LOC11 = newrstnode_332142(((NU8) 64), LOC10);
		add_332171(n, LOC11);
		asgnRefNoCycle((void**) (&(*result).sons->data[((NI) 2)]), n);
	}
	LA4: ;
	{
		Rstnode332011* extranode;
		Rstnode332011* LOC20;
		Rstnode332011* LOC21;
		Rstnode332011* LOC22;
		Rstnode332011* LOC23;
		if (!nimrodextension) goto LA14;
		{
			if (!(*result).sons->data[((NI) 1)] == 0) goto LA18;
			asgnRefNoCycle((void**) (&(*result).sons->data[((NI) 1)]), newrstnode_332108(((NU8) 13)));
		}
		LA18: ;
		extranode = newrstnode_332108(((NU8) 14));
		LOC20 = 0;
		LOC20 = newrstnode_332108(((NU8) 15));
		add_332171(extranode, LOC20);
		LOC21 = 0;
		LOC21 = newrstnode_332108(((NU8) 16));
		add_332171(extranode, LOC21);
		LOC22 = 0;
		LOC22 = newrstnode_332142(((NU8) 64), ((NimStringDesc*) &TMP2718));
		add_332171((*extranode).sons->data[((NI) 0)], LOC22);
		LOC23 = 0;
		LOC23 = newrstnode_332142(((NU8) 64), ((NimStringDesc*) &TMP2719));
		add_332171((*extranode).sons->data[((NI) 1)], LOC23);
		add_332171((*result).sons->data[((NI) 1)], extranode);
	}
	LA14: ;
	(*result).kind = ((NU8) 47);
	return result;
}

N_NIMCALL(Rstnode332011*, dirindex_340055)(Rstparser333587* p) {
	Rstnode332011* result;
	result = 0;
	result = parsedirective_339372(p, 0, parsesectionwrapper_339109);
	(*result).kind = ((NU8) 51);
	return result;
}

N_NIMCALL(Rstnode332011*, getreferencename_334540)(Rstparser333587* p, NimStringDesc* endstr) {
	Rstnode332011* result;
	Rstnode332011* res;
	result = 0;
	res = newrstnode_332108(((NU8) 0));
	{
		while (1) {
			switch ((*p).tok->data[(*p).idx].kind) {
			case ((NU8) 3):
			case ((NU8) 6):
			case ((NU8) 2):
			{
				Rstnode332011* LOC4;
				LOC4 = 0;
				LOC4 = newleaf_334529(p);
				add_332171(res, LOC4);
			}
			break;
			case ((NU8) 5):
			{
				{
					if (!eqStrings((*p).tok->data[(*p).idx].symbol, endstr)) goto LA8;
					(*p).idx += ((NI) 1);
					goto LA1;
				}
				goto LA6;
				LA8: ;
				{
					Rstnode332011* LOC11;
					LOC11 = 0;
					LOC11 = newleaf_334529(p);
					add_332171(res, LOC11);
				}
				LA6: ;
			}
			break;
			default:
			{
				rstmessage_333943((&(*p)), ((NU8) 1), endstr);
				goto LA1;
			}
			break;
			}
			(*p).idx += ((NI) 1);
		}
	} LA1: ;
	result = res;
	return result;
}

N_NIMCALL(Rstnode332011*, untileol_334578)(Rstparser333587* p) {
	Rstnode332011* result;
	result = 0;
	result = newrstnode_332108(((NU8) 0));
	{
		while (1) {
			Rstnode332011* LOC3;
			if (!!(((3 &(1<<(((*p).tok->data[(*p).idx].kind)&7)))!=0))) goto LA2;
			LOC3 = 0;
			LOC3 = newleaf_334529(p);
			add_332171(result, LOC3);
			(*p).idx += ((NI) 1);
		} LA2: ;
	}
	return result;
}

N_NIMCALL(void, expect_334616)(Rstparser333587* p, NimStringDesc* tok) {
	{
		if (!eqStrings((*p).tok->data[(*p).idx].symbol, tok)) goto LA3;
		(*p).idx += ((NI) 1);
	}
	goto LA1;
	LA3: ;
	{
		rstmessage_333943((&(*p)), ((NU8) 1), tok);
	}
	LA1: ;
}

N_NIMCALL(void, setsub_334365)(Rstparser333587* p, NimStringDesc* key, Rstnode332011* value) {
	NI length;
	NimStringDesc* LOC8;
{	length = ((*(*p).s).subs ? (*(*p).s).subs->Sup.len : 0);
	{
		NI i_334392;
		NI HEX3Atmp_334404;
		NI res_334407;
		i_334392 = 0;
		HEX3Atmp_334404 = 0;
		HEX3Atmp_334404 = (NI)(length - ((NI) 1));
		res_334407 = ((NI) 0);
		{
			while (1) {
				if (!(res_334407 <= HEX3Atmp_334404)) goto LA3;
				i_334392 = res_334407;
				{
					if (!eqStrings(key, (*(*p).s).subs->data[i_334392].key)) goto LA6;
					asgnRefNoCycle((void**) (&(*(*p).s).subs->data[i_334392].value), value);
					goto BeforeRet;
				}
				LA6: ;
				res_334407 += ((NI) 1);
			} LA3: ;
		}
	}
	(*(*p).s).subs = (TY333597*) setLengthSeq(&((*(*p).s).subs)->Sup, sizeof(Substitution333581), ((NI) ((NI)(length + ((NI) 1)))));
	LOC8 = 0;
	LOC8 = (*(*p).s).subs->data[length].key; (*(*p).s).subs->data[length].key = copyStringRC1(key);
	if (LOC8) nimGCunrefNoCycle(LOC8);
	asgnRefNoCycle((void**) (&(*(*p).s).subs->data[length].value), value);
	}BeforeRet: ;
}

N_NIMCALL(Rstnode332011*, parsecomment_335986)(Rstparser333587* p) {
	Rstnode332011* result;
	result = 0;
	switch ((*p).tok->data[(*p).idx].kind) {
	case ((NU8) 1):
	case ((NU8) 0):
	{
		{
			NIM_BOOL LOC4;
			LOC4 = 0;
			LOC4 = !(((*p).tok->data[(*p).idx].kind == ((NU8) 0)));
			if (!(LOC4)) goto LA5;
			LOC4 = ((*p).tok->data[(NI)((*p).idx + ((NI) 1))].kind == ((NU8) 1));
			LA5: ;
			if (!LOC4) goto LA6;
			(*p).idx += ((NI) 1);
		}
		goto LA2;
		LA6: ;
		{
			NI indent;
			indent = (*p).tok->data[(*p).idx].ival;
			{
				while (1) {
					switch ((*p).tok->data[(*p).idx].kind) {
					case ((NU8) 0):
					{
						goto LA9;
					}
					break;
					case ((NU8) 1):
					{
						{
							if (!((*p).tok->data[(*p).idx].ival < indent)) goto LA15;
							goto LA9;
						}
						LA15: ;
					}
					break;
					default:
					{
					}
					break;
					}
					(*p).idx += ((NI) 1);
				}
			} LA9: ;
		}
		LA2: ;
	}
	break;
	default:
	{
		{
			while (1) {
				if (!!(((3 &(1<<(((*p).tok->data[(*p).idx].kind)&7)))!=0))) goto LA20;
				(*p).idx += ((NI) 1);
			} LA20: ;
		}
	}
	break;
	}
	result = NIM_NIL;
	return result;
}

N_NIMCALL(Rstnode332011*, parsedotdot_337092)(Rstparser333587* p) {
	Rstnode332011* result;
	NI col;
	NimStringDesc* d;
	result = 0;
	result = NIM_NIL;
	col = (*p).tok->data[(*p).idx].col;
	(*p).idx += ((NI) 1);
	d = getdirective_335866(p);
	{
		NU8 LOC5;
		if (!!(((d) && (d)->Sup.len == 0))) goto LA3;
		pushind_334011(p, col);
		LOC5 = 0;
		LOC5 = getdirkind_336098(d);
		switch (LOC5) {
		case ((NU8) 9):
		{
			result = dirinclude_339405(p);
		}
		break;
		case ((NU8) 8):
		{
			result = dirimage_340007(p);
		}
		break;
		case ((NU8) 7):
		{
			result = dirfigure_340019(p);
		}
		break;
		case ((NU8) 12):
		{
			result = dirtitle_340031(p);
		}
		break;
		case ((NU8) 5):
		{
			result = dircontainer_339608(p);
		}
		break;
		case ((NU8) 6):
		{
			result = dircontents_340043(p);
		}
		break;
		case ((NU8) 11):
		{
			{
				if (!(((*(*p).s).options &(1<<((((NU8) 2))&7)))!=0)) goto LA15;
				result = dirraw_340085(p);
			}
			goto LA13;
			LA15: ;
			{
				rstmessage_333943((&(*p)), ((NU8) 5), d);
			}
			LA13: ;
		}
		break;
		case ((NU8) 3):
		{
			result = dircodeblock_339434(p, NIM_FALSE);
		}
		break;
		case ((NU8) 4):
		{
			result = dircodeblock_339434(p, NIM_TRUE);
		}
		break;
		case ((NU8) 10):
		{
			result = dirindex_340055(p);
		}
		break;
		default:
		{
			rstmessage_333943((&(*p)), ((NU8) 5), d);
		}
		break;
		}
		popind_334032(p);
	}
	goto LA1;
	LA3: ;
	{
		NIM_BOOL LOC23;
		Rstnode332011* a;
		Rstnode332011* b;
		NimStringDesc* LOC30;
		LOC23 = 0;
		LOC23 = match_334727((&(*p)), (*p).idx, ((NimStringDesc*) &TMP2720));
		if (!LOC23) goto LA24;
		(*p).idx += ((NI) 2);
		a = getreferencename_334540(p, ((NimStringDesc*) &TMP2708));
		{
			if (!((*p).tok->data[(*p).idx].kind == ((NU8) 2))) goto LA28;
			(*p).idx += ((NI) 1);
		}
		LA28: ;
		b = untileol_334578(p);
		LOC30 = 0;
		LOC30 = rstnodetorefname_333067(a);
		setref_334426(p, LOC30, b);
	}
	goto LA1;
	LA24: ;
	{
		NIM_BOOL LOC32;
		Rstnode332011* a;
		Rstnode332011* b;
		NimStringDesc* LOC49;
		LOC32 = 0;
		LOC32 = match_334727((&(*p)), (*p).idx, ((NimStringDesc*) &TMP2721));
		if (!LOC32) goto LA33;
		(*p).idx += ((NI) 2);
		a = getreferencename_334540(p, ((NimStringDesc*) &TMP2605));
		b = 0;
		{
			if (!((*p).tok->data[(*p).idx].kind == ((NU8) 2))) goto LA37;
			(*p).idx += ((NI) 1);
		}
		LA37: ;
		{
			NI LOC41;
			LOC41 = 0;
			LOC41 = nsuCmpIgnoreStyle((*p).tok->data[(*p).idx].symbol, ((NimStringDesc*) &TMP2722));
			if (!(LOC41 == ((NI) 0))) goto LA42;
			(*p).idx += ((NI) 1);
			expect_334616(p, ((NimStringDesc*) &TMP2601));
			b = untileol_334578(p);
		}
		goto LA39;
		LA42: ;
		{
			NI LOC45;
			LOC45 = 0;
			LOC45 = nsuCmpIgnoreStyle((*p).tok->data[(*p).idx].symbol, ((NimStringDesc*) &TMP2623));
			if (!(LOC45 == ((NI) 0))) goto LA46;
			(*p).idx += ((NI) 1);
			b = dirimage_340007(p);
		}
		goto LA39;
		LA46: ;
		{
			rstmessage_333943((&(*p)), ((NU8) 5), (*p).tok->data[(*p).idx].symbol);
		}
		LA39: ;
		LOC49 = 0;
		LOC49 = addnodes_333073(a);
		setsub_334365(p, LOC49, b);
	}
	goto LA1;
	LA33: ;
	{
		NIM_BOOL LOC51;
		Rstnode332011* a;
		Rstnode332011* b;
		NimStringDesc* LOC58;
		LOC51 = 0;
		LOC51 = match_334727((&(*p)), (*p).idx, ((NimStringDesc*) &TMP2723));
		if (!LOC51) goto LA52;
		(*p).idx += ((NI) 2);
		a = getreferencename_334540(p, ((NimStringDesc*) &TMP2724));
		{
			if (!((*p).tok->data[(*p).idx].kind == ((NU8) 2))) goto LA56;
			(*p).idx += ((NI) 1);
		}
		LA56: ;
		b = untileol_334578(p);
		LOC58 = 0;
		LOC58 = rstnodetorefname_333067(a);
		setref_334426(p, LOC58, b);
	}
	goto LA1;
	LA52: ;
	{
		result = parsecomment_335986(p);
	}
	LA1: ;
	return result;
}

N_NIMCALL(Rstnode332011*, parseenumlist_338822)(Rstparser333587* p) {
	Rstnode332011* result;
	NI w;
	result = 0;
	result = NIM_NIL;
	w = ((NI) 0);
	{
		while (1) {
			if (!(w <= ((NI) 2))) goto LA2;
			{
				NIM_BOOL LOC5;
				LOC5 = 0;
				LOC5 = match_334727((&(*p)), (*p).idx, wildcards_338827[(w)- 0]);
				if (!LOC5) goto LA6;
				goto LA1;
			}
			LA6: ;
			w += ((NI) 1);
		} LA2: ;
	} LA1: ;
	{
		NI col;
		NI j;
		if (!(w <= ((NI) 2))) goto LA10;
		col = (*p).tok->data[(*p).idx].col;
		result = newrstnode_332108(((NU8) 7));
		(*p).idx += (NI)(wildpos_338832[(w)- 0] + ((NI) 3));
		j = tokenafternewline_337205((&(*p)));
		{
			NIM_BOOL LOC14;
			LOC14 = 0;
			LOC14 = ((*p).tok->data[j].col == (*p).tok->data[(*p).idx].col);
			if (LOC14) goto LA15;
			LOC14 = match_334727((&(*p)), j, wildcards_338827[(w)- 0]);
			LA15: ;
			if (!LOC14) goto LA16;
			pushind_334011(p, (*p).tok->data[(*p).idx].col);
			{
				while (1) {
					Rstnode332011* item;
					item = newrstnode_332108(((NU8) 8));
					parsesection_336217(p, item);
					add_332171(result, item);
					{
						NIM_BOOL LOC22;
						NIM_BOOL LOC23;
						LOC22 = 0;
						LOC23 = 0;
						LOC23 = ((*p).tok->data[(*p).idx].kind == ((NU8) 1));
						if (!(LOC23)) goto LA24;
						LOC23 = ((*p).tok->data[(*p).idx].ival == col);
						LA24: ;
						LOC22 = LOC23;
						if (!(LOC22)) goto LA25;
						LOC22 = match_334727((&(*p)), (NI)((*p).idx + ((NI) 1)), wildcards_338827[(w)- 0]);
						LA25: ;
						if (!LOC22) goto LA26;
						(*p).idx += (NI)(wildpos_338832[(w)- 0] + ((NI) 4));
					}
					goto LA20;
					LA26: ;
					{
						goto LA18;
					}
					LA20: ;
				}
			} LA18: ;
			popind_334032(p);
		}
		goto LA12;
		LA16: ;
		{
			(*p).idx -= (NI)(wildpos_338832[(w)- 0] + ((NI) 3));
			result = NIM_NIL;
		}
		LA12: ;
	}
	LA10: ;
	return result;
}

N_NIMCALL(Rstnode332011*, parsedefinitionlist_338734)(Rstparser333587* p) {
	Rstnode332011* result;
	NI j;
	NI LOC1;
	result = 0;
	result = NIM_NIL;
	LOC1 = 0;
	LOC1 = tokenafternewline_337205((&(*p)));
	j = (NI)(LOC1 - ((NI) 1));
	{
		NIM_BOOL LOC4;
		NIM_BOOL LOC5;
		NIM_BOOL LOC6;
		NI LOC9;
		NI col;
		LOC4 = 0;
		LOC5 = 0;
		LOC6 = 0;
		LOC6 = (((NI) 1) <= j);
		if (!(LOC6)) goto LA7;
		LOC6 = ((*p).tok->data[j].kind == ((NU8) 1));
		LA7: ;
		LOC5 = LOC6;
		if (!(LOC5)) goto LA8;
		LOC9 = 0;
		LOC9 = currind_334001((&(*p)));
		LOC5 = (LOC9 < (*p).tok->data[j].ival);
		LA8: ;
		LOC4 = LOC5;
		if (!(LOC4)) goto LA10;
		LOC4 = !(eqStrings((*p).tok->data[(NI)(j - ((NI) 1))].symbol, ((NimStringDesc*) &TMP2601)));
		LA10: ;
		if (!LOC4) goto LA11;
		col = (*p).tok->data[(*p).idx].col;
		result = newrstnode_332108(((NU8) 9));
		{
			while (1) {
				Rstnode332011* a;
				j = (*p).idx;
				a = newrstnode_332108(((NU8) 11));
				parseline_336181(p, a);
				{
					NIM_BOOL LOC17;
					NIM_BOOL LOC18;
					NIM_BOOL LOC19;
					NI LOC21;
					Rstnode332011* b;
					Rstnode332011* c;
					LOC17 = 0;
					LOC18 = 0;
					LOC19 = 0;
					LOC19 = ((*p).tok->data[(*p).idx].kind == ((NU8) 1));
					if (!(LOC19)) goto LA20;
					LOC21 = 0;
					LOC21 = currind_334001((&(*p)));
					LOC19 = (LOC21 < (*p).tok->data[(*p).idx].ival);
					LA20: ;
					LOC18 = LOC19;
					if (!(LOC18)) goto LA22;
					LOC18 = !(eqStrings((*p).tok->data[(NI)((*p).idx + ((NI) 1))].symbol, ((NimStringDesc*) &TMP2601)));
					LA22: ;
					LOC17 = LOC18;
					if (!(LOC17)) goto LA23;
					LOC17 = !(((3 &(1<<(((*p).tok->data[(NI)((*p).idx + ((NI) 1))].kind)&7)))!=0));
					LA23: ;
					if (!LOC17) goto LA24;
					pushind_334011(p, (*p).tok->data[(*p).idx].ival);
					b = newrstnode_332108(((NU8) 12));
					parsesection_336217(p, b);
					c = newrstnode_332108(((NU8) 10));
					add_332171(c, a);
					add_332171(c, b);
					add_332171(result, c);
					popind_334032(p);
				}
				goto LA15;
				LA24: ;
				{
					(*p).idx = j;
					goto LA13;
				}
				LA15: ;
				{
					NIM_BOOL LOC29;
					NI LOC33;
					LOC29 = 0;
					LOC29 = ((*p).tok->data[(*p).idx].kind == ((NU8) 1));
					if (!(LOC29)) goto LA30;
					LOC29 = ((*p).tok->data[(*p).idx].ival == col);
					LA30: ;
					if (!LOC29) goto LA31;
					(*p).idx += ((NI) 1);
					LOC33 = 0;
					LOC33 = tokenafternewline_337205((&(*p)));
					j = (NI)(LOC33 - ((NI) 1));
					{
						NIM_BOOL LOC36;
						NIM_BOOL LOC37;
						NIM_BOOL LOC38;
						NIM_BOOL LOC39;
						LOC36 = 0;
						LOC37 = 0;
						LOC38 = 0;
						LOC39 = 0;
						LOC39 = (((NI) 1) <= j);
						if (!(LOC39)) goto LA40;
						LOC39 = ((*p).tok->data[j].kind == ((NU8) 1));
						LA40: ;
						LOC38 = LOC39;
						if (!(LOC38)) goto LA41;
						LOC38 = (col < (*p).tok->data[j].ival);
						LA41: ;
						LOC37 = LOC38;
						if (!(LOC37)) goto LA42;
						LOC37 = !(eqStrings((*p).tok->data[(NI)(j - ((NI) 1))].symbol, ((NimStringDesc*) &TMP2601)));
						LA42: ;
						LOC36 = LOC37;
						if (!(LOC36)) goto LA43;
						LOC36 = !(((*p).tok->data[(NI)(j + ((NI) 1))].kind == ((NU8) 1)));
						LA43: ;
						if (!LOC36) goto LA44;
					}
					goto LA34;
					LA44: ;
					{
						goto LA13;
					}
					LA34: ;
				}
				LA31: ;
			}
		} LA13: ;
		{
			NI LOC49;
			LOC49 = 0;
			LOC49 = len_332090(result);
			if (!(LOC49 == ((NI) 0))) goto LA50;
			result = NIM_NIL;
		}
		LA50: ;
	}
	LA11: ;
	return result;
}

N_NIMCALL(Rstnode332011*, parsetransition_338425)(Rstparser333587* p) {
	Rstnode332011* result;
	result = 0;
	result = newrstnode_332108(((NU8) 3));
	(*p).idx += ((NI) 1);
	{
		if (!((*p).tok->data[(*p).idx].kind == ((NU8) 1))) goto LA3;
		(*p).idx += ((NI) 1);
	}
	LA3: ;
	{
		if (!((*p).tok->data[(*p).idx].kind == ((NU8) 1))) goto LA7;
		(*p).idx += ((NI) 1);
	}
	LA7: ;
	return result;
}

N_NIMCALL(void, parseuntilnewline_336199)(Rstparser333587* p, Rstnode332011* father) {
	{
		while (1) {
			switch ((*p).tok->data[(*p).idx].kind) {
			case ((NU8) 2):
			case ((NU8) 3):
			case ((NU8) 4):
			case ((NU8) 6):
			case ((NU8) 5):
			{
				parseinline_335752(p, father);
			}
			break;
			case ((NU8) 0):
			case ((NU8) 1):
			{
				goto LA1;
			}
			break;
			}
		}
	} LA1: ;
}

N_NIMCALL(NI, getlevel_337182)(NI* map, NI* lvl, NIM_CHAR c) {
	NI result;
	result = 0;
	{
		if (!(map[(((NU8)(c)))- 0] == ((NI) 0))) goto LA3;
		(*lvl) += ((NI) 1);
		map[(((NU8)(c)))- 0] = (*lvl);
	}
	LA3: ;
	result = map[(((NU8)(c)))- 0];
	return result;
}

N_NIMCALL(Rstnode332011*, parseheadline_337449)(Rstparser333587* p) {
	Rstnode332011* result;
	NIM_CHAR c;
	result = 0;
	result = newrstnode_332108(((NU8) 1));
	parseuntilnewline_336199(p, result);
	c = (*p).tok->data[(NI)((*p).idx + ((NI) 1))].symbol->data[((NI) 0)];
	(*p).idx += ((NI) 2);
	(*result).level = getlevel_337182((*(*p).s).underlinetolevel, (&(*(*p).s).ulevel), c);
	return result;
}

N_NIMCALL(Rstnode332011*, parseoverline_338481)(Rstparser333587* p) {
	Rstnode332011* result;
	NIM_CHAR c;
	result = 0;
	c = (*p).tok->data[(*p).idx].symbol->data[((NI) 0)];
	(*p).idx += ((NI) 2);
	result = newrstnode_332108(((NU8) 2));
	{
		while (1) {
			parseuntilnewline_336199(p, result);
			{
				if (!((*p).tok->data[(*p).idx].kind == ((NU8) 1))) goto LA5;
				(*p).idx += ((NI) 1);
				{
					NI LOC9;
					Rstnode332011* LOC12;
					LOC9 = 0;
					LOC9 = currind_334001((&(*p)));
					if (!(LOC9 < (*p).tok->data[(NI)((*p).idx - ((NI) 1))].ival)) goto LA10;
					LOC12 = 0;
					LOC12 = newrstnode_332142(((NU8) 64), ((NimStringDesc*) &TMP2634));
					add_332171(result, LOC12);
				}
				goto LA7;
				LA10: ;
				{
					goto LA1;
				}
				LA7: ;
			}
			goto LA3;
			LA5: ;
			{
				goto LA1;
			}
			LA3: ;
		}
	} LA1: ;
	(*result).level = getlevel_337182((*(*p).s).overlinetolevel, (&(*(*p).s).olevel), c);
	{
		if (!((*p).tok->data[(*p).idx].kind == ((NU8) 4))) goto LA17;
		(*p).idx += ((NI) 1);
		{
			if (!((*p).tok->data[(*p).idx].kind == ((NU8) 1))) goto LA21;
			(*p).idx += ((NI) 1);
		}
		LA21: ;
	}
	LA17: ;
	return result;
}

N_NIMCALL(NI, tokend_337828)(Rstparser333587* p) {
	NI result;
	result = 0;
	result = (NI)((NI)((*p).tok->data[(*p).idx].col + ((*p).tok->data[(*p).idx].symbol ? (*p).tok->data[(*p).idx].symbol->Sup.len : 0)) - ((NI) 1));
	return result;
}

N_NIMCALL(void, getcolumns_337838)(Rstparser333587* p, TY333608** cols) {
	NI L;
	L = ((NI) 0);
	{
		while (1) {
			L += ((NI) 1);
			(*cols) = (TY333608*) setLengthSeq(&((*cols))->Sup, sizeof(NI), ((NI) (L)));
			(*cols)->data[(NI)(L - ((NI) 1))] = tokend_337828((&(*p)));
			(*p).idx += ((NI) 1);
			{
				if (!!(((*p).tok->data[(*p).idx].kind == ((NU8) 2)))) goto LA5;
				goto LA1;
			}
			LA5: ;
			(*p).idx += ((NI) 1);
			{
				if (!!(((*p).tok->data[(*p).idx].kind == ((NU8) 4)))) goto LA9;
				goto LA1;
			}
			LA9: ;
		}
	} LA1: ;
	{
		if (!((*p).tok->data[(*p).idx].kind == ((NU8) 1))) goto LA13;
		(*p).idx += ((NI) 1);
	}
	LA13: ;
	(*cols)->data[(NI)(L - ((NI) 1))] = ((NI) 32000);
}

N_NIMCALL(Rstnode332011*, parsesimpletable_338076)(Rstparser333587* p) {
	Rstnode332011* result;
	TY333608* cols;
	TY130408* row;
	NI i;
	NI last;
	NI line;
	NIM_CHAR c;
	Rstparser333587 q;
	Rstnode332011* a;
	Rstnode332011* b;
	result = 0;
	cols = 0;
	row = 0;
	i = 0;
	last = 0;
	line = 0;
	c = 0;
	memset((void*)(&q), 0, sizeof(q));
	q.Sup.m_type = (&NTI333587);
	a = 0;
	b = 0;
	result = newrstnode_332108(((NU8) 29));
	cols = (TY333608*) newSeq((&NTI333608), 0);
	row = (TY130408*) newSeq((&NTI130408), 0);
	a = NIM_NIL;
	c = (*p).tok->data[(*p).idx].symbol->data[((NI) 0)];
	{
		while (1) {
			{
				if (!((*p).tok->data[(*p).idx].kind == ((NU8) 4))) goto LA5;
				last = tokenafternewline_337205((&(*p)));
				{
					if (!((3 &(1<<(((*p).tok->data[last].kind)&7)))!=0)) goto LA9;
					(*p).idx = last;
					goto LA1;
				}
				LA9: ;
				getcolumns_337838(p, (&cols));
				row = (TY130408*) setLengthSeq(&(row)->Sup, sizeof(NimStringDesc*), ((NI) ((cols ? cols->Sup.len : 0))));
				{
					if (!!((a == NIM_NIL))) goto LA13;
					{
						NI j_338184;
						NI HEX3Atmp_338332;
						NI LOC16;
						NI res_338335;
						j_338184 = 0;
						HEX3Atmp_338332 = 0;
						LOC16 = 0;
						LOC16 = len_332090(a);
						HEX3Atmp_338332 = (NI)(LOC16 - ((NI) 1));
						res_338335 = ((NI) 0);
						{
							while (1) {
								if (!(res_338335 <= HEX3Atmp_338332)) goto LA18;
								j_338184 = res_338335;
								(*(*a).sons->data[j_338184]).kind = ((NU8) 32);
								res_338335 += ((NI) 1);
							} LA18: ;
						}
					}
				}
				LA13: ;
			}
			LA5: ;
			{
				if (!((*p).tok->data[(*p).idx].kind == ((NU8) 0))) goto LA21;
				goto LA1;
			}
			LA21: ;
			{
				NI j_338206;
				NI HEX3Atmp_338340;
				NI res_338343;
				j_338206 = 0;
				HEX3Atmp_338340 = 0;
				HEX3Atmp_338340 = (row ? (row->Sup.len-1) : -1);
				res_338343 = ((NI) 0);
				{
					while (1) {
						NimStringDesc* LOC26;
						if (!(res_338343 <= HEX3Atmp_338340)) goto LA25;
						j_338206 = res_338343;
						LOC26 = 0;
						LOC26 = row->data[j_338206]; row->data[j_338206] = copyStringRC1(((NimStringDesc*) &TMP2205));
						if (LOC26) nimGCunrefNoCycle(LOC26);
						res_338343 += ((NI) 1);
					} LA25: ;
				}
			}
			line = (*p).tok->data[(*p).idx].line;
			{
				while (1) {
					i = ((NI) 0);
					{
						while (1) {
							if (!!(((3 &(1<<(((*p).tok->data[(*p).idx].kind)&7)))!=0))) goto LA30;
							{
								NI LOC33;
								LOC33 = 0;
								LOC33 = tokend_337828((&(*p)));
								if (!(LOC33 <= cols->data[i])) goto LA34;
								row->data[i] = resizeString(row->data[i], (*p).tok->data[(*p).idx].symbol->Sup.len + 0);
appendString(row->data[i], (*p).tok->data[(*p).idx].symbol);
								(*p).idx += ((NI) 1);
							}
							goto LA31;
							LA34: ;
							{
								{
									if (!((*p).tok->data[(*p).idx].kind == ((NU8) 2))) goto LA39;
									(*p).idx += ((NI) 1);
								}
								LA39: ;
								i += ((NI) 1);
							}
							LA31: ;
						} LA30: ;
					}
					{
						if (!((*p).tok->data[(*p).idx].kind == ((NU8) 1))) goto LA43;
						(*p).idx += ((NI) 1);
					}
					LA43: ;
					{
						NI LOC47;
						LOC47 = 0;
						LOC47 = tokend_337828((&(*p)));
						if (!(LOC47 <= cols->data[((NI) 0)])) goto LA48;
						goto LA27;
					}
					LA48: ;
					{
						if (!((17 &(1<<(((*p).tok->data[(*p).idx].kind)&7)))!=0)) goto LA52;
						goto LA27;
					}
					LA52: ;
					{
						NI j_338295;
						NI HEX3Atmp_338350;
						NI res_338353;
						j_338295 = 0;
						HEX3Atmp_338350 = 0;
						HEX3Atmp_338350 = (row ? (row->Sup.len-1) : -1);
						res_338353 = ((NI) 1);
						{
							while (1) {
								if (!(res_338353 <= HEX3Atmp_338350)) goto LA56;
								j_338295 = res_338353;
								row->data[j_338295] = addChar(row->data[j_338295], 10);
								res_338353 += ((NI) 1);
							} LA56: ;
						}
					}
				}
			} LA27: ;
			a = newrstnode_332108(((NU8) 31));
			{
				NI j_338308;
				NI HEX3Atmp_338358;
				NI res_338361;
				j_338308 = 0;
				HEX3Atmp_338358 = 0;
				HEX3Atmp_338358 = (row ? (row->Sup.len-1) : -1);
				res_338361 = ((NI) 0);
				{
					while (1) {
						NI LOC60;
						Rstnode332011* LOC61;
						if (!(res_338361 <= HEX3Atmp_338358)) goto LA59;
						j_338308 = res_338361;
						initparser_334068((&q), (*p).s);
						q.col = cols->data[j_338308];
						q.line = (NI)(line - ((NI) 1));
						q.filename = copyString((*p).filename);
						LOC60 = 0;
						LOC60 = gettokens_333429(row->data[j_338308], NIM_FALSE, (&q.tok));
						q.col += LOC60;
						b = newrstnode_332108(((NU8) 33));
						LOC61 = 0;
						LOC61 = parsedoc_338069((&q));
						add_332171(b, LOC61);
						add_332171(a, b);
						res_338361 += ((NI) 1);
					} LA59: ;
				}
			}
			add_332171(result, a);
		}
	} LA1: ;
	return result;
}

N_NIMCALL(Rstnode332011*, parseoptionlist_338631)(Rstparser333587* p) {
	Rstnode332011* result;
	result = 0;
	result = newrstnode_332108(((NU8) 17));
	{
		while (1) {
			{
				NIM_BOOL LOC5;
				Rstnode332011* a;
				Rstnode332011* b;
				Rstnode332011* c;
				NI j;
				LOC5 = 0;
				LOC5 = isoptionlist_337292((&(*p)));
				if (!LOC5) goto LA6;
				a = newrstnode_332108(((NU8) 19));
				b = newrstnode_332108(((NU8) 23));
				c = newrstnode_332108(((NU8) 18));
				{
					NIM_BOOL LOC10;
					LOC10 = 0;
					LOC10 = match_334727((&(*p)), (*p).idx, ((NimStringDesc*) &TMP2613));
					if (!LOC10) goto LA11;
					(*p).idx += ((NI) 1);
				}
				LA11: ;
				{
					while (1) {
						Rstnode332011* LOC21;
						if (!!(((3 &(1<<(((*p).tok->data[(*p).idx].kind)&7)))!=0))) goto LA14;
						{
							NIM_BOOL LOC17;
							LOC17 = 0;
							LOC17 = ((*p).tok->data[(*p).idx].kind == ((NU8) 2));
							if (!(LOC17)) goto LA18;
							LOC17 = (((NI) 1) < ((*p).tok->data[(*p).idx].symbol ? (*p).tok->data[(*p).idx].symbol->Sup.len : 0));
							LA18: ;
							if (!LOC17) goto LA19;
							(*p).idx += ((NI) 1);
							goto LA13;
						}
						LA19: ;
						LOC21 = 0;
						LOC21 = newleaf_334529(p);
						add_332171(a, LOC21);
						(*p).idx += ((NI) 1);
					} LA14: ;
				} LA13: ;
				j = tokenafternewline_337205((&(*p)));
				{
					NIM_BOOL LOC24;
					NIM_BOOL LOC25;
					NI LOC28;
					LOC24 = 0;
					LOC25 = 0;
					LOC25 = (((NI) 0) < j);
					if (!(LOC25)) goto LA26;
					LOC25 = ((*p).tok->data[(NI)(j - ((NI) 1))].kind == ((NU8) 1));
					LA26: ;
					LOC24 = LOC25;
					if (!(LOC24)) goto LA27;
					LOC28 = 0;
					LOC28 = currind_334001((&(*p)));
					LOC24 = (LOC28 < (*p).tok->data[(NI)(j - ((NI) 1))].ival);
					LA27: ;
					if (!LOC24) goto LA29;
					pushind_334011(p, (*p).tok->data[(NI)(j - ((NI) 1))].ival);
					parsesection_336217(p, b);
					popind_334032(p);
				}
				goto LA22;
				LA29: ;
				{
					parseline_336181(p, b);
				}
				LA22: ;
				{
					if (!((*p).tok->data[(*p).idx].kind == ((NU8) 1))) goto LA34;
					(*p).idx += ((NI) 1);
				}
				LA34: ;
				add_332171(c, a);
				add_332171(c, b);
				add_332171(result, c);
			}
			goto LA3;
			LA6: ;
			{
				goto LA1;
			}
			LA3: ;
		}
	} LA1: ;
	return result;
}

N_NIMCALL(void, parseparagraph_337386)(Rstparser333587* p, Rstnode332011* result) {
	{
		while (1) {
			switch ((*p).tok->data[(*p).idx].kind) {
			case ((NU8) 1):
			{
				{
					if (!((*p).tok->data[(NI)((*p).idx + ((NI) 1))].kind == ((NU8) 1))) goto LA6;
					(*p).idx += ((NI) 1);
					goto LA1;
				}
				goto LA4;
				LA6: ;
				{
					NI LOC9;
					NU8 LOC12;
					LOC9 = 0;
					LOC9 = currind_334001((&(*p)));
					if (!((*p).tok->data[(*p).idx].ival == LOC9)) goto LA10;
					(*p).idx += ((NI) 1);
					LOC12 = 0;
					LOC12 = whichsection_337302((&(*p)));
					switch (LOC12) {
					case ((NU8) 4):
					case ((NU8) 64):
					case ((NU8) 1):
					case ((NU8) 2):
					case ((NU8) 40):
					{
						Rstnode332011* LOC14;
						LOC14 = 0;
						LOC14 = newrstnode_332142(((NU8) 64), ((NimStringDesc*) &TMP2634));
						add_332171(result, LOC14);
					}
					break;
					case ((NU8) 26):
					{
						Rstnode332011* LOC16;
						LOC16 = 0;
						LOC16 = parselineblock_337321(p);
						addifnotnil_332191(result, LOC16);
					}
					break;
					default:
					{
						goto LA1;
					}
					break;
					}
				}
				goto LA4;
				LA10: ;
				{
					goto LA1;
				}
				LA4: ;
			}
			break;
			case ((NU8) 5):
			{
				{
					NIM_BOOL LOC22;
					NIM_BOOL LOC23;
					NI LOC26;
					Rstnode332011* LOC29;
					Rstnode332011* LOC30;
					LOC22 = 0;
					LOC23 = 0;
					LOC23 = eqStrings((*p).tok->data[(*p).idx].symbol, ((NimStringDesc*) &TMP2601));
					if (!(LOC23)) goto LA24;
					LOC23 = ((*p).tok->data[(NI)((*p).idx + ((NI) 1))].kind == ((NU8) 1));
					LA24: ;
					LOC22 = LOC23;
					if (!(LOC22)) goto LA25;
					LOC26 = 0;
					LOC26 = currind_334001((&(*p)));
					LOC22 = (LOC26 < (*p).tok->data[(NI)((*p).idx + ((NI) 1))].ival);
					LA25: ;
					if (!LOC22) goto LA27;
					LOC29 = 0;
					LOC29 = newrstnode_332142(((NU8) 64), ((NimStringDesc*) &TMP2708));
					add_332171(result, LOC29);
					(*p).idx += ((NI) 1);
					LOC30 = 0;
					LOC30 = parseliteralblock_337099(p);
					add_332171(result, LOC30);
					goto LA1;
				}
				goto LA20;
				LA27: ;
				{
					parseinline_335752(p, result);
				}
				LA20: ;
			}
			break;
			case ((NU8) 2):
			case ((NU8) 3):
			case ((NU8) 4):
			case ((NU8) 6):
			{
				parseinline_335752(p, result);
			}
			break;
			default:
			{
				goto LA1;
			}
			break;
			}
		}
	} LA1: ;
}

N_NIMCALL(NU8, sonkind_338906)(Rstnode332011* father, NI i) {
	NU8 result;
	result = 0;
	result = ((NU8) 64);
	{
		NI LOC3;
		LOC3 = 0;
		LOC3 = len_332090(father);
		if (!(i < LOC3)) goto LA4;
		result = (*(*father).sons->data[i]).kind;
	}
	LA4: ;
	return result;
}

N_NIMCALL(void, parsesection_336217)(Rstparser333587* p, Rstnode332011* result) {
	{
		while (1) {
			NIM_BOOL leave;
			Rstnode332011* a;
			NU8 k;
			leave = NIM_FALSE;
			{
				while (1) {
					if (!((*p).tok->data[(*p).idx].kind == ((NU8) 1))) goto LA4;
					{
						NI LOC7;
						LOC7 = 0;
						LOC7 = currind_334001((&(*p)));
						if (!(LOC7 == (*p).tok->data[(*p).idx].ival)) goto LA8;
						(*p).idx += ((NI) 1);
					}
					goto LA5;
					LA8: ;
					{
						NI LOC11;
						Rstnode332011* a;
						LOC11 = 0;
						LOC11 = currind_334001((&(*p)));
						if (!(LOC11 < (*p).tok->data[(*p).idx].ival)) goto LA12;
						pushind_334011(p, (*p).tok->data[(*p).idx].ival);
						a = newrstnode_332108(((NU8) 28));
						parsesection_336217(p, a);
						add_332171(result, a);
						popind_334032(p);
					}
					goto LA5;
					LA12: ;
					{
						leave = NIM_TRUE;
						goto LA3;
					}
					LA5: ;
				} LA4: ;
			} LA3: ;
			{
				NIM_BOOL LOC17;
				LOC17 = 0;
				LOC17 = leave;
				if (LOC17) goto LA18;
				LOC17 = ((*p).tok->data[(*p).idx].kind == ((NU8) 0));
				LA18: ;
				if (!LOC17) goto LA19;
				goto LA1;
			}
			LA19: ;
			a = NIM_NIL;
			k = whichsection_337302((&(*p)));
			switch (k) {
			case ((NU8) 24):
			{
				(*p).idx += ((NI) 1);
				a = parseliteralblock_337099(p);
			}
			break;
			case ((NU8) 5):
			{
				a = parsebulletlist_338565(p);
			}
			break;
			case ((NU8) 26):
			{
				a = parselineblock_337321(p);
			}
			break;
			case ((NU8) 40):
			{
				a = parsedotdot_337092(p);
			}
			break;
			case ((NU8) 7):
			{
				a = parseenumlist_338822(p);
			}
			break;
			case ((NU8) 64):
			{
				rstmessage_333967((&(*p)), ((NU8) 3));
			}
			break;
			case ((NU8) 4):
			{
			}
			break;
			case ((NU8) 9):
			{
				a = parsedefinitionlist_338734(p);
			}
			break;
			case ((NU8) 13):
			{
				{
					if (!(((NI) 0) < (*p).idx)) goto LA32;
					(*p).idx -= ((NI) 1);
				}
				LA32: ;
				a = parsefields_336258(p);
			}
			break;
			case ((NU8) 3):
			{
				a = parsetransition_338425(p);
			}
			break;
			case ((NU8) 1):
			{
				a = parseheadline_337449(p);
			}
			break;
			case ((NU8) 2):
			{
				a = parseoverline_338481(p);
			}
			break;
			case ((NU8) 29):
			{
				a = parsesimpletable_338076(p);
			}
			break;
			case ((NU8) 17):
			{
				a = parseoptionlist_338631(p);
			}
			break;
			default:
			{
			}
			break;
			}
			{
				NIM_BOOL LOC42;
				LOC42 = 0;
				LOC42 = (a == NIM_NIL);
				if (!(LOC42)) goto LA43;
				LOC42 = !((k == ((NU8) 40)));
				LA43: ;
				if (!LOC42) goto LA44;
				a = newrstnode_332108(((NU8) 4));
				parseparagraph_337386(p, a);
			}
			LA44: ;
			addifnotnil_332191(result, a);
		}
	} LA1: ;
	{
		NIM_BOOL LOC48;
		NU8 LOC49;
		NU8 LOC51;
		LOC48 = 0;
		LOC49 = 0;
		LOC49 = sonkind_338906(result, ((NI) 0));
		LOC48 = (LOC49 == ((NU8) 4));
		if (!(LOC48)) goto LA50;
		LOC51 = 0;
		LOC51 = sonkind_338906(result, ((NI) 1));
		LOC48 = !((LOC51 == ((NU8) 4)));
		LA50: ;
		if (!LOC48) goto LA52;
		(*(*result).sons->data[((NI) 0)]).kind = ((NU8) 0);
	}
	LA52: ;
}

N_NIMCALL(Rstnode332011*, parsesectionwrapper_339109)(Rstparser333587* p) {
	Rstnode332011* result;
	result = 0;
	result = newrstnode_332108(((NU8) 0));
	parsesection_336217(p, result);
	{
		while (1) {
			NIM_BOOL LOC3;
			NI LOC5;
			LOC3 = 0;
			LOC3 = ((*result).kind == ((NU8) 0));
			if (!(LOC3)) goto LA4;
			LOC5 = 0;
			LOC5 = len_332090(result);
			LOC3 = (LOC5 == ((NI) 1));
			LA4: ;
			if (!LOC3) goto LA2;
			result = (*result).sons->data[((NI) 0)];
		} LA2: ;
	}
	return result;
}

N_NIMCALL(Rstnode332011*, parsedoc_338069)(Rstparser333587* p) {
	Rstnode332011* result;
	result = 0;
	result = parsesectionwrapper_339109(p);
	{
		if (!!(((*p).tok->data[(*p).idx].kind == ((NU8) 0)))) goto LA3;
		rstmessage_333967((&(*p)), ((NU8) 4));
	}
	LA3: ;
	return result;
}

N_NIMCALL(Rstnode332011*, rstparse_340320)(NimStringDesc* text, NimStringDesc* filename, NI line, NI column, NIM_BOOL* hastoc, NU8 options, Findfilehandler333023 findfile, Msghandler333021 msghandler) {
	Rstnode332011* result;
	Rstparser333587 p;
	Sharedstate333583* LOC1;
	NI LOC2;
	Rstnode332011* LOC3;
	result = 0;
	memset((void*)(&p), 0, sizeof(p));
	p.Sup.m_type = (&NTI333587);
	LOC1 = 0;
	LOC1 = newsharedstate_333877(options, findfile, msghandler);
	initparser_334068((&p), LOC1);
	p.filename = copyString(filename);
	p.line = line;
	LOC2 = 0;
	LOC2 = gettokens_333429(text, ((options &(1<<((((NU8) 0))&7)))!=0), (&p.tok));
	p.col = (NI)(column + LOC2);
	LOC3 = 0;
	LOC3 = parsedoc_338069((&p));
	result = resolvesubs_340250((&p), LOC3);
	(*hastoc) = p.hastoc;
	return result;
}
NIM_EXTERNC N_NOINLINE(void, docutils_rstInit000)(void) {
}

NIM_EXTERNC N_NOINLINE(void, docutils_rstDatInit000)(void) {
static TNimNode* TMP2551[8];
static TNimNode* TMP2552[5];
static TNimNode* TMP2553[7];
NI TMP2555;
static char* NIM_CONST TMP2554[7] = {
"tkEof", 
"tkIndent", 
"tkWhite", 
"tkWord", 
"tkAdornment", 
"tkPunct", 
"tkOther"};
static TNimNode* TMP2557[9];
static TNimNode* TMP2558[4];
NI TMP2560;
static char* NIM_CONST TMP2559[4] = {
"roSkipPounds", 
"roSupportSmilies", 
"roSupportRawDirective", 
"roSupportMarkdown"};
static TNimNode* TMP2561[2];
static TNimNode* TMP2573[10];
NI TMP2575;
static char* NIM_CONST TMP2574[10] = {
"meCannotOpenFile", 
"meExpected", 
"meGridTableNotImplemented", 
"meNewSectionExpected", 
"meGeneralParseError", 
"meInvalidDirective", 
"mwRedefinitionOfLabel", 
"mwUnknownSubstitution", 
"mwUnsupportedLanguage", 
"mwUnsupportedField"};
static TNimNode* TMP2587[3];
NI TMP2589;
static char* NIM_CONST TMP2588[3] = {
"Hint", 
"Warning", 
"Error"};
static TNimNode* TMP2592[6];
static TNimNode TMP969[65];
NTI333587.size = sizeof(Rstparser333587);
NTI333587.kind = 17;
NTI333587.base = (&NTI4011);
TMP2551[0] = &TMP969[1];
TMP969[1].kind = 1;
TMP969[1].offset = offsetof(Rstparser333587, idx);
TMP969[1].typ = (&NTI108);
TMP969[1].name = "idx";
TMP2551[1] = &TMP969[2];
NTI333141.size = sizeof(Token333141);
NTI333141.kind = 18;
NTI333141.base = 0;
NTI333141.flags = 2;
TMP2552[0] = &TMP969[4];
NTI333139.size = sizeof(NU8);
NTI333139.kind = 14;
NTI333139.base = 0;
NTI333139.flags = 3;
for (TMP2555 = 0; TMP2555 < 7; TMP2555++) {
TMP969[TMP2555+5].kind = 1;
TMP969[TMP2555+5].offset = TMP2555;
TMP969[TMP2555+5].name = TMP2554[TMP2555];
TMP2553[TMP2555] = &TMP969[TMP2555+5];
}
TMP969[12].len = 7; TMP969[12].kind = 2; TMP969[12].sons = &TMP2553[0];
NTI333139.node = &TMP969[12];
TMP969[4].kind = 1;
TMP969[4].offset = offsetof(Token333141, kind);
TMP969[4].typ = (&NTI333139);
TMP969[4].name = "kind";
TMP2552[1] = &TMP969[13];
TMP969[13].kind = 1;
TMP969[13].offset = offsetof(Token333141, ival);
TMP969[13].typ = (&NTI108);
TMP969[13].name = "ival";
TMP2552[2] = &TMP969[14];
TMP969[14].kind = 1;
TMP969[14].offset = offsetof(Token333141, symbol);
TMP969[14].typ = (&NTI149);
TMP969[14].name = "symbol";
TMP2552[3] = &TMP969[15];
TMP969[15].kind = 1;
TMP969[15].offset = offsetof(Token333141, line);
TMP969[15].typ = (&NTI108);
TMP969[15].name = "line";
TMP2552[4] = &TMP969[16];
TMP969[16].kind = 1;
TMP969[16].offset = offsetof(Token333141, col);
TMP969[16].typ = (&NTI108);
TMP969[16].name = "col";
TMP969[3].len = 5; TMP969[3].kind = 2; TMP969[3].sons = &TMP2552[0];
NTI333141.node = &TMP969[3];
NTI333143.size = sizeof(Tokenseq333143*);
NTI333143.kind = 24;
NTI333143.base = (&NTI333141);
NTI333143.flags = 2;
NTI333143.marker = TMP2556;
TMP969[2].kind = 1;
TMP969[2].offset = offsetof(Rstparser333587, tok);
TMP969[2].typ = (&NTI333143);
TMP969[2].name = "tok";
TMP2551[2] = &TMP969[17];
NTI333583.size = sizeof(Sharedstate333583);
NTI333583.kind = 18;
NTI333583.base = 0;
NTI333583.flags = 2;
TMP2557[0] = &TMP969[19];
NTI333013.size = sizeof(NU8);
NTI333013.kind = 14;
NTI333013.base = 0;
NTI333013.flags = 3;
for (TMP2560 = 0; TMP2560 < 4; TMP2560++) {
TMP969[TMP2560+20].kind = 1;
TMP969[TMP2560+20].offset = TMP2560;
TMP969[TMP2560+20].name = TMP2559[TMP2560];
TMP2558[TMP2560] = &TMP969[TMP2560+20];
}
TMP969[24].len = 4; TMP969[24].kind = 2; TMP969[24].sons = &TMP2558[0];
NTI333013.node = &TMP969[24];
NTI333015.size = sizeof(NU8);
NTI333015.kind = 19;
NTI333015.base = (&NTI333013);
NTI333015.flags = 3;
TMP969[25].len = 0; TMP969[25].kind = 0;
NTI333015.node = &TMP969[25];
TMP969[19].kind = 1;
TMP969[19].offset = offsetof(Sharedstate333583, options);
TMP969[19].typ = (&NTI333015);
TMP969[19].name = "options";
TMP2557[1] = &TMP969[26];
TMP969[26].kind = 1;
TMP969[26].offset = offsetof(Sharedstate333583, ulevel);
TMP969[26].typ = (&NTI108);
TMP969[26].name = "uLevel";
TMP2557[2] = &TMP969[27];
TMP969[27].kind = 1;
TMP969[27].offset = offsetof(Sharedstate333583, olevel);
TMP969[27].typ = (&NTI108);
TMP969[27].name = "oLevel";
TMP2557[3] = &TMP969[28];
NTI333581.size = sizeof(Substitution333581);
NTI333581.kind = 18;
NTI333581.base = 0;
NTI333581.flags = 2;
TMP2561[0] = &TMP969[30];
TMP969[30].kind = 1;
TMP969[30].offset = offsetof(Substitution333581, key);
TMP969[30].typ = (&NTI149);
TMP969[30].name = "key";
TMP2561[1] = &TMP969[31];
TMP969[31].kind = 1;
TMP969[31].offset = offsetof(Substitution333581, value);
TMP969[31].typ = (&NTI332007);
TMP969[31].name = "value";
TMP969[29].len = 2; TMP969[29].kind = 2; TMP969[29].sons = &TMP2561[0];
NTI333581.node = &TMP969[29];
NTI333597.size = sizeof(TY333597*);
NTI333597.kind = 24;
NTI333597.base = (&NTI333581);
NTI333597.flags = 2;
NTI333597.marker = TMP2568;
TMP969[28].kind = 1;
TMP969[28].offset = offsetof(Sharedstate333583, subs);
TMP969[28].typ = (&NTI333597);
TMP969[28].name = "subs";
TMP2557[4] = &TMP969[32];
TMP969[32].kind = 1;
TMP969[32].offset = offsetof(Sharedstate333583, refs);
TMP969[32].typ = (&NTI333597);
TMP969[32].name = "refs";
TMP2557[5] = &TMP969[33];
TMP969[33].kind = 1;
TMP969[33].offset = offsetof(Sharedstate333583, underlinetolevel);
TMP969[33].typ = (&NTI103393);
TMP969[33].name = "underlineToLevel";
TMP2557[6] = &TMP969[34];
TMP969[34].kind = 1;
TMP969[34].offset = offsetof(Sharedstate333583, overlinetolevel);
TMP969[34].typ = (&NTI103393);
TMP969[34].name = "overlineToLevel";
TMP2557[7] = &TMP969[35];
NTI333021.size = sizeof(Msghandler333021);
NTI333021.kind = 25;
NTI333021.base = 0;
NTI333021.flags = 3;
TMP969[35].kind = 1;
TMP969[35].offset = offsetof(Sharedstate333583, msghandler);
TMP969[35].typ = (&NTI333021);
TMP969[35].name = "msgHandler";
TMP2557[8] = &TMP969[36];
NTI333023.size = sizeof(Findfilehandler333023);
NTI333023.kind = 25;
NTI333023.base = 0;
NTI333023.flags = 3;
TMP969[36].kind = 1;
TMP969[36].offset = offsetof(Sharedstate333583, findfile);
TMP969[36].typ = (&NTI333023);
TMP969[36].name = "findFile";
TMP969[18].len = 9; TMP969[18].kind = 2; TMP969[18].sons = &TMP2557[0];
NTI333583.node = &TMP969[18];
NTI333585.size = sizeof(Sharedstate333583*);
NTI333585.kind = 22;
NTI333585.base = (&NTI333583);
NTI333585.flags = 2;
NTI333585.marker = TMP2569;
TMP969[17].kind = 1;
TMP969[17].offset = offsetof(Rstparser333587, s);
TMP969[17].typ = (&NTI333585);
TMP969[17].name = "s";
TMP2551[3] = &TMP969[37];
NTI333608.size = sizeof(TY333608*);
NTI333608.kind = 24;
NTI333608.base = (&NTI108);
NTI333608.flags = 2;
NTI333608.marker = TMP2570;
TMP969[37].kind = 1;
TMP969[37].offset = offsetof(Rstparser333587, indentstack);
TMP969[37].typ = (&NTI333608);
TMP969[37].name = "indentStack";
TMP2551[4] = &TMP969[38];
TMP969[38].kind = 1;
TMP969[38].offset = offsetof(Rstparser333587, filename);
TMP969[38].typ = (&NTI149);
TMP969[38].name = "filename";
TMP2551[5] = &TMP969[39];
TMP969[39].kind = 1;
TMP969[39].offset = offsetof(Rstparser333587, line);
TMP969[39].typ = (&NTI108);
TMP969[39].name = "line";
TMP2551[6] = &TMP969[40];
TMP969[40].kind = 1;
TMP969[40].offset = offsetof(Rstparser333587, col);
TMP969[40].typ = (&NTI108);
TMP969[40].name = "col";
TMP2551[7] = &TMP969[41];
TMP969[41].kind = 1;
TMP969[41].offset = offsetof(Rstparser333587, hastoc);
TMP969[41].typ = (&NTI138);
TMP969[41].name = "hasToc";
TMP969[0].len = 8; TMP969[0].kind = 2; TMP969[0].sons = &TMP2551[0];
NTI333587.node = &TMP969[0];
NTI333019.size = sizeof(NU8);
NTI333019.kind = 14;
NTI333019.base = 0;
NTI333019.flags = 3;
for (TMP2575 = 0; TMP2575 < 10; TMP2575++) {
TMP969[TMP2575+42].kind = 1;
TMP969[TMP2575+42].offset = TMP2575;
TMP969[TMP2575+42].name = TMP2574[TMP2575];
TMP2573[TMP2575] = &TMP969[TMP2575+42];
}
TMP969[52].len = 10; TMP969[52].kind = 2; TMP969[52].sons = &TMP2573[0];
NTI333019.node = &TMP969[52];
NTI333017.size = sizeof(NU8);
NTI333017.kind = 14;
NTI333017.base = 0;
NTI333017.flags = 3;
for (TMP2589 = 0; TMP2589 < 3; TMP2589++) {
TMP969[TMP2589+53].kind = 1;
TMP969[TMP2589+53].offset = TMP2589;
TMP969[TMP2589+53].name = TMP2588[TMP2589];
TMP2587[TMP2589] = &TMP969[TMP2589+53];
}
TMP969[56].len = 3; TMP969[56].kind = 2; TMP969[56].sons = &TMP2587[0];
NTI333017.node = &TMP969[56];
NTI333589.size = sizeof(Eparseerror333589);
NTI333589.kind = 17;
NTI333589.base = (&NTI4049);
TMP969[57].len = 0; TMP969[57].kind = 2;
NTI333589.node = &TMP969[57];
NTI333839.size = sizeof(Eparseerror333589*);
NTI333839.kind = 22;
NTI333839.base = (&NTI333589);
NTI333839.marker = TMP2590;
NTI333145.size = sizeof(Lexer333145);
NTI333145.kind = 17;
NTI333145.base = (&NTI4011);
NTI333145.flags = 1;
TMP2592[0] = &TMP969[59];
TMP969[59].kind = 1;
TMP969[59].offset = offsetof(Lexer333145, buf);
TMP969[59].typ = (&NTI151);
TMP969[59].name = "buf";
TMP2592[1] = &TMP969[60];
TMP969[60].kind = 1;
TMP969[60].offset = offsetof(Lexer333145, bufpos);
TMP969[60].typ = (&NTI108);
TMP969[60].name = "bufpos";
TMP2592[2] = &TMP969[61];
TMP969[61].kind = 1;
TMP969[61].offset = offsetof(Lexer333145, line);
TMP969[61].typ = (&NTI108);
TMP969[61].name = "line";
TMP2592[3] = &TMP969[62];
TMP969[62].kind = 1;
TMP969[62].offset = offsetof(Lexer333145, col);
TMP969[62].typ = (&NTI108);
TMP969[62].name = "col";
TMP2592[4] = &TMP969[63];
TMP969[63].kind = 1;
TMP969[63].offset = offsetof(Lexer333145, baseindent);
TMP969[63].typ = (&NTI108);
TMP969[63].name = "baseIndent";
TMP2592[5] = &TMP969[64];
TMP969[64].kind = 1;
TMP969[64].offset = offsetof(Lexer333145, skippounds);
TMP969[64].typ = (&NTI138);
TMP969[64].name = "skipPounds";
TMP969[58].len = 6; TMP969[58].kind = 2; TMP969[58].sons = &TMP2592[0];
NTI333145.node = &TMP969[58];
}

