自动生成函数存根

发布于 2024-07-11 19:00:33 字数 89 浏览 4 评论 0原文

是否有任何 Visual Studio 附加组件(或 windows/unix 独立程序)可以在 cpp 文件中为头文件中定义的函数(包括类成员函数)创建存根实现?

Is there any Visual Studio add-on (or windows/unix stand-alone program) that creates stub implementations in the cpp file for the functions (including class member functions) that are defined in the header file?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

丿*梦醉红颜 2024-07-18 19:00:33

我以前也遇到过同样的问题,现在我正在使用 Visual Assist X 的试用版。 可以通过右键单击方法名称 -> 来完成提到的任务 重构-> 创建实现然后重构 -> 将实现移至 CPP 文件。

我不是 Visual Assist X 的附属机构或什么的,但这确实极大地提高了我使用 Visual C++ 的编码速度。

I have the same problem before and now I am using trial version of Visual Assist X. The task mentioned can be done by right clicking on the method name -> Refactor -> Create Implementation and then Refactor -> Move Implementation to CPP file.

I am no Visual Assist X's affiliate or what, but this really increases my coding speed with Visual C++ dramatically.

明明#如月 2024-07-18 19:00:33

重构! for C++ 可与 Dev Studio 2005 和 2008 配合使用。免费版本“有点”可以让您执行此操作; 如果您在头文件中键入存根方法(通过键入诸如 void Foo(int bar){} 而不是 void Foo(int bar); 之类的内容),您可以“将方法移至源文件。”

完整版有更多功能,但我不熟悉它们的用法。

Refactor! for C++ works with Dev Studio 2005 and 2008. The free version "kind-of" let's you do this; if you type your stub method in your header file (by typing something like void Foo(int bar){} instead of void Foo(int bar);) you can then "Move method to source file."

The full version has many more features but I'm not familiar with their usage.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文