MCPcopy Create free account
hub / github.com/cortex-js/compute-engine / enclosure

Function enclosure

src/math-json/parse-sympy.ts:279–293  ·  view source on GitHub ↗
(
  s: string,
  i: number
)

Source from the content-addressed store, hash-verified

277function enclosure(
278 s: string,
279 i: number
280): [index: number, result: Expression | null] {
281 let r: Expression | null;
282 [i, r] = parenth_form(s, i);
283 // Collection displays, comprehensions, and `yield` expressions are not
284 // supported, so parentheses are the only recognized enclosure.
285 // if (r === null) [i, r] = list_display(s, i);
286 // if (r === null) [i, r] = dict_display(s, i);
287 // if (r === null) [i, r] = set_display(s, i);
288 // if (r === null) [i, r] = generator_expression(s, i);
289 // if (r === null) [i, r] = yield_atom(s, i);
290
291 return [i, r];
292}
293
294function atom(
295 s: string,
296 start: number

Callers 1

atomFunction · 0.85

Calls 1

parenth_formFunction · 0.85

Tested by

no test coverage detected