-
Notifications
You must be signed in to change notification settings - Fork 731
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
PugiXML incorrectly handles char8_t in C++20 #378
Comments
I also thought that it may be a good idea to just use I think if consumer could define |
This is sensible; this can probably be achieved using a private overload with |
Oh, I didn't look that deep, but it feels like case for I guess I should continue sticking to |
In C++20 there is a
std::u8string
andchar8_t
to make UTF-8 type-safe.Unfortunately when calling
xml_attribute::set_value(u8"a string")
for example compiler choosesset_value(bool)
overload which lead to a surprise when all attrubutes became juse"true"
.Which makes me thing that providing an overload which accepts
bool
is too wide: it can be any pointer at least. Would be nice to constrain it somehow.I'm not sure if there is a need to have a separate handling when
pugi::char_t
iswchar_t
or simply provide such overload when it's achar
.The text was updated successfully, but these errors were encountered: