Skip to content

Conversation

@cwhelms
Copy link

@cwhelms cwhelms commented Dec 22, 2023

The converstion from a wstring to std::string gave a warning:
C4244: 'argument': conversion from 'const wchar_t' to 'const _Elem', possible loss of data.

Conversion used to be recommended with codecvt, but that has been deprecated, so a transform here is simplest I think.

For reference on the options:
https://stackoverflow.com/questions/4804298/how-to-convert-wstring-into-string/12097772#12097772

The converstion from a wstring to std::string gave a
warning C4244: 'argument': conversion from 'const wchar_t' to 'const _Elem', possible loss of data.
@cwhelms cwhelms changed the title Fixing comiler warning in win.cc Fixing compiler warning in win.cc Mar 22, 2024
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

Successfully merging this pull request may close these issues.

1 participant