Skip to content

[diskann-quantization] Use f32::NAN instead of core::f32::NAN. - #1471

Merged
Mark Hildebrand (hildebrandmw) merged 1 commit into
mainfrom
mhildebr/associated-constant
Oct 13, 2026
Merged

Mark Hildebrand (hildebrandmw) merged 1 commit into
mainfrom
mhildebr/associated-constant

Conversation

@hildebrandmw

Copy link
Copy Markdown
Contributor

Nightly emits a deprecation warning:

use of deprecated constant `std::f32::NAN`: replaced by the `NAN` associated constant on `f32`

This fixes that.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟢 Approval recommended

The import removal resolves the warning while preserving valid references and existing behavior.

0 open findings

What changed in this PR

Resolves a nightly deprecation warning in the min-max quantizer without changing behavior.

Changes:

  • Removes use core::f32 so f32::NAN resolves to the primitive type’s associated constant.
File Description
diskann-quantization/​src/​minmax/​quantizer.rs Removes the import that selects deprecated module constants.

🧠 Review effort: Balanced


Give feedback about Copilot approvals in this survey to enter a drawing for a $150 gift card.

@codecov-commenter

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 90.95%. Comparing base (27cdd95) to head (9bd0cd5).

Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##             main    #1471      +/-   ##
==========================================
- Coverage   91.97%   90.95%   -1.03%     
==========================================
  Files         586      586              
  Lines      118178   118178              
==========================================
- Hits       108700   107490    -1210     
- Misses       9478    10688    +1210     
Flag Coverage Δ
miri 90.95% <ø> (-1.03%) ⬇️
unittests 90.65% <ø> (-1.28%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

Files with missing lines Coverage Δ
diskann-quantization/src/minmax/quantizer.rs 96.81% <ø> (ø)

... and 50 files with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@hildebrandmw
Mark Hildebrand (hildebrandmw) merged commit 008be99 into main Oct 13, 2026
32 checks passed
@hildebrandmw
Mark Hildebrand (hildebrandmw) deleted the mhildebr/associated-constant branch October 13, 2026 15:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants