Skip to content

Conversation

@Colengms
Copy link
Contributor

@Colengms Colengms commented May 1, 2019

The prior approach using a RegEx was identifying a backslash followed by a quote as an escaped quote, even if that backslash was itself escaped. Unclear how to solve that with RegEx. Replaced with manual parsing.

let newResults: string = "";
let lastWasBackslash: Boolean = false;
let lastBackslashWasEscaped: Boolean = false;
for (let i: number = 0; i < readResults.length; i++) {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you factor this out into a separate function, and then add some unit tests for it?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can that go in a future pull request? We want to ship this fix today.

@Colengms Colengms merged commit b67e701 into master May 1, 2019
@Colengms Colengms deleted the coleng/trailingQuoteBug branch May 1, 2019 22:58
@github-actions github-actions bot locked and limited conversation to collaborators Oct 8, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants