/* Generated by Nim Compiler v2.2.10 */
#define NIM_INTBITS 32

#include "nimbase.h"
#include <string.h>
#include <stdio.h>
#undef LANGUAGE_C
#undef MIPSEB
#undef MIPSEL
#undef PPC
#undef R3000
#undef R4000
#undef i386
#undef linux
#undef mips
#undef near
#undef far
#undef powerpc
#undef unix
typedef struct tyTuple__dPNkpxgceTc63bP5seHZGw tyTuple__dPNkpxgceTc63bP5seHZGw;
typedef struct NimStrPayload NimStrPayload;
typedef struct NimStringV2 NimStringV2;
typedef struct tyTuple__mBPo6SdWuL2NLQ9aX5t1kTg tyTuple__mBPo6SdWuL2NLQ9aX5t1kTg;
typedef struct tySequence__36jA1xDCIBAS29cySYLQ7kQ tySequence__36jA1xDCIBAS29cySYLQ7kQ;
typedef struct tySequence__36jA1xDCIBAS29cySYLQ7kQ_Content tySequence__36jA1xDCIBAS29cySYLQ7kQ_Content;
typedef struct tyObject_IndexEntry__r4FGmtl4yhJtHvFotaeMmQ tyObject_IndexEntry__r4FGmtl4yhJtHvFotaeMmQ;
typedef struct tyTuple__7q7q3E6Oj24ZNVJb9aonhAg tyTuple__7q7q3E6Oj24ZNVJb9aonhAg;
typedef struct tySequence__sM4lkSb7zS6F7OVMvW9cffQ tySequence__sM4lkSb7zS6F7OVMvW9cffQ;
typedef struct tySequence__sM4lkSb7zS6F7OVMvW9cffQ_Content tySequence__sM4lkSb7zS6F7OVMvW9cffQ_Content;
typedef struct tyObject_ValueError__S29bKZF4TUS33IR7ZXb7fFA tyObject_ValueError__S29bKZF4TUS33IR7ZXb7fFA;
typedef struct tyObject_CatchableError__TCF9b1Y9b2ct0xPZvZnaY7gg tyObject_CatchableError__TCF9b1Y9b2ct0xPZvZnaY7gg;
typedef struct Exception Exception;
typedef struct RootObj RootObj;
typedef struct TNimTypeV2 TNimTypeV2;
typedef struct tySequence__S89cE01OvNjsN9c71FKsSrqQ tySequence__S89cE01OvNjsN9c71FKsSrqQ;
typedef struct tySequence__S89cE01OvNjsN9c71FKsSrqQ_Content tySequence__S89cE01OvNjsN9c71FKsSrqQ_Content;
typedef struct tyTuple__UV3llMMYFckfui8YMBuUZA tyTuple__UV3llMMYFckfui8YMBuUZA;
typedef struct tyObject_StackTraceEntry__RcJz5RXFIYjIseutvVFICA tyObject_StackTraceEntry__RcJz5RXFIYjIseutvVFICA;
typedef NU8 tyEnum_IndexEntryKind__bp7boVnNZivfjr9au9bLARfQ;
struct NimStrPayload {
	NI cap;
	NIM_CHAR data[SEQ_DECL_SIZE];
};
struct NimStringV2 {
	NI len;
	NimStrPayload* p;
};
struct tyTuple__dPNkpxgceTc63bP5seHZGw {
	NimStringV2 Field0;
	NIM_BOOL Field1;
};
struct tySequence__36jA1xDCIBAS29cySYLQ7kQ {
  NI len; tySequence__36jA1xDCIBAS29cySYLQ7kQ_Content* p;
};
struct tyObject_IndexEntry__r4FGmtl4yhJtHvFotaeMmQ {
	tyEnum_IndexEntryKind__bp7boVnNZivfjr9au9bLARfQ kind;
	NimStringV2 keyword;
	NimStringV2 link;
	NimStringV2 linkTitle;
	NimStringV2 linkDesc;
	NI line;
	NimStringV2 module;
	NimStringV2 aux;
};
struct tyTuple__mBPo6SdWuL2NLQ9aX5t1kTg {
	tySequence__36jA1xDCIBAS29cySYLQ7kQ Field0;
	tyObject_IndexEntry__r4FGmtl4yhJtHvFotaeMmQ Field1;
};
struct tyTuple__7q7q3E6Oj24ZNVJb9aonhAg {
	NimStringV2 Field0;
	NimStringV2 Field1;
	NimStringV2 Field2;
};
typedef NU8 tyEnum_FileMode__YkEVJbjDa9aPvYTBr8yiUWg;
struct tySequence__sM4lkSb7zS6F7OVMvW9cffQ {
  NI len; tySequence__sM4lkSb7zS6F7OVMvW9cffQ_Content* p;
};
struct TNimTypeV2 {
	void* destructor;
	NI size;
	NI16 align;
	NI16 depth;
	NU32* display;
	void* traceImpl;
	void* typeInfoV1;
	NI flags;
	void* vTable[SEQ_DECL_SIZE];
};
struct RootObj {
	TNimTypeV2* m_type;
};
struct tySequence__S89cE01OvNjsN9c71FKsSrqQ {
  NI len; tySequence__S89cE01OvNjsN9c71FKsSrqQ_Content* p;
};
struct Exception {
	RootObj Sup;
	Exception* parent;
	NCSTRING name;
	NimStringV2 message;
	tySequence__S89cE01OvNjsN9c71FKsSrqQ trace;
	Exception* up;
};
struct tyObject_CatchableError__TCF9b1Y9b2ct0xPZvZnaY7gg {
	Exception Sup;
};
struct tyObject_ValueError__S29bKZF4TUS33IR7ZXb7fFA {
	tyObject_CatchableError__TCF9b1Y9b2ct0xPZvZnaY7gg Sup;
};
typedef NimStringV2 tyArray__YgExxhfgKcesA5EOUj1MOA[1];
struct tyTuple__UV3llMMYFckfui8YMBuUZA {
	NimStringV2 Field0;
	NimStringV2 Field1;
};
typedef tyTuple__UV3llMMYFckfui8YMBuUZA tyArray__cmwNI9aKEPDUazETuwUU9arQ[3];
struct tySequence__36jA1xDCIBAS29cySYLQ7kQ_Content { NI cap; tyObject_IndexEntry__r4FGmtl4yhJtHvFotaeMmQ data[SEQ_DECL_SIZE]; };
struct tySequence__sM4lkSb7zS6F7OVMvW9cffQ_Content { NI cap; NimStringV2 data[SEQ_DECL_SIZE]; };
struct tyObject_StackTraceEntry__RcJz5RXFIYjIseutvVFICA {
	NCSTRING procname;
	NI line;
	NCSTRING filename;
};
struct tySequence__S89cE01OvNjsN9c71FKsSrqQ_Content { NI cap; tyObject_StackTraceEntry__RcJz5RXFIYjIseutvVFICA data[SEQ_DECL_SIZE]; };
static N_INLINE(void, nimZeroMem)(void* p_p0, NI size_p1);
static N_INLINE(void, nimSetMem__system_u2172)(void* a_p0, int v_p1, NI size_p2);
N_LIB_PRIVATE N_NIMCALL(void, eqsink___system_u2700)(NimStringV2* dest_p0, NimStringV2 src_p1);
N_LIB_PRIVATE N_NIMCALL(NimStringV2, dollar___packagesZdocutilsZrstidx_u13)(tyEnum_IndexEntryKind__bp7boVnNZivfjr9au9bLARfQ e_p0);
static N_INLINE(void, nimAddCharV1)(NimStringV2* s_p0, NIM_CHAR c_p1);
N_LIB_PRIVATE N_NIMCALL(void, prepareAdd)(NimStringV2* s_p0, NI addLen_p1);
static N_INLINE(void, appendString)(NimStringV2* dest_p0, NimStringV2 src_p1);
static N_INLINE(void, copyMem__system_u1742)(void* dest_p0, void* source_p1, NI size_p2);
static N_INLINE(void, nimCopyMem)(void* dest_p0, void* source_p1, NI size_p2);
static N_INLINE(void, appendChar)(NimStringV2* dest_p0, NIM_CHAR c_p1);
N_LIB_PRIVATE N_NIMCALL(NimStringV2, quoteIndexColumn__packagesZdocutilsZrstidx_u30)(NimStringV2 text_p0);
N_NIMCALL(NimStringV2, rawNewString)(NI cap_p0);
N_LIB_PRIVATE N_NIMCALL(NimStringV2, dollar___systemZdollars_u9)(NI xX60gensym0__p0);
N_LIB_PRIVATE N_NIMCALL(void, eqdestroy___system_u2691)(NimStringV2 dest_p0);
static N_INLINE(NIM_BOOL*, nimErrorFlag)(void);
N_LIB_PRIVATE N_NIMCALL(void, newSeq__packagesZdocutilsZrstidx_u119)(tySequence__36jA1xDCIBAS29cySYLQ7kQ* s_p0, NI len_p1);
N_LIB_PRIVATE N_NIMCALL(void, setLen__packagesZdocutilsZrstidx_u127)(tySequence__36jA1xDCIBAS29cySYLQ7kQ* s_p0, NI newlen_p1);
N_LIB_PRIVATE N_NIMCALL(tyTuple__7q7q3E6Oj24ZNVJb9aonhAg, nossplitFile)(NimStringV2 path_p0);
N_LIB_PRIVATE N_NIMCALL(void, eqwasMoved___system_u2688)(NimStringV2* dest_p0);
N_LIB_PRIVATE N_NIMCALL(FILE*, open__stdZsyncio_u485)(NimStringV2 filename_p0, tyEnum_FileMode__YkEVJbjDa9aPvYTBr8yiUWg mode_p1, NI bufSize_p2);
N_LIB_PRIVATE N_NIMCALL(NIM_BOOL, readLine__stdZsyncio_u290)(FILE* f_p0, NimStringV2* line_p1);
N_LIB_PRIVATE N_NIMCALL(NI, nsuFindChar)(NimStringV2 s_p0, NIM_CHAR sub_p1, NI start_p2, NI last_p3);
N_LIB_PRIVATE N_NIMCALL(void, eqdestroy___system_u5506)(tySequence__sM4lkSb7zS6F7OVMvW9cffQ dest_p0);
N_LIB_PRIVATE N_NIMCALL(tySequence__sM4lkSb7zS6F7OVMvW9cffQ, nsuSplitChar)(NimStringV2 s_p0, NIM_CHAR sep_p1, NI maxsplit_p2);
N_LIB_PRIVATE N_NIMCALL(tyEnum_IndexEntryKind__bp7boVnNZivfjr9au9bLARfQ, parseIndexEntryKind__packagesZdocutilsZrstidx_u90)(NimStringV2 s_p0);
static N_INLINE(NIM_BOOL, eqStrings)(NimStringV2 a_p0, NimStringV2 b_p1);
static N_INLINE(NIM_BOOL, equalMem__system_u1750)(void* a_p0, void* b_p1, NI size_p2);
static N_INLINE(int, nimCmpMem)(void* a_p0, void* b_p1, NI size_p2);
N_LIB_PRIVATE N_NIMCALL(void*, nimNewObj)(NI size_p0, NI alignment_p1);
N_LIB_PRIVATE N_NIMCALL(NimStringV2, nsuFormatOpenArray)(NimStringV2 formatstr_p0, NimStringV2* a_p1, NI a_p1Len_0);
N_LIB_PRIVATE N_NIMCALL(void, raiseExceptionEx)(Exception* e_p0, NCSTRING ename_p1, NCSTRING procname_p2, NCSTRING filename_p3, NI line_p4);
N_LIB_PRIVATE N_NIMCALL(void, eqcopy___system_u2694)(NimStringV2* dest_p0, NimStringV2 src_p1);
N_LIB_PRIVATE N_NIMCALL(NimStringV2, unquoteIndexColumn__packagesZdocutilsZrstidx_u34)(NimStringV2 text_p0);
N_LIB_PRIVATE N_NIMCALL(NimStringV2, multiReplace__pureZstrutils_u1885)(NimStringV2 s_p0, tyTuple__UV3llMMYFckfui8YMBuUZA* replacements_p1, NI replacements_p1Len_0);
N_LIB_PRIVATE N_NIMCALL(NI, nsuParseInt)(NimStringV2 s_p0);
N_LIB_PRIVATE N_NIMCALL(void, eqcopy___packagesZdocutilsZrstidx_u200)(tyObject_IndexEntry__r4FGmtl4yhJtHvFotaeMmQ* dest_p0, tyObject_IndexEntry__r4FGmtl4yhJtHvFotaeMmQ* src_p1);
N_LIB_PRIVATE N_NIMCALL(void, close__stdZsyncio_u268)(FILE* f_p0);
N_LIB_PRIVATE N_NIMCALL(void, eqdestroy___pureZos_u200)(tyTuple__7q7q3E6Oj24ZNVJb9aonhAg dest_p0);
N_LIB_PRIVATE N_NIMCALL(void, alignedDealloc)(void* p_p0, NI align_p1);
static N_INLINE(NI, emarkamp___pureZhashes_u5)(NI h_p0, NI val_p1);
N_LIB_PRIVATE N_NIMCALL(NI, hash__pureZhashes_u587)(NimStringV2 x_p0);
static N_INLINE(NI, emarkdollar___pureZhashes_u20)(NI h_p0);
N_LIB_PRIVATE N_NIMCALL(void, eqdestroy___packagesZdocutilsZrstidx_u281)(tySequence__36jA1xDCIBAS29cySYLQ7kQ dest_p0);
N_LIB_PRIVATE N_NIMCALL(NimStringV2, eqdup___system_u2697)(NimStringV2 src_p0);
N_LIB_PRIVATE N_NIMCALL(NI, nsuCmpIgnoreStyle)(NimStringV2 a_p0, NimStringV2 b_p1);
static const struct {
  NI cap; NIM_CHAR data[11+1];
} TM__LlVUgWt08GOGBFRK3cbAww_2 = { 11 | NIM_STRLIT_FLAG, "markupTitle" };
static const NimStringV2 TM__LlVUgWt08GOGBFRK3cbAww_3 = {11, (NimStrPayload*)&TM__LlVUgWt08GOGBFRK3cbAww_2};
static const struct {
  NI cap; NIM_CHAR data[8+1];
} TM__LlVUgWt08GOGBFRK3cbAww_4 = { 8 | NIM_STRLIT_FLAG, "nimTitle" };
static const NimStringV2 TM__LlVUgWt08GOGBFRK3cbAww_5 = {8, (NimStrPayload*)&TM__LlVUgWt08GOGBFRK3cbAww_4};
static const struct {
  NI cap; NIM_CHAR data[7+1];
} TM__LlVUgWt08GOGBFRK3cbAww_6 = { 7 | NIM_STRLIT_FLAG, "heading" };
static const NimStringV2 TM__LlVUgWt08GOGBFRK3cbAww_7 = {7, (NimStrPayload*)&TM__LlVUgWt08GOGBFRK3cbAww_6};
static const struct {
  NI cap; NIM_CHAR data[3+1];
} TM__LlVUgWt08GOGBFRK3cbAww_8 = { 3 | NIM_STRLIT_FLAG, "idx" };
static const NimStringV2 TM__LlVUgWt08GOGBFRK3cbAww_9 = {3, (NimStrPayload*)&TM__LlVUgWt08GOGBFRK3cbAww_8};
static const struct {
  NI cap; NIM_CHAR data[3+1];
} TM__LlVUgWt08GOGBFRK3cbAww_10 = { 3 | NIM_STRLIT_FLAG, "nim" };
static const NimStringV2 TM__LlVUgWt08GOGBFRK3cbAww_11 = {3, (NimStrPayload*)&TM__LlVUgWt08GOGBFRK3cbAww_10};
static const struct {
  NI cap; NIM_CHAR data[6+1];
} TM__LlVUgWt08GOGBFRK3cbAww_12 = { 6 | NIM_STRLIT_FLAG, "nimgrp" };
static const NimStringV2 TM__LlVUgWt08GOGBFRK3cbAww_13 = {6, (NimStrPayload*)&TM__LlVUgWt08GOGBFRK3cbAww_12};
static const struct {
  NI cap; NIM_CHAR data[0+1];
} TM__LlVUgWt08GOGBFRK3cbAww_14 = { 0 | NIM_STRLIT_FLAG, "" };
static const NimStringV2 TM__LlVUgWt08GOGBFRK3cbAww_15 = {0, (NimStrPayload*)&TM__LlVUgWt08GOGBFRK3cbAww_14};
static const struct {
  NI cap; NIM_CHAR data[1+1];
} TM__LlVUgWt08GOGBFRK3cbAww_16 = { 1 | NIM_STRLIT_FLAG, "\\" };
static const NimStringV2 TM__LlVUgWt08GOGBFRK3cbAww_17 = {1, (NimStrPayload*)&TM__LlVUgWt08GOGBFRK3cbAww_16};
static const struct {
  NI cap; NIM_CHAR data[2+1];
} TM__LlVUgWt08GOGBFRK3cbAww_18 = { 2 | NIM_STRLIT_FLAG, "\\n" };
static const NimStringV2 TM__LlVUgWt08GOGBFRK3cbAww_19 = {2, (NimStrPayload*)&TM__LlVUgWt08GOGBFRK3cbAww_18};
static const struct {
  NI cap; NIM_CHAR data[2+1];
} TM__LlVUgWt08GOGBFRK3cbAww_20 = { 2 | NIM_STRLIT_FLAG, "\\t" };
static const NimStringV2 TM__LlVUgWt08GOGBFRK3cbAww_21 = {2, (NimStrPayload*)&TM__LlVUgWt08GOGBFRK3cbAww_20};
static const struct {
  NI cap; NIM_CHAR data[1+1];
} TM__LlVUgWt08GOGBFRK3cbAww_22 = { 1 | NIM_STRLIT_FLAG, "\012" };
static const NimStringV2 TM__LlVUgWt08GOGBFRK3cbAww_23 = {1, (NimStrPayload*)&TM__LlVUgWt08GOGBFRK3cbAww_22};
static const struct {
  NI cap; NIM_CHAR data[3+1];
} TM__LlVUgWt08GOGBFRK3cbAww_24 = { 3 | NIM_STRLIT_FLAG, "nim" };
static const NimStringV2 TM__LlVUgWt08GOGBFRK3cbAww_25 = {3, (NimStrPayload*)&TM__LlVUgWt08GOGBFRK3cbAww_24};
static const struct {
  NI cap; NIM_CHAR data[6+1];
} TM__LlVUgWt08GOGBFRK3cbAww_26 = { 6 | NIM_STRLIT_FLAG, "nimgrp" };
static const NimStringV2 TM__LlVUgWt08GOGBFRK3cbAww_27 = {6, (NimStrPayload*)&TM__LlVUgWt08GOGBFRK3cbAww_26};
static const struct {
  NI cap; NIM_CHAR data[7+1];
} TM__LlVUgWt08GOGBFRK3cbAww_28 = { 7 | NIM_STRLIT_FLAG, "heading" };
static const NimStringV2 TM__LlVUgWt08GOGBFRK3cbAww_29 = {7, (NimStrPayload*)&TM__LlVUgWt08GOGBFRK3cbAww_28};
static const struct {
  NI cap; NIM_CHAR data[3+1];
} TM__LlVUgWt08GOGBFRK3cbAww_30 = { 3 | NIM_STRLIT_FLAG, "idx" };
static const NimStringV2 TM__LlVUgWt08GOGBFRK3cbAww_31 = {3, (NimStrPayload*)&TM__LlVUgWt08GOGBFRK3cbAww_30};
static const struct {
  NI cap; NIM_CHAR data[8+1];
} TM__LlVUgWt08GOGBFRK3cbAww_32 = { 8 | NIM_STRLIT_FLAG, "nimTitle" };
static const NimStringV2 TM__LlVUgWt08GOGBFRK3cbAww_33 = {8, (NimStrPayload*)&TM__LlVUgWt08GOGBFRK3cbAww_32};
static const struct {
  NI cap; NIM_CHAR data[11+1];
} TM__LlVUgWt08GOGBFRK3cbAww_34 = { 11 | NIM_STRLIT_FLAG, "markupTitle" };
static const NimStringV2 TM__LlVUgWt08GOGBFRK3cbAww_35 = {11, (NimStrPayload*)&TM__LlVUgWt08GOGBFRK3cbAww_34};
extern TNimTypeV2 NTIv2__S29bKZF4TUS33IR7ZXb7fFA_;
static const struct {
  NI cap; NIM_CHAR data[28+1];
} TM__LlVUgWt08GOGBFRK3cbAww_36 = { 28 | NIM_STRLIT_FLAG, "unknown index entry value $1" };
static const NimStringV2 TM__LlVUgWt08GOGBFRK3cbAww_37 = {28, (NimStrPayload*)&TM__LlVUgWt08GOGBFRK3cbAww_36};
static const struct {
  NI cap; NIM_CHAR data[1+1];
} TM__LlVUgWt08GOGBFRK3cbAww_39 = { 1 | NIM_STRLIT_FLAG, "\011" };
static const struct {
  NI cap; NIM_CHAR data[2+1];
} TM__LlVUgWt08GOGBFRK3cbAww_40 = { 2 | NIM_STRLIT_FLAG, "\\\\" };
static NIM_CONST tyArray__cmwNI9aKEPDUazETuwUU9arQ TM__LlVUgWt08GOGBFRK3cbAww_38 = {{{2, (NimStrPayload*)&TM__LlVUgWt08GOGBFRK3cbAww_20},
{1, (NimStrPayload*)&TM__LlVUgWt08GOGBFRK3cbAww_39}}
,
{{2, (NimStrPayload*)&TM__LlVUgWt08GOGBFRK3cbAww_18},
{1, (NimStrPayload*)&TM__LlVUgWt08GOGBFRK3cbAww_22}}
,
{{2, (NimStrPayload*)&TM__LlVUgWt08GOGBFRK3cbAww_40},
{1, (NimStrPayload*)&TM__LlVUgWt08GOGBFRK3cbAww_16}}
}
;
extern NIM_BOOL nimInErrorMode__system_u4143;
static N_INLINE(void, nimSetMem__system_u2172)(void* a_p0, int v_p1, NI size_p2) {
	void* T1_;
	T1_ = (void*)0;
	T1_ = memset(a_p0, v_p1, ((size_t) (size_p2)));
}
static N_INLINE(void, nimZeroMem)(void* p_p0, NI size_p1) {
	nimSetMem__system_u2172(p_p0, ((int)0), size_p1);
}
N_LIB_PRIVATE N_NIMCALL(NimStringV2, dollar___packagesZdocutilsZrstidx_u13)(tyEnum_IndexEntryKind__bp7boVnNZivfjr9au9bLARfQ e_p0) {
	NimStringV2 result;
	switch (e_p0) {
	case ((tyEnum_IndexEntryKind__bp7boVnNZivfjr9au9bLARfQ)0):
	{
		result = TM__LlVUgWt08GOGBFRK3cbAww_3;
	}
	break;
	case ((tyEnum_IndexEntryKind__bp7boVnNZivfjr9au9bLARfQ)1):
	{
		result = TM__LlVUgWt08GOGBFRK3cbAww_5;
	}
	break;
	case ((tyEnum_IndexEntryKind__bp7boVnNZivfjr9au9bLARfQ)2):
	{
		result = TM__LlVUgWt08GOGBFRK3cbAww_7;
	}
	break;
	case ((tyEnum_IndexEntryKind__bp7boVnNZivfjr9au9bLARfQ)3):
	{
		result = TM__LlVUgWt08GOGBFRK3cbAww_9;
	}
	break;
	case ((tyEnum_IndexEntryKind__bp7boVnNZivfjr9au9bLARfQ)4):
	{
		result = TM__LlVUgWt08GOGBFRK3cbAww_11;
	}
	break;
	case ((tyEnum_IndexEntryKind__bp7boVnNZivfjr9au9bLARfQ)5):
	{
		result = TM__LlVUgWt08GOGBFRK3cbAww_13;
	}
	break;
	default:
	{
		result = TM__LlVUgWt08GOGBFRK3cbAww_15;
	}
	break;
	}
	return result;
}
static N_INLINE(void, nimAddCharV1)(NimStringV2* s_p0, NIM_CHAR c_p1) {
	prepareAdd(s_p0, ((NI)1));
	(*(*s_p0).p).data[(*s_p0).len] = c_p1;
	(*s_p0).len += ((NI)1);
	(*(*s_p0).p).data[(*s_p0).len] = 0;
}
static N_INLINE(void, nimCopyMem)(void* dest_p0, void* source_p1, NI size_p2) {
	void* T1_;
	T1_ = (void*)0;
	T1_ = memcpy(dest_p0, source_p1, ((size_t) (size_p2)));
}
static N_INLINE(void, copyMem__system_u1742)(void* dest_p0, void* source_p1, NI size_p2) {
	nimCopyMem(dest_p0, source_p1, size_p2);
}
static N_INLINE(void, appendString)(NimStringV2* dest_p0, NimStringV2 src_p1) {
	{
		if (!(((NI)0) < src_p1.len)) goto LA3_;
		copyMem__system_u1742(((void*) ((&(*(*dest_p0).p).data[(*dest_p0).len]))), ((void*) ((&(*src_p1.p).data[((NI)0)]))), (src_p1.len));
		(*dest_p0).len += src_p1.len;
		(*(*dest_p0).p).data[(*dest_p0).len] = 0;
	}
LA3_: ;
}
static N_INLINE(void, appendChar)(NimStringV2* dest_p0, NIM_CHAR c_p1) {
	(*(*dest_p0).p).data[(*dest_p0).len] = c_p1;
	(*dest_p0).len += ((NI)1);
	(*(*dest_p0).p).data[(*dest_p0).len] = 0;
}
N_LIB_PRIVATE N_NIMCALL(NimStringV2, quoteIndexColumn__packagesZdocutilsZrstidx_u30)(NimStringV2 text_p0) {
	NimStringV2 result;
	result.len = 0; result.p = NIM_NIL;
	result = rawNewString(((NI)(text_p0.len + ((NI)3))));
	{
		NIM_CHAR c_1;
		NI i_1;
		NI L_1;
		c_1 = (NIM_CHAR)0;
		i_1 = ((NI)0);
		L_1 = text_p0.len;
		{
			while (1) {
				if (!(i_1 < L_1)) goto LA3;
				c_1 = text_p0.p->data[i_1];
				switch (((NU8)(c_1))) {
				case 92:
				{
					prepareAdd((&result), 1);
appendString((&result), TM__LlVUgWt08GOGBFRK3cbAww_17);
				}
				break;
				case 10:
				{
					prepareAdd((&result), 2);
appendString((&result), TM__LlVUgWt08GOGBFRK3cbAww_19);
				}
				break;
				case 13:
				{
				}
				break;
				case 9:
				{
					prepareAdd((&result), 2);
appendString((&result), TM__LlVUgWt08GOGBFRK3cbAww_21);
				}
				break;
				default:
				{
					nimAddCharV1((&result), c_1);
				}
				break;
				}
				i_1 += ((NI)1);
			} LA3: ;
		}
	}
	return result;
}
static N_INLINE(NIM_BOOL*, nimErrorFlag)(void) {
	NIM_BOOL* result;
	result = (&nimInErrorMode__system_u4143);
	return result;
}
N_LIB_PRIVATE N_NIMCALL(tyTuple__dPNkpxgceTc63bP5seHZGw, formatIndexEntry__packagesZdocutilsZrstidx_u76)(tyEnum_IndexEntryKind__bp7boVnNZivfjr9au9bLARfQ kind_p0, NimStringV2 htmlFile_p1, NimStringV2 id_p2, NimStringV2 term_p3, NimStringV2 linkTitle_p4, NimStringV2 linkDesc_p5, NI line_p6) {
	tyTuple__dPNkpxgceTc63bP5seHZGw result;
	NimStringV2 colontmpD_;
	NimStringV2 colontmpD__2;
	NimStringV2 colontmpD__3;
	NimStringV2 colontmpD__4;
	NimStringV2 colontmpD__5;
	NimStringV2 colontmpD__6;
	NimStringV2 T1_;
	NimStringV2 T7_;
	NimStringV2 T8_;
	NimStringV2 T9_;
NIM_BOOL* nimErr_;
{nimErr_ = nimErrorFlag();
	nimZeroMem((void*)(&result), sizeof(tyTuple__dPNkpxgceTc63bP5seHZGw));
	colontmpD_.len = 0; colontmpD_.p = NIM_NIL;
	colontmpD__2.len = 0; colontmpD__2.p = NIM_NIL;
	colontmpD__3.len = 0; colontmpD__3.p = NIM_NIL;
	colontmpD__4.len = 0; colontmpD__4.p = NIM_NIL;
	colontmpD__5.len = 0; colontmpD__5.p = NIM_NIL;
	colontmpD__6.len = 0; colontmpD__6.p = NIM_NIL;
	T1_.len = 0; T1_.p = NIM_NIL;
	T1_ = dollar___packagesZdocutilsZrstidx_u13(kind_p0);
	eqsink___system_u2700((&result.Field0), T1_);
	nimAddCharV1((&result.Field0), 9);
	prepareAdd((&result.Field0), term_p3.len + 0);
appendString((&result.Field0), term_p3);
	nimAddCharV1((&result.Field0), 9);
	prepareAdd((&result.Field0), htmlFile_p1.len + 0);
appendString((&result.Field0), htmlFile_p1);
	{
		if (!(((NI)0) < id_p2.len)) goto LA4_;
		nimAddCharV1((&result.Field0), 35);
		prepareAdd((&result.Field0), id_p2.len + 0);
appendString((&result.Field0), id_p2);
		result.Field1 = NIM_FALSE;
	}
	goto LA2_;
LA4_: ;
	{
		result.Field1 = NIM_TRUE;
	}
LA2_: ;
	T7_.len = 0; T7_.p = NIM_NIL;
	colontmpD_ = quoteIndexColumn__packagesZdocutilsZrstidx_u30(linkTitle_p4);
	if (NIM_UNLIKELY(*nimErr_)) goto BeforeRet_;
	T7_ = rawNewString(colontmpD_.len + 1);
appendChar((&T7_), 9);
appendString((&T7_), colontmpD_);
	colontmpD__2 = T7_;
	prepareAdd((&result.Field0), colontmpD__2.len + 0);
appendString((&result.Field0), colontmpD__2);
	T8_.len = 0; T8_.p = NIM_NIL;
	colontmpD__3 = quoteIndexColumn__packagesZdocutilsZrstidx_u30(linkDesc_p5);
	if (NIM_UNLIKELY(*nimErr_)) goto BeforeRet_;
	T8_ = rawNewString(colontmpD__3.len + 1);
appendChar((&T8_), 9);
appendString((&T8_), colontmpD__3);
	colontmpD__4 = T8_;
	prepareAdd((&result.Field0), colontmpD__4.len + 0);
appendString((&result.Field0), colontmpD__4);
	T9_.len = 0; T9_.p = NIM_NIL;
	colontmpD__5 = dollar___systemZdollars_u9(line_p6);
	if (NIM_UNLIKELY(*nimErr_)) goto BeforeRet_;
	T9_ = rawNewString(colontmpD__5.len + 1);
appendChar((&T9_), 9);
appendString((&T9_), colontmpD__5);
	colontmpD__6 = T9_;
	prepareAdd((&result.Field0), colontmpD__6.len + 0);
appendString((&result.Field0), colontmpD__6);
	prepareAdd((&result.Field0), 1);
appendString((&result.Field0), TM__LlVUgWt08GOGBFRK3cbAww_23);
	eqdestroy___system_u2691(colontmpD__6);
	eqdestroy___system_u2691(colontmpD__5);
	eqdestroy___system_u2691(colontmpD__4);
	eqdestroy___system_u2691(colontmpD__3);
	eqdestroy___system_u2691(colontmpD__2);
	eqdestroy___system_u2691(colontmpD_);
	}BeforeRet_: ;
	return result;
}
N_LIB_PRIVATE N_NIMCALL(void, eqdestroy___packagesZdocutilsZrstidx_u197)(tyObject_IndexEntry__r4FGmtl4yhJtHvFotaeMmQ* dest_p0) {
	eqdestroy___system_u2691((*dest_p0).aux);
	eqdestroy___system_u2691((*dest_p0).module);
	eqdestroy___system_u2691((*dest_p0).linkDesc);
	eqdestroy___system_u2691((*dest_p0).linkTitle);
	eqdestroy___system_u2691((*dest_p0).link);
	eqdestroy___system_u2691((*dest_p0).keyword);
}
N_LIB_PRIVATE N_NIMCALL(void, eqwasMoved___packagesZdocutilsZrstidx_u194)(tyObject_IndexEntry__r4FGmtl4yhJtHvFotaeMmQ* dest_p0) {
	(*dest_p0).kind = 0;
	(*dest_p0).keyword.len = 0; (*dest_p0).keyword.p = NIM_NIL;
	(*dest_p0).link.len = 0; (*dest_p0).link.p = NIM_NIL;
	(*dest_p0).linkTitle.len = 0; (*dest_p0).linkTitle.p = NIM_NIL;
	(*dest_p0).linkDesc.len = 0; (*dest_p0).linkDesc.p = NIM_NIL;
	(*dest_p0).line = 0;
	(*dest_p0).module.len = 0; (*dest_p0).module.p = NIM_NIL;
	(*dest_p0).aux.len = 0; (*dest_p0).aux.p = NIM_NIL;
}
static N_INLINE(int, nimCmpMem)(void* a_p0, void* b_p1, NI size_p2) {
	int result;
	result = memcmp(a_p0, b_p1, ((size_t) (size_p2)));
	return result;
}
static N_INLINE(NIM_BOOL, equalMem__system_u1750)(void* a_p0, void* b_p1, NI size_p2) {
	NIM_BOOL result;
	int T1_;
	T1_ = (int)0;
	T1_ = nimCmpMem(a_p0, b_p1, size_p2);
	result = (T1_ == ((NI32)0));
	return result;
}
static N_INLINE(NIM_BOOL, eqStrings)(NimStringV2 a_p0, NimStringV2 b_p1) {
	NIM_BOOL result;
	NI alen_1;
	NI blen_1;
{	result = NIM_FALSE;
	alen_1 = a_p0.len;
	blen_1 = b_p1.len;
	{
		if (!(alen_1 == blen_1)) goto LA3_;
		{
			if (!(alen_1 == ((NI)0))) goto LA7_;
			result = NIM_TRUE;
			goto BeforeRet_;
		}
LA7_: ;
		result = equalMem__system_u1750(((void*) ((&a_p0.p->data[((NI)0)]))), ((void*) ((&b_p1.p->data[((NI)0)]))), (alen_1));
		goto BeforeRet_;
	}
LA3_: ;
	}BeforeRet_: ;
	return result;
}
N_LIB_PRIVATE N_NIMCALL(tyEnum_IndexEntryKind__bp7boVnNZivfjr9au9bLARfQ, parseIndexEntryKind__packagesZdocutilsZrstidx_u90)(NimStringV2 s_p0) {
	tyEnum_IndexEntryKind__bp7boVnNZivfjr9au9bLARfQ result;
	tyEnum_IndexEntryKind__bp7boVnNZivfjr9au9bLARfQ T1_;
NIM_BOOL* nimErr_;
{nimErr_ = nimErrorFlag();
	result = (tyEnum_IndexEntryKind__bp7boVnNZivfjr9au9bLARfQ)0;
	T1_ = (tyEnum_IndexEntryKind__bp7boVnNZivfjr9au9bLARfQ)0;
	if (eqStrings(s_p0, TM__LlVUgWt08GOGBFRK3cbAww_25)) goto LA2_;
	if (eqStrings(s_p0, TM__LlVUgWt08GOGBFRK3cbAww_27)) goto LA3_;
	if (eqStrings(s_p0, TM__LlVUgWt08GOGBFRK3cbAww_29)) goto LA4_;
	if (eqStrings(s_p0, TM__LlVUgWt08GOGBFRK3cbAww_31)) goto LA5_;
	if (eqStrings(s_p0, TM__LlVUgWt08GOGBFRK3cbAww_33)) goto LA6_;
	if (eqStrings(s_p0, TM__LlVUgWt08GOGBFRK3cbAww_35)) goto LA7_;
	goto LA8_;
	LA2_: ;
	{
		result = ((tyEnum_IndexEntryKind__bp7boVnNZivfjr9au9bLARfQ)4);
	}
	goto LA9_;
	LA3_: ;
	{
		result = ((tyEnum_IndexEntryKind__bp7boVnNZivfjr9au9bLARfQ)5);
	}
	goto LA9_;
	LA4_: ;
	{
		result = ((tyEnum_IndexEntryKind__bp7boVnNZivfjr9au9bLARfQ)2);
	}
	goto LA9_;
	LA5_: ;
	{
		result = ((tyEnum_IndexEntryKind__bp7boVnNZivfjr9au9bLARfQ)3);
	}
	goto LA9_;
	LA6_: ;
	{
		result = ((tyEnum_IndexEntryKind__bp7boVnNZivfjr9au9bLARfQ)1);
	}
	goto LA9_;
	LA7_: ;
	{
		result = ((tyEnum_IndexEntryKind__bp7boVnNZivfjr9au9bLARfQ)0);
	}
	goto LA9_;
	LA8_: ;
	{
		tyObject_ValueError__S29bKZF4TUS33IR7ZXb7fFA* T17_;
		tyArray__YgExxhfgKcesA5EOUj1MOA T18_;
		T17_ = NIM_NIL;
		T17_ = (tyObject_ValueError__S29bKZF4TUS33IR7ZXb7fFA*) nimNewObj(sizeof(tyObject_ValueError__S29bKZF4TUS33IR7ZXb7fFA), NIM_ALIGNOF(tyObject_ValueError__S29bKZF4TUS33IR7ZXb7fFA));
		(*T17_).Sup.Sup.Sup.m_type = (&NTIv2__S29bKZF4TUS33IR7ZXb7fFA_);
		(*T17_).Sup.Sup.name = "ValueError";
		T18_[0] = s_p0;
		(*T17_).Sup.Sup.message = nsuFormatOpenArray(TM__LlVUgWt08GOGBFRK3cbAww_37, T18_, 1);
		if (NIM_UNLIKELY(*nimErr_)) goto BeforeRet_;
		(*T17_).Sup.Sup.parent = ((Exception*) NIM_NIL);
		raiseExceptionEx((Exception*)T17_, "ValueError", "parseIndexEntryKind", "rstidx.nim", 95);
goto BeforeRet_;
	}
LA9_: ;
	}BeforeRet_: ;
	return result;
}
N_LIB_PRIVATE N_NIMCALL(NimStringV2, unquoteIndexColumn__packagesZdocutilsZrstidx_u34)(NimStringV2 text_p0) {
	NimStringV2 result;
NIM_BOOL* nimErr_;
{nimErr_ = nimErrorFlag();
	result.len = 0; result.p = NIM_NIL;
	result = multiReplace__pureZstrutils_u1885(text_p0, TM__LlVUgWt08GOGBFRK3cbAww_38, 3);
	if (NIM_UNLIKELY(*nimErr_)) goto BeforeRet_;
	}BeforeRet_: ;
	return result;
}
N_LIB_PRIVATE N_NIMCALL(void, eqcopy___packagesZdocutilsZrstidx_u200)(tyObject_IndexEntry__r4FGmtl4yhJtHvFotaeMmQ* dest_p0, tyObject_IndexEntry__r4FGmtl4yhJtHvFotaeMmQ* src_p1) {
	(*dest_p0).kind = (*src_p1).kind;
	eqcopy___system_u2694((&(*dest_p0).keyword), (*src_p1).keyword);
	eqcopy___system_u2694((&(*dest_p0).link), (*src_p1).link);
	eqcopy___system_u2694((&(*dest_p0).linkTitle), (*src_p1).linkTitle);
	eqcopy___system_u2694((&(*dest_p0).linkDesc), (*src_p1).linkDesc);
	(*dest_p0).line = (*src_p1).line;
	eqcopy___system_u2694((&(*dest_p0).module), (*src_p1).module);
	eqcopy___system_u2694((&(*dest_p0).aux), (*src_p1).aux);
}
N_LIB_PRIVATE N_NIMCALL(void, parseIdxFile__packagesZdocutilsZrstidx_u113)(NimStringV2 path_p0, tyTuple__mBPo6SdWuL2NLQ9aX5t1kTg* Result) {
	tyTuple__7q7q3E6Oj24ZNVJb9aonhAg tmpTuple_1;
	NimStringV2 base_1;
	NI f_1;
NIM_BOOL oldNimErrFin3_;
NIM_BOOL* nimErr_;
{nimErr_ = nimErrorFlag();
	nimZeroMem((void*)Result, sizeof(tyTuple__mBPo6SdWuL2NLQ9aX5t1kTg));
	nimZeroMem((void*)(&tmpTuple_1), sizeof(tyTuple__7q7q3E6Oj24ZNVJb9aonhAg));
	base_1.len = 0; base_1.p = NIM_NIL;
	f_1 = ((NI)0);
	newSeq__packagesZdocutilsZrstidx_u119((&(*Result).Field0), ((NI)500));
	setLen__packagesZdocutilsZrstidx_u127((&(*Result).Field0), ((NI)0));
	tmpTuple_1 = nossplitFile(path_p0);
	if (NIM_UNLIKELY(*nimErr_)) goto LA1_;
	base_1 = tmpTuple_1.Field1;
	eqwasMoved___system_u2688((&tmpTuple_1.Field1));
	{
		NimStringV2 line_1;
		FILE* f_2;
		NimStringV2 res_1;
		line_1.len = 0; line_1.p = NIM_NIL;
		f_2 = open__stdZsyncio_u485(path_p0, ((tyEnum_FileMode__YkEVJbjDa9aPvYTBr8yiUWg)0), ((NI)8000));
		if (NIM_UNLIKELY(*nimErr_)) goto LA1_;
		res_1.len = 0; res_1.p = NIM_NIL;
		res_1 = rawNewString(((NI)80));
		{
			while (1) {
				NIM_BOOL T7_;
				T7_ = (NIM_BOOL)0;
				T7_ = readLine__stdZsyncio_u290(f_2, (&res_1));
				if (NIM_UNLIKELY(*nimErr_)) goto LA4_;
				if (!T7_) goto LA6;
				line_1 = res_1;
				{
					tySequence__sM4lkSb7zS6F7OVMvW9cffQ cols_1;
					NI s_1;
					tyEnum_IndexEntryKind__bp7boVnNZivfjr9au9bLARfQ T14_;
					NimStringV2 T25_;
					NimStringV2 T26_;
					NI T27_;
					cols_1.len = 0; cols_1.p = NIM_NIL;
					s_1 = nsuFindChar(line_1, 9, ((NI)0), ((NI)-1));
					if (NIM_UNLIKELY(*nimErr_)) goto LA9_;
					{
						if (!(s_1 < ((NI)0))) goto LA12_;
						eqdestroy___system_u5506(cols_1);
						goto LA8;
					}
LA12_: ;
					setLen__packagesZdocutilsZrstidx_u127((&(*Result).Field0), ((NI)(f_1 + ((NI)1))));
					cols_1 = nsuSplitChar(line_1, 9, ((NI)-1));
					if (NIM_UNLIKELY(*nimErr_)) goto LA9_;
					T14_ = (tyEnum_IndexEntryKind__bp7boVnNZivfjr9au9bLARfQ)0;
					T14_ = parseIndexEntryKind__packagesZdocutilsZrstidx_u90(cols_1.p->data[((NI)0)]);
					if (NIM_UNLIKELY(*nimErr_)) goto LA9_;
					(*Result).Field0.p->data[f_1].kind = T14_;
					eqsink___system_u2700((&(*Result).Field0.p->data[f_1].keyword), cols_1.p->data[((NI)1)]);
					eqwasMoved___system_u2688((&cols_1.p->data[((NI)1)]));
					eqsink___system_u2700((&(*Result).Field0.p->data[f_1].link), cols_1.p->data[((NI)2)]);
					eqwasMoved___system_u2688((&cols_1.p->data[((NI)2)]));
					{
						if (!((*Result).Field0.p->data[f_1].kind == ((tyEnum_IndexEntryKind__bp7boVnNZivfjr9au9bLARfQ)3))) goto LA17_;
						eqcopy___system_u2694((&(*Result).Field0.p->data[f_1].module), base_1);
					}
					goto LA15_;
LA17_: ;
					{
						{
							if (!((*Result).Field1.keyword.len == ((NI)0))) goto LA22_;
							eqcopy___system_u2694((&(*Result).Field0.p->data[f_1].module), base_1);
						}
						goto LA20_;
LA22_: ;
						{
							eqcopy___system_u2694((&(*Result).Field0.p->data[f_1].module), (*Result).Field1.keyword);
						}
LA20_: ;
					}
LA15_: ;
					T25_.len = 0; T25_.p = NIM_NIL;
					T25_ = unquoteIndexColumn__packagesZdocutilsZrstidx_u34(cols_1.p->data[((NI)3)]);
					if (NIM_UNLIKELY(*nimErr_)) {eqdestroy___system_u2691(T25_); goto LA9_;}
					eqsink___system_u2700((&(*Result).Field0.p->data[f_1].linkTitle), T25_);
					T26_.len = 0; T26_.p = NIM_NIL;
					T26_ = unquoteIndexColumn__packagesZdocutilsZrstidx_u34(cols_1.p->data[((NI)4)]);
					if (NIM_UNLIKELY(*nimErr_)) {eqdestroy___system_u2691(T26_); goto LA9_;}
					eqsink___system_u2700((&(*Result).Field0.p->data[f_1].linkDesc), T26_);
					T27_ = (NI)0;
					T27_ = nsuParseInt(cols_1.p->data[((NI)5)]);
					if (NIM_UNLIKELY(*nimErr_)) goto LA9_;
					(*Result).Field0.p->data[f_1].line = T27_;
					{
						if (!((*Result).Field0.p->data[f_1].kind == ((tyEnum_IndexEntryKind__bp7boVnNZivfjr9au9bLARfQ)1) || (*Result).Field0.p->data[f_1].kind == ((tyEnum_IndexEntryKind__bp7boVnNZivfjr9au9bLARfQ)0))) goto LA30_;
						eqcopy___packagesZdocutilsZrstidx_u200((&(*Result).Field1), (&(*Result).Field0.p->data[f_1]));
					}
LA30_: ;
					f_1 += ((NI)1);
					{
						LA9_:;
					}
					{
						eqdestroy___system_u5506(cols_1);
					}
					if (NIM_UNLIKELY(*nimErr_)) goto LA4_;
				} LA8: ;
			} LA6: ;
		}
		{
			LA4_:;
		}
		{
			eqdestroy___system_u2691(res_1);
		}
		if (NIM_UNLIKELY(*nimErr_)) goto LA3_;
		{
			LA3_:;
		}
		{
			oldNimErrFin3_ = *nimErr_; *nimErr_ = NIM_FALSE;
			close__stdZsyncio_u268(f_2);
			if (NIM_UNLIKELY(*nimErr_)) goto LA1_;
			*nimErr_ = oldNimErrFin3_;
		}
		if (NIM_UNLIKELY(*nimErr_)) goto LA1_;
	}
	{
		LA1_:;
	}
	{
		eqdestroy___system_u2691(base_1);
		eqdestroy___pureZos_u200(tmpTuple_1);
	}
	if (NIM_UNLIKELY(*nimErr_)) goto BeforeRet_;
	}BeforeRet_: ;
}
N_LIB_PRIVATE N_NIMCALL(void, eqdestroy___packagesZdocutilsZrstidx_u281)(tySequence__36jA1xDCIBAS29cySYLQ7kQ dest_p0) {
	NI colontmp_;
	colontmp_ = ((NI)0);
	{
		while (1) {
			NI T3_;
			T3_ = dest_p0.len;
			if (!(colontmp_ < T3_)) goto LA2;
			eqdestroy___system_u2691(dest_p0.p->data[colontmp_].aux);
			eqdestroy___system_u2691(dest_p0.p->data[colontmp_].module);
			eqdestroy___system_u2691(dest_p0.p->data[colontmp_].linkDesc);
			eqdestroy___system_u2691(dest_p0.p->data[colontmp_].linkTitle);
			eqdestroy___system_u2691(dest_p0.p->data[colontmp_].link);
			eqdestroy___system_u2691(dest_p0.p->data[colontmp_].keyword);
			colontmp_ += ((NI)1);
		} LA2: ;
	}
	if (dest_p0.p && !(dest_p0.p->cap & NIM_STRLIT_FLAG)) {
 alignedDealloc(dest_p0.p, NIM_ALIGNOF(tyObject_IndexEntry__r4FGmtl4yhJtHvFotaeMmQ));
}
}
N_LIB_PRIVATE N_NIMCALL(NIM_BOOL, isDocumentationTitle__packagesZdocutilsZrstidx_u24)(NimStringV2 hyperlink_p0) {
	NIM_BOOL result;
	NI T1_;
NIM_BOOL* nimErr_;
{nimErr_ = nimErrorFlag();
	result = (NIM_BOOL)0;
	T1_ = (NI)0;
	T1_ = nsuFindChar(hyperlink_p0, 35, ((NI)0), ((NI)-1));
	if (NIM_UNLIKELY(*nimErr_)) goto BeforeRet_;
	result = (T1_ < ((NI)0));
	}BeforeRet_: ;
	return result;
}
N_LIB_PRIVATE N_NIMCALL(void, eqwasMoved___packagesZdocutilsZrstidx_u278)(tySequence__36jA1xDCIBAS29cySYLQ7kQ* dest_p0) {
	(*dest_p0).len = 0; (*dest_p0).p = NIM_NIL;
}
static N_INLINE(NI, emarkamp___pureZhashes_u5)(NI h_p0, NI val_p1) {
	NI result;
	NU h_2;
	NU val_2;
	NU res_1;
	h_2 = ((NU) (h_p0));
	val_2 = ((NU) (val_p1));
	res_1 = (NU)((NU32)(h_2) + (NU32)(val_2));
	res_1 = (NU)((NU32)(res_1) + (NU32)((NU)((NU32)(res_1) << (NU32)(((NI)10) & (32 - 1)))));
	res_1 = (NU)(res_1 ^ (NU)((NU32)(res_1) >> (NU32)(((NI)6) & (32 - 1))));
	result = ((NI) (res_1));
	return result;
}
static N_INLINE(NI, emarkdollar___pureZhashes_u20)(NI h_p0) {
	NI result;
	NU h_2;
	NU res_1;
	h_2 = ((NU) (h_p0));
	res_1 = (NU)((NU32)(h_2) + (NU32)((NU)((NU32)(h_2) << (NU32)(((NI)3) & (32 - 1)))));
	res_1 = (NU)(res_1 ^ (NU)((NU32)(res_1) >> (NU32)(((NI)11) & (32 - 1))));
	res_1 = (NU)((NU32)(res_1) + (NU32)((NU)((NU32)(res_1) << (NU32)(((NI)15) & (32 - 1)))));
	result = ((NI) (res_1));
	return result;
}
N_LIB_PRIVATE N_NIMCALL(NI, hash__packagesZdocutilsZrstidx_u322)(tyObject_IndexEntry__r4FGmtl4yhJtHvFotaeMmQ* x_p0) {
	NI result;
	NI T1_;
	NI T2_;
	NI T3_;
	NI T4_;
NIM_BOOL* nimErr_;
{nimErr_ = nimErrorFlag();
	result = (NI)0;
	T1_ = (NI)0;
	T1_ = hash__pureZhashes_u587((*x_p0).keyword);
	if (NIM_UNLIKELY(*nimErr_)) goto BeforeRet_;
	T2_ = (NI)0;
	T2_ = hash__pureZhashes_u587((*x_p0).link);
	if (NIM_UNLIKELY(*nimErr_)) goto BeforeRet_;
	result = emarkamp___pureZhashes_u5(T1_, T2_);
	if (NIM_UNLIKELY(*nimErr_)) goto BeforeRet_;
	T3_ = (NI)0;
	T3_ = hash__pureZhashes_u587((*x_p0).linkTitle);
	if (NIM_UNLIKELY(*nimErr_)) goto BeforeRet_;
	result = emarkamp___pureZhashes_u5(result, T3_);
	if (NIM_UNLIKELY(*nimErr_)) goto BeforeRet_;
	T4_ = (NI)0;
	T4_ = hash__pureZhashes_u587((*x_p0).linkDesc);
	if (NIM_UNLIKELY(*nimErr_)) goto BeforeRet_;
	result = emarkamp___pureZhashes_u5(result, T4_);
	if (NIM_UNLIKELY(*nimErr_)) goto BeforeRet_;
	result = emarkdollar___pureZhashes_u20(result);
	if (NIM_UNLIKELY(*nimErr_)) goto BeforeRet_;
	}BeforeRet_: ;
	return result;
}
N_LIB_PRIVATE N_NIMCALL(void, eqsink___packagesZdocutilsZrstidx_u290)(tySequence__36jA1xDCIBAS29cySYLQ7kQ* dest_p0, tySequence__36jA1xDCIBAS29cySYLQ7kQ src_p1) {
	if ((*dest_p0).p != src_p1.p) {	eqdestroy___packagesZdocutilsZrstidx_u281((*dest_p0));
	}
(*dest_p0).len = src_p1.len; (*dest_p0).p = src_p1.p;
}
N_LIB_PRIVATE N_NIMCALL(tySequence__36jA1xDCIBAS29cySYLQ7kQ, eqdup___packagesZdocutilsZrstidx_u287)(tySequence__36jA1xDCIBAS29cySYLQ7kQ src_p0) {
	tySequence__36jA1xDCIBAS29cySYLQ7kQ result;
	NI T1_;
	NI colontmp_;
	result.len = 0; result.p = NIM_NIL;
	T1_ = src_p0.len;
	setLen__packagesZdocutilsZrstidx_u127((&result), T1_);
	colontmp_ = ((NI)0);
	{
		while (1) {
			NI T4_;
			T4_ = result.len;
			if (!(colontmp_ < T4_)) goto LA3;
			result.p->data[colontmp_].kind = src_p0.p->data[colontmp_].kind;
			result.p->data[colontmp_].keyword = eqdup___system_u2697(src_p0.p->data[colontmp_].keyword);
			result.p->data[colontmp_].link = eqdup___system_u2697(src_p0.p->data[colontmp_].link);
			result.p->data[colontmp_].linkTitle = eqdup___system_u2697(src_p0.p->data[colontmp_].linkTitle);
			result.p->data[colontmp_].linkDesc = eqdup___system_u2697(src_p0.p->data[colontmp_].linkDesc);
			result.p->data[colontmp_].line = src_p0.p->data[colontmp_].line;
			result.p->data[colontmp_].module = eqdup___system_u2697(src_p0.p->data[colontmp_].module);
			result.p->data[colontmp_].aux = eqdup___system_u2697(src_p0.p->data[colontmp_].aux);
			colontmp_ += ((NI)1);
		} LA3: ;
	}
	return result;
}
N_LIB_PRIVATE N_NIMCALL(void, eqdestroy___packagesZdocutilsZrst_u16216)(tyTuple__mBPo6SdWuL2NLQ9aX5t1kTg* dest_p0) {
	eqdestroy___packagesZdocutilsZrstidx_u281((*dest_p0).Field0);
	eqdestroy___system_u2691((*dest_p0).Field1.aux);
	eqdestroy___system_u2691((*dest_p0).Field1.module);
	eqdestroy___system_u2691((*dest_p0).Field1.linkDesc);
	eqdestroy___system_u2691((*dest_p0).Field1.linkTitle);
	eqdestroy___system_u2691((*dest_p0).Field1.link);
	eqdestroy___system_u2691((*dest_p0).Field1.keyword);
}
N_LIB_PRIVATE N_NIMCALL(void, eqdup___packagesZdocutilsZrstidx_u203)(tyObject_IndexEntry__r4FGmtl4yhJtHvFotaeMmQ* src_p0, tyObject_IndexEntry__r4FGmtl4yhJtHvFotaeMmQ* Result) {
	nimZeroMem((void*)Result, sizeof(tyObject_IndexEntry__r4FGmtl4yhJtHvFotaeMmQ));
	(*Result).kind = (*src_p0).kind;
	(*Result).keyword = eqdup___system_u2697((*src_p0).keyword);
	(*Result).link = eqdup___system_u2697((*src_p0).link);
	(*Result).linkTitle = eqdup___system_u2697((*src_p0).linkTitle);
	(*Result).linkDesc = eqdup___system_u2697((*src_p0).linkDesc);
	(*Result).line = (*src_p0).line;
	(*Result).module = eqdup___system_u2697((*src_p0).module);
	(*Result).aux = eqdup___system_u2697((*src_p0).aux);
}
N_LIB_PRIVATE N_NIMCALL(void, eqsink___packagesZdocutilsZrstidx_u206)(tyObject_IndexEntry__r4FGmtl4yhJtHvFotaeMmQ* dest_p0, tyObject_IndexEntry__r4FGmtl4yhJtHvFotaeMmQ* src_p1) {
	(*dest_p0).kind = (*src_p1).kind;
	if ((*dest_p0).keyword.p != (*src_p1).keyword.p) {	eqdestroy___system_u2691((*dest_p0).keyword);
	}
(*dest_p0).keyword.len = (*src_p1).keyword.len; (*dest_p0).keyword.p = (*src_p1).keyword.p;
	if ((*dest_p0).link.p != (*src_p1).link.p) {	eqdestroy___system_u2691((*dest_p0).link);
	}
(*dest_p0).link.len = (*src_p1).link.len; (*dest_p0).link.p = (*src_p1).link.p;
	if ((*dest_p0).linkTitle.p != (*src_p1).linkTitle.p) {	eqdestroy___system_u2691((*dest_p0).linkTitle);
	}
(*dest_p0).linkTitle.len = (*src_p1).linkTitle.len; (*dest_p0).linkTitle.p = (*src_p1).linkTitle.p;
	if ((*dest_p0).linkDesc.p != (*src_p1).linkDesc.p) {	eqdestroy___system_u2691((*dest_p0).linkDesc);
	}
(*dest_p0).linkDesc.len = (*src_p1).linkDesc.len; (*dest_p0).linkDesc.p = (*src_p1).linkDesc.p;
	(*dest_p0).line = (*src_p1).line;
	if ((*dest_p0).module.p != (*src_p1).module.p) {	eqdestroy___system_u2691((*dest_p0).module);
	}
(*dest_p0).module.len = (*src_p1).module.len; (*dest_p0).module.p = (*src_p1).module.p;
	if ((*dest_p0).aux.p != (*src_p1).aux.p) {	eqdestroy___system_u2691((*dest_p0).aux);
	}
(*dest_p0).aux.len = (*src_p1).aux.len; (*dest_p0).aux.p = (*src_p1).aux.p;
}
N_LIB_PRIVATE N_NIMCALL(NI, cmp__packagesZdocutilsZrstidx_u318)(tyObject_IndexEntry__r4FGmtl4yhJtHvFotaeMmQ* a_p0, tyObject_IndexEntry__r4FGmtl4yhJtHvFotaeMmQ* b_p1) {
	NI result;
NIM_BOOL* nimErr_;
{nimErr_ = nimErrorFlag();
	result = (NI)0;
	result = nsuCmpIgnoreStyle((*a_p0).keyword, (*b_p1).keyword);
	if (NIM_UNLIKELY(*nimErr_)) goto BeforeRet_;
	{
		if (!(result == ((NI)0))) goto LA3_;
		result = nsuCmpIgnoreStyle((*a_p0).link, (*b_p1).link);
		if (NIM_UNLIKELY(*nimErr_)) goto BeforeRet_;
	}
LA3_: ;
	}BeforeRet_: ;
	return result;
}
