Opened 4 years ago

Last modified 4 years ago

#5646 closed defect

format.h is bugged — at Version 5

Reported by: Silier Owned by: adrian
Priority: Must Have Milestone: Alpha 24
Component: Build & Packages Keywords:
Cc: Patch:

Description (last modified by Silier)

fmt::internal::CharTraits<char>::convert': cannot access private member declared

that basically means one cannot use wstring and pass it to LOGWARNING or similar calls, where conversion is needed.

Issue have been fixed, but we have outdated version: https://github.com/fmtlib/fmt/issues/117 File itself is available here: https://github.com/fmtlib/fmt/blob/master/include/fmt/format.h

One cannot simply download and replace the file, because there have been done modifications to our version of file, so they need to be done in new version of file too.

Code to reproduce:

LOGWARNING("Passed wrong value %ls", L"wstring");

Change History (5)

comment:1 by adrian, 4 years ago

Owner: set to adrian
Status: newassigned

comment:2 by adrian, 4 years ago

@Angen could you say how to reproduce this bug?

I put LOGWARNING(L"warning") and LOGWARNING(std::wstring("warning")) in some file and I received completely different compiler errors like followings:

error: no matching function for call to ‘sprintf(const wchar_t [36])’
error: no matching function for call to ‘std::__cxx11::basic_string<wchar_t>::basic_string(const char [11])’

comment:3 by Silier, 4 years ago

Description: modified (diff)

in reply to:  2 comment:4 by Silier, 4 years ago

Replying to adrian:

@Angen could you say how to reproduce this bug?

Sorry it took me so long, I have updated ticket with example.

comment:5 by Silier, 4 years ago

Description: modified (diff)
Note: See TracTickets for help on using tickets.