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

[c-index-test] Fix JSON string quoting #9864

Open
wants to merge 1 commit into
base: next
Choose a base branch
from

Conversation

Wilfred
Copy link

@Wilfred Wilfred commented Jan 21, 2025

Previously, c-index-test assumed that all it could write strings to the JSON output directly. This breaks if any strings contain double-quotes or backslashes, which can occur for C++ string literals.

Ensure that strings are properly quoted for JSON, and add a test for string literals.

@Wilfred Wilfred force-pushed the c-index-test-valid-json branch from a94f892 to ce2d1fe Compare January 31, 2025 01:30
@drodriguez
Copy link

@swift-ci please test llvm

@drodriguez
Copy link

@swift-ci please smoke test

Previously, c-index-test assumed that all it could write strings
to the JSON output directly. This breaks if any strings contain
double-quotes or backslashes, which can occur for C++ string literals.

Ensure that strings are properly quoted for JSON, and add a test
for string literals.
@Wilfred Wilfred force-pushed the c-index-test-valid-json branch from ce2d1fe to a0f7924 Compare February 12, 2025 01:30
@drodriguez
Copy link

@swift-ci please test llvm

@drodriguez
Copy link

@swift-ci please smoke test

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.

3 participants