Skip to content

Codecvt c++17 - #326

Merged
asmaloney merged 1 commit into
asmaloney:masterfrom
meynardc:codecvt_c++17
Oct 24, 2025
Merged

Codecvt c++17#326
asmaloney merged 1 commit into
asmaloney:masterfrom
meynardc:codecvt_c++17

Conversation

@meynardc

Copy link
Copy Markdown
Contributor

Hi,

We use libE57Format in a stdc++17 project (https://github.com/micmacIGN/micmac/tree/master/MMVII)

Sadly, the codecvt_utf8_utf16(...) function is deprecated since C++17 and removed in C++26.
I propose a replacement using the windows native function MultiByteToWideChar() (only if compiling on Windows and only if C++ version is >= 17).

To test it, in CMakeLists.txt set :
target_compile_features( ${PROJECT_NAME} PRIVATE cxx_std_14 )
to cxx_std_17 or cxx_std_20.

(This PR follows my previous PR #325, making Windows CI working again)

@asmaloney

Copy link
Copy Markdown
Owner

Could you please rebase this onto master?

@meynardc

Copy link
Copy Markdown
Contributor Author

Rebased ...

@asmaloney
asmaloney merged commit 5fb9561 into asmaloney:master Oct 24, 2025
12 checks passed
@asmaloney

Copy link
Copy Markdown
Owner

Thanks!

@meynardc
meynardc deleted the codecvt_c++17 branch October 24, 2025 14:30
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.

2 participants