2025-04-13 16:29:51 +00:00
|
|
|
import * as booleans from './boolean/all.js'
|
2025-04-16 04:23:48 +00:00
|
|
|
import * as coretypes from './coretypes/all.js'
|
2025-04-13 16:29:51 +00:00
|
|
|
import * as generics from './generic/all.js'
|
|
|
|
import * as numbers from './number/all.js'
|
2025-04-22 01:48:51 +00:00
|
|
|
import * as complex from './complex/all.js'
|
2025-04-07 16:18:46 +00:00
|
|
|
import {TypeDispatcher} from '#core/TypeDispatcher.js'
|
2025-03-30 20:00:07 -07:00
|
|
|
|
2025-04-24 12:06:47 -07:00
|
|
|
// At the moment, since we are not sorting patterns in any way,
|
|
|
|
// order matters in the construction. Patterns that come later in
|
|
|
|
// the following list will be tried earlier. (The rationale for that
|
|
|
|
// ordering is that any time you merge something, it should supersede
|
|
|
|
// whatever has been merged before.)
|
|
|
|
// Hence, in building the math instance, we put complex first because
|
|
|
|
// we want its conversion (which converts _any_ non-complex type to
|
|
|
|
// complex, potentially making a poor overload choice) to be tried last.
|
|
|
|
const math = new TypeDispatcher(complex, generics, booleans, coretypes, numbers)
|
2025-04-02 11:22:53 -07:00
|
|
|
|
|
|
|
export default math
|