Skip to content

Conversation

@tmds
Copy link
Member

@tmds tmds commented Apr 20, 2023

Fixes #84763.

When the string is parsed using DateTimeStyles Allow White, the parser will skip any type of white space in the parsed string. Then when the parser tries to match with a non-regular space from the format string, it fails because it only accepts regular spaces in the format string.

This changes the accepted white space characters for Allow White in the format string to match with the skipped white space characters in the parsed string.

@tarekgh ptal.

…DateTimeStyles Allow White

When the string is parsed using DateTimeStyles Allow White, the parser
will skip any type of white space in the parsed string. Then when the parser
tries to match with a non-regular space from the format string, it fails
because it only accepts regular spaces in the format string.

This changes the accepted white space characters for Allow White in the format
string to match with the skipped white space characters in the parsed string.
@ghost ghost added area-System.Globalization community-contribution Indicates that the PR has been added by a community member labels Apr 20, 2023
@ghost
Copy link

ghost commented Apr 20, 2023

Tagging subscribers to this area: @dotnet/area-system-globalization
See info in area-owners.md if you want to be subscribed.

Issue Details

Fixes #84763.

When the string is parsed using DateTimeStyles Allow White, the parser will skip any type of white space in the parsed string. Then when the parser tries to match with a non-regular space from the format string, it fails because it only accepts regular spaces in the format string.

This changes the accepted white space characters for Allow White in the format string to match with the skipped white space characters in the parsed string.

@tarekgh ptal.

Author: tmds
Assignees: -
Labels:

area-System.Globalization

Milestone: -

@tarekgh
Copy link
Member

tarekgh commented Apr 20, 2023

Thanks @tmds for helping with this one too.

@tarekgh
Copy link
Member

tarekgh commented Apr 20, 2023

@tmds is there any requested signing you need to do? Looks the CI leg license/cla Expected — Waiting for status to be reported is pending on that.

@tarekgh tarekgh added the needs-author-action An issue or pull request that requires more info or actions from the author. label Apr 20, 2023
@tmds
Copy link
Member Author

tmds commented Apr 21, 2023

Thanks @tmds for helping with this one too.

Thanks for your help. It's been interesting contributing to these less familiar parts.

is there any requested signing you need to do? Looks the CI leg license/cla Expected — Waiting for status to be reported is pending on that.

It's just on this PR. I'm going to close and re-open to trigger CI.

@tmds tmds closed this Apr 21, 2023
@tmds tmds reopened this Apr 21, 2023
@tarekgh tarekgh merged commit fd9be9f into dotnet:main Apr 22, 2023
@ghost ghost locked as resolved and limited conversation to collaborators May 23, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

area-System.Globalization community-contribution Indicates that the PR has been added by a community member needs-author-action An issue or pull request that requires more info or actions from the author.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Some DateTimeTest format tests fail on the upcoming Fedora 39

2 participants