MCPcopy
hub / github.com/josdejong/mathjs / myFunction

Function myFunction

test/unit-tests/expression/node/FunctionNode.test.js:110–116  ·  view source on GitHub ↗
(args, _math, _scope)

Source from the content-addressed store, hash-verified

108 it('should compile a FunctionNode with a raw function', function () {
109 const mymath = math.create()
110 function myFunction (args, _math, _scope) {
111 assert.strictEqual(args.length, 2)
112 assert(args[0] instanceof mymath.Node)
113 assert(args[1] instanceof mymath.Node)
114 assert.deepStrictEqual(toObject(_scope), scope)
115 return 'myFunction(' + args.join(', ') + ')'
116 }
117 myFunction.rawArgs = true
118 mymath.import({ myFunction })
119

Callers

nothing calls this directly

Calls 1

toObjectFunction · 0.90

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…