Skip to content

Support of std::formatΒ #387

@Alex-PLACET

Description

@Alex-PLACET

Hi,
I have an issue with the use of std::format.
On the wasm version __cpp_lib_format is not defined and the call of std::format jut do nothing.
On the native version __cpp_lib_format is not defined too and the call of std::format leads to a crash:
Here a minimal reproducible example:

#include <iostream>
#include <format>
#if defined(__cpp_lib_format)
    std::cout << "__cpp_lib_format is defined" << std::endl;
#else
    std::cout << "__cpp_lib_format is undefined" << std::endl;
#endif

const int value = 23;
const std::string value_formatted = std::format("{}", value);
std::cout << value_formatted << std::endl;

I tried with c++20 and c++23 kernels.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions