MCPcopy Index your code
hub / github.com/josdejong/mathjs / createError

Function createError

src/expression/parse.js:1845–1851  ·  view source on GitHub ↗

* Create an error * @param {Object} state * @param {string} message * @return {Error} instantiated error * @private

(state, message)

Source from the content-addressed store, hash-verified

1843 * @private
1844 */
1845 function createError (state, message) {
1846 const c = col(state)
1847 const error = new SyntaxError(message + ' (char ' + c + ')')
1848 error.char = c
1849
1850 return error
1851 }
1852
1853 // Now that we can parse, automatically convert strings to Nodes by parsing
1854 typed.addConversion({ from: 'string', to: 'Node', convert: parse })

Callers 2

parseStartFunction · 0.85
parseMatrixFunction · 0.85

Calls 1

colFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…