PackageTrack
Sign in Get early access

xmlparser

Pull-based, zero-allocation XML parser.

0.13.6 121M downloads/mo #719 most downloaded on crates.io RazrFalcon/xmlparser

What this package is like to depend on

Last release 3 years ago

no release in 18 months

Release timing varies

gaps range from 2 weeks to 1.3 years

Nearly every release is documented

notes for 22 of 23 stable releases

1 version withdrawn

withdrawn after publishing

9 years old

24 releases · first in 2017

0 releases in the last 12 months

see the full history below

Release timeline

24 releases · Dec 2017 to Sep 2023
2018 2019 2020 2021 2022 2023 2024 2025 2026
Release Pre-release Withdrawn

Releases

latest 24
  1. 0.13.6 30 Sep 2023
    Release notes

    Added

    • Token::span, Tokenizer::stream and allow cloning of Tokenizer. Thanks to @krtab.

    Changed

    • Optimize is_xml_char function. Makes parsing 5-10% faster. Thanks to @Simon-Martens.
    Open source →
  2. 0.13.5 18 Oct 2022
    Release notes

    Fixed

    • Do no use recursive calls during parsing. Could lead to stack overflow on some input.
    • Revert Do not expand predefined references in Stream::consume_reference.
    • Tests on Rust 1.61. Thanks to @krtab.
    Open source →
  3. 0.13.4 24 Jun 2021 withdrawn
    Release notes

    Fixed

    • Do not expand predefined references in Stream::consume_reference. Thanks to @Jesse-Bakker.
    Open source →
  4. 0.13.3 02 Sep 2020
    Release notes

    Changed

    Fixed

    • DtdEnd token parsing when ] and > are separated by a whitespace.
    Open source →
  5. 0.13.2 15 Jun 2020
    Release notes

    Fixed

    • Allow processing instruction before DTD.
    Open source →
  6. 0.13.1 12 Mar 2020
    Release notes

    Fixed

    • Allow comments before DTD.
    Open source →
  7. 0.13.0 07 Jan 2020
    Release notes

    Changed

    • Moved to Rust 2018.
    • Completely new Error enum.
    • New error messages.
    • 10-20% faster parsing.
    • Use Tokenizer::from_fragment instead of Tokenizer::enable_fragment_mode.

    Removed

    • TokenType.
    Open source →
  8. 0.12.0 21 Dec 2019
    Release notes

    Changed

    • ]]> is no longer allowed inside a Text node.
    • Only XML characters are allowed now. Otherwise, StreamError::NonXmlChar will occur.
    • Disallow - at the end of a comment. <!--a---> is an error now.
    • A missing space between attributes is an error now.
    • StreamError::InvalidQuote and StreamError::InvalidSpace signature changed.
    Open source →
  9. 0.11.0 18 Nov 2019
    Release notes

    Added

    Changed

    • StreamError::InvalidString doesn't store an actual string now.
    Open source →
  10. 0.10.0 14 Sep 2019
    Release notes

    Changed

    • 10-15% faster parsing.
    • Merge ByteStream and Stream.
    • StreamError::InvalidChar signature changed.
    • StreamError::InvalidChar was split into InvalidChar and InvalidCharMultiple.

    Fixed

    • Check for NameStartChar during qualified name parsing.

      E.g. <-p> is an invalid tag name from now.

    • Qualified name with multiple : is an error now.

    • ]> is a valid text/CharData now. Previously it was parsed as DoctypeEnd.

    Removed

    • StreamError::InvalidAttributeValue. StreamError::InvalidChar will be emitted instead.
    Open source →
  11. 0.9.0 27 Feb 2019
    Release notes

    Added

    • span field to all Token variants, which contains a whole token span in bytes.
    • Stream::try_consume_byte.

    Changed

    • All Token variants are structs now and not tuples.

    • StrSpan contains an actual string span an not only region now.

      So we can use a non-panic and zero-cost StrSpan::as_str instead of StrSpan::to_str, that was performing slicing each time.

    • Split Stream into ByteStream and Stream.

    • Stream::skip_spaces will parse only ASCII whitespace now.

    • Rename StrSpan::to_str into StrSpan::as_str.

    • Rename Reference::EntityRef into Reference::Entity.

    • Rename Reference::CharRef into Reference::Char.

    • StrSpan::from_substr and StrSpan::slice_region are private now.

    Removed

    • Token::Whitespaces. Will be parsed as Token::Text.
    • Stream::curr_char.
    • Stream::is_curr_byte_eq.
    • Stream::consume_either.
    • Stream::skip_ascii_spaces. Use Stream::skip_spaces instead.
    • StrSpan::trim.
    • StrSpan::len.
    • StrSpan::full_len.
    • StrSpan::as_bytes.

    Fixed

    • Declaration attributes with mixed quotes parsing.
    Open source →
  12. 0.8.1 02 Jan 2019
    Release notes

    Changed

    • Changed the crate category in the Cargo.toml
    Open source →
  13. 0.8.0 13 Dec 2018
    Release notes

    Added

    • Error::pos().

    Changed

    • Rename Stream::gen_error_pos into Stream::gen_text_pos.
    • Rename Stream::gen_error_pos_from into Stream::gen_text_pos_from.
    • Stream::gen_text_pos speed up.

    Fixed

    • TextPos is Unicode aware now.
    • XML declaration parsing when file has a BOM.
    Open source →
  14. 0.7.0 29 Oct 2018
    Release notes

    Changed

    • < inside an attribute value is an error now.
    • Token::Declaration represents standalone as bool now.
    • XML declaration must be defined only once now.
    • XML declaration must start at 0 position.
    • DTD must be defined only once now.
    Open source →
  15. 0.6.1 08 Oct 2018
    Release notes

    Added

    • Stream::curr_byte_unchecked.

    Fixed

    • UTF-8 BOM processing.
    Open source →
  16. 0.6.0 31 Aug 2018
    Release notes

    Changed

    • Reference::EntityRef contains &str and not StrSpan now.
    • Rename Stream::try_consume_char_reference into try_consume_reference. And it will return Reference and not char now.
    • Rename Tokenizer::set_fragment_mode into enable_fragment_mode.
    • Rename ErrorPos into TextPos.

    Fixed

    • TextPos calculation via Stream::gen_error_pos.

    Removed

    • TextUnescape and XmlSpace because useless.
    Open source →
  17. 0.5.0 14 Jun 2018
    Release notes

    Added

    • StreamError::InvalidChar.
    • StreamError::InvalidSpace.
    • StreamError::InvalidString.

    Changed

    • Stream::consume_reference will return only InvalidReference error from now.
    • Error::InvalidTokenWithCause merged into Error::InvalidToken.
    • Stream::gen_error_pos_from does not require mut self from now.
    • StreamError::InvalidChar requires Vec<u8> and not String from now.
    • ErrorPos uses u32 and not usize from now.

    Removed

    • failure dependency.
    • log dependency.
    Open source →
  18. 0.4.1 23 May 2018
    Release notes

    Added

    • An ability to parse an XML fragment.
    Open source →
  19. 0.4.0 21 Apr 2018
    Release notes

    Changed

    • Relicense from MIT to MIT/Apache-2.0.

    Removed

    • FromSpan trait.
    • from_str and from_span methods are removed. Use the From trait instead.
    Open source →
  20. 0.3.0 10 Apr 2018
    Release notes

    Changed

    • Use failure instead of error-chain.
    • Minimum Rust version is 1.18.
    • New error messages.
    • TokenType is properly public now.

    Removed

    • ChainedError
    Open source →
  21. 0.2.0 11 Mar 2018
    Release notes

    Added

    • Qualified name parsing.

    Changed

    • Breaking. Token::ElementStart and Token::Attribute contains prefix and local part of the qualified name now.
    Open source →
  22. 0.1.2 12 Feb 2018
    Release notes

    Added

    • Stream::skip_ascii_spaces.
    • Small performance optimizations.
    Open source →
  23. 0.1.1 17 Jan 2018
    Release notes

    Changed

    • log 0.3 -> 0.4
    Open source →
  24. 0.1.0 15 Dec 2017

    Nothing published for this version

Every package, every release, already written down.

The archive is open and free. Watching your own project is what we are building next.

Browse the archive