/** * Differential fixture battery for the slice-0.75 ToNumericPrimitive substrate. * * Single source of truth shared by both legs (charter §A.3): * - TS leg (`packages/core/tests/ir-semantics-to-numeric.test.ts`) asserts the * decision kernel against native JS `Number()` / operators for every row. * - Python leg (`packages/python/tests/ir-semantics-to-number-py.test.ts`) * emits the helper block + assertion calls into a module string and runs it * under `python3`, checking value, `type(result) is float`, and the `-0` * sign probe (tribunal amendments 1, 2 & 4). * * Every row encodes the input on BOTH targets so the two legs stay byte-aligned * to one oracle. `tsExpr` is JS source for the input; `pyExpr` is Python source * for the same value. The kernel-side input value (`value`) drives the TS leg * directly without re-parsing source. */ /** Marker for the expected numeric result, target-agnostic. */ export type ExpectedNumber = { readonly kind: 'value'; readonly n: number; } | { readonly kind: 'negzero'; } | { readonly kind: 'poszero'; } | { readonly kind: 'nan'; } | { readonly kind: 'posinf'; } | { readonly kind: 'neginf'; }; export interface ToNumberFixture { /** Human-readable probe label, surfaced in failure output. */ readonly probe: string; /** The semantic input value fed to the TS kernel directly. */ readonly value: unknown; /** JS source expression producing `value` (TS leg sanity oracle = Number(tsExpr)). */ readonly tsExpr: string; /** Python source expression producing the equivalent value. */ readonly pyExpr: string; /** Expected ToNumber result. */ readonly expected: ExpectedNumber; /** * Fail-closed row: the input is outside the slice-0.75 primitive domain, so * `toNumber` returns `{ ok:false }` (TS) and `_kern_to_number` raises (Python). * `expected` is ignored for these. */ readonly failClosed?: true; } export declare const UNDEFINED_INPUT: unique symbol; export declare const TO_NUMBER_FIXTURES: readonly ToNumberFixture[]; export interface IntFixture { readonly probe: string; readonly value: unknown; readonly tsExpr: string; readonly pyExpr: string; readonly expected: number; } /** `toInt32` carry-forward fixtures (oracle Slice-3 mandatory rows). */ export declare const TO_INT32_FIXTURES: readonly IntFixture[]; /** `toUint32` carry-forward fixtures. */ export declare const TO_UINT32_FIXTURES: readonly IntFixture[]; /** * `toIntegerOrInfinity` carry-forward fixtures. `expected` may be `±Infinity`. * (Distinct return type from int32/uint32: number, possibly non-finite.) */ export declare const TO_INTEGER_OR_INFINITY_FIXTURES: readonly IntFixture[];