-
Notifications
You must be signed in to change notification settings - Fork 0
Open
Description
Goal
Expand numeric support beyond int/double/decimal to enable broader use cases.
Purpose
Support high-precision calculations (BigInteger), performance-critical float operations, and long integer measurements. Enable users to choose the appropriate numeric type for their domain while maintaining type safety and dimensional consistency.
Scope
Calculator<T>implementations forlong,float, andBigInteger- Parsing and JSON converters aligned with new backends
- Benchmarks validating no regressions for existing types
Deliverables
LongCalculator,FloatCalculator, andBigIntegerCalculatorimplementations- Corresponding
Measurement<long>,Measurement<float>,Measurement<BigInteger>support - Parsing extensions for all new numeric types
- JSON converters for all new measurement types
- Comprehensive unit tests for arithmetic operations and conversions
- Benchmarks demonstrating performance characteristics
Acceptance Criteria
- New calculators and measurements available with full arithmetic support
- Parsing and JSON converters support the new types correctly
- Benchmark run shows no regression beyond existing performance gates
- All calculator implementations follow the same patterns as existing types
- Edge cases (overflow, underflow, precision loss) are documented and tested
- XML docs added for all new public types and members
Technical Notes
- Follow existing
Int32CalculatorandDoubleCalculatorpatterns exactly - Ensure dimensional operations (multiply, divide, power) work correctly
- BigInteger may have different overflow semantics; document clearly
- Float precision loss should be documented with guidance on when to use
Risk & Mitigation
Risk: BigInteger operations may have unexpected performance characteristics
Mitigation: Comprehensive benchmarks; document performance trade-offs clearly
Risk: Float precision loss may surprise users
Mitigation: Document precision limitations; add guidance on appropriate use cases
Reactions are currently unavailable