C# vs. C++

H

Hendrik Schober

Arne said:
Hendrik Schober wrote:
[...]
What if you have to fiddle with templates in a
several MLoC project?

No difference.

If you constantly need to rebuild MLOC's the project structure
is fubar.

I'll stop taking you serious right here. You seem to not to
know what you're talking about.
[...]
Arne

Schobi
 
G

Giovanni Dicanio

C# was developed because Sun wouldn't allow MS to tightly couple its Java
implementation to Windows, encouraging people to build Windows-only Java
apps. (The "embrace and extend" system of locking in your customers.)

I don't agree.

C# is more complete and more advanced than Java.
In C# Microsoft put lots of improvements over Java.
I think that in C# Microsoft put lessons learned from several languages:
C++, Java, and classic Visual Basic, too.

For example: Java has no concept of properties (you must use get/set like in
C++).
Java has no concept of delegate.
In Java all methods are virtual by default (instead, in C# you must specify
that).
And C# has a very good RAD environment with WinForm, I don't think that Java
has anything similar.

And C# has also LINQ, instead I think that in Java there is no language
support for SQL-like syntax.

And C# has the 'using' and 'IDisposable' for non-memory resources (like file
handles, etc.).
Instead I think that Java has nothing similar.

And it is very easy to use C++ code from C#, thanks to C++/CLI. Again, I
think that calling C++ code from Java is not so easy...

Giovanni
 
A

Alvin Bruney [ASP.NET MVP]

C# was invented because Microsoft had a good idea for a new API for
Windows (namely .NET Framework) and Anders Hejlsberg had some good ideas
for a new programming language, similar but not identical to Java.

No, Clinton is right. Java was falling short of what they wanted to do. See
http://blogs.msdn.com/patrick_dussu...-it-all-started-aka-the-birth-of-the-clr.aspx

--

Regards,
Alvin Bruney [MVP ASP.NET]

[Shameless Author plug]
Download OWC Black Book, 2nd Edition
Exclusively on www.lulu.com/owc $15.00
Need a free copy of VSTS 2008 w/ MSDN Premium?
http://msmvps.com/blogs/alvin/Default.aspx
 
B

Ben Voigt [C++ MVP]

Giovanni said:
I don't agree.

C# is more complete and more advanced than Java.
In C# Microsoft put lots of improvements over Java.
I think that in C# Microsoft put lessons learned from several
languages: C++, Java, and classic Visual Basic, too.

For example: Java has no concept of properties (you must use get/set
like in C++).
Java has no concept of delegate.
In Java all methods are virtual by default (instead, in C# you must
specify that).
And C# has a very good RAD environment with WinForm, I don't think
that Java has anything similar.

C# doesn't have. Visual Studio has, in the Forms Designer, a RAD
environment which is rather prone to crashing (i.e. less than "very good").
Quite a number of Java IDEs have RAD GUI designers as well, I'm sure. I
don't use Java for application development, but I'd start by looking at some
of the many Eclipse plugins if I needed a dialog / window design tool.
 
G

Giovanni Dicanio

C# doesn't have. Visual Studio has, in the Forms Designer, a RAD
environment

You're correct, thanks.

which is rather prone to crashing (i.e. less than "very good").

I did not do anything big in WinForm, but I had no problem with VS2008
WinForm Designer and C#.
(Maybe it does not scale up well?)

Giovanni
 
A

Andre Kaufmann

Ben said:
Giovanni said:
"Kenneth Porter" <[email protected]> ha scritto nel
messaggio news:[email protected]...
[...]
C# doesn't have. Visual Studio has, in the Forms Designer, a RAD

I think the WinForms designer is part of the .NET framework and can be
hosted in other applications too.
environment which is rather prone to crashing (i.e. less than "very good").

The C++ one is quite bad but I don't have that impression regarding the
C# (managed languages) one.


Andre
 
B

Ben Voigt [C++ MVP]

