MCPcopy Create free account
hub / github.com/emscripten-core/emscripten / makeInlineCalculation

Function makeInlineCalculation

src/parseTools.mjs:270–276  ·  view source on GitHub ↗
(expression, value, tempVar)

Source from the content-addressed store, hash-verified

268// replace VALUE with value. If value is not a simple identifier of a variable,
269// value will be replaced with tempVar.
270function makeInlineCalculation(expression, value, tempVar) {
271 if (!isNiceIdent(value)) {
272 expression = `${tempVar} = ${value},${expression}`;
273 value = tempVar;
274 }
275 return `(${expression.replace(/VALUE/g, value)})`;
276}
277
278// XXX Make all i64 parts signed
279

Callers 1

splitI64Function · 0.85

Calls 1

isNiceIdentFunction · 0.85

Tested by

no test coverage detected