Glen Whitney
27bf23db54
This adds the target initial definition of a homogeneous Tuple<T> type, and just enough processing that the type can be defined and non-template methods that deal with the generic base type Tuple can be called. Still has no actual template instantiation.
21 lines
661 B
JavaScript
21 lines
661 B
JavaScript
/* Core of pocomath: generates the default instance */
|
|
import PocomathInstance from './core/PocomathInstance.mjs'
|
|
import * as numbers from './number/native.mjs'
|
|
import * as bigints from './bigint/native.mjs'
|
|
import * as complex from './complex/native.mjs'
|
|
import * as tuple from './tuple/native.mjs'
|
|
// Most of tuple is not ready yet:
|
|
const tupleReady = {
|
|
Tuple: tuple.Tuple,
|
|
equal: tuple.equal,
|
|
length: tuple.length,
|
|
tuple: tuple.tuple
|
|
}
|
|
import * as generic from './generic/all.mjs'
|
|
import * as ops from './ops/all.mjs'
|
|
|
|
const math = PocomathInstance.merge(
|
|
'math', numbers, bigints, complex, tupleReady, generic, ops)
|
|
|
|
export default math
|