From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from duke.felloff.net ([216.126.196.34]) by ewsd; Sun Oct 25 19:18:23 -0400 2020 Message-ID: <41990F43512FF80F5598EE88078499ED@felloff.net> Date: Mon, 26 Oct 2020 00:18:12 +0100 From: cinap_lenrek@felloff.net To: 9front@9front.org Subject: Re: [9front] rc: null list in concatenation line numbers In-Reply-To: <37CF109B904B5F178848E0FADF7E5CAF@eigenstate.org> MIME-Version: 1.0 Content-Type: text/plain; charset="US-ASCII" Content-Transfer-Encoding: 7bit List-ID: <9front.9front.org> List-Help: X-Glyph: ➈ X-Bullshit: self-healing framework map/reduce HTTP over HTML strategy shader + if(f|l != 0){ + emitf(Xloc); + emiti(f|l); + } you need parentesis there around: f|l + /* + * These are small enough that with a ton of sourcing, + * overflow is a realistic risk. If we run out of files, + * set to file 0, which is always '???' + */ + f = (t->file > LFMAX) ? 0 : t->file << LSHIFT; + l = (t->line > LMASK) ? -1 : t->line; setting line to -1 also implicitely makes the file all ones... + if(i == nlexpath){ + if(nlexpath < LFMAX){ + lexpath = erealloc(lexpath, (nlexpath + 1)*sizeof(char*)); + lexpath[nlexpath] = estrdup(zero); + lexfile = nlexpath++; + }else + lexfile = 0; + } might want to use doubling the size for each realloc... also wonder if the file can even change in the tree... the file would only change when we source a file, no? so i wonder if we need to keep track of the file in the tree at all, and not just update it at runtime in the thread. -- cinap