Skip to content

Fails to compile with GCC 6.x - make destructors noexcept #1317

@breznak

Description

@breznak

Testing the latest & greatest gcc compiler, I run into some issues.

  • about the use of NTA_CHECK(..) << "msg" macro:
[ 40%] Building CXX object src/CMakeFiles/nupic_core_solo.dir/nupic/engine/Region.cpp.o
/home/mmm/devel/HTM/nupic.core/src/nupic/engine/Output.cpp: In destructor ‘nupic::Output::~Output()’:
/home/mmm/devel/HTM/nupic.core/src/nupic/engine/Output.cpp:51:36: error: throw will always call terminate() [-Werror=terminate]
   NTA_CHECK(links_.size() == 0) << "Internal error in region deletion";
                                    ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/home/mmm/devel/HTM/nupic.core/src/nupic/engine/Output.cpp:51:36: note: in C++11 destructors default to noexcept

Looks like we'll have to rewrite these macros

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions