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

implement stringify for std::nullopt_t #2740

Merged
merged 1 commit into from Aug 30, 2023

Conversation

mjerabek
Copy link
Contributor

Description

With CHECK(some_optional == std::nullopt), nullopt was stringified differently than std::optional<T>() (that is, {?} as opposed to { }). That's because std::nullopt is not an optional but a special type.

This MR adds stringification for std::nullopt_t.

@codecov
Copy link

codecov bot commented Aug 30, 2023

Codecov Report

Merging #2740 (a62dcc9) into devel (f24d39e) will decrease coverage by 0.01%.
The diff coverage is n/a.

@@            Coverage Diff             @@
##            devel    #2740      +/-   ##
==========================================
- Coverage   91.34%   91.32%   -0.01%     
==========================================
  Files         192      192              
  Lines        7850     7850              
==========================================
- Hits         7170     7169       -1     
- Misses        680      681       +1     

@horenmar horenmar added the Tweak label Aug 30, 2023
@horenmar horenmar merged commit 3a5cde5 into catchorg:devel Aug 30, 2023
74 checks passed
@mjerabek
Copy link
Contributor Author

Btw, is it expected that I didn't have to modify the approval tests? That is, is it expected that ToStringOptional.tests.cpp is not included in them?

@horenmar
Copy link
Member

That's what the approvals tag does.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants