C# 2.0 Spec Released
An anonymous reader writes "Microsoft released the design specifications document for C# 2.0 (codenamed 'Whidbey') to be released early next year. New features of the language include generics similar to those found in Eiffel and Ada, anonymous methods similar to lambda functions in Lisp, iterators, and partial types."
Whidbey is the code name for the next Visual Studio, not just C#.
Maybe you want to take a look a mono.
Note to self: get smarter troll to guard door.
C# is ECMA standardized. Java is wholly owned by Sun. Sun has repeatedly balked at standardizing Java due to the inherent loss of control.
Perhaps there are potential submarine patents, but Java is absolutely vendor-tied while C# is at least relatively open.
No, but consider the competition. C++ is insanely complicated and broken, and is popular. Perl is insanely broken and complicated, and it is popular.
Anyway, anonymous higher order functions and generics are two really glaring deficiencies in Java, C#, and many other modern OO languages, so adding them is a step in the right direction. It's not as if these are minor, useless features.
> Is this their plan to "lock in" universities to teaching microsoft programing to all levels, because it will take
> 4 years of classes just to cover it all?
That's crazy. Universities don't teach programming languages except as tools to teach more important concepts.
No doubt in doing so violating some Mr Softie software patent and thus receiving a cease and desist.
actually i would doubt it
Before adopting WHATWG, read the moonlight.NET EULA [http://www.microsoft.com/interop/msnovellcollab/moonlight.mspx]
Perl 6 will have continuations...
h tm l
http://www.sidhe.org/~dan/blog/archives/000156.
OK so I'm in the position of having to write an emergency support application for a M$-based system in a M$-based environment. Stuck in there. Completely. Been requested to make a maintainable, manageable solution. And yes, this is to say "make it for M$, with M$ tools as much as you can".
.NET, M$ introduced a quite nice API and Java language (come on, where are the real differences) into Visual Studio, which at least saved my day; I had found an acceptable programming environment for within Windows..!
I guess even within these circumstances, I'd have refused to open Visual Studio for this project, if it didn't say ".NET" as well. I mean, think of it: previous versions of VS only supported C++ or VB, with APIs to cry for (admittedly, I don't know about MFC, only about Win32).
I actually happen to dislike C++, but on top of that, it doesn't suit my project, because the low-levelness makes it harder to program without errors (e.g. null pointers, memory leaking). I'd rather have a language at a scripting level -- and NO, that's NOT VB. I hope I don't have to explain why I hate VB if only on very first sight.
So with
There's really no need for anybody to pick on C#, long as it's realized that it's just finally a nice programming environment for Windows, and nothing (well, not much) more. (BTW, it's not much different from NeXT (now Apple)'s use/ takeover of Objective C.)
"We can confirm that Debian does *not* ship the version with the trojan horse. Our version predates it." [CA-2002-28]
You should get out more. There's a world of programming paradigms most people have never heard of, because they're still stuck using C-alike block structured OO languages.
Continutions are, roughly speaking, a generalization of setjmp and longjmp in C. However, to have true "first-class" continuations they need to be objects that you can pass around, store in data structures, etc. In C this isn't true, because if you return from the stack frame that did the setjmp, the continuation is invalidated. Lisp has "call/cc", some implementations of ML have "calcc" (typed), and many scripting languages have it, because it's pretty easy to implement in an interpreted language.
Continuations can be used to implement exceptions, user-level thread packages, "early exits" from recursive code, and other cool stuff.
That's crazy. Universities don't teach programming languages except as tools to teach more important concepts.
Thats a great idea. Sounds great on paper, sounds great in theory. Sounds great while you're playing around with a bubble sort.
After that, its a load of crap.
Tell you what: You learn your bubble sort however you want. Your assignment is to write a program that uses a row colored spheres with numbers texture mapped to the surface of the sphere to demonstrate how the bubble sort actually operates.
I learned to do this at my university, and was lucky enough to get a professor that hadn't bought into the Windows Thing, and tought graphics programming with OpenGL (available everywhere) instead of DirectX (available in windows, and if you're lucky, wine).
In fact, when you get out of your pretty little university, you can try and get a job on "I know my programming theory". If you don't know the language and APIs that Company X is using, you're sunk. These days they don't settle for learning on the job. I had a wonderful job interview for developing an interesting application, I wowed them all with my knowledge, except for one little thing: I didn't know Perl/GTK which was what they were writing their application in. A few weeks later I got a check in the mail for my flight, car rental, and hotel and a thank you letter for taking the time to interview them in person.
If I have been able to see further than others, it is because I bought a pair of binoculars.
wow, that will they think of next?
C is a low level language and makes no bones about it being such.
Is such a high level language such as one that is designed to run upon other protocals the same?
No.
Really, I know what I'm doing...Ohhhh, look at the shiny buttons!
It's Scheme that has call/cc. Common Lisp didn't provide it (though it's not hard to write something similar if you really want it.)
college computer science people *are* learning it
What colleges are teaching C#? At my school we had one Pascal course then went into C followed by C++. I believe we could have taken Assembly right after Pascal, but I'll take that after I finish C++. I've heard of other schools starting with java or even python. I'm not arguing that schools don't teach C#, I just want to know which ones do so I can be sure not to transfer there.
Win a signed Stephen Carpenter ESP Guitar from the Deftones: http://def-tag.com/?r=0008781
It's really C-Hash.
Or as Microsoft execs like to pronounce it amongst themselves, cash.
-- Alastair
Removing something is very difficult. In fact, it is not recommended (unless it is a serious flaw or bug). There may be millions of developers using a particular feature or programming technique that is "bad". If you go and remove it, it could adversely affect all these programmers and their existing code. This is one reason why companies don't really remove features. Backward compatibility in software is absolutely crucial (especially when you force developers to upgrade to new versions all the time).
The best thing to do is to "phase" out the undesired feature by not recommending it, not featuring it prominently in books, shifting features into optional components that must be installed, etc.
I know this isn't exactly the ideal way to do things but I see no other way. I mean, if I was responsible for Visual Studio (or C# specifications), I would not remove features. Who knows who is using a particlar feature?
Sivaram Velauthapillai
Sivaram Velauthapillai
Seeking the meaning of life... @slashdot of all places
I still find it vaguely amusing that Microsoft released a product which cannot be properly displayed in the Latin-1 character set,
The octothorpe symbol, '#', has slanted vertical strokes. The "sharp" sign has slanted horizontal strokes.
Personally, a "broken" language is a language that requires so much work to do things right that programmers that use them frequently do things wrong. For example, my all time favorite security flaw: the buffer overflow.
A good language should support the development of code that doesn't contain common flaws. In my opinion, C and C++ are directly responsible for security flaws that cost trillions.
I'm not a full-time developer, I usually develop some basic web applications to enhance some of the new solutions I implement for Systems Administration. My experience with it is limited, but I'll give you my pro's and con's:
Pro's
Easier access to IO - just try it in Java and see. It's much faster in C#
Improved XML support - also a lot simpler in c#
Not as many third party specifications to learn. I remember having to learn Struts, Ant, Tomcat, and then Sophia after learning JSP - what a pain in the ass.
MSDN - The help system inside VS.NET is better than most languages' will ever be.
Con's
Not the best IDE in my opinon - IntelliJ smokes Visual Studio.NET in almost every respect(except for the help).
Can't use it on Linux or BSD - my applications are bound to fail more frequently than an equivalent Java/PHP/Perl app running on a secure box.
Most of the support I used to recieve about Java, Python, and other open source languages don't discuss c#. There just aren't the same amount of mailing lists, IRC channels, forums, to throw around C# ideas. The ones that do discuss it tend to cater to the Lowest Common Denominator.
I have to resort to Visual Studio 6 in order to create desktop applications that run on everyone's machine. The .NET framework has been a hard sell for the enterprise I work in.
What exactly do you mean by undocumented? The language and virtual machine are fully documented, you can download the sources to jdk and libraries, and is much more open than C$, though less than others open source projects.
"I think this line is mostly filler"
Universities are right to teach important concepts (and not just algorithms like bubble-sort -- that's friggin freshmen stuff anyway) like software engineering, project managment, relational algebra (i.e. database stuff), networking, AI, parsing, logic, circuit design, and (I'm lumping here) under-the-hood operating system concepts.
If you've got a Computer Science degree, and you payed attention, you can pick up the syntax for a new language within an hour. With a good API reference, you can be banging out code like an old pro with a weekend of study. It's not that hard.
What matters far more than how well you know a language is how well you know how to program. Any monkey with a keyboard can whip out a Visual Basic app.
But to write truly masterful code... that transcends skill with a language and approaches art.
That said, I'm going to contradict myself: it's important to know the basic capabilities of the language you're working with. Java would be a shitty language to write, say, a program that computes the sum of the two numbers input to it on the command line, because it takes so long for the VM to load -- far more than the actual execution time of the program.
Fortunately, things like that can be quickly learned.
"Times have not become more violent. They have just become more televised."
-Marilyn Manson
First off, Whidbey is the next version of Visual Studio, which is designed to use the dotnet framework v2. The SDK will be released publicly around the same time, so those who prefer Notepad need not pay one cent to write dotnet apps.
n fo/road map.aspx
Secondly, generics, partial types, and such are being added to the CLR, as well as Microsoft's "first-class" languages, meaning that yes VB.NET will include them. VB.NET also gets operator overloading, native support for unsigned types, and in-line XML commenting.
You can read it all at the roadmap here:
http://msdn.microsoft.com/vstudio/producti
It tells about some of the changes to the IDE, the CLR, and the languages. One interesting new "feature" is a sort of grammatical analyzer for writing code that will suggest improvements or corrections, similar to the way word underlines misspellings or grammar errors.
Whether it will be a great tool or a bloody nuisance remains to be seen.
Natural != (nontoxic || beneficial)
Enums have been added, generics have been added, automatic iteration in for loops have been added, et cetera. True, it hasn't been released yet (the first Java 1.5 betas are due next quarter), neither is Whidbey, and the JSRs have been out for some time, and the prototype compiler with generic support has been available for months.
Okay, no offense, but that's the worst description of continuations I've ever heard. It seems to be giving people ideas that it's like goto, which is a common reaction people have when they first hear about continuations. But it's not accurate. Goto manipulates the instruction pointer alone; continuations manipulate the entire stack in much more interesting ways.
There's some good stuff on continuations out there. They have little use in imperative programming styles like C++ encourages. In functional styles, they're used to implement exceptions, non-determinism, coroutines, generators, and a host of other control features that can open up whole new worlds of programming.
The crack about "ways of confusing people" doesn't mean that continuations tend make your code unreadable, like goto. It means that continuations are a confusing concept, but if you understand continuations, you can make much clearer code.
The quote that the parent AC plagarized is from Antoine de Saint-Exupery, the French aircraft designer living in the first half of the 20th century. (And author of The Little Prince, if that hasn't been banned in America yet.) He was speaking in the context of original design, not individual features.
While the plane is still on paper, that's the time to remove all the unneccessary cruft. That's de Saint-Exupery's point. Not after the plane has been built; then the dependancy problems you mention arise. That's not the proper time. Certainly not in midflight.
You cannot apply a technological solution to a sociological problem. (Edwards' Law)
"C# is ECMA standardized"
BWhahahaha, you fell for that, huh? Propaganda makes trolls all over the world.
I'm in web development ( full microsoft environment ) using C#, SqlServer2000, WinXP
Pros:
Cons:
Of course not.
But those who don't remember history are doomed to repeat it.
=-=-=-=-=-=-=-=-=-=-=-=-=-=-
Friends don't let friends enable ecmascript.
From the C# 2.0 spec:
"When an instance of Stack<int> is created, the native storage of the items array is an int[] rather than object[], providing substantial storage efficiency compared to the non-generic Stack. Likewise, the Push and Pop methods of a Stack<int> operate on int values, making it a compile-time error to push values of other types onto the stack, and eliminating the need to explicitly cast values back to their original type when they're retrieved."
Java uses Object boxing for built-in types in their generics implementation.
Java announced Generics months ago. In all, it seems like the java stuff is more exciting, although the lambda-like stuff in C# seems interesting.
Java generics are broken because they don't guarantee type safety across compilation units. That requires VM changes, changes that Microsoft was willing to make but Sun wasn't.
Java is more and more turning into an accumulation of evil kludges. Instead of type-safe generics, we got a hack. Instead of lexical closures, we got nested classes. Instead of structs, we got some half-hearted promise of optimization under some nebulous set of circumstances that can't work in general. Instead of multidimensional arrays, we got some classes with a horrendous syntax that, on some theoretical JIT, might actually run faster than a snail.
I don't know whether C# will grow up into a well-designed general purpose programming language, but it is crystal clear that Java has missed the boat.
Wrong.
Pascal is not meant for serious programming like C is, but Pascal has sorta grown into this business application language, and is far from obsolete.
You also cannot do anything in C++ that you can in C. You can do this in C, but not C++:
Or...
These examples were shamelessly ripped from Bjarne's FAQ, which is available Here.
You need to restart your computer. Hold down the Power button for several seconds or press the Restart button.
Ok, this is actually a .NET issue, not really a c# issue.
.NET, are text based streams, made up of 16-bit chars. When writing a (16-bit) char to StandardOutput it is converted to something else (UTF-8, maybe).
.NET, vim + .NET framework and the online MSDN reference is completely sufficient.
StandardInput and StandardOutput, in
Piping binary data from one app to another is a very non-trivial task.
These are the small "features" that make c# unsuitable for anyone "thinking UNIX". Of course piping through stdout/stdin is not needed: you can use remoting, sockets or whatever - but those make easy things hard.
Anyone who has written a c# program that uses stdin/stdout for binary data?
BTW, you definately does not need Visual Studio to program
Who the hell is the ECMA?
"Ecma International is an industry association founded in 1961, dedicated to the standardization of information and communication systems."
Here is a list of their standards. It includes specs related to C, Ada, IDL, ECMAScript (JavaScript), C# and WSDL. Interestingly enough, Sun and Oracle are absent from their membership list.
Why not an IETF standard?
Hint: the "I" stands for Internet. What does C# have to do with the Internet?
do you *really* think this design was an accident?
-- kryps
In case anyone reading the parent didn't get it, that means that the C# implementation of generics will have a strong efficiency advantage over Java's b/c boxing/unboxing is a costly operation.
Amazing magic tricks