c++ - 没有匹配函数错误

标签 c++ linux

我有这段代码,我试图在 Linux 上用 G++-4.7 编译它:

TermToGeneCount *tg = new TermToGeneCount();
TermToGeneCount *tgn = new TermToGeneCount();
Dag<int64_t>* dags = new Dag<int64_t>();
//....
getTermToGeneCount(nwPar.getAnnotationRetriever(),dags,tg,tgn);

其中 getTermToGeneCount 在与以下相同的命名空间中定义:

void DefaultNwBuilder::getTermToGeneCount(const JavaWrapping::javaAnnotationRetrieverWrapper& annRetriever, Dag<int64_t>* dags, TermToGeneCount* tg, TermToGeneCount* tgn) const{
    //..
    }

当我编译时出现这个错误:

error: no matching function for call to ‘cnw::DefaultNwBuilder::getTermToGeneCount(const JavaWrapping::javaAnnotationRetrieverWrapper&, Dag<long int>*&, TermToGeneCount*&, TermToGeneCount*&)’
note: candidates are:

我认为问题出在第二个参数上,因为如果我删除它(从调用和方法定义中),它就会起作用。

你能帮帮我吗?

最佳答案

可能是 32 位与 64 位平台编译问题。错误中的 long int 不一定映射到 int64_t...

关于c++ - 没有匹配函数错误,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/16356654/

相关文章:

c# - VB6/C++ WINAPI 到 C#

c++ - 一个可执行文件的“连续”C++ 输出作为另一个程序的输入

c++ - 如何在没有 C++ 拷贝的情况下从 ostringstream 获取 char 指针

c++ - 四舍五入一个整数,使其乘以一个 float 返回一个整数

linux - 使用 Ansible 永久设置环境变量

linux - 如何在不将所有软件包升级到 debian wheezy 的情况下强制 debian squeeze 使用 debian wheezy 中的 libqt4-dev?

linux - 单个文件中的多个文件结尾 $

c++ - 检测系统是否可以运行amd64可执行文件

c - 在C中获取父进程的子列表

linux - 在启动时执行交互式脚本并显示到默认的 tty 附加监视器屏幕