#[unsafe(no_mangle)]pub unsafe extern "C" fn lc_knearest_d2(
xyz: *const f64,
n: usize,
simbox: *const lc_cell,
k: usize,
mask: *const c_int,
cell_hint: f64,
out_nn: *mut c_int,
out_d2: *mut f64,
) -> c_intExpand description
Like lc_knearest, and write squared distances into out_d2.
out_d2 is caller-owned, length n * k. Unused slots are NaN.
out_d2 may be NULL to skip distances (same as lc_knearest).
ยงSafety
Same pointer contract as lc_knearest. out_d2, if non-null,
is aligned for double and writable for n * k doubles.