C#: A language alternative or just J--?, Part 1
What the new language for .Net and post-Java Microsoft means to you
By Mark Johnson, JavaWorld.com, 11/22/00
- Digg
- Reddit
- SlashDot
- Stumble
- del.icio.us
- Technorati
- dzone
C# (pronounced "C sharp") is Microsoft researcher Anders Hejlsberg's latest accomplishment. C# looks astonishingly like Java;
it includes language features like single inheritance, interfaces, nearly identical syntax, and compilation to an intermediate
format. But C# distinguishes itself from Java with language design features borrowed from Delphi, direct integration with
COM (Component Object Model), and its key role in Microsoft's .Net Windows networking framework.
In this article, I will examine common motivations for creating a new computer language, and speculate on which might have
led to C#. Next I will introduce C# with regard to its similarities to Java. Then I will discuss a couple of high-level, fundamental
differences in scope between Java and C#. I close the article by evaluating the wisdom (or lack thereof) in developing large
applications in multiple languages, a key strategy for .Net and C#.
Currently, C# and .Net are available only as a C# language specification (not yet in final form), a "pre-beta SDK Technology
Preview" for Windows 2000, and a quickly growing corpus of articles on MSDN. This article is based on those resources and
some of my own speculation.
Read the whole series, "C#: A Language Alternative or Just J--?":
Enter C#
Imagine you're creating a new computer language, and you want to solve some of the traditional problems for C and C++ programmers:
memory leaks, difficulty writing multithreaded applications, static linking, illegal pointer references, overly complex multiple-inheritance
rules, and so on. To flatten the learning curve, you design the language to look a great deal like C and C++. Then you add
garbage collection, integrated thread interlocking, and dynamic linking, you throw out pointers, you allow only single inheritance
but introduce the concept of an interface, and so on. Five years ago, Sun Microsystems introduced Java technology, which did
those things and was platform-neutral, to boot.
In June 2000, Microsoft preannounced C#, which was designed expressly for its nascent .Net application development framework.
In addition to C#, the immensely talented Hejlsberg created the revolutionary languages Turbo Pascal and Delphi while at Borland,
but also the counterrevolutionary Visual J++ while at Microsoft. C# and Java address many of the same problems with C and
C++. In fact, C# looks so much like Java that you could very easily confuse them.
So why create C# at all? Is C# a "Java wannabe?" Since Microsoft obviously needs to deal with the Visual J++ developers it
has left stranded, is C# just "Visual J--"; that is, Java with some new features and without the Sun logo, trademark, and
narrow-eyed lawyers? Or is C# a technology that gives Windows developers the functionality of Java, could possibly compete
directly with Java, and is useful in its own right?
- Digg
- Reddit
- SlashDot
- Stumble
- del.icio.us
- Technorati
- dzone
Resources
- Read Part 2 of "C#A Language Alternative or Just J--?," Mark Johnson (December, 2000) for an in-depth look into the semantic
differences and design choices between C# and Java
http://www.javaworld.com/javaworld/jw-12-2000/jw-1221-csharp2.html
- "Bits, Flames, and Links," Bobby Schmidt (MSDN Online, Sept. 29, 2000) -- gets you started experimenting with C#, and includes a generous resource list
http://msdn.microsoft.com/library/welcome/dsmsdn/deepc08172000.htm
- "C#, The Natural Progression," Michael Perry (JavaWorld, August 2000) -- a high-level article, reprinted from ITworld.com, that outlines the C# technology
http://www.javaworld.com/javaworld/jw-08-2000/jw-0804-itw-csharp.html
- ITworld.com and JavaWorld columnists duke it out (pardon the pun) on C# vs. Java
http://www.javaworld.com/jw-11-2000/jw-1122-letters.html
- "C# Under the Microscope" (Slashdot, Aug. 9, 2000) -- a good, quick analysis of C#. The hacker prattle following the article provides more heat than light, but
also the occasional worthwhile observation
http://slashdot.org/articles/00/08/09/1612254.shtml
- "Microsoft .Net vs. J2EE -- How Do They Stack Up?" Jim Farley (java.oreilly.com)
http://java.oreilly.com/news/farley_0800.html
- If you're running Windows 2000, download this "pre-beta" evaluation kit
- http://msdn.microsoft.com/downloads/default.asp?URL=/code/
sample.asp?url=/msdn-files/027/000/976/msdncompositedoc.xml
- "Deep Inside C#An Interview with Microsoft Chief Architect Anders Hejlsberg," John Osborn, (www.oreilly.co) -- a fascinating article with the designer of C#. Be sure to read the James Gosling interview mentioned here, since Gosling's
comments, it appears to me, were used out of context
http://windows.oreilly.com/news/hejlsberg_0800.html
- A preliminary injunction in the Sun vs. Microsoft case, from Northern California U.S. District Court
http://techlawjournal.com/courts/sunwvmsft/19981117ord.htm
- "Sharp New LanguageC# Offers the Power of C++ and Simplicity of Visual Basic," Joshua Trupin (MSDN Online, September 2000)
http://msdn.microsoft.com/msdnmag/issues/0900/csharp/csharp.asp
- "First Impressions of C#Java Killer or Java Wannabe," David Reilly (EarthWeb, Aug. 11, 2000):
- http://gamelan.earthweb.com/dlink.resource-jhtml.72.1082.|repository||softwaredev
|content|article|2000|08|10|SDreillycsharp1|SDreillycsharp1~xml.41.jhtml?cda=true
- "First Impressions of C#a Language Overview," David Reilly (EarthWeb, Aug. 22, 2000)
- http://gamelan.earthweb.com/earthweb/cda/dlink.resource-jhtml.72.1082.|repository||
softwaredev|content|article|2000|08|21|SDreillycsharp2|SDreillycsharp2~xml.41.jhtml?cda=true
- "Report from Microsoft PDC 2000," John Ruley (Byte.com, July 17, 2000) -- a first-hand report from the Microsoft Professional Developers Conference, where C# was presented
http://www.byte.com/feature/BYT20000714S0003
- "Microsoft Challenges Java with C Sharp," Charles Babcock, (Inter@ctive Week, July 3, 2000) -- includes news about potential C# standardization
http://www.zdnet.com/intweek/stories/news/0,4164,2597408,00.html
- "Java business conferenceSun cancels Java standard plans," John Cox (Network World Fusion Dec. 8, 1999) -- documents Sun's flip-flop on Java standardization
http://www.nwfusion.com/news/1999/1208std.html
- "Microsoft Pitches 'C sharp' Against Java," John Leyden (vnunet.com, June 27, 2000)
http://www.vnunet.com/News/1104875
- "Microsoft Cans Visual J++ Tool," John Geralds (vnunet.com, July 12, 2000) -- Surprise, surprise
http://www.vnunet.com/News/1106388
- "Microsoft .Net Plans Face Court Hurdle," John Leyden (vnunet.com, June 23, 2000) -- How will .Net play in the context of the antitrust case? Fear, uncertainty, and doubt, for those who just
can't get enough
http://www.vnunet.com/News/1104495
- A large list of C# programming articles
http://www.hitmill.com/programming/dotNET/csharp.html
- ECMA (European Computer Manufacturers Association) homepage
http://www.ecma.ch/
- ECMA News has a discussion of C#'s submission to ECMA
http://www.ecma.ch/ecma1/NEWS/NEWS.HTM#Two%20new%20projects%20for%20ECMA%20TC39
- "C Sharp Previews Sound Flat," Charles Babcock, (Inter@ctive Week, July 17, 2000) has a good competitive analysis
http://www.zdnet.com/intweek/stories/news/0,4164,2604273,00.html
- "Microsoft's .Net Strategy," Gopalan Suresh Raj (Oct. 13, 2000)
http://www.execpc.com/~gopalan/misc/viewpoint.html
- "C# Strikes a Chord", Jacques Surveyer (Dr. Dobb's Journal)
http://www.ddj.com/articles/2000/0065/0065g/0065g.htm
- "C# Is Pronounced 'See Sharp,'" Arthur Griffith (windows.oreilly.com)
http://windows.oreilly.com/news/seesharp_0700.html