如何将C ++转换为C# [英] How convert C++ to C#
本文介绍了如何将C ++转换为C#的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我有文件.cpp(代码c ++)。
如何将此文件转换为C#?
I have file .cpp (code c++).
How can I convert this file to C#?
推荐答案
如果片段C ++
代码相对较小,它应该简单,具有两种语言的一点知识,手工制作转换。另一方面,如果您有大量代码(或者,无论如何,复杂代码),您可以考虑将其打包到DLL
中,然后调用DLL
函数来自C#
代码,
If the pieceofC++
code is relatively small the it should be simple, with a bit knowledge of both languages, to hand craft the conversion. On the other hand, if you have a big amount of code (or, anyway, complex code) you may consider packaging it into aDLL
and then call theDLL
functions from yourC#
code,
https:// msdn.microsoft.com/en-us/magazine/cc301520.aspx [ ^ ]
这篇关于如何将C ++转换为C#的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文