commit_hash stringlengths 40 40 | author stringlengths 1 57 | date timestamp[s]date 2010-07-26 04:45:09 2026-04-14 18:21:10 | message stringlengths 8 1.39M | diff stringlengths 68 51.2k | files_changed int64 1 136 | insertions int64 0 2.35k | deletions int64 0 1.9k |
|---|---|---|---|---|---|---|---|
49ec6c5ffc1009a8a2b0d0ead748fc57a1029ae0 | Alex Huszagh | 2021-04-25T21:22:55 | Moved digit functions from atoi to util. | diff --git a/lexical-core/src/atoi/exponent.rs b/lexical-core/src/atoi/exponent.rs
index 13358f5..caef0db 100644
--- a/lexical-core/src/atoi/exponent.rs
+++ b/lexical-core/src/atoi/exponent.rs
@@ -1,7 +1,6 @@
//! String-to-integer routines specialized to parse the exponent of a float.
use crate::util::*;
-use super... | 5 | 33 | 33 |
1e81ae11feecda11492e9c61af445b82af44ab10 | Alex Huszagh | 2021-04-25T21:08:15 | Added in the static strings for NaN/Inf checking. | diff --git a/lexical-core/src/atof/api.rs b/lexical-core/src/atof/api.rs
index 63ae989..4ffeb4b 100644
--- a/lexical-core/src/atof/api.rs
+++ b/lexical-core/src/atof/api.rs
@@ -67,6 +67,8 @@ fn parse_infinity<'a, ToIter, StartsWith, Iter, F>(
format: NumberFormat,
radix: u32,
lossy: bool,
+ inf_string... | 2 | 106 | 41 |
3b6aa6e9e29726ed343cc37e4d42e5951d61cb82 | Alex Huszagh | 2021-04-25T20:30:38 | Fixed benches. | diff --git a/lexical-benchmark/lexical/benches/atof.rs b/lexical-benchmark/lexical/benches/atof.rs
index 027f528..2acb51a 100644
--- a/lexical-benchmark/lexical/benches/atof.rs
+++ b/lexical-benchmark/lexical/benches/atof.rs
@@ -67,271 +67,130 @@ lazy_static! {
static ref DIGITS64_DATA: Vec<String> = parse_json("d... | 1 | 107 | 248 |
327b393db2ce364ff93acac7c0d1c3ae7e86ab5b | Alex Huszagh | 2021-04-25T20:13:25 | Numerous performance improvements. | diff --git a/benches/atof_real.rs b/benches/atof_real.rs
index 7f93a2f..e33301e 100644
--- a/benches/atof_real.rs
+++ b/benches/atof_real.rs
@@ -120,15 +120,15 @@ fn lexical(criterion: &mut Criterion) {
lexical_generator!(group, "atof_real_f32_lexical", data, f32);
lexical_generator!(group, "atof_real_f64_lex... | 11 | 159 | 96 |
d3e4ee8fc0981427b0d1b1a13ba8422a724c1e01 | Alex Huszagh | 2021-04-25T19:14:36 | Updated timeouts on benches. | diff --git a/benches/atof_real.rs b/benches/atof_real.rs
index 9a85ef6..7f93a2f 100644
--- a/benches/atof_real.rs
+++ b/benches/atof_real.rs
@@ -116,7 +116,7 @@ macro_rules! parse_generator {
fn lexical(criterion: &mut Criterion) {
let data = read_data();
let mut group = criterion.benchmark_group("lexical");... | 2 | 9 | 9 |
53d5d08086f057fa94d9256ebb5d40f5ac044d94 | Alex Huszagh | 2021-04-24T05:08:36 | Partially removed radix from NumberFormat, fixed atof unittests. | diff --git a/lexical-core/src/atof/algorithm/correct.rs b/lexical-core/src/atof/algorithm/correct.rs
index 97d0778..2a84222 100644
--- a/lexical-core/src/atof/algorithm/correct.rs
+++ b/lexical-core/src/atof/algorithm/correct.rs
@@ -406,15 +406,17 @@ fn pow2_exponent(radix: u32) -> i32 {
///
/// The float string must... | 4 | 123 | 92 |
1b95b990ae0d21d079aaa4bf58bb719fa682de5a | Alex Huszagh | 2021-04-19T19:52:06 | Patch for #53. | diff --git a/lexical-core/src/util/sequence.rs b/lexical-core/src/util/sequence.rs
index 6f9191e..a87075d 100644
--- a/lexical-core/src/util/sequence.rs
+++ b/lexical-core/src/util/sequence.rs
@@ -2,7 +2,7 @@
#![allow(dead_code)]
-use crate::lib::{cmp, iter, marker, ops, ptr, slice};
+use crate::lib::{cmp, iter, m... | 1 | 57 | 28 |
69e133d90d3e6e2231e19fe222ffe9ae1cc3ec25 | Alex Huszagh | 2021-04-19T19:26:25 | Bug fix for slice::sort on no_std. | diff --git a/lexical-core/src/util/sequence.rs b/lexical-core/src/util/sequence.rs
index 3b0687f..6f9191e 100644
--- a/lexical-core/src/util/sequence.rs
+++ b/lexical-core/src/util/sequence.rs
@@ -371,15 +371,17 @@ impl<T: Ord> BinarySearch<T> for dyn SliceLikeImpl<T> {
/// Collection that has a `sort()` method.
pu... | 1 | 8 | 6 |
5c41e9b94448086f17f504110e64e61311089f97 | Alex Huszagh | 2021-04-19T19:21:11 | Added libm dependency and commit to stabilize no_std. | diff --git a/lexical-core/Cargo.toml b/lexical-core/Cargo.toml
index 5a48785..f37c4be 100644
--- a/lexical-core/Cargo.toml
+++ b/lexical-core/Cargo.toml
@@ -36,6 +36,8 @@ ryu = { version = "1.0", optional = true }
quickcheck = { version = "1.0.3", optional = true }
# Enable proptest for newer Rustc versions.
proptes... | 3 | 48 | 25 |
86d17b8054317c94af80676887f05cb80244687f | Alex Huszagh | 2021-04-19T17:11:16 | Reverted arrayvec to 0.5.2 for 1.37.0 support. | diff --git a/lexical-core/Cargo.toml b/lexical-core/Cargo.toml
index 523c186..7203379 100644
--- a/lexical-core/Cargo.toml
+++ b/lexical-core/Cargo.toml
@@ -27,7 +27,7 @@ cfg-if = "1.0"
# Use static_assertions for correct or format features.
static_assertions = { version = "1", optional = true }
# Use arrayvec for t... | 4 | 39 | 37 |
dd82a3fb6f013d8b28eb3fac63c91fece9edaa43 | Alex Huszagh | 2021-04-19T15:51:56 | Fix build.rs for #43.
Default to 32-bit limbs if CARGO_CFG_TARGET_ARCH is not set. This way,
we do not rely on the host architecture for the fallback. 32-bit limbs
should generally be performant on most architectures. | diff --git a/lexical-core/build.rs b/lexical-core/build.rs
index e42cfbe..e91737e 100644
--- a/lexical-core/build.rs
+++ b/lexical-core/build.rs
@@ -7,14 +7,12 @@ fn main() {
// See `lexical-core/src/atof/algorithm/math.rs` for detailed
// instructions of architecture instruction support for 64-bit
// ma... | 1 | 5 | 7 |
c7f23ae3270b8f43005b4f65894c742f5dacbee3 | Alex Huszagh | 2021-04-19T05:45:35 | Removed allow statements to silence warnings fixed in 1.26. | diff --git a/lexical-core/src/util/table.rs b/lexical-core/src/util/table.rs
index 6e8dee4..b08b7cf 100644
--- a/lexical-core/src/util/table.rs
+++ b/lexical-core/src/util/table.rs
@@ -341,7 +341,6 @@ type F32Transmute = Transmute<u32, f32>;
/// Precalculated values of 2**i for i in range [-149, 127].
#[cfg(feature... | 1 | 0 | 2 |
49cb9fb9690dd47177cc086f5e9acf5f9b865d7a | Alex Huszagh | 2021-04-19T04:19:52 | Bug fix for missing assert_relative_eq error without correct. | diff --git a/lexical-core/src/ftoa/api.rs b/lexical-core/src/ftoa/api.rs
index 4f32113..a8f4dda 100644
--- a/lexical-core/src/ftoa/api.rs
+++ b/lexical-core/src/ftoa/api.rs
@@ -222,7 +222,10 @@ mod tests {
use crate::util::*;
use crate::util::test::*;
+ #[cfg(feature = "correct")]
use quickcheck::qu... | 2 | 7 | 4 |
994721ba07e7e4fcc22be9c33ed5aa3f2120614c | Alex Huszagh | 2021-04-19T01:29:39 | Bug fixes for unittests. | diff --git a/lexical-core/src/ftoa/api.rs b/lexical-core/src/ftoa/api.rs
index 4768790..4f32113 100644
--- a/lexical-core/src/ftoa/api.rs
+++ b/lexical-core/src/ftoa/api.rs
@@ -423,12 +423,22 @@ mod tests {
quickcheck! {
fn f32_quickcheck(f: f32) -> bool {
let mut buffer = new_buffer();
- ... | 3 | 15 | 5 |
d57c5b0b3f0580b042cb579182c0540243f1a6e5 | myrrlyn | 2021-04-18T21:04:58 | Address #53 | diff --git a/lexical-core/src/util/sequence.rs b/lexical-core/src/util/sequence.rs
index 14bead0..ac8b7e8 100644
--- a/lexical-core/src/util/sequence.rs
+++ b/lexical-core/src/util/sequence.rs
@@ -87,11 +87,14 @@ pub fn insert_many<V, T, I>(vec: &mut V, index: usize, iterable: I)
ptr::copy(ptr.add(lower_si... | 1 | 6 | 3 |
0eef94d3f5b37961c9c0f792e0d0a527bddc48be | myrrlyn | 2021-04-18T20:59:48 | Address #43 | diff --git a/lexical-core/build.rs b/lexical-core/build.rs
index aa40df6..e42cfbe 100644
--- a/lexical-core/build.rs
+++ b/lexical-core/build.rs
@@ -7,12 +7,15 @@ fn main() {
// See `lexical-core/src/atof/algorithm/math.rs` for detailed
// instructions of architecture instruction support for 64-bit
// ma... | 1 | 9 | 6 |
722fd2954197455d03074250ad0739982747288c | myrrlyn | 2021-04-18T20:01:08 | Address #53 | diff --git a/lexical-core/src/util/sequence.rs b/lexical-core/src/util/sequence.rs
index 5617c9a..14bead0 100644
--- a/lexical-core/src/util/sequence.rs
+++ b/lexical-core/src/util/sequence.rs
@@ -48,7 +48,7 @@ pub fn insert_many<V, T, I>(vec: &mut V, index: usize, iterable: I)
where V: VecLike<T>,
I: i... | 1 | 6 | 2 |
caccf5fcad5b0c6cd4cd313a80c195f4c49f676e | myrrlyn | 2021-04-18T19:50:38 | Update to arrayvec 0.7. MSRV is now 1.51 | diff --git a/lexical-core/Cargo.toml b/lexical-core/Cargo.toml
index 7203379..523c186 100644
--- a/lexical-core/Cargo.toml
+++ b/lexical-core/Cargo.toml
@@ -27,7 +27,7 @@ cfg-if = "1.0"
# Use static_assertions for correct or format features.
static_assertions = { version = "1", optional = true }
# Use arrayvec for t... | 3 | 34 | 36 |
2feaaf3d1527af64306364d33a7f4cba04370896 | myrrlyn | 2021-04-18T19:35:08 | Gate `impl std::error::Error` under `#[cfg(feature = "std")` | diff --git a/lexical-core/src/util/error.rs b/lexical-core/src/util/error.rs
index cb6d4f5..deb7cf8 100644
--- a/lexical-core/src/util/error.rs
+++ b/lexical-core/src/util/error.rs
@@ -1,7 +1,9 @@
//! C-compatible error type.
+use crate::lib::fmt::{self, Display, Formatter};
+
+#[cfg(feature = "std")]
use std::erro... | 1 | 7 | 8 |
0326d71a98f614143ff9015fc7c5078cad53a8ec | myrrlyn | 2021-04-18T19:28:49 | Fix a clippy warning | diff --git a/src/lib.rs b/src/lib.rs
index 36fb791..899b13c 100644
--- a/src/lib.rs
+++ b/src/lib.rs
@@ -166,8 +166,7 @@ pub use lexical_core::{FromLexicalFormat,FromLexicalLossyFormat};
/// Get a vector as a slice, including the capacity.
#[inline]
-unsafe fn vector_as_slice<'a, T>(buf: &'a mut lib::Vec<T>)
- -... | 1 | 1 | 2 |
e544a2d8aed81ab61aac4206acde30602051cc8e | Jens Reidel | 2021-02-08T08:43:04 | Downgrade rand, fix proptest tests | diff --git a/Cargo.toml b/Cargo.toml
index d95add7..aaea32b 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -26,7 +26,7 @@ cfg-if = "1.0"
lexical-core = { path = "lexical-core", version = "^0.7.4", default-features = false }
# The following are only required for comprehensive float unittests.
# IE, internal testing only... | 2 | 13 | 13 |
98b8a50eb4389a30aade10b2356026cdf44e2941 | Lucas | 2020-12-20T09:48:46 | Update cfg-if to 1.0.0 | diff --git a/Cargo.toml b/Cargo.toml
index df0eb35..8341e59 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -22,7 +22,7 @@ exclude = [
travis-ci = { repository = "Alexhuszagh/rust-lexical" }
[dependencies]
-cfg-if = "0.1"
+cfg-if = "1.0"
lexical-core = { path = "lexical-core", version = "^0.7.4", default-features = fa... | 2 | 2 | 2 |
dac8b25f692d6a7dd930d1945cbddd9f94ea4791 | Lucas | 2020-10-02T09:51:33 | Import macros explicitly. | diff --git a/lexical-core/src/atof/algorithm/small_powers.rs b/lexical-core/src/atof/algorithm/small_powers.rs
index 411ba1c..7237998 100644
--- a/lexical-core/src/atof/algorithm/small_powers.rs
+++ b/lexical-core/src/atof/algorithm/small_powers.rs
@@ -1,5 +1,8 @@
//! Precalculated small powers.
+#[cfg(any(feature =... | 11 | 24 | 22 |
9d7a2ea87342186d89069d09d577186446c25666 | Lucas | 2020-10-02T09:49:28 | Silence unused doc warnings | diff --git a/lexical-core/src/lib.rs b/lexical-core/src/lib.rs
index e74b08b..fad2014 100644
--- a/lexical-core/src/lib.rs
+++ b/lexical-core/src/lib.rs
@@ -126,6 +126,9 @@
//! [`set_inf_string`]: fn.set_inf_string.html
//! [`set_infinity_string`]: fn.set_infinity_string.html
+// silence warnings for unused doc com... | 1 | 3 | 0 |
1dc4691e2e9eb3afe9749df21fcd187e120466ac | Lucas | 2020-10-02T09:22:02 | Improve readability of `cfg_if` branches | diff --git a/lexical-core/src/lib.rs b/lexical-core/src/lib.rs
index e74b08b..b459c05 100644
--- a/lexical-core/src/lib.rs
+++ b/lexical-core/src/lib.rs
@@ -175,29 +175,30 @@ compile_error!("Lexical only accepts one of the following backends: `grisu3` or
// Import the back-end, if applicable.
cfg_if! {
-if #[cfg(fe... | 1 | 17 | 16 |
26bbc2f2dd71a9d7b20d15b624750beaacfa3fdc | Lucas | 2020-10-02T09:08:19 | improve documentation for lexical_core::write function | diff --git a/lexical-core/src/lib.rs b/lexical-core/src/lib.rs
index e74b08b..3a1c6a9 100644
--- a/lexical-core/src/lib.rs
+++ b/lexical-core/src/lib.rs
@@ -227,9 +227,31 @@ pub use util::*;
///
/// Panics if the buffer may not be large enough to hold the serialized
/// number. In order to ensure the function will n... | 1 | 24 | 2 |
7a572682c48c6711216a6bded9ac9021ed9cce85 | Zack Pierce | 2020-06-18T21:11:51 | Use arrayvec without its "std" feature to improve no_std friendliness | diff --git a/lexical-core/Cargo.toml b/lexical-core/Cargo.toml
index 12cf0b8..e370d73 100644
--- a/lexical-core/Cargo.toml
+++ b/lexical-core/Cargo.toml
@@ -27,7 +27,7 @@ cfg-if = "0.1"
# Use static_assertions for correct or format features.
static_assertions = { version = "1", optional = true }
# Use arrayvec for t... | 1 | 1 | 1 |
3015ee17ea7bfe1ebb40101a68755a03e603aec5 | Max Drach | 2020-06-04T00:08:34 | impl std::error::Error for lexical::Error | diff --git a/lexical-core/src/util/error.rs b/lexical-core/src/util/error.rs
index 2434bc7..cb6d4f5 100644
--- a/lexical-core/src/util/error.rs
+++ b/lexical-core/src/util/error.rs
@@ -1,5 +1,8 @@
//! C-compatible error type.
+use std::error::Error as StdError;
+use std::fmt;
+
/// Error code, indicating failure ty... | 1 | 15 | 0 |
66336d9f9de2351c51603ae23bebecce02d7768f | Alex Huszagh | 2020-01-23T22:49:48 | Update versions for release. | diff --git a/Cargo.toml b/Cargo.toml
index 2544945..cea6265 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -10,7 +10,7 @@ license = "MIT/Apache-2.0"
name = "lexical"
readme = "README.md"
repository = "https://github.com/Alexhuszagh/rust-lexical"
-version = "5.0.0"
+version = "5.1.0"
exclude = [
"data/*",
"be... | 3 | 5 | 5 |
eb87f5b43a3e090e940f360e5b95434e52558272 | Alex Huszagh | 2020-01-22T21:58:06 | Minor performance improvements for atoi (I hate it too). | diff --git a/lexical-core/src/atoi/generic.rs b/lexical-core/src/atoi/generic.rs
index 58397ec..9201c04 100644
--- a/lexical-core/src/atoi/generic.rs
+++ b/lexical-core/src/atoi/generic.rs
@@ -157,7 +157,7 @@ macro_rules! standalone_atoi_separator {
sign => $sign:ident,
consume => $consume:ident
... | 1 | 8 | 8 |
7ca441fe9a1a9245f8eb6f51d77596ff2b7547ed | Alex Huszagh | 2020-01-22T21:41:01 | Added high-level, public API functions to lexical and lexical-core for format-dependent parsers. | diff --git a/lexical-core/src/lib.rs b/lexical-core/src/lib.rs
index e444a95..6a21d25 100644
--- a/lexical-core/src/lib.rs
+++ b/lexical-core/src/lib.rs
@@ -382,3 +382,171 @@ pub fn parse_partial_lossy_radix<N: FromLexicalLossy>(bytes: &[u8], radix: u8)
{
N::from_lexical_partial_lossy_radix(bytes, radix)
}
+
+//... | 2 | 589 | 3 |
46ad79c06db42481e224dbee6223a3550f108e2e | Alex Huszagh | 2020-01-22T21:04:45 | Added unittests for generic data interfaces. | diff --git a/lexical-core/src/atof/algorithm/format/generic.rs b/lexical-core/src/atof/algorithm/format/generic.rs
index 81dcdb3..e1f4d5a 100644
--- a/lexical-core/src/atof/algorithm/format/generic.rs
+++ b/lexical-core/src/atof/algorithm/format/generic.rs
@@ -195,5 +195,155 @@ generic_data_interface!(
#[cfg(test)]
... | 1 | 151 | 1 |
9c6821014cff960553fe513540e128144f402277 | Alex Huszagh | 2020-01-22T08:01:28 | Removed bencher from lexical, moved to criterion. | diff --git a/Cargo.toml b/Cargo.toml
index 0544015..2544945 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -33,8 +33,9 @@ toml = { version = "0.5", optional = true }
[dev-dependencies]
approx = "0.3.0"
-bencher = "0.1.5"
+criterion = "0.3"
dtoa = "0.4"
+ryu_impl = { version = "1.0", package = "ryu" }
itoa = { versio... | 9 | 135 | 138 |
6a4024e83504a2893cd50351d18634aa77ce4729 | Alex Huszagh | 2020-01-22T04:02:21 | Added more unittests for format-based float parsers. | diff --git a/lexical-core/src/atof/algorithm/format/validate.rs b/lexical-core/src/atof/algorithm/format/validate.rs
index 46ccb05..f5a584e 100644
--- a/lexical-core/src/atof/algorithm/format/validate.rs
+++ b/lexical-core/src/atof/algorithm/format/validate.rs
@@ -48,7 +48,10 @@ pub(super) fn validate_required_fraction... | 3 | 198 | 4 |
e1b442b121403c9139a387d1847331fd05590b68 | Alex Huszagh | 2020-01-19T13:51:03 | Re-added iter.chain for performance. | diff --git a/lexical-core/src/atof/algorithm/bigcomp.rs b/lexical-core/src/atof/algorithm/bigcomp.rs
index 280d625..fdb1f5f 100644
--- a/lexical-core/src/atof/algorithm/bigcomp.rs
+++ b/lexical-core/src/atof/algorithm/bigcomp.rs
@@ -189,8 +189,6 @@ pub(super) fn make_ratio<F: Float>(radix: u32, sci_exponent: i32, f: F,... | 1 | 5 | 7 |
fa71cd3a254b332d22f78da47549278dd4d0a3f9 | Alex Huszagh | 2020-01-17T22:08:54 | Added initial support for FormatIterators. | diff --git a/lexical-core/src/atof/algorithm/format/standard.rs b/lexical-core/src/atof/algorithm/format/standard.rs
index 8bf7410..e0df010 100644
--- a/lexical-core/src/atof/algorithm/format/standard.rs
+++ b/lexical-core/src/atof/algorithm/format/standard.rs
@@ -1,6 +1,7 @@
//! Specialized float parsers for differen... | 4 | 116 | 70 |
441c70bbf43ff69823c70c37d29e5c1fac54c4fe | Alex Huszagh | 2020-01-17T07:54:32 | Re-factored atof::algorithm state to delegate to specialized parsers in format. | diff --git a/lexical-core/src/atof/algorithm/correct.rs b/lexical-core/src/atof/algorithm/correct.rs
index 00b4385..a8da374 100644
--- a/lexical-core/src/atof/algorithm/correct.rs
+++ b/lexical-core/src/atof/algorithm/correct.rs
@@ -307,7 +307,7 @@ fn pown_to_native<F>(bytes: &[u8], radix: u32, lossy: bool, sign: Sign)... | 7 | 252 | 158 |
420b452b42e507fe51bb57737302193004d97177 | Alex Huszagh | 2020-01-17T06:15:06 | Removed unnecessary #[allow(unused_imports)]. | diff --git a/lexical-core/src/lib.rs b/lexical-core/src/lib.rs
index f05d59b..fa3dd8e 100644
--- a/lexical-core/src/lib.rs
+++ b/lexical-core/src/lib.rs
@@ -23,11 +23,11 @@
//! let r = lexical_core::parse::<u8>(b"1a5"); // Err(ErrorCode::InvalidDigit.into())
//!
//! // In order to extract and parse a number from a s... | 1 | 3 | 4 |
69b5d2a97c216eab3748b1c7bfcf066e707ce6c5 | Alex Huszagh | 2020-01-07T15:34:14 | Updated Cargo.toml due to requiring manually-specified bench paths. | diff --git a/Cargo.toml b/Cargo.toml
index ea535db..2754fe9 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -126,26 +126,32 @@ required-features = ["comprehensive_float_test"]
[[bench]]
name = "atof"
+path = "benches/atof.rs"
harness = false
[[bench]]
name = "atof_malicious"
+path = "benches/atof_malicious.rs"
ha... | 3 | 8 | 0 |
0533064369e9485103564f54d12085421e3701fc | Alex Huszagh | 2020-01-07T01:32:16 | Removed unnecessary build dependencies. | diff --git a/Cargo.toml b/Cargo.toml
index 9b19d61..ea535db 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -11,7 +11,6 @@ name = "lexical"
readme = "README.md"
repository = "https://github.com/Alexhuszagh/rust-lexical"
version = "5.0.0"
-build = "build.rs"
exclude = [
"data/*",
"benches/*",
@@ -39,9 +38,6 @@... | 6 | 0 | 55 |
3c864b83d2a03bbf937838dcb3aa9cf95ea9ff7e | Alex Huszagh | 2020-01-07T01:29:08 | Updates for no_std. | diff --git a/lexical-capi/Cargo.toml b/lexical-capi/Cargo.toml
index fbcc4f5..e7ae81e 100644
--- a/lexical-capi/Cargo.toml
+++ b/lexical-capi/Cargo.toml
@@ -22,7 +22,6 @@ crate-type = ["cdylib", "staticlib"]
travis-ci = { repository = "Alexhuszagh/rust-lexical" }
[dependencies]
-cfg-if = "0.1"
lexical-core = { pat... | 4 | 4 | 30 |
f6f21b277bcc9ee0d7ce05e9391f8c6182243c70 | Alex Huszagh | 2020-01-06T23:23:28 | Update lexical-derive for v0.7 | diff --git a/lexical-derive/Cargo.toml b/lexical-derive/Cargo.toml
index d5870a4..7373717 100644
--- a/lexical-derive/Cargo.toml
+++ b/lexical-derive/Cargo.toml
@@ -7,7 +7,7 @@ publish = false
[dependencies]
quote = "1.0"
syn = "1.0"
-lexical-core = { path = "../lexical-core", version = "0.6.0", default-features = f... | 1 | 1 | 1 |
9c85c39f7d6f65d9808be162475b49d69b395c11 | Robert-André Mauchin | 2019-12-06T19:38:56 | Bump arrayvec to 0.5 | diff --git a/lexical-core/Cargo.toml b/lexical-core/Cargo.toml
index eb685a9..fe87d72 100644
--- a/lexical-core/Cargo.toml
+++ b/lexical-core/Cargo.toml
@@ -32,7 +32,7 @@ travis-ci = { repository = "Alexhuszagh/rust-lexical" }
cfg-if = "=0.1.9"
static_assertions = "0.3.3"
# Use arrayvec for the correct parser.
-arra... | 1 | 1 | 1 |
a810d5dcc57a914d04bbcaaee45edc80ed33cb3e | Igor Gnatenko | 2019-11-26T12:28:46 | chore: Update static_assertions to 1
Signed-off-by: Igor Gnatenko <i.gnatenko.brain@gmail.com> | diff --git a/lexical-core/Cargo.toml b/lexical-core/Cargo.toml
index eb685a9..57c7a50 100644
--- a/lexical-core/Cargo.toml
+++ b/lexical-core/Cargo.toml
@@ -20,7 +20,6 @@ exclude = [
# TODO(ahuszagh) Dependency Versioning and Rustc Roadmap:
# - Update cfg-if to "0.1.10" when we support only Rustc >= 1.32.0.
# - ... | 3 | 98 | 99 |
ee8c463307c835ded5e81b15e5c202dd25c78929 | Alex Huszagh | 2019-10-08T14:35:56 | Remove redundant build.rs configurations. | diff --git a/build.rs b/build.rs
index 3a2792d..4645d83 100644
--- a/build.rs
+++ b/build.rs
@@ -5,8 +5,6 @@ fn version_parse(version: &str) -> rustc_version::Version {
}
fn main() {
- println!("cargo:rerun-if-changed=build.rs");
-
let version = rustc_version::version().unwrap();
// VERSIONS
diff --g... | 3 | 0 | 6 |
7850e57d0d60b48a3cba96a44c3f337efb0eaa5f | Alex Huszagh | 2019-09-22T12:56:02 | Patch mismatched types for num trait for float methods in MSVC environment. | diff --git a/lexical-core/src/util/num.rs b/lexical-core/src/util/num.rs
index 43cab76..03404bd 100644
--- a/lexical-core/src/util/num.rs
+++ b/lexical-core/src/util/num.rs
@@ -871,7 +871,7 @@ macro_rules! float_method_msvc {
return unsafe { core::intrinsics::$intr($f $(,$i)*) };
#[cfg(all(not(featu... | 1 | 2 | 2 |
aaaae873455253ddafd11f3aa3c1af6046f66d5e | Alex Huszagh | 2019-09-21T23:42:18 | Patch for #26, which is causing builds to fail on MSVC. | diff --git a/lexical-core/src/util/num.rs b/lexical-core/src/util/num.rs
index ceca73b..43cab76 100644
--- a/lexical-core/src/util/num.rs
+++ b/lexical-core/src/util/num.rs
@@ -871,7 +871,7 @@ macro_rules! float_method_msvc {
return unsafe { core::intrinsics::$intr($f $(,$i)*) };
#[cfg(all(not(featu... | 1 | 1 | 1 |
0fbdc0ba53627fcbabdf29500cd152650061f192 | Alex Huszagh | 2019-09-16T22:54:39 | Update panic handlers for lexical-capi. | diff --git a/lexical-capi/src/lib.rs b/lexical-capi/src/lib.rs
index 9b5917d..5b054cb 100644
--- a/lexical-capi/src/lib.rs
+++ b/lexical-capi/src/lib.rs
@@ -8,6 +8,8 @@
// Require intrinsics in a no_std context.
#![cfg_attr(not(feature = "std"), no_std)]
+#![cfg_attr(not(feature = "std"), feature(core_intrinsics))]... | 1 | 3 | 2 |
eca92805c5e8604dcbb3b599b58ca914597d69ea | Astro | 2019-09-16T00:39:46 | Remove panic_handler. | diff --git a/lexical-core/src/lib.rs b/lexical-core/src/lib.rs
index d84d72f..a08d0b5 100644
--- a/lexical-core/src/lib.rs
+++ b/lexical-core/src/lib.rs
@@ -116,7 +116,6 @@
#![cfg_attr(not(feature = "std"), no_std)]
#![cfg_attr(all(not(feature = "std"), feature = "correct", feature = "radix"), feature(alloc))]
#![cf... | 1 | 0 | 23 |
9cf8e79c96966cff8fb1a48816eeaef3eaa64e47 | Alex Huszagh | 2019-09-05T21:02:42 | Only enable debug for structs containing references/vectors due to #23, when not needed in the public API. | diff --git a/lexical-core/src/atof/algorithm/bignum.rs b/lexical-core/src/atof/algorithm/bignum.rs
index fbc02b5..2cbb2e2 100644
--- a/lexical-core/src/atof/algorithm/bignum.rs
+++ b/lexical-core/src/atof/algorithm/bignum.rs
@@ -24,7 +24,8 @@ if #[cfg(feature = "radix")] {
// BIGINT
/// Storage for a big integer ty... | 2 | 6 | 4 |
69e5971b4d7f980d4250e5ce660e40bb8821d468 | Alex Huszagh | 2019-09-02T16:58:50 | Bug fixes for 1.24.0, minor patches for the lexical-capi build script, and exported no_mangle-d symbols to the crate root for the lexical-capi for compatibility with older rustc versions. | diff --git a/lexical-capi/src/api.rs b/lexical-capi/src/api.rs
index 4897ec6..4de4aaf 100644
--- a/lexical-capi/src/api.rs
+++ b/lexical-capi/src/api.rs
@@ -47,6 +47,7 @@ macro_rules! decimal_from_range {
/// # Panics
///
/// Panics if either pointer is null.
+ #[doc(hidden)]
... | 5 | 59 | 6 |
d17f05197accc0d43a84d644578dbdbf225a8046 | Alex Huszagh | 2019-09-02T16:24:41 | Patch for rustc 1.24.0. | diff --git a/lexical-core/src/util/sequence.rs b/lexical-core/src/util/sequence.rs
index cc6cb98..a935687 100644
--- a/lexical-core/src/util/sequence.rs
+++ b/lexical-core/src/util/sequence.rs
@@ -65,30 +65,30 @@ pub fn insert_many<V, T, I>(vec: &mut V, index: usize, iterable: I)
unsafe {
let old_len = ve... | 1 | 7 | 7 |
f1b72bbefe7f3e410100ef829a3cf262ecef2994 | Alex Huszagh | 2019-09-02T15:46:00 | Bug fix for using std::isize. | diff --git a/lexical-core/src/util/sequence.rs b/lexical-core/src/util/sequence.rs
index 793eb36..cc6cb98 100644
--- a/lexical-core/src/util/sequence.rs
+++ b/lexical-core/src/util/sequence.rs
@@ -58,8 +58,8 @@ pub fn insert_many<V, T, I>(vec: &mut V, index: usize, iterable: I)
}
let (lower_size_bound, _) =... | 1 | 2 | 2 |
47bf74d6aff5712716ebc34e9f3654b3b99412ed | Alex Huszagh | 2019-09-02T13:55:29 | Fixed minor versioning and vector-wrapper bugs.
Updating versioning to remove redundant carets.
Updated insert_many for ArrayVec to work with iterators with invalid size hints (used internally, no safety guarantees were previously broken due to how insert_many was used).
Fixed bugs with reserve and reserve_exact for A... | diff --git a/Cargo.toml b/Cargo.toml
index 2a69c17..d5d286a 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -23,7 +23,7 @@ travis-ci = { repository = "Alexhuszagh/rust-lexical" }
[dependencies]
cfg-if = "0.1"
-lexical-core = { path = "lexical-core", version = "^0.6.0", default-features = false }
+lexical-core = { path ... | 4 | 49 | 17 |
8565cd1a480cf0506eaefd7ddd111f366deaa609 | Alex Huszagh | 2019-09-01T23:40:15 | Substituted stackvector with arrayvec. | diff --git a/lexical-core/Cargo.toml b/lexical-core/Cargo.toml
index ab452af..2756211 100644
--- a/lexical-core/Cargo.toml
+++ b/lexical-core/Cargo.toml
@@ -23,8 +23,8 @@ travis-ci = { repository = "Alexhuszagh/rust-lexical" }
[dependencies]
cfg-if = "0.1"
static_assertions = "0.3.3"
-# Use stack-vector for the corr... | 8 | 130 | 58 |
88c5fd3a0b15d4c0ed80e7ab6e3c2793ef804f66 | Alex Huszagh | 2019-08-20T19:07:55 | Bug fix for 128-bit integers on targets with i128/u128. | diff --git a/lexical-core/src/atoi.rs b/lexical-core/src/atoi.rs
index 67e3b7f..72cbcf2 100644
--- a/lexical-core/src/atoi.rs
+++ b/lexical-core/src/atoi.rs
@@ -222,6 +222,7 @@ macro_rules! parse_digits_u128 {
// Parse the digits for the 128-bit atoi processor.
perftools_inline!{
+#[cfg(has_i128)]
pub(crate) fn pa... | 2 | 2 | 0 |
af84b5cb5cafe464589712ef6688e8881efe84d8 | Alex Huszagh | 2019-08-20T16:19:26 | Simplified the atoi processor with a few macros. | diff --git a/lexical-core/src/atoi.rs b/lexical-core/src/atoi.rs
index 42db38b..67e3b7f 100644
--- a/lexical-core/src/atoi.rs
+++ b/lexical-core/src/atoi.rs
@@ -80,15 +80,42 @@
use util::*;
use lib::result::Result as StdResult;
+// SHARED
+// ------
+
+// Convert u8 to digit.
macro_rules! to_digit {
($c:expr,... | 1 | 105 | 98 |
c50538dcfbab8acd555e22dd07dd19e3b865ece6 | Alex Huszagh | 2019-08-12T15:10:04 | Updated the fuzz targets and increased the comprehensive tests to ensure base10 cannot have errors. | diff --git a/Cargo.toml b/Cargo.toml
index cd2c3bf..07a6e8a 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -14,6 +14,7 @@ build = "build.rs"
exclude = [
"data/*",
"benches/*",
+ "lexical-codegen/*",
"lexical-benchmark/*",
]
diff --git a/lexical-core/Cargo.toml b/lexical-core/Cargo.toml
index 03c06b8.... | 19 | 120 | 398 |
bc6accea4bb92ba3877a0aecf2ef25db1f6ec9ec | Alex Huszagh | 2019-08-07T12:32:11 | Patch for failures in doctests for inadequate buffer sizes when the radix feature is enabled in base10. | diff --git a/lexical-core/src/ftoa/api.rs b/lexical-core/src/ftoa/api.rs
index 7be9c9c..2e4c2d5 100644
--- a/lexical-core/src/ftoa/api.rs
+++ b/lexical-core/src/ftoa/api.rs
@@ -478,14 +478,14 @@ mod tests {
#[test]
#[should_panic]
fn f32toa_buffer_test() {
- let mut buffer = [b'0'; MAX_F32_SIZE-1]... | 5 | 33 | 20 |
b8779159e1d4f18d752da2aa670b5346b4bcc14d | Alex Huszagh | 2019-08-06T00:12:31 | Documentation updates for the lexical-core methods. | diff --git a/lexical-core/src/util/api.rs b/lexical-core/src/util/api.rs
index 833f09b..0ae3024 100644
--- a/lexical-core/src/util/api.rs
+++ b/lexical-core/src/util/api.rs
@@ -36,13 +36,13 @@ pub(crate) unsafe fn slice_from_range_mut<'a, T>(first: *mut T, last: *mut T)
#[doc(hidden)]
macro_rules! generate_from_range... | 1 | 22 | 16 |
b76803aeae568f92f3a4a6089934f1916ab8b8a8 | Alex Huszagh | 2019-07-26T18:04:27 | Bug fix for missing pow in WrappedFloat. | diff --git a/lexical-core/src/util/wrapped.rs b/lexical-core/src/util/wrapped.rs
index b149929..846e28d 100644
--- a/lexical-core/src/util/wrapped.rs
+++ b/lexical-core/src/util/wrapped.rs
@@ -483,6 +483,11 @@ impl<T: Float> Integer for WrappedFloat <T> {
unreachable!()
}
+ #[inline]
+ fn pow(self... | 1 | 5 | 0 |
3a912ee54366c563d55c7381c6386a0bc4384db2 | Alex Huszagh | 2019-07-26T14:53:11 | Patch for #20. | diff --git a/lexical-core/src/atof/algorithm/correct.rs b/lexical-core/src/atof/algorithm/correct.rs
index 0807250..f36efa1 100644
--- a/lexical-core/src/atof/algorithm/correct.rs
+++ b/lexical-core/src/atof/algorithm/correct.rs
@@ -21,6 +21,16 @@ use super::small_powers::get_small_powers_64;
// SHARED
+// Left-tr... | 4 | 67 | 11 |
7ee56a2efdb9bf0f001e17597c5dd9435b1e08bb | Jon Gjengset | 2019-07-23T15:22:13 | Bump dependencies | diff --git a/lexical-core/Cargo.toml b/lexical-core/Cargo.toml
index 3a0abb8..3e61cec 100644
--- a/lexical-core/Cargo.toml
+++ b/lexical-core/Cargo.toml
@@ -22,18 +22,18 @@ travis-ci = { repository = "Alexhuszagh/rust-lexical" }
[dependencies]
cfg-if = "0.1"
-static_assertions = "0.2.5"
+static_assertions = "0.3.3"... | 2 | 6 | 6 |
cdfa0a0bc5cf2a65a6862ce459080de9150b53b7 | Evgeniy Reizner | 2019-07-15T19:02:41 | Use Write::write_fmt instead of to_string in benches.
to_string allocates for each execution, skewing the results. | diff --git a/benches/ftoa.rs b/benches/ftoa.rs
index 8157264..edb890e 100644
--- a/benches/ftoa.rs
+++ b/benches/ftoa.rs
@@ -33,8 +33,15 @@ fn ftoa_f32_dtoa(bench: &mut Bencher) {
})})
}
-fn ftoa_f32_to_string(bench: &mut Bencher) {
- bench.iter(|| { F32_DATA.iter().for_each(|x| { black_box(x.to_string()); }... | 2 | 100 | 30 |
f6c5d5c66106513cd1b49bcee284fdfc6fca4fe5 | Alex Huszagh | 2019-06-24T23:02:41 | Silenced unknown_lint warning for bare_trait_objects for old Rust compilers. | diff --git a/lexical-core/src/util/sequence.rs b/lexical-core/src/util/sequence.rs
index 447b232..74d3214 100644
--- a/lexical-core/src/util/sequence.rs
+++ b/lexical-core/src/util/sequence.rs
@@ -238,7 +238,7 @@ pub trait Contains<T: PartialEq> {
}
// Remove when we drop support below 1.27.
-#[allow(bare_trait_obj... | 2 | 9 | 9 |
ae30192eb00a69aff78bbd22bab8ac2c81233c41 | Alex Huszagh | 2019-06-20T20:09:51 | Minor patch for 128-bit support in the high-level package. | diff --git a/Cargo.toml b/Cargo.toml
index ee0e17c..0abf947 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -9,7 +9,8 @@ license = "MIT/Apache-2.0"
name = "lexical"
readme = "README.md"
repository = "https://github.com/Alexhuszagh/rust-lexical"
-version = "2.2.0"
+version = "2.2.1"
+build = "build.rs"
exclude = [
... | 1 | 2 | 1 |
7b69c6b61e2f4bc9744bf48436e152254752c76c | Alex Huszagh | 2019-06-20T19:22:28 | Silenced bare trait object warnings until we drop support for <= 1.26. | diff --git a/lexical-core/src/util/sequence.rs b/lexical-core/src/util/sequence.rs
index 508dd6e..447b232 100644
--- a/lexical-core/src/util/sequence.rs
+++ b/lexical-core/src/util/sequence.rs
@@ -237,6 +237,8 @@ pub trait Contains<T: PartialEq> {
fn contains(&self, x: &T) -> bool;
}
+// Remove when we drop sup... | 2 | 18 | 0 |
c3ed01225fa1881aed256937f2a24f712801b404 | Alex Huszagh | 2019-02-12T19:05:53 | Added f32 versions just for #8 for good measure. | diff --git a/lexical-core/src/atof/api.rs b/lexical-core/src/atof/api.rs
index b3eb059..9ac7ba0 100644
--- a/lexical-core/src/atof/api.rs
+++ b/lexical-core/src/atof/api.rs
@@ -247,6 +247,9 @@ mod tests {
assert!(atof32_slice(b"INF").is_infinite());
assert!(atof32_slice(b"+inf").is_infinite());
... | 2 | 7 | 0 |
3fe9bd0fef5b32d6fb9fa2de27911d24c116dd29 | Alex Huszagh | 2019-02-12T18:57:07 | Added data to address #8. | diff --git a/lexical-core/src/atof/api.rs b/lexical-core/src/atof/api.rs
index 48bf2e0..b3eb059 100644
--- a/lexical-core/src/atof/api.rs
+++ b/lexical-core/src/atof/api.rs
@@ -349,6 +349,9 @@ mod tests {
assert_eq!(ErrorCode::InvalidDigit, try_atof64_slice(b"-.").error.code);
assert_eq!(ErrorCode::In... | 2 | 7 | 0 |
0c45b0111045179ec6ff7dc5af3b1492d56993ef | Alex Huszagh | 2019-02-06T18:39:50 | Updated benchmarks for unchecked_index. | diff --git a/lexical-benchmark/lexical/Cargo.toml b/lexical-benchmark/lexical/Cargo.toml
index 7dfd5a7..691fefd 100644
--- a/lexical-benchmark/lexical/Cargo.toml
+++ b/lexical-benchmark/lexical/Cargo.toml
@@ -16,6 +16,7 @@ serde_json = "1.0"
[features]
default = []
+unchecked_index = ["lexical-core/unchecked_index"... | 1 | 1 | 0 |
b19492351a39b4b46d6d5b1439625ce8f3e583bd | Alex Huszagh | 2019-02-06T18:01:53 | Fixed to derived lexical::Error from error::Error. | diff --git a/src/error.rs b/src/error.rs
index a8b16f8..709fea7 100644
--- a/src/error.rs
+++ b/src/error.rs
@@ -1,6 +1,7 @@
//! Error definitions for lexical.
use lib::fmt;
+use lib::error::Error as StdError;
// ERROR
@@ -50,6 +51,21 @@ impl fmt::Display for Error {
}
}
+impl StdError for Error {
+ ... | 1 | 16 | 0 |
e16bd20b45f6ed7cc12cf50779abd04c5b90cfa8 | Alex Huszagh | 2019-02-06T17:57:11 | Added unchecked_index to the high-level atoi functionality. | diff --git a/Cargo.toml b/Cargo.toml
index 36dfa67..078395e 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -53,6 +53,9 @@ ryu = ["lexical-core/ryu"]
std = ["lexical-core/std"]
# Trim a trailing ".0" from an exported float string, and represent -0.0 as "0".
trim_floats = ["lexical-core/trim_floats"]
+# Don't force bound... | 1 | 3 | 0 |
3b1ebcd3bfac57b8ed2a4982391607e0a2a311e4 | Alex Huszagh | 2019-02-06T17:48:39 | Bug fixes for atoi functionality. | diff --git a/lexical-core/src/atof/algorithm/correct.rs b/lexical-core/src/atof/algorithm/correct.rs
index a31f48d..bb98bff 100644
--- a/lexical-core/src/atof/algorithm/correct.rs
+++ b/lexical-core/src/atof/algorithm/correct.rs
@@ -163,7 +163,7 @@ fn parse_mantissa<'a, M>(radix: u32, mut bytes: &'a [u8])
// Parse... | 4 | 137 | 107 |
84634fb237ee2b6848dd00b3a0d8cccaa92c520c | Alex Huszagh | 2019-01-27T18:03:39 | Updated versioning. | diff --git a/Cargo.toml b/Cargo.toml
index 31f6733..36dfa67 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -9,7 +9,7 @@ license = "MIT/Apache-2.0"
name = "lexical"
readme = "README.md"
repository = "https://github.com/Alexhuszagh/rust-lexical"
-version = "2.0.0"
+version = "2.1.0"
exclude = [
"data/*",
"benc... | 2 | 3 | 3 |
25dbffc6be03286ca9b7d576d87ef71bb2ee1b31 | Alex Huszagh | 2019-01-27T17:52:58 | Updated the high-level API to work with the low-level changes. | diff --git a/src/lib.rs b/src/lib.rs
index e391e3f..0c99ff7 100644
--- a/src/lib.rs
+++ b/src/lib.rs
@@ -78,8 +78,9 @@ pub use lexical_core::EXPONENT_DEFAULT_CHAR;
#[cfg(feature = "radix")]
pub use lexical_core::EXPONENT_BACKUP_CHAR;
-// Re-export NAN_STRING, INF_STRING and INFINITY_STRING globally.
-pub use lexica... | 1 | 3 | 2 |
32d321e9e9cb5e7b6ccbf720321e7e3240bf6a53 | Alex Huszagh | 2018-12-27T19:08:31 | Removed some bounds checks where the get must be valid. | diff --git a/lexical-core/src/atof/api.rs b/lexical-core/src/atof/api.rs
index ce043a8..2b65f01 100644
--- a/lexical-core/src/atof/api.rs
+++ b/lexical-core/src/atof/api.rs
@@ -17,9 +17,11 @@ if #[cfg(feature = "correct")] {
/// Trait to define parsing of a string to float.
trait StringToFloat: Float {
/// Seria... | 8 | 345 | 205 |
c4db437c1c08ff8b6199b3539484868b8f8c5a88 | Alex Huszagh | 2018-12-23T18:42:20 | Fixed the fuzzing targets. | diff --git a/lexical-core/fuzz/fuzz_targets/atof32.rs b/lexical-core/fuzz/fuzz_targets/atof32.rs
index 826d87b..b3ca433 100644
--- a/lexical-core/fuzz/fuzz_targets/atof32.rs
+++ b/lexical-core/fuzz/fuzz_targets/atof32.rs
@@ -3,5 +3,5 @@
extern crate lexical_core;
fuzz_target!(|data: &[u8]| {
- let _ = lexical_co... | 14 | 14 | 14 |
e5c4ce546125eb52c8fd14f8612139d1a0f03bfb | Alex Huszagh | 2018-12-23T04:05:24 | Update versions for release. | diff --git a/Cargo.toml b/Cargo.toml
index a1611ec..bed9e66 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -9,7 +9,7 @@ license = "MIT/Apache-2.0"
name = "lexical"
readme = "README.md"
repository = "https://github.com/Alexhuszagh/rust-lexical"
-version = "1.9.1"
+version = "2.0.0"
exclude = [
"data/*",
"benc... | 2 | 3 | 3 |
444a01ced162cdc8499459166f51cc5585ded89a | Alex Huszagh | 2018-12-22T02:22:16 | Bug fix for FLOAT_ROUNDING exposition. | diff --git a/lexical-core/src/atof/algorithm/incorrect.rs b/lexical-core/src/atof/algorithm/incorrect.rs
index 1f2708a..a97f15e 100644
--- a/lexical-core/src/atof/algorithm/incorrect.rs
+++ b/lexical-core/src/atof/algorithm/incorrect.rs
@@ -155,10 +155,10 @@ fn parse_float<'a>(radix: u32, bytes: &'a [u8])
///
/// The... | 5 | 11 | 6 |
5000e1a1c2f6960999d42604f9f3ca8d8856d5c5 | Alex Huszagh | 2018-12-22T02:07:23 | Bug fixes for FLOAT_ROUNDING not being present without correct. | diff --git a/lexical-core/src/lib.rs b/lexical-core/src/lib.rs
index a6f5ea9..9bbcc8f 100644
--- a/lexical-core/src/lib.rs
+++ b/lexical-core/src/lib.rs
@@ -187,7 +187,6 @@ pub use util::{MAX_U8_SIZE, MAX_U16_SIZE, MAX_U32_SIZE, MAX_U64_SIZE, MAX_U128_S
pub use util::{MAX_F32_SIZE, MAX_F64_SIZE};
// Re-export the f... | 3 | 3 | 2 |
27a83c1c6c7a340a7ea101aebc28d75e3edeb04f | Alex Huszagh | 2018-12-21T17:02:18 | Fine-tuned performance to avoid performance regressions. | diff --git a/lexical-core/src/atof/api.rs b/lexical-core/src/atof/api.rs
index f522211..8521110 100644
--- a/lexical-core/src/atof/api.rs
+++ b/lexical-core/src/atof/api.rs
@@ -159,11 +159,11 @@ macro_rules! wrap {
($name:ident, $f:tt, $lossy:expr) => (
/// Parse float and return value, subslice read, and... | 3 | 39 | 40 |
6627f0763cecc2ceeefd73b2b7faf79c029df11c | Alex Huszagh | 2018-12-21T15:24:41 | Fixed soem codegen issues. | diff --git a/lexical-core/src/atof/algorithm/correct.rs b/lexical-core/src/atof/algorithm/correct.rs
index 4adf96a..0e12241 100644
--- a/lexical-core/src/atof/algorithm/correct.rs
+++ b/lexical-core/src/atof/algorithm/correct.rs
@@ -129,7 +129,7 @@ impl<'a> FloatSlice<'a> {
// but we should remove them before ... | 6 | 65 | 64 |
fe2b2fbdbbdb78794db8cb0527c522af047ae54c | Alex Huszagh | 2018-12-21T14:41:02 | Implemented the FFI APIs in terms of the safe, Rust APIs. | diff --git a/lexical-core/src/atof/algorithm/correct.rs b/lexical-core/src/atof/algorithm/correct.rs
index be3533b..4adf96a 100644
--- a/lexical-core/src/atof/algorithm/correct.rs
+++ b/lexical-core/src/atof/algorithm/correct.rs
@@ -65,6 +65,8 @@ impl<'a> FloatSlice<'a> {
self.integer.len()
}
+// TODO(a... | 9 | 302 | 380 |
b8775220ca61df7ae72ae8e4811ec34dcf3e3d91 | Alex Huszagh | 2018-12-20T19:27:31 | Updated various algorithms to use slices by default, rather than ranges. | diff --git a/lexical-core/src/util/algorithm.rs b/lexical-core/src/util/algorithm.rs
index 9c62b66..21f58ec 100644
--- a/lexical-core/src/util/algorithm.rs
+++ b/lexical-core/src/util/algorithm.rs
@@ -169,13 +169,11 @@ pub fn case_insensitive_ends_with_slice<'a>(l: &'a [u8], r: &'a [u8])
/// Returns a pointer to the n... | 1 | 22 | 44 |
4e73ebdf0d7d3051df7964cff46605512d70f72b | Alex Huszagh | 2018-12-20T19:10:59 | Finished atoi safe implementation. | diff --git a/lexical-core/src/atof/algorithm/correct.rs b/lexical-core/src/atof/algorithm/correct.rs
index 0e44802..38dec02 100644
--- a/lexical-core/src/atof/algorithm/correct.rs
+++ b/lexical-core/src/atof/algorithm/correct.rs
@@ -8,7 +8,7 @@
// Fix a compiler bug that thinks `ExactExponent` isn't used.
#![allow(un... | 14 | 228 | 190 |
4a222e7a2948b7a73d1096bc0145e94e2065fa23 | Alex Huszagh | 2018-12-20T17:13:36 | Finished ftoa using safe code. | diff --git a/lexical-core/src/ftoa/api.rs b/lexical-core/src/ftoa/api.rs
index e9eedff..a3056b5 100644
--- a/lexical-core/src/ftoa/api.rs
+++ b/lexical-core/src/ftoa/api.rs
@@ -28,8 +28,7 @@ pub(crate) trait FloatToString: Float {
/// Export float to radix string with slow algorithm.
#[cfg(feature = "radix"... | 3 | 25 | 41 |
8897479cd8fc34cda0d0698bdab71941a191fb24 | Alex Huszagh | 2018-12-20T14:48:44 | Finished most of itoa using safe slice ranges. | diff --git a/lexical-core/src/atof/algorithm/correct.rs b/lexical-core/src/atof/algorithm/correct.rs
index 6d6a685..ddbc473 100644
--- a/lexical-core/src/atof/algorithm/correct.rs
+++ b/lexical-core/src/atof/algorithm/correct.rs
@@ -304,11 +304,11 @@ fn pow2_fast_path<F>(mantissa: u64, radix: u32, pow2_exp: i32, expone... | 12 | 273 | 333 |
1b429d5ec4999de3033889a32492e75d93d5efa6 | Alex Huszagh | 2018-12-19T21:10:32 | Use 64-bit limbs on AArch64 and PowerPC64, since both support mulhi, mullo instructions for 64-bit inputs. | diff --git a/lexical-core/src/atof/algorithm/bigcomp.rs b/lexical-core/src/atof/algorithm/bigcomp.rs
index 31056d8..912f6c4 100644
--- a/lexical-core/src/atof/algorithm/bigcomp.rs
+++ b/lexical-core/src/atof/algorithm/bigcomp.rs
@@ -231,7 +231,12 @@ pub unsafe fn fast_atof<F, Iter>(digits: Iter, radix: u32, sci_exponen... | 7 | 158 | 38 |
b6a9f3a9eb652525f45be6c04e6f3a36b58ef749 | Alex Huszagh | 2018-12-18T17:05:35 | Bug fix for issue with feature(alloc) not being turned on with bhcmp on nightly. | diff --git a/lexical-core/src/lib.rs b/lexical-core/src/lib.rs
index f6fb714..42c205a 100644
--- a/lexical-core/src/lib.rs
+++ b/lexical-core/src/lib.rs
@@ -88,7 +88,7 @@
// Require intrinsics in a no_std context.
#![cfg_attr(not(feature = "std"), no_std)]
-#![cfg_attr(all(not(feature = "std"), feature = "algorithm... | 1 | 1 | 1 |
b55a9db0df84a1a43b83e31f5317f1d35fa28a09 | Alex Huszagh | 2018-12-18T16:51:00 | Bug fixes for failing radix unittests. | diff --git a/lexical-core/src/atof/algorithm/correct.rs b/lexical-core/src/atof/algorithm/correct.rs
index 3b53a28..a509dc4 100644
--- a/lexical-core/src/atof/algorithm/correct.rs
+++ b/lexical-core/src/atof/algorithm/correct.rs
@@ -937,7 +937,8 @@ mod tests {
// invalid mantissa
#[cfg(feature = "ra... | 3 | 16 | 14 |
11e5b51823897fb650fd52010ea3d7e8d461206c | Alex Huszagh | 2018-12-18T16:45:04 | Updated the panic assertions in the documentation. | diff --git a/lexical-core/src/util/api.rs b/lexical-core/src/util/api.rs
index 12fe82b..63bd6e2 100644
--- a/lexical-core/src/util/api.rs
+++ b/lexical-core/src/util/api.rs
@@ -58,10 +58,13 @@ macro_rules! generate_from_range_api {
/// If the `radix` feature is enabled, panics if radix is not in
/// t... | 1 | 7 | 0 |
edcd844f469c4398d0328fb16ade04ffa856c238 | Alex Huszagh | 2018-12-18T06:41:14 | Added another test the f32 correctly rounds from string. | diff --git a/lexical-core/src/atof/algorithm/correct.rs b/lexical-core/src/atof/algorithm/correct.rs
index a7da9a2..3b7f5f3 100644
--- a/lexical-core/src/atof/algorithm/correct.rs
+++ b/lexical-core/src/atof/algorithm/correct.rs
@@ -1074,6 +1074,11 @@ mod tests {
// Round-up, above halfway
che... | 1 | 5 | 0 |
e7e4cecf990e52b16073f5d33f79cd2c8f0cb6a0 | Alex Huszagh | 2018-12-18T06:09:58 | Added support for disguised fast path cases. | diff --git a/lexical-core/src/atof/algorithm/correct.rs b/lexical-core/src/atof/algorithm/correct.rs
index 2d9617d..a7da9a2 100644
--- a/lexical-core/src/atof/algorithm/correct.rs
+++ b/lexical-core/src/atof/algorithm/correct.rs
@@ -15,6 +15,7 @@ use util::*;
use super::cached::ModeratePathCache;
use super::bigcomp;
... | 4 | 198 | 11 |
57dff01a83961728c7d006c74727c72092199a18 | Alex Huszagh | 2018-12-18T04:27:55 | Fixed a few invalid floating-point decimal strings that were incorrectly being identified as valid floats via proptests. | diff --git a/lexical-core/src/atof/algorithm/exponent.rs b/lexical-core/src/atof/algorithm/exponent.rs
index 7651f1f..2f4af02 100644
--- a/lexical-core/src/atof/algorithm/exponent.rs
+++ b/lexical-core/src/atof/algorithm/exponent.rs
@@ -17,7 +17,10 @@ use util::*;
pub(super) unsafe extern "C" fn parse_exponent(state: ... | 3 | 114 | 9 |
610f67534030bcfa74d4ec0cae5e02eff8e953ac | Alex Huszagh | 2018-12-17T19:04:22 | Added panic conditions, for #3. | diff --git a/lexical-core/src/util/api.rs b/lexical-core/src/util/api.rs
index b7d7fc7..12fe82b 100644
--- a/lexical-core/src/util/api.rs
+++ b/lexical-core/src/util/api.rs
@@ -52,6 +52,12 @@ macro_rules! generate_from_range_api {
/// * `radix` - Radix for the number parsing (normally 10).
/// * `fi... | 2 | 70 | 4 |
be31f27e92d3c710bf414681f2a10e80f7b68e18 | Alex Huszagh | 2018-12-17T18:25:41 | Patch for failing macro test, simple typo. | diff --git a/lexical-core/src/lib.rs b/lexical-core/src/lib.rs
index ee824fc..f6c6e4b 100644
--- a/lexical-core/src/lib.rs
+++ b/lexical-core/src/lib.rs
@@ -72,7 +72,7 @@
//! assert_eq!(slc, "15");
//!
//! // If an insufficiently long buffer is passed, the serializer will panic.
-//! let mut buf = b['0'; 1];
+//! le... | 1 | 1 | 1 |
f7612228b3d87900ae78226107dd848c1a1e22dd | Alex Huszagh | 2018-12-16T17:30:36 | Added the trim_floats feature and remove the capacity to use smaller buffers and copy into the buffer. | diff --git a/Cargo.toml b/Cargo.toml
index c71f5fc..4bb40ee 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -50,6 +50,8 @@ radix = ["lexical-core/radix"]
ryu = ["lexical-core/ryu"]
# Use the `std` library.
std = ["lexical-core/std"]
+# Trim a trailing ".0" from an exported float string.
+trim_floats = []
# Build the co... | 6 | 178 | 102 |
953cc39666ae3dee3214c7408aa02ecfe51408ad | Alex Huszagh | 2018-12-16T16:42:26 | Bug fix for issue #2. | diff --git a/lexical-core/src/atof/api.rs b/lexical-core/src/atof/api.rs
index 04b6823..b77ff69 100644
--- a/lexical-core/src/atof/api.rs
+++ b/lexical-core/src/atof/api.rs
@@ -105,6 +105,11 @@ unsafe fn filter_special<F: StringToFloat>(radix: u32, first: *const u8, last: *
(F::INFINITY, first.add(INF_STRING.l... | 1 | 6 | 0 |
265e25b1e69e3c2cecc764a1a5d3b2f88b807b27 | Alex Huszagh | 2018-12-16T16:37:55 | Expose BUFFER_SIZE constant. | diff --git a/lexical-core/src/lib.rs b/lexical-core/src/lib.rs
index d20e3c6..44086df 100644
--- a/lexical-core/src/lib.rs
+++ b/lexical-core/src/lib.rs
@@ -93,6 +93,9 @@ pub use util::{INF_STRING, INFINITY_STRING, NAN_STRING};
// Re-export the error structs and enumerations.
pub use util::{Error, ErrorCode, is_succe... | 2 | 4 | 1 |
b8b332764dd896411ff1cdbb0b57c7802f47520d | Alex Huszagh | 2018-12-16T06:55:00 | Updated version dependencies, and fixed a very minor integer overflow bug (when applying a unary minus to signed integers that had previously overflowed during parsing, when the value overflows to min_value exactly. Since we already return an ErrorKind::Overflow for this, this error should be should be silenced with wr... | diff --git a/Cargo.toml b/Cargo.toml
index 24cebaf..c71f5fc 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -9,7 +9,7 @@ license = "MIT/Apache-2.0"
name = "lexical"
readme = "README.md"
repository = "https://github.com/Alexhuszagh/rust-lexical"
-version = "1.8.1"
+version = "1.8.2"
exclude = [
"data/*",
"benc... | 2 | 3 | 3 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.