bombela / backward-cpp

A beautiful stack trace pretty printer for C++
MIT License
3.73k stars 471 forks source link

Make backward-cpp C++17-complient #235

Closed AndreyMlashkin closed 2 years ago

AndreyMlashkin commented 3 years ago

Currently, there are functions in use, that were removed from std lib, for example:

include\backward.hpp(4018,10): error C2039: 'set_unexpected': is not a member of 'std'

bombela commented 3 years ago

It think this was fixed by https://github.com/bombela/backward-cpp/commit/0b4483f8e2143e35bc157d7bf76bcbdd063a2553

Maybe you are using an older version?

mgerhardy commented 2 years ago

This works for me - but I'm sure the version of msc should get checked, too.

#if defined(_MSC_VER)
    set_terminate(&terminator);
    set_unexpected(&terminator);
#endif