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

Add new stripquoted keyword arg and fix stripwhitespace #112

Merged
merged 3 commits into from
Apr 21, 2022
Merged

Commits on Apr 21, 2022

  1. Add new stripquoted keyword arg and fix stripwhitespace

    Fixes #109. As noted in that issue, stripping whitespace *within* quoted
    strings, IMO, should be considered a bug, since one of the primary
    reasons for quoting strings in various applications is to delineate the
    exact characters that make up the string. This PR fixes
    `stripwhitespace` to preserve whitepace encountered within strings, and
    only strip whitespace for non-quoted strings (leading or trailing) and
    leading/trailing around quoted fields.
    
    On the other hand, there are legitimate use-cases for also stripping
    whitespace within quoted strings, so we add a new opt-in `stripquoted`
    keyword argument that allows the additional precision of also stripping
    whitespace inside quotes. Note that passing `stripquoted=true` implies
    `stripwhitespace=true`, so it can be considered a "stronger" version of
    `stripewhitespace`.
    quinnj committed Apr 21, 2022
    Configuration menu
    Copy the full SHA
    1ed5650 View commit details
    Browse the repository at this point in the history
  2. Update src/Parsers.jl

    Co-authored-by: Nick Robinson <npr251@gmail.com>
    quinnj and nickrobinson251 committed Apr 21, 2022
    Configuration menu
    Copy the full SHA
    0a7be28 View commit details
    Browse the repository at this point in the history
  3. Update test/runtests.jl

    Co-authored-by: Nick Robinson <npr251@gmail.com>
    quinnj and nickrobinson251 committed Apr 21, 2022
    Configuration menu
    Copy the full SHA
    e5b4be1 View commit details
    Browse the repository at this point in the history