Skip to content

Skip } in associative array - #16

Open
jmc-netactuate wants to merge 2 commits into
elliotchance:masterfrom
jmc-netactuate:patch-1
Open

Skip } in associative array#16
jmc-netactuate wants to merge 2 commits into
elliotchance:masterfrom
jmc-netactuate:patch-1

Conversation

@jmc-netactuate

@jmc-netactuate jmc-netactuate commented May 24, 2019

Copy link
Copy Markdown

Add consumeStringUntilNotByte: it does what it says on the tin, consumes the string until it encounters a byte other than the lookingForByte.

Use consumeStringUntilNotByte in consumeAssociativeArray to consume the '}' closing bracket, which is necessary when there is additional content beyond the end of a nested associative array.


This change is Reviewable

Add consumeStringUntilNotByte: it does what it says on the tin, consumes the string until it encounters a byte other than the lookingForByte.

Use consumeStringUntilNotByte in consumeAssociativeArray to consume the '}' closing bracket, which is necessary when there is additional content beyond the end of a nested associative array.
It locates the first byte that isn't lookingForNot.

@elliotchance elliotchance left a comment

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

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

Thank you for doing this. Your change makes perfect sense, but I cannot accept it without a unit test.

Reviewed 2 of 2 files at r1.
Reviewable status: :shipit: complete! all files reviewed, all discussions resolved

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants