Undefined symbols for architecture x86_64
mpelleau opened this issue · 0 comments
mpelleau commented
When trying to inherit from htd::Hypergraph
, I get the following error :
Undefined symbols for architecture x86_64:
"typeinfo for htd::Hypergraph", referenced from:
construction vtable for htd::Hypergraph-in-MYHGraph in Main.o
typeinfo for MYHGraph in Main.o
ld: symbol(s) not found for architecture x86_64
There must be an undefined virtual
member function in MYHGraph
, but I cannot figure out which function is missing.
Here is the code of my class:
#ifndef MY_HGRAPH_H
#define MY_HGRAPH_H
#include <htd/main.hpp>
class MYHGraph : public htd::Hypergraph {
public:
unsigned int rank;
public:
MYHGraph() : htd::Hypergraph(htd::createManagementInstance(htd::Id::FIRST)) {}
MYHGraph(unsigned int rank) : htd::Hypergraph(htd::createManagementInstance(htd::Id::FIRST)), rank(rank) {}
~MYHGraph() {}
};
#endif