Skip to content

Releases: Alexhuszagh/rust-lexical

Lexical-Core Version 0.8.2 Release

11 Mar 19:31
Compare
Choose a tag to compare

Reproduced all dependent licenses in lexical, and document extensively what features are dependent on what licensing terms.

Bug Fix for Number Format API

03 Sep 14:06
Compare
Choose a tag to compare

Existing code using digit separators such as "4_2.0" in the integral component would fail, due the counting of non-digit separators in number parsing not incrementing when calling step_by_unchecked. This led to erroneous Error::EmptyInteger results.

Lexical-Core Version 0.8.0 Release

03 Sep 14:03
Compare
Choose a tag to compare

This was a large release that Involved a near complete re-write of lexical for faster algorithms, a simpler internal design, and faster digit parsing implementations.

Options API

  • Added the Options API, a way to customize numeric conversions at runtime. The Options API is described in depth here, and contains the following structs:
    • ParseFloatOptions
    • ParseIntegerOptions
    • WriteFloatOptions
    • WriteIntegerOptions

Format API

  • Change NumberFormat to be a packed u128 struct to allow more extensive configuration and use const generics.
  • Changed NumberFormat to be an internal implementation detail, and NumberFormatBuilder to be the public API for creating custom formats at compile time.

Simplified the public API

  • Added parse_with_options, parse_partial_with_options.

  • Added write_with_options, write_unchecked, and write_with_options_unchecked.

  • Remove the write_format, write_radix, and similar functions.

  • Remove the parse_format, parse_radix, and similar functions.

  • Added a faster float writer and parser for power of 2 radixes.

  • Added the required_exponent_notation flag to NumberFormat.

  • Added the power-of-two feature, for conversion to and from strings with power-of-two bases.

  • Added the compact feature, optimized for binary size rather than performance.

  • Added extensive documentation on benchmarks, algorithms used, and internal implementation details.

Removal Features

  • Removed the dtoa feature. This allows only 1 compact backend and 1 performance backend, for fully additive features. The new Dragonbox algorithm is faster than any existing algorithms.
  • Removed the rounding feature. This was never used in practice.
  • Removed the lexical-capi. Existing, high-performance C/C++ libraries exist, so it's no longer practical.

Algorithm Improvements

  • Made the Eisel-Lemire algorithm the default float-parser, leading to substantial improvements in performance.
  • Made Dragonbox the default float writer.
  • Removed pre-computed float tables of powers-of-two, and recreated stable powers of 2 through bit manipulations.
  • Improved the algorithms to write and parse 128-bit integers, using faster division and multiplication algorithms.
  • Simplified the big-integer arithmetic, improving performance and simplifying maintenance for float parsing algorithms.

Other Changes

  • Updated the MSRV to 1.51.0.
  • Updated the benchmarks to note the significant algorithm changes.
  • Added automatic formatting via Rustfmt, linting via Clippy, as well as increased documentation of safety guarantees.
  • Added support for base prefixes and suffixes.
  • Reduced static storage required for extended-float algorithms.
  • Updated the fuzz handlers and conformance tests.
  • Refactored all numeric conversions into separate crates, using workspaces.

Bug Fixes

  • Fixed a bug with trailing digit separators in special values.

Lexical-Core Version 0.7.6 Release

21 Apr 17:35
Compare
Choose a tag to compare
  • Updated cfg_if version.
  • Downgraded rand to fix proptests.
  • Fixed a bug on newer Rustc versions where slice::sort is not present in no_std.
  • Added a feature libm which enables stable no_std use.
  • Patched an implementation of insert_many due to a security advisory which does not affect lexical.

Lexical-Core Version 0.7.5 Release

21 Apr 04:43
Compare
Choose a tag to compare

Fixed issue with Integer::BITS conflicting with new compilers.

Lexical-Core Version 0.6.8 Release

21 Apr 17:13
Compare
Choose a tag to compare
  • Patched an implementation of insert_many due to a security advisory which does not affect lexical.
  • Fixed build script for cross-compiling.
  • Updated cfg_if version.

Lexical-Core Version 0.4.8 Release

21 Apr 16:33
Compare
Choose a tag to compare
  • Updated cfg_if dependency.
  • Dropped support for Rustc versions older than 1.31.0.
  • Patched an implementation of insert_many due to a security advisory which does not affect lexical.
  • Fixed build script for cross-compiling.

Lexical-Core Version 0.7.4 Release

29 Jan 16:21
Compare
Choose a tag to compare

Updated NumberFormat flags.

  • Changed NumberFormat to use 64-bit flags.
  • Added NO_INTEGER_LEADING_ZEROS and NO_FLOAT_LEADING_ZEROS NumberFormat flags.
  • Added InvalidLeadingZeros to ErrorCode enum.
  • Added validate_no_leading_zeros to reject invalid inputs.
  • Added new leading zero checks to all pre-defined NumberFormat constants.

Lexical-Core Version 0.6.7 Release

29 Jan 16:21
Compare
Choose a tag to compare

Updated NumberFormat flags.

  • Changed NumberFormat to use 64-bit flags.
  • Added NO_INTEGER_LEADING_ZEROS and NO_FLOAT_LEADING_ZEROS NumberFormat flags.
  • Added InvalidLeadingZeros to ErrorCode enum.
  • Added validate_no_leading_zeros to reject invalid inputs.
  • Added new leading zero checks to all pre-defined NumberFormat constants.

Lexical-Core Version 0.7.3 Release

26 Jan 17:35
Compare
Choose a tag to compare

Updated the format bitflags to make matches more efficient.

  • Digit separator flags are grouped by component (integer, etc.).
  • Allows jump tables for for internal matches.