Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 9 years ago.
您可能想尝试一下这个工具,看看它是否适合您。有一个演示,您可以一次翻译最多 100 行代码:
http://tangiblesoftwaresolutions.com /Product_Details/CPlusPlus_to_CSharp_Converter_Details.html
尝试一下并告诉我们。但自己将其移植到 C# 中可能会更有利,这样您就可以掌握 C# 附带的功能。
You might want to try this tool and see if that works out for you. There is a demo where you translate up to a 100 lines of code at a time:
http://tangiblesoftwaresolutions.com/Product_Details/CPlusPlus_to_CSharp_Converter_Details.html
Try it out and let us know. But it would prolly be more beneficial to port this yourself in c# so you can get a handle of the features that c# comes with.
你需要手动完成,1KLOC 并不多。但是,您将需要学习C#。
回答您的问题:
List
You will need to do it manually, and 1KLOC isn't much.However, you will need to learn C#.
To answer your questions:
List<T>
1 - C# 还支持运算符重载,请参阅:http://msdn .microsoft.com/en-us/library/aa288467(VS.71).aspx(它看起来非常适合 C++ 运算符覆盖)
2 - C# 是垃圾收集的,因此您只需要“new”而不是 alloc。 free 是由垃圾收集器完成的
3 - 我不知道,但是当移植代码时,你必须在标准 C# 库中找到等效项
4 - 在 MSDN 中有很多信息。
5 - ( http://code2code.net/ ) ???但最好立即进行有关
编码标准的更多信息:http://msdn。 microsoft.com/en-us/library/xzf533w0.aspx即命名: http://msdn.microsoft.com/en-us/library/ x2dbyw72.aspx
1 - C# also support operator overloading see : http://msdn.microsoft.com/en-us/library/aa288467(VS.71).aspx (it looks very much to c++ operator overriding)
2 - C# is garbage collected so you only need "new" instead of alloc. free is done by the garbage collector
3 - I have no idea , but when porting code you would have to find in standard c# library the equivalents
4 - In MSDN there is a lot of information.
5 - ( http://code2code.net/ ) ??? but better to do it at hand
More information on coding standards : http://msdn.microsoft.com/en-us/library/xzf533w0.aspxie naming: http://msdn.microsoft.com/en-us/library/x2dbyw72.aspx
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
暂无简介
文章 0 评论 0
接受
发布评论
评论(3)
您可能想尝试一下这个工具,看看它是否适合您。有一个演示,您可以一次翻译最多 100 行代码:
http://tangiblesoftwaresolutions.com /Product_Details/CPlusPlus_to_CSharp_Converter_Details.html
尝试一下并告诉我们。但自己将其移植到 C# 中可能会更有利,这样您就可以掌握 C# 附带的功能。
You might want to try this tool and see if that works out for you. There is a demo where you translate up to a 100 lines of code at a time:
http://tangiblesoftwaresolutions.com/Product_Details/CPlusPlus_to_CSharp_Converter_Details.html
Try it out and let us know. But it would prolly be more beneficial to port this yourself in c# so you can get a handle of the features that c# comes with.
你需要手动完成,1KLOC 并不多。
但是,您将需要学习C#。
回答您的问题:
List
You will need to do it manually, and 1KLOC isn't much.
However, you will need to learn C#.
To answer your questions:
List<T>
1 - C# 还支持运算符重载,请参阅:http://msdn .microsoft.com/en-us/library/aa288467(VS.71).aspx(它看起来非常适合 C++ 运算符覆盖)
2 - C# 是垃圾收集的,因此您只需要“new”而不是 alloc。 free 是由垃圾收集器完成的
3 - 我不知道,但是当移植代码时,你必须在标准 C# 库中找到等效项
4 - 在 MSDN 中有很多信息。
5 - ( http://code2code.net/ ) ???但最好立即进行有关
编码标准的更多信息:http://msdn。 microsoft.com/en-us/library/xzf533w0.aspx
即命名: http://msdn.microsoft.com/en-us/library/ x2dbyw72.aspx
1 - C# also support operator overloading see : http://msdn.microsoft.com/en-us/library/aa288467(VS.71).aspx (it looks very much to c++ operator overriding)
2 - C# is garbage collected so you only need "new" instead of alloc. free is done by the garbage collector
3 - I have no idea , but when porting code you would have to find in standard c# library the equivalents
4 - In MSDN there is a lot of information.
5 - ( http://code2code.net/ ) ??? but better to do it at hand
More information on coding standards : http://msdn.microsoft.com/en-us/library/xzf533w0.aspx
ie naming: http://msdn.microsoft.com/en-us/library/x2dbyw72.aspx