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

fmt::to_string/compilation doesn't work with a null string_view #3241

Closed
DenisYaroshevskiy opened this issue Dec 22, 2022 · 3 comments
Closed

Comments

@DenisYaroshevskiy
Copy link

At the moment you can't fmt a default constructed string_view: https://godbolt.org/z/ddzYqYE99

@vitaut
Copy link
Contributor

vitaut commented Dec 22, 2022

Specifically, this is about fmt::to_string.

@DenisYaroshevskiy
Copy link
Author

I don't think so https://godbolt.org/z/Y6e4oPdPx

@vitaut vitaut changed the title Memcping a nullptr is a ub fmt::to_string/compilation doesn't work with a null string_view Dec 22, 2022
phprus added a commit to phprus/fmt that referenced this issue Dec 23, 2022
Signed-off-by: Vladislav Shchapov <[email protected]>
vitaut pushed a commit that referenced this issue Dec 23, 2022
Signed-off-by: Vladislav Shchapov <[email protected]>
@vitaut vitaut closed this as completed Dec 23, 2022
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

No branches or pull requests

2 participants