MCPcopy Create free account
hub / github.com/Moddable-OpenSource/moddable / fxBufferSymbols

Function fxBufferSymbols

xs/tools/xslBase.c:146–172  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

144}
145
146void fxBufferSymbols(txLinker* linker)
147{
148 txByte* p;
149 txS2 c, i;
150 txLinkerSymbol** address;
151 txInteger size;
152
153 c = (txS2)(linker->symbolIndex);
154 size = 2;
155 address = &linker->symbolArray[0];
156 for (i = 0; i < c; i++) {
157 size += (*address)->length;
158 address++;
159 }
160
161 linker->symbolsBuffer = fxNewLinkerChunk(linker, size);
162 linker->symbolsSize = size;
163
164 p = linker->symbolsBuffer;
165 mxEncode2(p, c);
166 address = &(linker->symbolArray[0]);
167 for (i = 0; i < c; i++) {
168 c_memcpy(p, (*address)->string, (*address)->length);
169 p += (*address)->length;
170 address++;
171 }
172}
173
174void fxDefaultSymbols(txLinker* linker)
175{

Callers 2

mainFunction · 0.85
mainFunction · 0.85

Calls 1

fxNewLinkerChunkFunction · 0.85

Tested by

no test coverage detected