gpt4 book ai didi

c++ - 没有名字的函数

转载 作者:IT老高 更新时间:2023-10-28 23:11:28 31 4
gpt4 key购买 nike

我想知道如何调用这个函数?如果它没有名称,我在哪里可以找到它的实现?

extern void (*_malloc_message)(const char* p1, const char* p2, const char* p3, const char* p4);

最佳答案

这不是一个函数。这是一个声明,说 _malloc_message 是一个指向函数的指针,返回类型 void 和给定的参数。

为了使用它,您必须为它分配具有该参数、返回类型和参数类型的函数的地址

然后你会像使用函数一样使用 _malloc_message

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

31 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com