N_NIMCALL(void, openbaselexer_179035)(Tbaselexer179024* L, Tllstream178204* inputstream, NI buflen) { NI TMP2155; void* LOC5; NI TMP2156; nimfr("openBaseLexer", "nimlexbase.nim") nimln(147, "nimlexbase.nim"); { if (!!((((NI) 0) < buflen))) goto LA3; failedassertimpl_87217(((NimStringDesc*) &TMP2154)); } LA3: ; nimln(148, "nimlexbase.nim"); (*L).bufpos = ((NI) 0); nimln(149, "nimlexbase.nim"); (*L).buflen = buflen; nimln(150, "nimlexbase.nim"); TMP2155 = mulInt(buflen, ((NI) 1)); LOC5 = 0; LOC5 = alloc_6001(((NI)chckRange((NI)(TMP2155), ((NI) 0), ((NI) 2147483647)))); (*L).buf = ((NCSTRING) (LOC5)); nimln(151, "nimlexbase.nim"); TMP2156 = subInt(buflen, ((NI) 1)); (*L).sentinel = (NI)(TMP2156); nimln(152, "nimlexbase.nim"); (*L).linestart = ((NI) 0); nimln(153, "nimlexbase.nim"); (*L).linenumber = ((NI) 1); nimln(154, "nimlexbase.nim"); unsureAsgnRef((void**) (&(*L).stream), inputstream); nimln(155, "nimlexbase.nim"); fillbuffer_179097(L); nimln(156, "nimlexbase.nim"); skiputf8bom_180416(L); popFrame(); }
N_NIMCALL(void, openbaselexer_179035)(Tbaselexer179024* L, Tllstream178204* inputstream, NI buflen) { void* LOC1; (*L).bufpos = ((NI) 0); (*L).buflen = buflen; LOC1 = 0; LOC1 = alloc_6001(((NI) ((NI)(buflen * ((NI) 1))))); (*L).buf = ((NCSTRING) (LOC1)); (*L).sentinel = (NI)(buflen - ((NI) 1)); (*L).linestart = ((NI) 0); (*L).linenumber = ((NI) 1); unsureAsgnRef((void**) (&(*L).stream), inputstream); fillbuffer_179097(L); skiputf8bom_180416(L); }