userver icon indicating copy to clipboard operation
userver copied to clipboard

service_template fmt::join build error on MacOS

Open tkhanipov opened this issue 1 year ago • 1 comments

I followed the tutorial but got compilation error, see https://stackoverflow.com/questions/78935510/no-member-named-join-in-namespace-fmt#comment139204286_78935510

tkhanipov avatar Sep 05 '24 08:09 tkhanipov

I have the same issue after updating toolchain to 15 version:

./cmake-build-release/_deps/userver-src/universal/include/userver/utils/traceful_exception.hpp:52:25: error: no member named 'back_inserter' in namespace 'std'
   52 |     fmt::format_to(std::back_inserter(ex.GetMessageBuffer()), "{}", data);

I tried to fix it manually, then:

cmake-build-release/_deps/userver-src/universal/include/userver/utils/checked_pointer.hpp:52:5: error: no member named 'abort' in namespace 'std'; did you mean simply 'abort'?
   52 |     std::abort();

And etc.

shad0w-jo4n avatar Oct 07 '24 22:10 shad0w-jo4n

Adding missing #include <fmt/ranges.h> in ~10 files helped in my case.

Basiliuss avatar Oct 19 '24 21:10 Basiliuss

Should be fixed by now.

segoon avatar Dec 12 '24 12:12 segoon