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

printf does not support wchar_t #721

Closed
timblechmann opened this issue Apr 26, 2018 · 4 comments
Closed

printf does not support wchar_t #721

timblechmann opened this issue Apr 26, 2018 · 4 comments

Comments

@timblechmann
Copy link
Contributor

printf doesn't seem to work with wchar_t, while sprintf does:

#include <fmt/printf.h>

int main()
{
  fmt::sprintf(L"Elapsed time: %.2f seconds", 1.23); // compiles
  fmt::printf(L"Elapsed time: %.2f seconds", 1.23);  // does not compile
}
@vitaut
Copy link
Contributor

vitaut commented Apr 27, 2018

It should be pretty straightforward to implement wprintf, it's just noone has done it yet. Could you by any chance submit a PR?

@timblechmann
Copy link
Contributor Author

my main use-case disappeared and i'm stuck with chaotic real-life for the next 2-3 weeks, but if you give me the right entry points, i'm happy to create a PR

@vitaut
Copy link
Contributor

vitaut commented Apr 28, 2018

my main use-case disappeared

If you don't have a use case for this feature, then I suggest punting on it for now and revisiting once it's actually needed.

@vitaut
Copy link
Contributor

vitaut commented May 5, 2018

Fixed in #724.

@vitaut vitaut closed this as completed May 5, 2018
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