spdlog
spdlog copied to clipboard
fmt error
logger.error("[{},{},{}] info.xml 有{}个,信息错误: {}", FILENAME, FUNCTION, LINE, pathinfo.at(pathinfo.size() - 3) + "\" + pathinfo.at(pathinfo.size() - 2) + "\" + pathinfo.at(pathinfo.size() - 1)); 编译报错: 1>D:\zhjrProjects\zhjrWork\utils\utils.cpp(565,18): error C3615: constexpr 函数“fmt::v9::basic_format_parse_context<char,fmt::v9::detail::error_handler>::on_error”不能生成常量表达式 1>C:\Program Files\Microsoft Visual Studio\2022\Enterprise\VC\Tools\MSVC\14.35.32215\include\spdlog\fmt\bundled\core.h(718,27): message : 对未定义的函数或为未声明为“constexpr”的函数的调用导致了故障 1>C:\Program Files\Microsoft Visual Studio\2022\Enterprise\VC\Tools\MSVC\14.35.32215\include\spdlog\fmt\bundled\core.h(718,27): message : 请参见“fmt::v9::detail::error_handler::on_error”的用法
Formatting is disorganized and difficult to read. Please format it.
EDIT: There are four {} but the number of additional arguments appears to be 3.