The "Natural Fit"
It has been a busy few days in the world of the rant (see Mr. Grimes' Farewell) and reply (see Grumpy Grimes and Scott Swigart Responds to Richard Grimes). Now this is a topic that I have a bit of passion for.
I am not going to restate the very good arguments by Scott and Duncan, I would simply encourage you to spend a few minutes reading them if you have not already. I would like to address a different point from Mr. Grimes, and one I have heard before:
"C# is the natural language to use for .NET and there was no need for VB.NET"
First, every time I hear someone say this they just move on without explaining themselves or providing any support. What exactly does "the natural language" mean?
Yes, there are a few things that are possible with the CLR that you can't do with VB but you can with C#.
One that I hear often is /// comments. To me this does not justify the time it would take for a Visual Basic developer to forget the entire language that they know and learn C#. In fact it is possible with a free add in and will be native in Visual Studio 2005. What few things VB can not do that C# can are often times not an issue for the vast majority of Visual Basic developers.
These few things are pretty much brushed off the table in Visual Studio 2005. As Paul Vick says in his blog today, "But the point is that with the release of Whidbey, VB will finally be fully caught up in terms of supporting .NET...".
Maybe by "the natural language" they mean that lots of people at Microsoft develop in C#. I have heard this said before to explain why you should just jump to C#. This statement is very true. Why, because most Microsoft developers have a C++ background and C# is a natural upgrade path for them just as VB.NET is a natural upgrade path for a Visual Basic developer. As a point of fact also there are Visual Basic developers working at Microsoft, myself being one of them.
If you figure C# is the natural language because that what a lot of Microsoft developers use lets just run that out into other ideas:
Most Microsoft developers make commercial software not internal enterprise applications. Does that mean you should quit your job working for a company as a developer?
Large amounts of Microsoft developers write operating systems, does that mean that operating systems are the natural product for developers?
Granted, these is a bit extreme but my point is that what Microsoft developers develop in is a choice that makes the most business sense for the products and conditions they are working under. The choice between VB and C# is about just that, what makes the most sense in YOUR environment based on YOUR developers and THEIR experience not what makes sense at Microsoft.
Let's apply this "Natural Language" idea to other topic. Burger King sells lots of Whoppers. The Whopper comes with beef by default. Now I like a good hamburger ever now and then but some times I just want a chicken sandwich. If I order a chicken Whopper does that mean it is not the natural fit for a Whooper and I shouldn't do it?
No, a Whopper is to pieces of bread, some lettuce and a bit of sauce with some meat in the middle (IMHO a pretty good taste too). What that meat is in the middle is up to you, it can be beef, chicken or nothing if you don't eat meat.
Eat the Whooper of your choice and use the language that makes sense to you. Stop worry about what someone else thinks is more natural between the two slices of bread.
Comments
- Anonymous
February 25, 2005
Good post. Since I started with .Net a couple of years ago I've only found one case where I had problems translating between the two languages and that was integer overflow in C# which in my opinion is a poor programming practice anyway. I've been with the BASIC language since I learned it on the Apple ][E and my Commodore64 and now love VB.Net. I think the two languages are pretty much the same, really, anyway. Drop the Dim, move the type to the front and add a semi-colon. Get rid of End X and use braces instead. Most everything's the same. The MSIL's almost exactly the same, too except for the extra variable declaration we get to support legacy people not using Return. - Anonymous
February 25, 2005
I think you maybe applying your own idea to what he meant by "natural language". I don't think he was saying it was the natural language for .net because a lot of people in Microsoft use it. However, I probably shouldn't be speaking for him.
I do agree with him though that maybe VB.Net shouldn't have been built. My guess is that the learning curve for a VB developer to move to VB.NET vs. C# is minimal (just syntactical). The largest hurdle by far is the .NET API and conceptual (e.g. inheritance and polymorphysm.)
Unlike other languages like Prolog, Perl, Python, VB.Net doesn't offer really anything from the language perspective that would be missing from C# I think.
If Microsoft just built C# and not VB.NET, we wouldn't have these strange API documentation everywhere where there is C# and VB.Net sample code for everything. Eventually, VB devs would learn that C# is not C++ and the hurdle is easier and a lot would make the jump eventually. - Anonymous
February 25, 2005
My thoughts exactly. VB.NET seems to be potrayed very often as a poor cousin or C#, I quite resent this myself. Having moved from ASP 3.0 to VB.NET for developing web applications, I find it much easier and intuitive to develop in VB.NET with virtually no learning curve (except for the innards of OOP). I can program in C# but see no need to learn the language in depth. If I find any code snippets in C#, I translate these into VB.NET and things work equally well. The lack of the /// comments and automatic XML documentation generation in VB.NET is in my opinion the most shallow argument in favour of C#. In the end it boils down to personal preference. I look forward to VS 2005 when the languages come closer in terms of feature set. - Anonymous
February 25, 2005
You are missing the point the complaint isn't about whether VB.NET is a better language or not than C#. The problem is that VB.NET is not an upgrade of VB classic but a replacement.
There are so many changes in forms, graphics, and languague let along all the nifty new things that the choice is wide open if you choose to go on to .NET.
VB.NET doesn't help me with my existing VB classic app and when I do need to use .NET it doesn't really matter which of the two I am going to use.
What I need is a VBClassic.NET that allows me to run VB6 using the .NET framework. If you can talk about Ruby, and ML being ported to .NET and produce IL code there is absolutely no reason to support the syntax and setup of VB6. - Anonymous
February 25, 2005
I made it a point not to wade into the VB 6.0 and VB.NET debate right now. Duncan and Scott address that issue in their blogs so I did not feel the need to readdress the issue. I instead just wanted to focus on the "Natural Language" comment that I hear often. - Anonymous
February 26, 2005
The comment has been removed - Anonymous
March 02, 2005
C# was developed specifically for .NET therefore I see it as <i>the</i> natural .NET language. VB was adapted to fit within .NET and because of that, it is very akward in some aspects, even for VB6 developers. - Anonymous
March 02, 2005
A good related post is from Paul Vick at http://www.panopticoncentral.net/archive/2005/03/02/7762.aspx. Paul talks about how none of the VB 6.0 (or prior) runtimes and code was written in VB but how sections of the .NET framework, and even more of the .NET 2.0 framework are written in VB.NET. - Anonymous
March 05, 2005
The comment has been removed - Anonymous
March 06, 2005
The comment has been removed - Anonymous
March 07, 2005
And they wonder why the VB community is so fragile, we've now been upgraded to the position where we can be assaulted from both C# on one side and VB6 on the other.
Despite all the talk about how .NET breaks their minds and their codes I haven't seen and comprehensive examples of this negative productivity.
What is the -true vb path-? I don't see too many apocalyptic changes to VB only that there is MORE of it in .NET. What is it that you are doing with VB6 that you can't with VB7? Is it the default form instances? the array bounds? ByVal as default instead of ByRef? Can someone hand me some real deep answers? - Anonymous
June 11, 2009
PingBack from http://castironbakeware.info/story.php?title=brad-mccabe-s-weblog-the-natural-fit