这里有几个函数声明,我无法理解如何完成.我已经扫描了网络以查看无效指针是什么,我理解它必须被转换为有用的东西(因为它只指向一些内存块),但我不知道这对于完成这些有什么帮助声明.
/* type of comparison function that specifies a unique order.
Returns 1 if pointer1 should come before,
0 if equal to, or -1 if after pointer2. */
typedef int (*compare_function) (const void* pointer1, const void* pointer2);
/* get the data object */
void* get_obj(const void* item_pointer);
Run Code Online (Sandbox Code Playgroud)
有更多这样的功能,但我想如果我理解如何做这两个我应该保持良好状态.例如,对于第二个函数,我们如何将item_pointer转换为应该返回的任何适当的东西?