N_NIMCALL(tllstream173204*, filterstrip_216008)(tllstream173204* stdin_216010, NimStringDesc* filename, tnode185813* call) { tllstream173204* result; NimStringDesc* pattern; NIM_BOOL leading; NIM_BOOL trailing; NimStringDesc* line; nimfr("filterStrip", "filters.nim") result = 0; nimln(58, "filters.nim"); pattern = strarg_216021(call, ((NimStringDesc*) &TMP2658), 1, ((NimStringDesc*) &TMP2659)); nimln(59, "filters.nim"); leading = boolarg_216028(call, ((NimStringDesc*) &TMP2660), 2, NIM_TRUE); nimln(60, "filters.nim"); trailing = boolarg_216028(call, ((NimStringDesc*) &TMP2661), 3, NIM_TRUE); nimln(61, "filters.nim"); result = llstreamopen_173218(((NimStringDesc*) &TMP2659)); nimln(62, "filters.nim"); nimln(62, "filters.nim"); line = rawNewString(80); nimln(63, "filters.nim"); while (1) { NIM_BOOL LOC2; NimStringDesc* stripped; nimln(63, "filters.nim"); LOC2 = 0; LOC2 = llstreamreadline_173248(stdin_216010, &line); if (!LOC2) goto LA1; nimln(64, "filters.nim"); stripped = nsuStrip(line, leading, trailing); nimln(65, "filters.nim"); { NIM_BOOL LOC5; nimln(65, "filters.nim"); LOC5 = 0; nimln(65, "filters.nim"); nimln(65, "filters.nim"); LOC5 = (pattern->Sup.len == 0); if (LOC5) goto LA6; nimln(65, "filters.nim"); LOC5 = nsuStartsWith(stripped, pattern); LA6: ; if (!LOC5) goto LA7; nimln(66, "filters.nim"); llstreamwriteln_173274(result, stripped); } goto LA3; LA7: ; { nimln(68, "filters.nim"); llstreamwriteln_173274(result, line); } LA3: ; } LA1: ; nimln(69, "filters.nim"); llstreamclose_173238(stdin_216010); popFrame(); return result; }
N_NIMCALL(NimStringDesc*, npocmdLineRest)(TY189404* P_189913) { NimStringDesc* Result_189914; NimStringDesc* LOC1; Result_189914 = 0; LOC1 = 0; LOC1 = copyStrLast((*P_189913).Cmd, (*P_189913).Pos, (NI64)((*P_189913).Cmd->Sup.len - 1)); Result_189914 = nsuStrip(LOC1, NIM_TRUE, NIM_TRUE); return Result_189914; }
N_NIMCALL(NimStringDesc*, npocmdLineRest)(Optparser176011* p) { NimStringDesc* result; NimStringDesc* LOC1; result = 0; LOC1 = 0; LOC1 = copyStrLast((*p).cmd, (*p).pos, (NI)(((*p).cmd ? (*p).cmd->Sup.len : 0) - ((NI) 1))); result = nsuStrip(LOC1, NIM_TRUE, NIM_TRUE); return result; }
N_NIMCALL(NimStringDesc*, npocmdLineRest)(toptparser416607* p) { NimStringDesc* result; NI TMP7031; NimStringDesc* LOC1; nimfr("cmdLineRest", "parseopt.nim") result = 0; nimln(128, "parseopt.nim"); nimln(128, "parseopt.nim"); nimln(128, "parseopt.nim"); nimln(128, "parseopt.nim"); nimln(128, "parseopt.nim"); TMP7031 = subInt((*p).Cmd->Sup.len, 1); LOC1 = 0; LOC1 = copyStrLast((*p).Cmd, (*p).Pos, (NI32)(TMP7031)); result = nsuStrip(LOC1, NIM_TRUE, NIM_TRUE); popFrame(); return result; }N_NOINLINE(void, pureparseoptInit)(void) {
N_NIMCALL(NimStringDesc*, npocmdLineRest)(toptparser527807* p) { NimStringDesc* result; NI TMP7636; NimStringDesc* LOC1; nimfr("cmdLineRest", "parseopt.nim") result = 0; nimln(128, "parseopt.nim"); nimln(128, "parseopt.nim"); nimln(128, "parseopt.nim"); nimln(128, "parseopt.nim"); nimln(128, "parseopt.nim"); TMP7636 = subInt((*p).Cmd->Sup.len, 1); LOC1 = 0; LOC1 = copyStrLast((*p).Cmd, (*p).Pos, (NI64)(TMP7636)); result = nsuStrip(LOC1, NIM_TRUE, NIM_TRUE); popFrame(); return result; }
N_NIMCALL(Tllstream202204*, filterstrip_236006)(Tllstream202204* stdin_236008, NimStringDesc* filename, Tnode214790* call) { Tllstream202204* result; NimStringDesc* pattern; NIM_BOOL leading; NIM_BOOL trailing; NimStringDesc* line; result = 0; pattern = strarg_236017(call, ((NimStringDesc*) &TMP1543), ((NI) 1), ((NimStringDesc*) &TMP1544)); leading = boolarg_236023(call, ((NimStringDesc*) &TMP1547), ((NI) 2), NIM_TRUE); trailing = boolarg_236023(call, ((NimStringDesc*) &TMP1548), ((NI) 3), NIM_TRUE); result = llstreamopen_202217(((NimStringDesc*) &TMP1544)); line = rawNewString(((NI) 80)); { while (1) { NIM_BOOL LOC3; NimStringDesc* stripped; LOC3 = 0; LOC3 = llstreamreadline_202550(stdin_236008, (&line)); if (!LOC3) goto LA2; stripped = nsuStrip(line, leading, trailing, TMP1549); { NIM_BOOL LOC6; LOC6 = 0; LOC6 = ((pattern ? pattern->Sup.len : 0) == ((NI) 0)); if (LOC6) goto LA7; LOC6 = nsuStartsWith(stripped, pattern); LA7: ; if (!LOC6) goto LA8; llstreamwriteln_202608(result, stripped); } goto LA4; LA8: ; { llstreamwriteln_202608(result, line); } LA4: ; } LA2: ; } llstreamclose_202277(stdin_236008); return result; }
N_NIMCALL(Tllstream179204*, filterstrip_218012)(Tllstream179204* stdin_218014, NimStringDesc* filename, Tnode192813* call) { Tllstream179204* result; NimStringDesc* pattern; NIM_BOOL leading; NIM_BOOL trailing; NimStringDesc* line; result = 0; pattern = strarg_218029(call, ((NimStringDesc*) &TMP1430), ((NI) 1), ((NimStringDesc*) &TMP1431)); leading = boolarg_218038(call, ((NimStringDesc*) &TMP1434), ((NI) 2), NIM_TRUE); trailing = boolarg_218038(call, ((NimStringDesc*) &TMP1435), ((NI) 3), NIM_TRUE); result = llstreamopen_179220(((NimStringDesc*) &TMP1431)); line = rawNewString(((NI) 80)); { while (1) { NIM_BOOL LOC3; NimStringDesc* stripped; LOC3 = 0; LOC3 = llstreamreadline_179610(stdin_218014, (&line)); if (!LOC3) goto LA2; stripped = nsuStrip(line, leading, trailing); { NIM_BOOL LOC6; LOC6 = 0; LOC6 = ((pattern ? pattern->Sup.len : 0) == ((NI) 0)); if (LOC6) goto LA7; LOC6 = nsuStartsWith(stripped, pattern); LA7: ; if (!LOC6) goto LA8; llstreamwriteln_179686(result, stripped); } goto LA4; LA8: ; { llstreamwriteln_179686(result, line); } LA4: ; } LA2: ; } llstreamclose_179310(stdin_218014); return result; }
N_NIMCALL(Tllstream_IHsOGFu33dIY69a9bLlFHlHw*, filterstrip_8vZ6X8KZZNI4xsTx2A9bPBw)(Tllstream_IHsOGFu33dIY69a9bLlFHlHw* stdin_kOIrmbkfx9bA9aensSDHNIyg, NimStringDesc* filename0, Tnode_bROa11lyF5vxEN9aYNbHmhw* call0) { Tllstream_IHsOGFu33dIY69a9bLlFHlHw* result0; NimStringDesc* pattern0; NIM_BOOL leading0; NIM_BOOL trailing0; NimStringDesc* line0; result0 = (Tllstream_IHsOGFu33dIY69a9bLlFHlHw*)0; pattern0 = strarg_hrsET2VpzHuUBdZObITwmQ(call0, ((NimStringDesc*) &T_TpC7tIfhGAaosc7HIsUuXA_2), ((NI) 1), ((NimStringDesc*) &T_TpC7tIfhGAaosc7HIsUuXA_3)); leading0 = boolarg_J1A66BRI6GgqzqhU0EZntw(call0, ((NimStringDesc*) &T_TpC7tIfhGAaosc7HIsUuXA_6), ((NI) 2), NIM_TRUE); trailing0 = boolarg_J1A66BRI6GgqzqhU0EZntw(call0, ((NimStringDesc*) &T_TpC7tIfhGAaosc7HIsUuXA_7), ((NI) 3), NIM_TRUE); result0 = llstreamopen_HQSZA6kzdilYF0Pf022dhA(((NimStringDesc*) &T_TpC7tIfhGAaosc7HIsUuXA_3)); line0 = rawNewString(((NI) 80)); { while (1) { NIM_BOOL LOC3; NimStringDesc* stripped0; LOC3 = (NIM_BOOL)0; LOC3 = llstreamreadline_Qwm1ilRhcaI3znjOGn4xBg(stdin_kOIrmbkfx9bA9aensSDHNIyg, (&line0)); if (!LOC3) goto LA2; stripped0 = nsuStrip(line0, leading0, trailing0, T_TpC7tIfhGAaosc7HIsUuXA_8); { NIM_BOOL LOC6; LOC6 = (NIM_BOOL)0; LOC6 = ((pattern0 ? pattern0->Sup.len : 0) == ((NI) 0)); if (LOC6) goto LA7; LOC6 = nsuStartsWith(stripped0, pattern0); LA7: ; if (!LOC6) goto LA8; llstreamwriteln_p1fwzwO1YKdwAKg6V27RTw_2(result0, stripped0); } goto LA4; LA8: ; { llstreamwriteln_p1fwzwO1YKdwAKg6V27RTw_2(result0, line0); } LA4: ; } LA2: ; } llstreamclose_TQe1mwqs39ccgay5ywsr9azw(stdin_kOIrmbkfx9bA9aensSDHNIyg); return result0; }
N_NIMCALL(Tllstream280204*, filterstrip_313006_1413030668)(Tllstream280204* stdin_313008_1413030668, NimStringDesc* filename0, Tnode290802* call0) { Tllstream280204* result0; NimStringDesc* pattern0; NIM_BOOL leading0; NIM_BOOL trailing0; NimStringDesc* line0; result0 = (Tllstream280204*)0; pattern0 = strarg_313017_1413030668(call0, ((NimStringDesc*) &T1413030668_2), ((NI) 1), ((NimStringDesc*) &T1413030668_3)); leading0 = boolarg_313023_1413030668(call0, ((NimStringDesc*) &T1413030668_6), ((NI) 2), NIM_TRUE); trailing0 = boolarg_313023_1413030668(call0, ((NimStringDesc*) &T1413030668_7), ((NI) 3), NIM_TRUE); result0 = llstreamopen_280218_597494479(((NimStringDesc*) &T1413030668_3)); line0 = rawNewString(((NI) 80)); { while (1) { NIM_BOOL LOC3; NimStringDesc* stripped0; LOC3 = (NIM_BOOL)0; LOC3 = llstreamreadline_280550_597494479(stdin_313008_1413030668, (&line0)); if (!LOC3) goto LA2; stripped0 = nsuStrip(line0, leading0, trailing0, T1413030668_8); { NIM_BOOL LOC6; LOC6 = (NIM_BOOL)0; LOC6 = ((pattern0 ? pattern0->Sup.len : 0) == ((NI) 0)); if (LOC6) goto LA7; LOC6 = nsuStartsWith(stripped0, pattern0); LA7: ; if (!LOC6) goto LA8; llstreamwriteln_280608_597494479(result0, stripped0); } goto LA4; LA8: ; { llstreamwriteln_280608_597494479(result0, line0); } LA4: ; } LA2: ; } llstreamclose_280278_597494479(stdin_313008_1413030668); return result0; }
N_NIMCALL(TY71204*, Filterstrip_86009)(TY71204* Stdin_86011, NimStringDesc* Filename_86012, TY50526* Call_86013) { TY71204* Result_86358; NimStringDesc* Pattern_86359; NIM_BOOL Leading_86360; NIM_BOOL Trailing_86361; NIM_BOOL LOC2; NimStringDesc* Line_86362; NimStringDesc* Stripped_86363; NIM_BOOL LOC4; Result_86358 = 0; Pattern_86359 = 0; Pattern_86359 = Strarg_86020(Call_86013, ((NimStringDesc*) &TMP191856), 1, ((NimStringDesc*) &TMP191857)); Leading_86360 = 0; Leading_86360 = Boolarg_86026(Call_86013, ((NimStringDesc*) &TMP191860), 2, NIM_TRUE); Trailing_86361 = 0; Trailing_86361 = Boolarg_86026(Call_86013, ((NimStringDesc*) &TMP191861), 3, NIM_TRUE); Result_86358 = Llstreamopen_71217(((NimStringDesc*) &TMP191857)); while (1) { LOC2 = Llstreamatend_71263(Stdin_86011); if (!!(LOC2)) goto LA1; Line_86362 = 0; Line_86362 = Llstreamreadline_71240(Stdin_86011); Stripped_86363 = 0; Stripped_86363 = nsuStrip(Line_86362, Leading_86360, Trailing_86361); LOC4 = (Pattern_86359->Sup.len == 0); if (LOC4) goto LA5; LOC4 = nsuStartsWith(Stripped_86363, Pattern_86359); LA5: ; if (!LOC4) goto LA6; Llstreamwriteln_71259(Result_86358, Stripped_86363); goto LA3; LA6: ; Llstreamwriteln_71259(Result_86358, Line_86362); LA3: ; } LA1: ; Llstreamclose_71232(Stdin_86011); return Result_86358; }