kpeeters / tree.hh

An STL-like C++ header-only tree library
GNU General Public License v3.0
132 stars 32 forks source link

"C++17 deprecation" warnings when compiling under VS2019 #3

Closed hals1010 closed 3 years ago

hals1010 commented 3 years ago

I cannot compile tree.hh under VS2019 and ISO C++17 Standard (/std:c++17):

Severity Code Description Project File Line Suppression State Error C4996 'std::allocator<treenode>::destroy': warning STL4010: Various members of std::allocator are deprecated in C++17. Use std::allocator_traits instead of accessing these members directly. You can define _SILENCE_CXX17_OLD_ALLOCATOR_MEMBERS_DEPRECATION_WARNING or _SILENCE_ALL_CXX17_DEPRECATION_WARNINGS to acknowledge that you have received this warning. 3DView C:\HamburgSVN\CurryWin\C100\include\tree.hh 566

(8 errors in total)

Regards, Jörn

kpeeters commented 3 years ago

I have pushed what is hopefully a fix to the master branch; can you please try again (I do not use VS myself and clang++-10 does not (yet) produce that warning).

hals1010 commented 3 years ago

Hi Kasper,

yes, this did the trick - thanks for your quick fix!

Best, Jörn