<commit_before>macro_rules! float_tests {
    { $vector:ident, $scalar:ident } => {
        #[cfg(test)]
        mod $vector {
            use super::*;
            use helpers::lanewise::*;

            #[cfg(target_arch = "wasm32")]
            use wasm_bindgen_test::*;

            #[cfg(target_arch = "wasm32")]
            wasm_bindgen_test_configure!(run_in_browser);

            // TODO impl this as an associated fn on vectors
            fn from_slice(slice: &[$scalar]) -> core_simd::$vector {
                let mut value = core_simd::$vector::default();
                let value_slice: &mut [_] = value.as_mut();
                value_slice.copy_from_slice(&slice[0..value_slice.len()]);
                value
            }

            const A: [$scalar; 16] = [0.,   1.,  2.,  3.,  4.,  5.,  6.,  7.,  8.,  9., 10., 11., 12., 13., 14., 15.];
            const B: [$scalar; 16] = [16., 17., 18., 19., 20., 21., 22., 23., 24., 25., 26., 27., 28., 29., 30., 31.];
            const C: [$scalar; 16] = [
                -0.0,
                0.0,
                -1.0,
                1.0,
                <$scalar>::MIN,
                <$scalar>::MAX,
                <$scalar>::INFINITY,
                -<$scalar>::INFINITY,
                <$scalar>::MIN_POSITIVE,
                -<$scalar>::MIN_POSITIVE,
                <$scalar>::EPSILON,
                -<$scalar>::EPSILON,
                0.0 / 0.0,
                -0.0 / 0.0,
                // Still not sure if wasm can have weird nans, or I'd check them
                // too. Until then
                1.0 / 3.0,
                -1.0 / 4.0
            ];
<commit_msg>use NEG_INFINITY and NAN constants instead computing them<commit_after>macro_rules! float_tests {
    { $vector:ident, $scalar:ident } => {
        #[cfg(test)]
        mod $vector {
            use super::*;
            use helpers::lanewise::*;

            #[cfg(target_arch = "wasm32")]
            use wasm_bindgen_test::*;

            #[cfg(target_arch = "wasm32")]
            wasm_bindgen_test_configure!(run_in_browser);

            // TODO impl this as an associated fn on vectors
            fn from_slice(slice: &[$scalar]) -> core_simd::$vector {
                let mut value = core_simd::$vector::default();
                let value_slice: &mut [_] = value.as_mut();
                value_slice.copy_from_slice(&slice[0..value_slice.len()]);
                value
            }

            const A: [$scalar; 16] = [0.,   1.,  2.,  3.,  4.,  5.,  6.,  7.,  8.,  9., 10., 11., 12., 13., 14., 15.];
            const B: [$scalar; 16] = [16., 17., 18., 19., 20., 21., 22., 23., 24., 25., 26., 27., 28., 29., 30., 31.];
            const C: [$scalar; 16] = [
                -0.0,
                0.0,
                -1.0,
                1.0,
                <$scalar>::MIN,
                <$scalar>::MAX,
                <$scalar>::INFINITY,
                <$scalar>::NEG_INFINITY,
                <$scalar>::MIN_POSITIVE,
                -<$scalar>::MIN_POSITIVE,
                <$scalar>::EPSILON,
                -<$scalar>::EPSILON,
                <$scalar>::NAN,
                -<$scalar>::NAN,
                // TODO: Would be nice to check sNaN...
                100.0 / 3.0,
                -100.0 / 3.0,
            ];

{'fraction_non_alphanumeric': 0.16797820823244553, 'fraction_numerical': 0.0526634382566586, 'mean_word_length': 1.2255892255892256, 'pattern_counts': {'":': 0, '<': 21, '<?xml version=': 0, '>': 25, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 4, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3218118', 'n_tokens_mistral': 1184, 'n_tokens_neox': 1026, 'n_words': 238}