i_float 2.0.0

This fixed float math library provides an efficient and deterministic solution for arithmetic and geometric operations.
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
use crate::int::point::IntPoint;
use i_key_sort::bin_key::index::{BinKey, BinLayout};

impl BinKey<i32> for IntPoint {
    #[inline(always)]
    fn bin_key(&self) -> i32 {
        self.x
    }

    #[inline(always)]
    fn bin_index(&self, layout: &BinLayout<i32>) -> usize {
        layout.index(self.x)
    }
}