A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://github.com/fmtlib/fmt/issues/4162 below:

Crash when using fmt with gcc to print chinese character · Issue #4162 · fmtlib/fmt · GitHub

I want to print chinese character with fmt::print. Here is my code.

#define FMT_HEADER_ONLY
#include <fmt/printf.h>
int main() {
    fmt::print(" 我喜欢fmt \n");
    fmt::print("I like fmt\n");
    while (1) {
        // do nothing
    }
    return 0;
}

My toolchain is mingw-w64 + gcc8.5.0, and my source file is saved as utf-8. When built with options -finput-charset=utf-8 -fexec-charset=gb2312, the generated exe prints nothing but just exits.

FMT-11.0.2 and FMT-10.2.1 are both tested, and the results are same.


RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4