5.4 KiB
5.4 KiB
Version 1.0.0 (2022-08-07)
- Replace error types
InvalidUtf8Array,InvalidUtf8Slice,InvalidUtf8FirstByteandInvalidUtf8withUtf8ErrorplusUtf8ErrorKind.
Which of the new error kind variants is reported don't map 1:1 to the old enum variants: For exampleUtf8ErrorKind::NonUtf8Byteis returned for sequences that would previously have been reported as too high codepoint or overlong encoding. - Rename many other error types for consistency:
InvalidCodepoint->CodepointErrorInvalidUtf16FirstUnit->Utf16FirstUnitErrorInvalidUtf16Array->Utf16ArrayErrorInvalidUtf16Slice->Utf16SliceError1InvalidUtf16Tuple->Utf16TupleError
- Change return type of
CodepointError::error_range()toRangeInclusive. - Rename some errors variants:
Utf16SliceError::FirstLowSurrogate->FirstIsTrailingSurrogateUtf16SliceError::SecondNotLowSurrogate->SecondIsNotTrailingSurrogateUtf16TupleError::InvalidSecond->SecondIsNotTrailingSurrogate
- Expose the error type of
Utf16Char::from_bmp()and rename it toNonBmpError. - Remove re-exports of
Utf8CharIteratorandUtf16CharIteratorfrom the crate root.
(They are still exposed via theiteratormodule.) - Remove impls of the deprecated
AsciiExttrait, and make the methods available in#![no_std]-mode. - Make many of the previously
AsciiExtmethods take self by value. - Drop support for pre-1.0 versions of the ascii crate.
- Remove
iter_bytes()anditer_units(). - Increase minimum Rust version to 1.56 and change the minimum Rust version policy.
- Fix possible UB or panic in
Utf8Char::from_slice_start_unchecked()when passed an empty slice.
(relates to #12.) - Make many methods
const fn. - Add
const fnsUtf8Char::new()andUtf16Char::new().
Version 0.3.6 (2019-08-23)
- Fix pointless undefined behavior in
Utf16Char.to_ascii_char()(which is part of ascii feature) - Widen ascii version requirement to include 1.*.
- Add
[u16; 2]UTF-16 array alternatives to(u16, Some(u16))UTF-16 tuple methods. - Add
Utf16Char.is_bmp().
Version 0.3.5 (2018-10-23)
- Fix docs.rs build failure
Version 0.3.4 (2018-10-23)
- Fix UB in UTF-8 validation which lead to invalid codepoints being accepted in release mode.
- Add fallible decoding iterator adapters
Utf8CharMergerandUtf16CharMergerand slice-based iteratorsUtf8CharDecoderandUtf16CharDecoder - Widen ascii version requirement from 0.8.* to 0.8.0 - 0.10.*
- Implement creating / extending
Strings fromUtf16Char-producing iterators
Version 0.3.3 (2018-10-16)
- Fix UTF-8 overlong check. (
from_array()andfrom_slice()accepted two-byte encodings of ASCII characters >= '@', which includes all letters) - Implement
FromStrforUtf16Char - Add
from_str_start()toUtf8CharandUtf16Char - Add
Utf{8,16}Char{s,Indices}:str-based iterators forUtf8CharandUtf16Charequivalent tochar'sCharsandCharIndices. - Add
StrExtwith functions to create the above iterators. - Implement
FromIteratorandExtendforVec<{u8,u16}>with reference-producingUtf{8,16}Chariterators too. - Add
Utf8CharSplitterandUtf16CharSplitter:Utf{8,16}Char-to-u{8,16}iterator adapters. - Add
IterExt,iter_bytes()anditer_units()to create the above splitting iterators. - Add
Utf8Char::from_ascii(),Utf16Char::from_bmp()with_uncheckedversions of both. - Add cross-type
PartialEqandPartialOrdimplementations. - Change the
description()for a few error types.
Version 0.3.2 (2018-08-08)
- Hide
AsciiExtdeprecation warning and add replacement methods. - Correct documentation for
U8UtfExt::extra_utf8_bytes(). - Fix misspellings in some error descriptions.
- Avoid potentially bad transmutes.
Version 0.3.1 (2017-06-16)
- Implement
DisplayforUtf8CharandUtf16Char.
Version 0.3.0 (2017-03-29)
- Replace the "no_std" feature with opt-out "std".
- Upgrade ascii to v0.8.
- Make tests compile on stable.
- Remove
CharExt::write_utf{8,16}()becauseencode_utf{8,16}()has been stabilized. - Return a proper error from
U16UtfExt::utf16_needs_extra_unit()instead ofNone. - Rename
U16UtfExt::utf_is_leading_surrogate()tois_utf16_leading_surrogate(). - Rename
Utf16Char::from_slice()tofrom_slice_start()andCharExt::from_utf{8,16}_slice()tofrom_utf{8,16}_slice_start()to be consistent withUtf8Char. - Fix a bug where
CharExt::from_slice()would accept some trailing surrogates as standalone codepoints.
Version 0.2.0 (2016-07-24)
- Change
CharExt::write_utf{8,16}()to panic instead of returningNoneif the slice is too short. - Fix bug where
CharExt::write_utf8()andUtf8Char::to_slice()could change bytes it shouldn't. - Rename lots of errors with search and replace:
- CodePoint -> Codepoint
- Several -> Multiple
- Update the ascii feature to use ascii v0.7.
- Support
#[no_std]; see 70e090ee for differences. - Ungate impls of
AsciiExt. (doesn't require ascii or nightly) - Make the tests compile (and pass) again. (They still require nightly).
Version 0.1.* (2016-04-07)
First release.