Skip to content

Print lone surrogates as replacement characters #42094

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

Closed
askeksa-google opened this issue May 28, 2020 · 0 comments
Closed

Print lone surrogates as replacement characters #42094

askeksa-google opened this issue May 28, 2020 · 0 comments
Assignees
Labels
area-vm Use area-vm for VM related issues, including code coverage, and the AOT and JIT backends.

Comments

@askeksa-google
Copy link

The recent breaking change described in #41100 changes UTF-8 encoding such that lone surrogates are encoded as replacement characters. However, this change did not extend to the print implementation in the VM, which contains its own UTF-8 encoder.

This causes the failures seen in https://dart-review.googlesource.com/c/sdk/+/149285 where a test outputs surrogates via print (which are encoded directly) and the Dart implementation running the test system is updated to treat encoded surrogates as invalid.

We should change the UTF-8 encoder used in print (when not overridden by the embedder) to match the behavior of our Dart UTF-8 encoder.

@askeksa-google askeksa-google added the area-vm Use area-vm for VM related issues, including code coverage, and the AOT and JIT backends. label May 28, 2020
@askeksa-google askeksa-google self-assigned this May 28, 2020
dart-bot pushed a commit that referenced this issue May 30, 2020
This test crashes the android test runner, and should be fixed
when issue #42094 is rolled
to the checked-in SDK.

BUG=#42094

Change-Id: I91e5ea5358b08d3776ae485b90aff7cd01d02322
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/149580
Reviewed-by: William Hesse <[email protected]>
Reviewed-by: Martin Kustermann <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area-vm Use area-vm for VM related issues, including code coverage, and the AOT and JIT backends.
Projects
None yet
Development

No branches or pull requests

1 participant