Menu

#2 overriding virtual destructor error

v1.0_(example)
open
nobody
None
5
2013-04-19
2013-04-19
dkn2114
No

goblin 2.8.b30
gcc version 4.7.3 (Ubuntu/Linaro 4.7.3-1ubuntu1)
uname -s Linux
uname -m x86_64

I was building goblin and found a lot of errors like:

include/sparseGraph.h:94:7: error: looser throw specifier for ‘virtual planarLineGraph::~planarLineGraph()’
In file included from include/abstractSubgraph.h:17:0,
from lib_src/abstractSubgraph.cpp:4:
include/sparseGraph.h:57:5: error: overriding ‘virtual sparseGraph::~sparseGraph() throw ()’

I fixed it by adding a destructor with the signature

~className() throw();

in all derived class, where it was not there, and it made this error message go away.

Discussion


Log in to post a comment.