Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Trim next element after DocType #603

Merged
merged 2 commits into from Jun 10, 2023
Merged

Trim next element after DocType #603

merged 2 commits into from Jun 10, 2023

Commits on Jun 9, 2023

  1. Add tests for comments and processing instructions in XML prolog

    See <https://www.w3.org/TR/xml11/#NT-prolog>
    
    failures (2):
        xml_prolog::comments
        xml_prolog::pi
    Dan Griffin authored and Mingun committed Jun 9, 2023
    Configuration menu
    Copy the full SHA
    c8332d9 View commit details
    Browse the repository at this point in the history
  2. Trim Text events after DOCTYPE so spaces does not produce an event.

    Otherwise consequent `Text` events (which is possible if their delimited by
    Comment or PI events, which is skipped) will be merged but not trimmed.
    That will lead to returning a `Text` event when try to call `deserialize_struct`
    or `deserialize_map` which will trigger `DeError::ExpectedStart` error.
    
    The incorrect trim behavior was introduced in tafia#581, when DocType event began to be processed
    Dan Griffin authored and Mingun committed Jun 9, 2023
    Configuration menu
    Copy the full SHA
    d49f2d5 View commit details
    Browse the repository at this point in the history