You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[kirill@main-pc test]$ g++ -std=c++20 -fsanitize=undefined ~/test.cpp
In file included from /jwt-cpp/include/jwt-cpp/jwt.h:12,
from /jwt-cpp/include/jwt-cpp/traits/kazuho-picojson/traits.h:12,
from /jwt-cpp/include/jwt-cpp/traits/kazuho-picojson/defaults.h:4,
from /home/kirill/test.cpp:2:
/jwt-cpp/include/jwt-cpp/base.h: In static member function«static const std::initializer_list<std::__cxx11::basic_string<char>>&jwt::alphabet::helper::base64url_percent_encoding::fill()»:
/jwt-cpp/include/jwt-cpp/base.h:86:100: ошибка: «(((const std::__cxx11::basic_string<char>*)(&<temporary>))!= 0)» не есть константное выражение
86 | static std::initializer_list<std::string> fill{"%3D", "%3d"};|
Code of Conduct
I agree to follow this project's Code of Conduct
The text was updated successfully, but these errors were encountered:
This is because std::initializer_list is a proxy object that should not be used as a storage (it has been made for one purpose, being used as a parameter). It could be replaced with a standard array.
What happened?
Hi. It's can't be compiled with this command:
Problem in line 86 file include/jwt-cpp/base.h
How To Reproduce?
Version
0.6.0
What OS are you seeing the problem on?
Linux
What compiler are you seeing the problem on?
GCC
Relevant log output
Code of Conduct
The text was updated successfully, but these errors were encountered: