|
-
Jul 19th, 2003, 02:39 PM
#1
Thread Starter
Frenzied Member
Why do most of you C++ programmers not jump onto C++ .net?
Can C++ .net just as easily (or easier becuase of the environment) make completely unmanaged apps?
-
Jul 19th, 2003, 05:47 PM
#2
Monday Morning Lunatic
Visual C++ .NET can still make unmanaged C++ (i.e. normal) programs quite easily. In fact, unmanaged C++ is easier than managed
I refuse to tie my hands behind my back and hear somebody say "Bend Over, Boy, Because You Have It Coming To You".
-- Linus Torvalds
-
Jul 19th, 2003, 06:19 PM
#3
Thread Starter
Frenzied Member
How could native C++ be easier than managed?
-
Jul 20th, 2003, 04:40 AM
#4
Monday Morning Lunatic
You don't have to mess around with all the garbage collection, things like that.
Then again I'm biased, because I'm used to all the features of C++, and the fact that I need to use them carefully...its a non-issue really.
The only thing .NET could make slightly easier is making GUIs, threads, or network connections. All three are already handled in other C++ libraries, that are far more portable.
I refuse to tie my hands behind my back and hear somebody say "Bend Over, Boy, Because You Have It Coming To You".
-- Linus Torvalds
-
Jul 21st, 2003, 04:10 AM
#5
What do you mean by the jump? I use Visual C++.Net 2003 as my programming environment, but I still program traditional C++ with it. Why? Because
a) Managed C++ is mainly meant as a bridge from old code to .Net. Basically it is there to provide an easy way to make class libraries accessible from .Net languages. The core of the .Net framework is probably implemented in Hybrid C++.
b) I learned C++ for it's purpose: to provide a very performant, flexible, portable and reusable programming language. Managed C++ must adhere to the CLS, so some features are not available, namely templates, the cool operator overloading syntax, multiple inheritance (ok, I can live without that) and some other things. The lack of templates truly is a problem. Also .Net is slower than native C++. For portability: there's no sign of the Mono project ever writing a Managed C++ compiler, so that code is bound to MS.
c) .Net is awkward to use from Managed C++. A Java-equivalent of Managed C++ alone would be tricky, with everything being a pointer. Simply writing every variable as a pointer is tiresome. In true Managed C++ you must in addition distinguish between value types and class types (struct and class in C#), handle boxing etc. It's a mess.
d) When I want to write for .Net I use C#. C# was developed for .Net and is extremly easy to use. Give me one good reason to prefer Managed C++ over C#.
I could probably think of one or two more reasons, but I don't think they're necessary
All the buzzt
 CornedBee
"Writing specifications is like writing a novel. Writing code is like writing poetry."
- Anonymous, published by Raymond Chen
Don't PM me with your problems, I scan most of the forums daily. If you do PM me, I will not answer your question.
-
Jul 21st, 2003, 06:25 AM
#6
Monday Morning Lunatic
IIRC, struct and class are equivalent in C++, apart from the default permissions.
I refuse to tie my hands behind my back and hear somebody say "Bend Over, Boy, Because You Have It Coming To You".
-- Linus Torvalds
-
Jul 21st, 2003, 09:40 AM
#7
But not in C#.
C#:
Code:
struct S
{
public int i;
public float f;
}
class C
{
public int i;
public float f;
}
Managed C++:
Code:
__value struct/class S
{
public:
int i;
float f;
};
__gc struct/class C
{
public:
int i;
float f;
};
All the buzzt
 CornedBee
"Writing specifications is like writing a novel. Writing code is like writing poetry."
- Anonymous, published by Raymond Chen
Don't PM me with your problems, I scan most of the forums daily. If you do PM me, I will not answer your question.
-
Jul 21st, 2003, 09:42 AM
#8
Thread Starter
Frenzied Member
I didn't know it was so different from C#. I'll stick with native C++ and C#. Thanks.
-
Jul 21st, 2003, 09:45 AM
#9
Monday Morning Lunatic
*slaps self*
Yeah CB, you're right. I misread your paragraph.
I refuse to tie my hands behind my back and hear somebody say "Bend Over, Boy, Because You Have It Coming To You".
-- Linus Torvalds
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|