Skip to content

Latest commit

 

History

History
404 lines (316 loc) · 15.1 KB

CHANGELOG.md

File metadata and controls

404 lines (316 loc) · 15.1 KB

Changelog

All notable changes will be documented in this file.

This document is written according to the Keep a Changelog style.

  1. Version 1
    1. 1.1.0
    2. 1.0.1
    3. 1.0.0
  2. Version 0 (Prototyping)
    1. 0.22
    2. 0.21
    3. 0.20
    4. 0.19
    5. 0.18
    6. 0.17
    7. 0.16
    8. 0.15
    9. 0.14
    10. 0.13
    11. 0.12
    12. 0.11
    13. 0.10
    14. 0.9
    15. 0.8
    16. 0.7
    17. 0.6
    18. 0.5
    19. 0.4
    20. 0.3
    21. 0.2
    22. 0.1

Version 1

bitvec’s initial development is now complete, and uses the one-dot series. It will continue to receive maintenance, but its API is now stable and will not change until const-generics allow BitArray to be rewritten.

1.1.0

The BitSlice::shift_{left,right} functions have been renamed to BitSlice::shift_{start,end} to try to better reflect their behavior. These functions move data relative to the index as defined by the O: BitOrder type parameter, not according to the processor lsl and lsr instructions.

1.0.1

Notes

Performance regressions have been reported between the development series 0.20 onwards and 1.0. It appears at least some of these regressions are due to the removal of the #[inline] attribute on bitvec public functions.

This attribute has been applied to all bitvec functions. You may see regressions in size of your final artifact, but you should also see improvements in your runtime speed. This is being tracked in sharksforarms/deku#246.

Changes

  • The bits![static mut …] invocation has been made unsafe at the invocation site, in response to Issue #156 filed by GitHub user @SimonSapin.

    This is technically an API break (formerly safe code now requires an unsafe block) but as no run-time behavior or compile-time types have changed except for this, and Rust considers breaking incorrect code to be acceptable within SemVer patches, I am publishing it as a patch.

  • GitHub user @dtolnay fixed incorrect serde behaviors in Pull Request #185. This behavior was first reported in Issue #167 by GitHub user @Nelarius.

  • Compilation no longer depends on environment variables set by Cargo, as requested in Pull Request #162 by GitHub user @rocallahan.

  • The bitvec![val; len] macro can again take len as a runtime value as well as a compile-time constant. Pull Request #160 was provided by GitHub user @coolreader18.

  • The return types of slice::Iter::by_{refs,vals} are restored to named types, rather than impl Iterator... opaque types. This allows them to be used directly in other sites. This defect was reported in Issue #169 by GitHub user @dignifiedquire.

1.0.0

🚨 THIS IS A BREAKING CHANGE RELEASE! 🚨

Your code has broken. You will need to change it in order to use this. This work on your part is worth it.

This release has a great deal of changes from the 0.22 development series! Most breaking changes should have reasonable error messages indicating how they can be repaired.

Removed APIs do not have deprecation notices! Use of removed APIs will fail to compile. You must check this changelog, or the crate documentation, to find out appropriate replacements.

Type Parameter Reördering

The <O, T> type parameter pair that has existed since 0.10 is reversed to be <T, O>! This will cause all of your type definitions to fail, as suddenly all of your chosen type arguments do not satisfy the demanded traits.

This change was made in accordance with Issue #136, requested by GitHub user @changhe3.

Additional Changes

  • The MSRV is raised to 1.56.
  • BitField now supports signed integers! BitMemory is completely removed.
  • BitSlice::from_slice{,_mut} are now infallible constructors, and panic when the source is too long. The original fallible behavior is renamed to BitSlice::try_from_slice{,_mut}.
  • the {Bit,}DomainMut types have been removed. The {Bit,}Domain types now take a Mutability type parameter instead. The .{bit_,}domain{,_mut}() methods on BitSlice exist as normal, but have changed their return types to specify a Const or Mut type parameter rather than {Bit,}Domain or {Bit,}DomainMut, respectively.
  • Iter::by_{ref,val} are renamed to by_{ref,val}s, to prevent collision with Iterator::by_ref.
  • The long-standing behavior of the &=, |=, and ^= operators has been changed! They now operate directly on data structures, rather than routing through iterators. If you want to perform boolean arithmetic using arbitrary bool streams, use iterator combinators like .iter_mut().zip(stream).for_each(|(mut orig, new)| *orig ^= new). This change allows the arithmetic implementations to be accelerated when working between bit-slices of equal types.
  • BitSlice::set_all is removed, as the standard-library API [T]::fill replaces it.
  • BitSlice::offset_from is removed. Use .as_bitptr().offset_from().
  • BitSlice::as_raw_slice is removed. Use .domain() to access the underlying memory.

