-
-
Notifications
You must be signed in to change notification settings - Fork 6.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Suppress warnings #1861
Comments
That warning is telling you that there was a subtle ABI change (actually a conformance fix) between 6 and 7.1, such that libraries built with 6.x or earlier may not work properly when called from code built with 7.x (and vice-versa). As long as all your C++ code is built with GCC 7.1 or later, you can safely ignore this warning. To disable it, pass -Wno-psabi to the compiler. For more details on the context of the change, see the GCC 7 changelog, and the associated bug. |
Anything to do for this library? |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
json.hpp version 3.9.1 I don't want to use -Wno-psabi, It's not elegant enough. |
Your compiler tells you that an implementation detail of |
Thank you for your reply,But json.hpp should be compatible with gcc 8.3.0.
|
The total warnning message as follows:
|
Regarding the warning, we already had an issue #1861 on this in December 2019. There, it was noted that there was a subtle ABI change (actually a conformance fix) between GCC 6 and 7.1, such that libraries built with GCC 6.x or earlier may not work properly when called from code built with GCC 7.x (and vice-versa). The GCC 7 Release notes https://gcc.gnu.org/gcc-7/changes.html state:
As long as all your C++ code is built with GCC 7.1 or later, you can safely ignore this warning. To disable it, pass There is nothing wrong with the library. |
Thanks a lot. |
Hello guys,
In file included from /usr/include/c++/6/vector:69:0,
from /tmp/tmp.t84kxtTjFo/jsonLib/single_include/nlohmann/json.hpp:49,
from /tmp/tmp.t84kxtTjFo/main.cpp:3:
/usr/include/c++/6/bits/vector.tcc: In member function ‘void std::vector<_Tp, _Alloc>::reserve(std::vector<_Tp, _Alloc>::size_type) [with _Tp = nlohmann::basic_json<>; _Alloc = std::allocator<nlohmann::basic_json<> >]’:
/usr/include/c++/6/bits/vector.tcc:75:70: note: parameter passing for argument of type ‘std::move_iterator<nlohmann::basic_json<>*>’ will change in GCC 7.1
_GLIBCXX_MAKE_MOVE_IF_NOEXCEPT_ITERATOR(this->_M_impl._M_finish));
I have a lot of "will change in GCC 7.1" warnings and it make hard to see real problems.
set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -w")
set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -w")
I set this parameters in CMakeLists but id doesn't work :(
Best regards,
Konstantin.
The text was updated successfully, but these errors were encountered: