我在程序中调用库“gum”的方法时遇到问题:
gum::BayesNet<double> *myBayNet=new gum::BayesNet<double>;
gum::DiscrereVariable* DV=new gum::DiscretizedVariable<double>;
int main()
{
// error: invalid declaration
// of 'gum::BayesNet<duoble>::add' & //forbids declaration of 'DV'
unsigned int gum::BayesNet<duoble>::add(const (*DV) str)
{
return (*myBayNet).add(str);
}
}
(请参阅评论中的错误消息。)