typocomath/src/numbers/predicate.ts
Glen Whitney 6f44567306 refactor: Extend reflection to all implementations so far
And also enhances the reflected type parsing so that the types of all
  implementations so far will parse.
2023-10-17 14:54:10 -07:00

8 lines
280 B
TypeScript

import type {Signature} from '../interfaces/type.js'
import {$reflect} from '../interfaces/type.js'
export const isReal = (): Signature<'isReal', number> => (a) => true
export const isSquare = (): Signature<'isSquare', number> => (a) => a >= 0
$reflect!([isReal, isSquare])