-
Notifications
You must be signed in to change notification settings - Fork 1.5k
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 SSO for constexpr string #1735
Conversation
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for going through and working on this! Sorry for the wait on a review here. Things look pretty good to me, just a few questions / nitpicks and request for more extensive test coverage :)
This comment was marked as resolved.
This comment was marked as resolved.
This comment was marked as resolved.
This comment was marked as resolved.
This comment was marked as resolved.
This comment was marked as resolved.
c164242
to
de327ee
Compare
This comment was marked as resolved.
This comment was marked as resolved.
This comment was marked as resolved.
This comment was marked as resolved.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The only real "request changes" here is the missing _STD
, otherwise looks great! Thanks for all of the bug fixes and extensive added test coverage 😻
This comment was marked as resolved.
This comment was marked as resolved.
Thanks, this is so much easier to understand now! 😻 I pushed changes to remove one more workaround (didn't affect correctness). |
... and do so without ending the lifetime of the enclosing `basic_string` by reusing its storage.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm going to push a tiny change to address the pre-existing issue and approve.
Co-authored-by: Michael Schellenberger Costa <mschellenbergercosta@gmail.com>
I'm mirroring this to the MSVC-internal repo - please notify me if any further changes are pushed. |
Thanks for simplifying these codepaths and making |
Co-authored-by: Stephan T. Lavavej <stl@nuwen.net> Co-authored-by: Casey Carter <Casey@Carter.net>
In #1502 we found that it should be possible to enable SSO, but we wanted to get constexpr string in.
It turns out that we were not that far off. I verified that all test compile fine with clang-12. That said, it seems I uncovered 2 distinct MSVC bugs:
_Ptr
to the_Buf
member. So I believe clang is correct here and MSVC should recognize that_Buf
s lifetime did not yet start