kod wygląda tak
#include <fstream>
#include <spdlog/spdlog.h>
void test()
{
spdlog::warn("test");
}
kompilator clang 18.1.1 z msys2 , spdlog i fmt ostanie wersje dodane przez add_subdirecotry
niedawno zmienila sie wersja kompilatora i wyskoczyło masę podobnych warningów
[main] Building folder: bug_fmt
[build] Starting build
[proc] Executing command: C:\msys64\clang64\bin\cmake.EXE --build d:/bug_fmt/build --config Debug --target all --
[build] [1/2 50% :: 1.216] Building CXX object CMakeFiles/bug_fmt.dir/sysutilsX.cpp.obj
[build] In file included from D:/bug_fmt/sysutilsX.cpp:1:
[build] In file included from C:/msys64/clang64/include/c++/v1/fstream:194:
[build] In file included from C:/msys64/clang64/include/c++/v1/__locale:23:
[build] In file included from C:/msys64/clang64/include/c++/v1/string:625:
[build] In file included from C:/msys64/clang64/include/c++/v1/string_view:213:
[build] C:/msys64/clang64/include/c++/v1/__fwd/string_view.h:22:41: warning: 'char_traits<fmt::detail::char8_type>' is deprecated: char_traits<T> for T not equal to char, wchar_t, char8_t, char16_t or char32_t is non-standard and is provided for a temporary period. It will be removed in LLVM 19, so please migrate off of it. [-Wdeprecated-declarations]
[build] 22 | template <class _CharT, class _Traits = char_traits<_CharT> >
[build] | ^
[build] D:/bug_fmt/spdlog/include/spdlog/fmt/bundled/core.h:377:26: note: in instantiation of default argument for 'basic_string_view<fmt::detail::char8_type>' required here
[build] 377 | template <typename Char> using std_string_view = std::basic_string_view<Char>;
[build] | ^~~~~
[build] D:/bug_fmt/spdlog/include/spdlog/fmt/bundled/core.h:467:50: note: in instantiation of template type alias 'std_string_view' requested here
[build] 467 | S, detail::std_string_view<Char>>::value)>
[build] | ^
[build] D:/bug_fmt/spdlog/include/spdlog/fmt/bundled/format.h:713:57: note: in instantiation of template class 'fmt::basic_string_view<fmt::detail::char8_type>' requested here
[build] 713 | inline auto compute_width(basic_string_view<char8_type> s) -> size_t {
[build] | ^
[build] C:/msys64/clang64/include/c++/v1/__string/char_traits.h:81:8: note: 'char_traits<fmt::detail::char8_type>' has been explicitly marked deprecated here
[build] 81 | struct _LIBCPP_DEPRECATED_(
[build] | ^
[build] C:/msys64/clang64/include/c++/v1/__config:975:53: note: expanded from macro '_LIBCPP_DEPRECATED_'
[build] 975 | # define _LIBCPP_DEPRECATED_(m) __attribute__((__deprecated__(m)))
[build] | ^
[build] 1 warning generated.
[build] [2/2 100% :: 1.407] Linking CXX executable bug_fmt.exe
[driver] Build completed: 00:00:01.474
[build] Build finished with exit code 0
I repozytorium https://github.com/mariuszmaximus/bug_fmt
Ja sie poddałem :(