Managed C++ vs. C++/CLI vs. C#

March 22, 2007

My Advice: use C#, or at least use C++/CLI!

 But, of course we won’t have that luxury all the time. Right now my client insist on using .Net Framework 1.1. Which means: 1. I have to use Visual Studio .Net 2003. 2. I can not use C++/CLI. 3. I can not use Templates. Doh! What a mess… Not that I hated Managed C++, but sometimes language can make programs, that should have been simple, complicated. Well, that’s that… of course in .Net 1.1, we can use C#. And using C# would have made everything easier. Instead, they refuse developing on C# but rather prefer to use C++. Now, because unmanaged and managed codes get jumbled up together, memory leaks might occurs somewhere especially for people whose not accustomed to developing in Managed C++ and Native C++ together. C++/CLI of course couldn’t save on this particular subject.

Okay, now for my real advice: if you’re developing a program that doesn’t touch unmanaged library (or just a bit of unmanaged code that can be easily be solved using P/Invoke on C#) use C#. If you ARE using both managed and unmanaged code to built the program.. go C++/CLI. Now, for the extreme (and the pitiful ones who have to develop on .Net 1.1), there’s no way but to develop on Managed C++.


Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s

%d bloggers like this: