如何在emacs中查找不属于类的C函数?
到目前为止,我能够调用属于结构类的成员函数。 CEDET可以很好地给出建议。然而,对于非成员函数,例如 C 中的函数,通常不属于任何函数,即像 sort、qsort 这样的函数......如果我有一个类/结构的实例,我只能使用 CEDET 自动完成。没有它,我必须手动输入该函数。
有没有办法为此类功能提供代码建议?
So far, I was able to call member functions which belong to a class for a struct. CEDET can give the suggestion nicely. However, for non-member functions, such as functions in C, which usually does not belong to anything i.e. functions like sort, qsort.... I can only auto-complete with CEDET if I have an instance of a class/struct. Without it, I have to type the function manually.
Is there a way to have code suggestion for such functions?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
CEDET 对于此类函数工作得很好 - 您需要确保所有必需的标头都包含在源代码中。您还可以使用 Mx bovinate 命令强制 CEDET 重新解析缓冲区。但最好使用 bzr 存储库中的 CEDET,因为针对 C 和 C 的修复C++ 模式经常被使用。
如果仍然不起作用,请查看
Mx Semantic-analyze-debug-assist
命令的输出,并将结果发布到 cedet-devel 列表CEDET works fine for such functions - you need to be sure, that all necessary headers are included into your source code. You can also force CEDET to re-parse buffer with
M-x bovinate
command. But it's better to use CEDET from bzr repository, because fixes for C & C++ mode are made very often.If it still don't working look to output of
M-x semantic-analyze-debug-assist
command, and post results to cedet-devel list