I have seen how useful std::format can be. But every time I try to include it on C++20 it does not work. it is apparently already included in its libraries but it does not appear, and there is no information online. Even cppreference has its example but it does not even run on its online compiler. I attached a snippet from it.
Does anyone of you guys know how to make it work without a super complex importing libraries from GitHub. I mainly work on VisualStudio.
#include <iostream>
#include <format>
int main() {
std::cout << std::format("Hello {}!\n", "world");
}
main.cpp:2:10: fatal error: No such file or directory
2 | #include <format>
| ^~~~~~~~
compilation terminated.
format
has not yet been implemented by any C++ standard library. So you'll have to download and install a stand-alone version for the time being. – Fencing-std=c++20
this does not seem to exist yet. – Celik