Documentation

Module and type documentation have been lifted into the doc/ tree as Markdown files. The user guide, in book/ has been more thoroughly rewritten.

Please file any problems or confusions about the documentation as an issue! The documentation is a project artifact equally, if not more, important as the Rust library.

Dependency Raises

As part of the migration of incidental logic out of bitvec, the following utility libraries have been updated:

  • funty 2.0 provides a more comprehensive coverage of the language primitives.
  • wyz 0.5 contains more logic formerly in the utility module, as well as a stronger system for generalizing over references.

Version 0 (Prototyping)

bitvec’s first three and a half years of development used the zero-dot series as it explored its behavior. These versions are now deprecated and will not receive further support. They are listed only in summary, and may be removed from crates.io in the future.

0.22

  • Raised MSRV to 1.51 for const generics.
  • Named the iterators produced by Iter::by_{ref,val}.
  • Fixed Issue #114, reported by GitHub user @VilleHallivuori.
  • Extracted pointer mutability tracking to wyz 0.4.

0.21

  • Raised funty dependency to ~1.2.
  • Moved bit-array typename construction out of bitarr! and into BitArr!.
  • Created BitVec::from_{element,slice} constructors for Issue #6, reöpened by GitHub user @HamishWMC.
  • Fixed the behavior of BitSlice::{first,last}_{one,zero}, requested in Issue #103 by GitHub user @seanyoung.
  • Added BitSlice::{leading,trailing}_{ones,zeros}, also in #103 by @seanyoung.
  • Added static to the bits! argument for hidden-static construction.
  • Accelerate Iter{Ones,Zeros} with specialization.
  • Pull Request #104 by GitHub user @ordian fixed crashing when calling BitVec::insert exactly at self.len().

0.20

  • Allowed use of atomic and Cell types as the original storage type.
  • Added bit-seeking APIs (.iter_{ones,zeros}) to match APIs in bit-set, requested in Issue #83 by GitHub user @arucil.
  • Refined the <T: Unsigned as BitStore>::Alias system to prevent improper mutation.
  • Implemented IntoIterator on BitArray.
  • Construct BitVec from integer elements, not just bits.
  • Added .remove_alias() to mutable-bit-slice iterators.
  • Ported more of core::ptr as bitvec::ptr.
  • Renamed BitMut to BitRef and create single-bit BitPtr pointers.
  • Created BitPtrRange as an analogue to Range<*bool>.
  • Removed deprecated BitView methods.

0.19

  • Accelerated BitSlice::copy_from_bitslice
  • Created BitSlice::offset_from to enable computing how far into a base bit-slice a subslice begins.
  • Used radium 0.5’s stronger type system, including fallback aliases when targets do not have atomics.
  • Changed internal implementation of the macro constructors.

0.18

  • Raised MSRV to 1.44.
  • Renamed the C-compatible ordering Local to LocalBits.
  • Fixed an incomplete change of default type parameters from LocalBits to Lsb0.
  • Introduced the BitStore::Alias system for coöperative mutation.
  • Reärranged the view conversion traits, creating BitView alongside AsBits and AsBitsMut.
  • Greatly improved cross-compile testing with a CI suite by @AlexHuszagh.
  • Removed numeric arithmetic, per Issue #17 (by me) and Issue #50 by GitHub user @luojia65.
  • Created BitArray, as requested in Issue #32 by GitHub user @FedericoPonzi. This also includes a bitarr! constructor.
  • Merged Pull Request #68 by GitHub user @sharksforarms.
  • Fixed Issue #69 by GitHub user @YoshikiTakashima.
  • Per Issue #75 by GitHub user @diondokter, BitMemory describes all unsigned integers, not just BitStore implementors, and BitField can transact them all.

0.17

  • In Pull Request #34, GitHub user @mystor provided a bits! implementation that encodes buffers at compile time, and allows them to be borrowed as BitSlices.
  • Renamed Cursor to BitOrder, and LittleEndian and BigEndian to Lsb0 and Msb0.
  • Removed the Words alias, and implemented BitStore on `usize.
  • Removed the As{Ref,Mut}<BitSlice<_, T>> implementations for [T], as requested in [Issue #35] by GitHub user [@Fotosmile].
  • Fixed [Issue #40] with [Pull Request #41], both provided by GitHub user [@ImmemorConsultrixContrarie].
  • Fixed [Issue #43], reported by GitHub users @AlexHuszagh and [@obeah].
  • Fixed an improper deällocation, per [Issue #55] reported by GitHub user [@kulp].

0.16

  • Created Cursor::mask for faster direct memory access.
  • Created the BitField trait.
  • Added a Word alias to the target’s usize equivalent (now just usize).
  • Created a Local implementation of Cursor (now the LocalBits alias).
  • Changed default type parameters to <Local, Word>.
  • Created the index module, reducing runtime assertions.
  • Fixed [Issue #33], reported by GitHub sure [@jonas-schievink], which addressed incorrect reällocation in BitVec::reserve.
  • Updated radium dependency to 0.3, fixing [Issue #36] reported by GitHub user [@lynaghk].

0.15

  • Raised MSRV to 1.36.
  • Reärranged the feature set to use the now-available extern crate alloc;.
  • Conditionally remove Send from BitSlice.
  • Improve the bitvec! repetition constructor, as reported in [Issue #28] by GitHub user [@caelunshun].

0.14

  • Added reversed (left-to-right) addition, requested in [Issue #16] by GitHub user [@GeorgeGkas].

0.13

  • Changed the bit-region pointer encoding to its final form.

0.12

  • Created BitSlice::at, which manifests a proxy reference to a single bit.
  • Renamed Bits to BitStore
  • Created the Bits and BitsMut traits to view ordinary memory as a bit-slice.

0.11

  • Raised the MSRV to 1.33.
  • Created the domain module, which manages all translations of bit-precision views into raw underlying memory.
  • Added a bitbox! macro constructor.
  • Improved the bit-region pointer encoding.
  • BitBox and BitVec are now Sync, per discussions with [@ratorx].
  • Implemented serde support (behind the serde feature).
  • Began working with atomics.
  • Fixed [Issue #9], reported by GitHub user [@torce].
  • Fixed [Issue #10], reported by GitHub user [@overminder].
  • Fixed [Issue #12], reported by GitHub user [@koushiro].
  • Fixed [Issue #15], reported by GitHub user [@schomatis].

0.10

  • Raised the MSRV to 1.31.
  • Created the BitPtr (now BitSpan) pointer encoding that enables addressing any bit, not just the front of an element.
  • Fixed [Issue #7], reported by GitHub user [@geq1t], repairing .count_{ones,zeros} inside single-element bit-slices.
  • Fixed [Issue #8], reported by GitHub user [@ratorx], implementing Send and Sync on BitSlice.
  • Disallowed u64 on 32-bit targets.

0.9

  • Renamed Endian to Cursor (now BitOrder)
  • Removed Default bound on Bits (now BitStore)

0.8

  • Added alloc and std features in [Pull Request #3] by GitHub user [@rphmeier].

0.7

  • Raised MSRV to 1.30.
  • Created the prelude module.
  • Adopted the Rust CoC.

0.6

  • Raised MSRV to 1.25.
  • Renamed .count_{one,zero} to .count_{ones,zeros}.

0.5

  • Implemented Hash.
  • Created numeric 2’s-complement arithmetic implementations.
  • Created set-testing methods (all, any, not_all, not_any, some, count_one, count_zero).

0.4

  • Added BitSlice::for_each.
  • Added more trait implementations.

0.3

  • Added BitSlice, and offloaded much of the BitVec API to it.

0.2

  • Expanded bitvec! argument syntax, and improved its codegen.

0.1

  • Created BitVec and bitvec!.
  • Created Endian (now BitOrder) and Bits (now BitStore) traits.