Skip to content

Replace sketch-specific value traits with num-traits #96

@notfilippo

Description

@notfilippo

We currently define sketch-specific value traits (DensityValue from #62, CountMinValue) that expose only the operations needed by each sketch. There is growing overlap between them.

For example, DensityValue is implemented for f32/f64, and we sometimes convert to f64 for operations.

Proposal

Evaluate replacing these traits with appropriate traits from num-traits (e.g., Float) to:

  • Reduce duplication
  • Reuse well-known numeric abstractions
  • Avoid unnecessary conversions

This is exploratory.

Metadata

Metadata

Assignees

No one assigned

    Labels

    featureNew feature or request

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions