如何将C ++转换为C# [英] How convert C++ to C#

查看:154
本文介绍了如何将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 pieceof C++ 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 a DLL and then call the DLL functions from your C# code,


https:// msdn.microsoft.com/en-us/magazine/cc301520.aspx [ ^ ]


这篇关于如何将C ++转换为C#的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