Andre said:
Ben said:
Giovanni said:
"Kenneth Porter" <[email protected]> ha scritto nel
messaggio news:[email protected]...
[...]
C# doesn't have. Visual Studio has, in the Forms Designer, a RAD

I think the WinForms designer is part of the .NET framework and can be
hosted in other applications too.

The .NET framework includes support for including design-time support for
user controls, but not the design environment itself. I think the design
environment can be hosted, but you'd be using the Visual Studio
extensibility SDK and licensing Visual Studio runtime components, not just
the .NET framework.
The C++ one is quite bad but I don't have that impression regarding
the C# (managed languages) one.

I've had the C# designer (VS2005) crash numerous times. The fact that the
crash dialog for Visual Studio isn't actually modal (a serendipitous bug I
suspect) is the only thing that's saved by solution from total uselessness
on multiple occasions (i.e. I was able to close the faulting designer window
and save the solution before letting the crash window exit Visual Studio,
otherwise merely opening the solution produced a crash)
 
A

Andre Kaufmann

Ben said:
Andre Kaufmann wrote:
[...]
The .NET framework includes support for including design-time support for
user controls, but not the design environment itself. I think the design
environment can be hosted, but you'd be using the Visual Studio

I'm not 100% sure about how much of the functionality of the WinForms
Designer is part of the .NET framework. I only know that it has been
hosted by some commercial applications too. However, I've hosted the
Windows Workflow Designer in my own application, but it wasn't simply
adding some controls to my main form. So I suspect the same might be
true for the WinForms Designer too.
extensibility SDK and licensing Visual Studio runtime components, not just
the .NET framework.

Since the core of the Visual Studio IDE (now) can be hosted / used for
free I don't think the runtime components have to be licenced.
However the Visual Studio Shell has to be shipped, additionally to the
..NET framework. I'm not familiar with the Visual Studio Shell and I
don't know if the WinForms designer is part of it. But I suspect it to
be so.

Andre
 
B

Ben Voigt [C++ MVP]

extensibility SDK and licensing Visual Studio runtime components,
Since the core of the Visual Studio IDE (now) can be hosted / used for
free I don't think the runtime components have to be licenced.

"for free" is assuredly not the same as "not licensed".
However the Visual Studio Shell has to be shipped, additionally to the
.NET framework. I'm not familiar with the Visual Studio Shell and I
don't know if the WinForms designer is part of it. But I suspect it to
be so.

Andre
 
H

Howard Swope

Actually one can host the .Net designer in an application. It is rather
complicated and not well documented, at least as of VS2003. I hosted the
..Net 1.1 design time in an application, but I learned it through an online
example. It involved implementing many interfaces and seemed a bit half
baked, at least as a library that was meant for use in other applications.
My guess is that it was designed for VisualStudio, but then exposed to the
public as an afterthought. I haven't tried it in later versions. For what I
needed to do at the time it was great, I just wish it was a bit more
designed as a general purpose component.

Ben Voigt said:
Andre said:
Ben said:
Giovanni Dicanio wrote:
"Kenneth Porter" <[email protected]> ha scritto nel
messaggio [...]
C# doesn't have. Visual Studio has, in the Forms Designer, a RAD

I think the WinForms designer is part of the .NET framework and can be
hosted in other applications too.

The .NET framework includes support for including design-time support for
user controls, but not the design environment itself. I think the design
environment can be hosted, but you'd be using the Visual Studio
extensibility SDK and licensing Visual Studio runtime components, not just
the .NET framework.
The C++ one is quite bad but I don't have that impression regarding
the C# (managed languages) one.

I've had the C# designer (VS2005) crash numerous times. The fact that the
crash dialog for Visual Studio isn't actually modal (a serendipitous bug I
suspect) is the only thing that's saved by solution from total uselessness
on multiple occasions (i.e. I was able to close the faulting designer
window and save the solution before letting the crash window exit Visual
Studio, otherwise merely opening the solution produced a crash)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top