Skip to content

JSONSerialization: Add support for .withoutEscapingSlashes, .fragmentsAllowed #2713

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

Merged
merged 2 commits into from
Apr 9, 2020

Conversation

spevans
Copy link
Contributor

@spevans spevans commented Mar 3, 2020

Also fixes SR-12275: JSONEncoder on Linux can't encode number JSON fragments

  • JSONEncoder now encodes fragments by default to match Darwin.

  • JSONDecoder now allows fragments when decoding to match Darwin.

  • Update the following TestJSONEncoder tests now that fragments encode,
    these tests now pass on Darwin:

    test_encodingTopLevelSingleValueEnum
    test_encodingTopLevelSingleValueEnum
    test_encodingTopLevelSingleValueClass

@spevans
Copy link
Contributor Author

spevans commented Mar 3, 2020

@swift-ci test

@spevans
Copy link
Contributor Author

spevans commented Mar 3, 2020

cc @millenomi @parkera

@spevans spevans force-pushed the pr_json_writing_options branch from 419c8d4 to cd3b9b2 Compare March 4, 2020 18:44
@spevans
Copy link
Contributor Author

spevans commented Mar 4, 2020

@swift-ci test linux

1 similar comment
@spevans
Copy link
Contributor Author

spevans commented Mar 4, 2020

@swift-ci test linux

@spevans spevans force-pushed the pr_json_writing_options branch from cd3b9b2 to c926720 Compare March 4, 2020 23:06
@spevans
Copy link
Contributor Author

spevans commented Mar 4, 2020

@swift-ci test linux

@jakepetroules jakepetroules requested a review from bendjones March 5, 2020 05:54
@spevans
Copy link
Contributor Author

spevans commented Mar 5, 2020

@swift-ci test linux

Copy link
Contributor

@bendjones bendjones left a comment

Choose a reason for hiding this comment

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

A small nit but overall this LGTM @millenomi

@bendjones bendjones requested a review from millenomi April 6, 2020 20:14
spevans added 2 commits April 6, 2020 21:38
- JSONEncoder now encodes fragments by default to match Darwin.

- JSONDecoder now allows fragments when decoding to match Darwin.

- Update the following TestJSONEncoder tests now that fragments encode,
  these tests now pass on Darwin:

  test_encodingTopLevelSingleValueEnum
  test_encodingTopLevelSingleValueStruct
  test_encodingTopLevelSingleValueClass
@spevans spevans force-pushed the pr_json_writing_options branch from c926720 to 09fca84 Compare April 6, 2020 20:57
@spevans
Copy link
Contributor Author

spevans commented Apr 6, 2020

@swift-ci test linux

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