Slashdot Mirror


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."

634 comments

  1. Whidbey? by krumms · · Score: 0, Offtopic

    Worst. Codename. Ever.

    1. Re:Whidbey? by ergo98 · · Score: 2, Informative

      There's an island just outside of Seattle that is called "Whidbey Island".

    2. Re:Whidbey? by Doomrat · · Score: 1

      *ahem*, worse than Codename: Woody?

      How about Codename: Stiffy
      Codename: Morning Wood
      Codename: I really gotta bone, 'yo.

    3. Re:Whidbey? by Anonymous Coward · · Score: 0

      The SOED does not contain the word Whidbey, but I can find its parts:

      Whid: 1. A word. /Criminal slang/

      Bey: The governor of a distict or province in the Ottoman Empire.

      Conclusion: A Whidbey is someone who does criminal things on his ottoman.

    4. Re:Whidbey? by Otter · · Score: 1

      I dunno -- that string of GNOME release names with things like "Euphoric Jellyfish" and "Look, my pants fell off!" makes Whidbey look downright poetic.

    5. Re:Whidbey? by floydigus · · Score: 1

      Almost certainly a corruption of Whitby (white bay).

      --

      All things in moderation; including moderation

    6. Re:Whidbey? by Jim_Hawkins · · Score: 0

      Holy shit.

      If you're gonna bash Microsoft at least make it a half-worthwhie bash.

    7. Re:Whidbey? by Anonymous Coward · · Score: 0

      More like "whitey".

    8. Re:Whidbey? by Anonymous Coward · · Score: 0

      Has anyone used GNOME "Look, my pants fell off" in conjunction with Debian "Woody"?

  2. Re:That's great by Anonymous Coward · · Score: 1, Insightful

    What are you talking about fool? MS is perfectly within their rights to create whatever they want, blame it on the pointy-haired bosses for assuming everything MS creates is golden.

    2 Personalities, one body.
  3. gc#? by Anonymous Coward · · Score: 2, Insightful

    Ok, I know I'm a bad coder for liking C sharp, but gcc should really support it - like it or not, college computer science people *are* learning it, and Free software should support it. In fact, supporting visual basic compilation wouldn't be a bad idea either...

    1. Re:gc#? by Anonymous Coward · · Score: 2, Insightful

      put your money where your mouth is; so to speak :)

      gcc is Free software; so download the source and add c# or visual basic support. Once you get the ball rolling others will join in and help.

    2. Re:gc#? by termos · · Score: 5, Informative

      Maybe you want to take a look a mono.

      --
      Note to self: get smarter troll to guard door.
    3. Re:gc#? by hedley · · Score: 0, Troll

      No doubt in doing so violating some Mr Softie software patent and thus receiving a cease and desist.

    4. Re:gc#? by Anonymous Coward · · Score: 0

      Really? I'm not learning it. Right now I'm learning Java, and then I'm doing a course where C, C++ and Perl are all used for various problem-solving.

      There is a Visual Basic course but it's mostly business students taking it.

    5. Re:gc#? by Anonymous Coward · · Score: 0

      What's with continually reinventing languages? There are hundreds out there now, thousands even, and in essence they all boil down to the same 5 or 10 doing the same shit. How many more do we need? Will I reach 2010 and look back and see another hundred new and abandoned languages doing Yet More Of The Same?

      dammit

    6. Re:gc#? by Miguel+de+Icaza · · Score: 3, Funny

      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]
    7. Re:gc#? by Anonymous Coward · · Score: 0

      You're not a bad coder for using C#. It's better than programming in C or C++...

    8. Re:gc#? by Anonymous Coward · · Score: 0

      .. and now for the REASON.

    9. Re:gc#? by Anonymous Coward · · Score: 0

      But remember to avoid simians with the kissing disease.

    10. Re:gc#? by Anonymous Coward · · Score: 1, Insightful

      that's just natural selection in action

      people keep making languages, taking what they see as the best part of others, and occasionally putting in a new concept

      the crappy ones, which is most of them, get selected out of course, but eventually someone will make one that kicks the crap out of everything else (but it won't happen if people stop trying)

      almost certainly in 2010 you will look back and see dozens more crappy abandoned languages, but hopefully there will be 1 or 2 that make things easier

    11. Re:gc#? by Anonymous Coward · · Score: 0

      actually i would doubt it

      You're not Miguel, lamer

    12. Re:gc#? by edalytical · · Score: 4, Insightful

      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
    13. Re:gc#? by Anonymous Coward · · Score: 0

      And you yourself are certainly a large sample.

    14. Re:gc#? by AceM2 · · Score: 1

      If someone gets really bored and has nothing better to do.. Why not? but then again.. Really.. Who cares what 'college computer science people' are learning? I don't see the point in having to support every language out there.. The thing is, there are so many other projects that talented coders could be working on =/

    15. Re:gc#? by Anonymous Coward · · Score: 1, Informative

      I just want to know which ones do so I can be sure not to transfer there.

      Stanford, for one. It's an optional course that doesn't count towards the major, but they do teach C#. I can see why you'd want to avoid one of the top two schools for Computer Science in the world, because they teach an optional class on a language that might get you a job. Wait, no I can't.

      Anyway, YMMV, and I didn't get in to Stanford after all, so maybe I'm not the best source, but http://cs193n.stanford.edu/ sure looks like a C# class to me.

    16. Re:gc#? by penguin7of9 · · Score: 1

      Mono is JIT-based. It is starting to suffer from the same problems that Java suffers from: huge memory footprints and slow startup times.

      C# is a nice enough language to compile into regular, linkable executables. The resulting executables would not necessarily run faster in terms of raw CPU performance than JIT-based implementations, but they would be much, much better behaved as applications: faster startup times, easier distribution, lower memory footprint.

    17. Re:gc#? by Anonymous Coward · · Score: 0

      hahahahhahaha

      if its an elective that counts for zip, its not a real class.

      all classes count for something, if they still exist in a year that is.

      but this is the reason why no one cares about C#, more garbage from MS marketing dept. instead of R&D

    18. Re:gc#? by jadams2484 · · Score: 1

      I know for a fact West Point and the University of Arizona have C# classes

    19. Re:gc#? by Anonymous Coward · · Score: 0

      University of California, Irvine teaches Python->C/Asm->C++/Java in the Engineering program. In CS it's Java end-to-end.

    20. Re:gc#? by edalytical · · Score: 1

      It's an optional course that doesn't count towards the major

      Who cares about a class that doesn't count for anything. You made it sound like colleges are advocating the language. Should gcc support every screwball language taught at a university? No. Schools teach COBOL does that mean I should be using it? No.

      a language that might get you a job

      Again who cares if it might get me a job. Believe me I would hate that job! If it came down to it I would ratter take a lower paying job coding in a language I like on a platform I like. Money is not everything.

      --
      Win a signed Stephen Carpenter ESP Guitar from the Deftones: http://def-tag.com/?r=0008781
    21. Re:gc#? by SynKKnyS · · Score: 1

      A local community college is now teaching C#.

    22. Re:gc#? by abradsn · · Score: 0

      c -- around 1970 c++ -- around 1985 even Java is 5 years old.

      In computer science sometimes old is good. If however you are the one faced with the choice of using the most modern language as opposed to an archaic language, you would choose the one that best supports your needs.

      C# if you need to compile or hope for future compatibility

      Java if you want a language that still hasn't "caught on"

    23. Re:gc#? by abradsn · · Score: 1

      C# is new and based on it's predecessors. It stands to reason that it is better for application development.

    24. Re:gc#? by Anonymous Coward · · Score: 0

      >
      Ok, I know I'm a bad coder for liking C sharp, but gcc should really support it - like it or not, college computer science people *are* learning it, and Free software should support it. In fact, supporting visual basic compilation wouldn't be a bad idea either...
      >
      >
      So parasites like you who create Windows Shareware can get hold of a free complier?

      I *DON'T* think so.....

      There's absolutely *NO* need or place for C# in the non-Windows world.

      Get over it.

    25. Re:gc#? by Glock27 · · Score: 1
      University of California, Irvine teaches Python->C/Asm->C++/Java in the Engineering program. In CS it's Java end-to-end.

      Wow, no FORTRAN in the engineering track. Well, it's easy enough to learn...

      --
      Galileo: "The Earth revolves around the Sun!"
      Score: -1 100% Flamebait
    26. Re:gc#? by man_of_mr_e · · Score: 1

      There is nothing Windows-centric about C#. It's a very useful language, designed by a very good language architect (Anders Hejlsberg, one of the primary architects of Pascal at Borland).

      Now, various parts of the .NET framework are certainly Windows-centric, but C# itself is not.

    27. Re:gc#? by Anonymous Coward · · Score: 0

      To reduce application startup time, Ngen.exe is what you're looking for.
      It precompiles a native binary so that JIT is not necessary. It is available under both Mono and .Net

    28. Re:gc#? by miguel · · Score: 1

      Mono supports both JIT compilation, as well as precompilation (mono --aot program will precompile your code), improving startup code significantly.

      If anything Mono feels *faster* every day, as we improve the JIT engine.

      It seems you have not bothered to even use Mono, since we have great startup times.

    29. Re:gc#? by penguin7of9 · · Score: 1

      Mono supports both JIT compilation, as well as precompilation (mono --aot program will precompile your code), improving startup code significantly.

      At issue isn't my code (which is short), at issue is the load times for the libraries. Presumably, whoever built the binary distribution (I'm using AToker's Debian packages) did whatever is best for it. And startup times for Mono GUI apps, while not as slow as Swing, are slower than native apps. Also, the memory footprint (RSS) for gtk-hello-world.exe is 7.3Mbytes, which is a lot for something that only puts up an empty window. JITs have their costs, and native batch compilers really do have their place.

      If anything Mono feels *faster* every day, as we improve the JIT engine.

      Yes, but at the same time, Mono gets more libraries and people link to more libraries. That's what makes applications start up slower and consume more memory even if the JIT is improving.

      It seems you have not bothered to even use Mono,

      It seems you presume a little too much.

    30. Re:gc#? by vistic · · Score: 1

      At ASU it used to start out with C++, but now we've pretty much entirely transitioned to Java from beginning to end.

      CSE100 is an intro course to C++. CSE110 is the same intro course, but in Java. Neither of those go towards the major. Then CSE200 is a course required for the major and we have to use Java only. I think later on in CSE240 they teach C++, Scheme, Prolog, and C.

    31. Re:gc#? by esquimaux · · Score: 1
      Also, the memory footprint (RSS) for gtk-hello-world.exe is 7.3Mbytes, which is a lot for something that only puts up an empty window. JITs have their costs, and native batch compilers really do have their place.
      There are lost of ahead-of-time compilers for modern languages which produce programs with large memory footprints. Among them: GCJ. So if the GNU compiler can't work miracles with Java, there's no reason to assume it'll work miracles with C# (+ the runtime and huge class library) either.

      There are effective approaches to reducing footprint that have nothing to do with when the bytecode is turned into native code. Tree-shaking is one that worked for Lisp and similar systems. (That does require static ahead-of-time program *analysis*, but that's different.) Sharing VMs for different programs is another.

      The downside is that you may lose some of the dynamic capabilities of the language.

    32. Re:gc#? by Foofoobar · · Score: 1

      People in college are learning it only if they are going to a weak ass college with a lame comp sci dept. Community college anyone?

      Tell you what... when C# become cross browser compliant, they MAYBE industry experts will consider it a serious language. Untuil then, it's just Microsoft trying to tie developers into using only one OS.

      --
      This is my sig. There are many like it but this one is mine.
    33. Re:gc#? by Anonymous Coward · · Score: 0
      gcc is Free software; so download the source and add c# or visual basic support. Once you get the ball rolling others will join in and help.
      This is what I dislike about the FOSS community: the kneejerk reaction to any feature request is "do it yourself". Of course, /. is all about kneejerk reactions, which is doubtless why the reactor above was modded "insightful".
    34. Re:gc#? by mr+breakfast · · Score: 1

      The CLR that .Net is built on top of is also JIT based- from what I can tell when they got beaten on by Sun for writing J++ and calling it java they transferred all their microsoft java people over to design the .net virtual machine. The only reason it seems faster is because it is bound deeply to the OS.

      A C# executable is pretty much like an executable Jar file in that it invokes the VM and runs in that context.

    35. Re:gc#? by Anonymous Coward · · Score: 0

      Cross browser??? LOL. Go back to your javascripting.

    36. Re:gc#? by Foofoobar · · Score: 1

      Oops... heh. Meant cross platform. Thanks.

      Yeah, get C# to be cross platform compliant and maybe more people will use it. Right now as is, server side development is moving away from platform-centric coding as more and more people realize that their code needs to be able to work on a variety of platforms. Sun, Linux, Windows, Mac, etc... if your code cannot migrate, the app will more than likely get replaced with code that
      can... especially within a business environment.

      I have seen ALOT of applications and scripts get chucked or redone simply because they cannot work on a variety of platforms. Naturally, SOME apps it really doesn't matter... but as far as development is concerned, especially when it comes to the web and web services, cross platform is the key to your success.

      --
      This is my sig. There are many like it but this one is mine.
    37. Re:gc#? by penguin7of9 · · Score: 1

      There are lost of ahead-of-time compilers for modern languages which produce programs with large memory footprints. Among them: GCJ. So if the GNU compiler can't work miracles with Java, there's no reason to assume it'll work miracles with C# (+ the runtime and huge class library) either.

      A huge memory footprint is an issue with the runtime, not the compiler. Using a batch compiler is necessary to simplify the runtime to the point that executables have a small runtime footprint and start up quickly (having an entire JIT operate at runtime will consume lots of memory), but it is not sufficient by itself. The gcj implementation obviously does not do a good enough job, but that's not the fault of the gcc compiler, it's a problem with the runtime.

      There are effective approaches to reducing footprint that have nothing to do with when the bytecode is turned into native code. Tree-shaking is one that worked for Lisp and similar systems. (That does require static ahead-of-time program *analysis*, but that's different.) Sharing VMs for different programs is another.

      Tree shaking didn't really work well in practice, and large memory footprints and slow startup times were one of the things that killed Lisp (the other were its bizarre type system and lack of value classes, some of which Java inherits and C# fixes).

      The downside is that you may lose some of the dynamic capabilities of the language.

      C# still has more limited dynamic capabilities than even Objective C, which can be used to generate executables with a tiny footprint. Language implementors don't need tree shaking or anything like that to get decent performance and memory footprint, they just need to pay attention to memory and performance issues.

    38. Re:gc#? by ziggyboy · · Score: 0

      What a load of crap. The CS dep't of the university I go to does not teach any Windows-specific technologies at all. Having a very UNIX-centric curriculum, we're taught to program primarily using gcc/g++ on SunOS ad Linux from day one. The only department teaching VB is Information Systems... but who needs those geek wannabes anyway?

  4. Code name by flynt · · Score: 4, Informative

    Whidbey is the code name for the next Visual Studio, not just C#.

    1. Re:Code name by Anonymous Coward · · Score: 0

      Oh great, so another year goes by, and I have to shell out another 800 ($1300?) to get the latest version?

      While I think C# is a great language, doing a full point upgrade and linking it to a yearly product rollout is incredibly annoying. Yes I know it's Microsoft so we should expect these kind of things, but every year!? I skipped Everett (VS.NET 2003) because I ascertained that they were mainly minor improvements and weren't really worth it, but this sounds like a whole different kettle of fish.

      Aye well, that's the price you pay for being (or trying to be?) cutting edge I guess... *sigh*

    2. Re:Code name by flynt · · Score: 1

      The upgrade to VS.Net 2003 is/was only $30 (yes, thirty) for anyone with a copy of Visual Studio .Net. I don't know if this deal is still going on.

    3. Re:Code name by wjsteele · · Score: 1

      Um... the upgrade from Visual Studio.NET to Visual Studio.NET 2003 was only $29.

      Bill

      --
      It's my Sig and you can't have it. Mine! All Mine!
    4. Re:Code name by cookd · · Score: 1

      In addition, I don't know where he comes up with "early next year." Everything I've heard up till now says that Visual Studio 2004 is coming "late next year." And I've been following it pretty closely.

      Perhaps I missed something in the news, maybe about a new .Net SDK coming out separately from Visual Studio .Net 2004. But "early next year" is highly doubtful.

      --
      Time flies like an arrow. Fruit flies like a banana.
    5. Re:Code name by gfody · · Score: 2, Informative

      if(x = 1)...

      still not even a compiler warning.. *sigh*

      --

      bite my glorious golden ass.
    6. Re:Code name by PhrostyMcByte · · Score: 1

      Actually, whidbey is the codename for the new .NET framework.

    7. Re:Code name by TomV · · Score: 1

      The shrinkwrap release won't be here until next year. I'd say the reason this got released now is because today (26th oct) is the first day of the Moft Professional Developers' Conference in LA, and the attendees will be getting early releases of Whidbey, Yukon and Longhorn.

      So as of about now Whidbey's out in the wild. At least to an extent where the spec for C# 2.0 will be useful to some people.

      tomV

    8. Re:Code name by cookd · · Score: 1

      Huh? Whachoo talkin' bout, Willis?

      C#? Yeah, under C#, no compiler warnings. Cuz it won't even compile!

      C++? Under C++, it is by default a level 4 warning.

      --
      Time flies like an arrow. Fruit flies like a banana.
    9. Re:Code name by Anonymous Coward · · Score: 0

      You're my hero

    10. Re:Code name by thing12 · · Score: 1
      if(x = 1)... still not even a compiler warning.. *sigh*

      Nope... that'll give you an error because (x = 1) is not a boolean expression. But I guess I wouldn't be surprised if 'if(x = true)' compiled without a warning.

    11. Re:Code name by thing12 · · Score: 1
      The upgrade to VS.Net 2003 is/was only $30 (yes, thirty) for anyone with a copy of Visual Studio .Net

      And the upgrade for the .NET Framework from 1.0 to 1.1 was FREE for, well, anyone. There is/was nothing stopping anyone from using .NET 1.1 with the original VS.Net. Heck... I guess if you wanted to, you could use the Mono compiler with Visual Studio. The IDE is not the Framework - and while their releases coincide, you don't need to spend money to get the benefits.

    12. Re:Code name by joto · · Score: 1
      still not even a compiler warning..

      Either learn to turn on warnings in your compiler, or find a better compiler. In particular gcc will complain with -Wall. But that is little reason to advocate gcc, as I think you would have to look hard to find a compiler that doesn't.

      I'm not familiar with C#, but given it's java heritage, I suspect it's not even legal.

    13. Re:Code name by Surt · · Score: 1

      Turn on the warning for assignment in conditional. Or if using c# that's going to be illegal either way you meant it.

      --
      "Who is the Journal of Quantum Physics going to believe?" --Stephen Hawking
    14. Re:Code name by cubic6 · · Score: 1

      Well, if(x = 1) is actually a boolean expression... it evaluates to 1, which is true. It's also useful for testing the result of a function like this:

      if (result = aFunction()) {

      }

      --
      Karma: Contrapositive
    15. Re:Code name by Shaheen · · Score: 1

      That's why you use if(1 == x). 1 can not resolve to an l-value.

      --
      You should never take life too seriously - You'll never get out of it alive.
    16. Re:Code name by thing12 · · Score: 1

      Yes, that's true - in C - but it's not a boolean expression in c# - x is an integer, 1 is a constant - neither can be implicitely converted to boolean.

    17. Re:Code name by blancolioni · · Score: 1

      This is why I hate using the C family of programming languages -- writing unnatural code to avoid language bugs is not my cup of tea.

    18. Re:Code name by Viking+Coder · · Score: 1

      Hey - how do you know x is an integer? How do you know it's not a class that overloads operator= and returns a boolean?

      Or do you know something about C# that I don't?

      Does C# force operator= to return the same type as the right-hand operand?

      Or maybe, does C# force every variable named "x" to be an integer?

      Or is there something else that I'm missing?

      --
      Education is the silver bullet.
    19. Re:Code name by thing12 · · Score: 1
      Hey - how do you know x is an integer?

      Ok fine.. I made an assumption. 'x' isn't necessarily an integer, it could be any other type. But 1 is definitely a constant... and even if x were a bool, there's no implicit conversion of constant to bool... so you get a compiler error. If x were bool, and you wrote 'if(x=true)' - it would work - but you would still get a compiler warning asking if you meant to use == instead of = because you're assigning and comparing to a constant value.

      So what am I missing? I don't think that I made a poor assumption when I thought that x is probably an integer. But my point was that using c#'s base types that statement would generate a compiler error. And it would still generate a warning even the assignment were valid and x were bool.

      Does C# force operator= to return the same type as the right-hand operand?

      No.. C# forces a return that's the same as the left-hand operand. So yes you can work around the compiler error and the warning by declaring x to be of a class that you defined to have implicit conversions from int (or any type that can be implicitely converted from a constant) to that type, and another for that type to bool. So yes... in that very special case it would work. But why the hell are we worried about a special case that would never appear in the real world when all I wanted to say is that the original poster was wrong.

      Man I love getting trolled and wasting all this time responding... yay for me.

    20. Re:Code name by Viking+Coder · · Score: 1

      Man I love getting trolled and wasting all this time responding...

      I have no more trolled you than you have trolled the original poster. And there were assumptions and innacuracies in your post - I wanted to clear them up.

      Also, you keep refereng to "1" as a "constant," and that "there's no implicit conversion of constant to bool." "1" is indeed a "constant," but it's a "constant integer" - and the integer part of that is the interesting part. Because, "there's no implicit conversion of integer to bool." The "constant" part of "1" has nothing to do with this conversion or the failing of the conversion.

      Your argument was specious.

      --
      Education is the silver bullet.
    21. Re:Code name by thing12 · · Score: 1
      I have no more trolled you than you have trolled the original poster.

      Hah.. I didn't troll the original poster - I merely stated the facts as I saw them and really didn't want any response from it at all. I'd hardly call that trolling.

      The "constant" part of "1" has nothing to do with this conversion or the failing of the conversion.

      Your argument was specious.

      I don't think the argument was so specious. Compile it yourself and see the errors:

      int x; bool y;
      if (x=1) {} // Cannot implicitly convert type 'int' to 'bool'
      if (x) {} // Cannot implicitly convert type 'int' to 'bool'
      if (1) {} // Constant value '1' cannot be converted to a 'bool'
      if (y=1) {} // Constant value '1' cannot be converted to a 'bool'
      if (y=true) {} // Assignment in conditional expression is always constant; did you mean to use == instead of = ?

      The first 4 are errors, the last is of course a warning. And 1 is not a constant integer in C#, it's simply a numeric constant. The compiler may decide to put small numeric constants that don't have decimals into integers, but if you were to use a value outside the range of an integer it would pick a type based on whatever it could fit it into (i.e. uint, long, ulong, etc...). It's not uninteresting that 1 is a constant.

      Anyway, I'm done. Either you're convinced that I was genuinely trying to help, or you're not.

    22. Re:Code name by Anonymous Coward · · Score: 0

      Heh. I first read that as Wideboy. I bet I'm not far wrong and it's a right little bloater!

    23. Re:Code name by Pieroxy · · Score: 1

      In your examples, 1 is not a constant, it's a literal expression.

      Both wrong, I rul3z!

    24. Re:Code name by thing12 · · Score: 1
      Both wrong, I rul3z!

      ROFL! Thanks!

  5. Article in a Nutshell by Lord+of+haha · · Score: 0, Troll

    40 pages of why we know that we are better then you.

  6. moving towards bloatware or are these important? by Anonymous Coward · · Score: 2, Insightful

    You've truely engineered something great not when you can't add anything more to it, but only when you can no longer remove anything from it.

    Its great that they are adding new features. But are they removing anything that was decided to be a bad idea? Now is the time to do it, in the early versions shortly after its birth, before there is too much legacy code...

    Will MS begin to use this for its own products like Office in the near future?

  7. OpenOffice.org is your friend by PissingInTheWind · · Score: 0, Troll

    For those who can't get that link because it is a .doc document (what a shame on /. front page), you can still use OpenOffice.org to read it.

    C# still sucks...

    --

    A message from the system administrator: 'I've upped my priority. Now up yours.'
    1. Re:OpenOffice.org is your friend by Anonymous Coward · · Score: 0

      So Java sucks too then I guess since C# and Java are very similar.

    2. Re:OpenOffice.org is your friend by Anonymous Coward · · Score: 0

      Yes, java does suck. No argument there.

    3. Re:OpenOffice.org is your friend by Fortyseven · · Score: 1

      You have reaffirmed my hatred for this thing.

    4. Re:OpenOffice.org is your friend by Arker · · Score: 1

      Java is almost as bad. The only reason it's not as bad is because Sun is more afraid of pissing developers off than MS is, and has made quite a few concessions as a result.

      --
      =-=-=-=-=-=-=-=-=-=-=-=-=-=-
      Friends don't let friends enable ecmascript.
    5. Re:OpenOffice.org is your friend by Anonymous Coward · · Score: 0

      BS. Sun ignores it's developers and adds features for competitive reasons against .NET. Just look at the debate over autoboxing.

    6. Re:OpenOffice.org is your friend by holy+zarquon's+singi · · Score: 1

      or using the gnu tools: cat $* | strings | less

      --
      "...we should just trust our president in every decision that he makes and we should just support that." B.Spears 2003
  8. follow the link by buddydawgofdavis · · Score: 2, Funny

    Seems like a pretty limited spec.

    All it says is:
    Plugger: No approperiate application for type application/msword found!

    whatever...

    1. Re:follow the link by damiam · · Score: 1

      Plugger is so 1997. Use mplayerplug-in for multimedia and open other documents in their regular apps.

      --
      It's hard to be religious when certain people are never incinerated by bolts of lightning.
    2. Re:follow the link by Anonymous Coward · · Score: 0

      Could you help me install this? Can I email you at mathlete@bellsouth.net? Thanks buddy!

  9. Does C# have continuations? by ClarkEvans · · Score: 1

    ie, Ruby does; Perl/Python do not

    1. Re:Does C# have continuations? by OverlordQ · · Score: 0, Flamebait

      Oh boo hoo, the reason it's not in Perl is probably because there's a better/easier way :)

      (Please note I have no clue what he means by continuations)

      --
      Your hair look like poop, Bob! - Wanker.
    2. Re:Does C# have continuations? by saden1 · · Score: 0, Flamebait

      He got you too? WTF is continuations? Exception handling?

      Please speak American. We don't know what continuations are.

      --

      -----
      One is born into aristocracy, but mediocrity can only be achieved through hard work.
    3. Re:Does C# have continuations? by Tom7 · · Score: 4, Informative

      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.

    4. Re:Does C# have continuations? by Anonymous Coward · · Score: 0

      The Stackless Python project describes continuations well.
      http://www.stackless.com/spcpaper.htm

      In short, Continuations are very useful for network programming; continuations and Threads logically attack the same problem: how to manage program state when you have more than one chain of execution. However, continuations make threading seem like a barbaric solution -- both inneficient and error prone.

    5. Re:Does C# have continuations? by Gorobei · · Score: 3, Informative

      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.)

    6. Re:Does C# have continuations? by Piquan · · Score: 1

      How do you figure? I mean, you could write outward-only continuations by using catch/throw, but complete continuations, it would seem, would require you to rewrite eval (to accept a continuation argument).

    7. Re:Does C# have continuations? by Gorobei · · Score: 1

      You are quite right. The approachs are either: define a set of macros that define continuation accepting forms of the core CL forms (lambda, apply, etc,) and require people to use them; or define those macros, and write a code-walker macro to convert user code into the continuation style form.

      When I was writing in Scheme (back in 1986,) I found myself using call/cc quite often. In CL, I rarely find myself missing continuations, perhaps because the hairy parts of my code don't use defun, but rather use macros to express the functional bits, and code-walkers package up the various definitions into compilable functions.


      On Lisp has several chapters on continuations in CL. I, at least, found it interesting reading.

    8. Re:Does C# have continuations? by John+Courtland · · Score: 1

      Is that semi-analogous to a catch/throw statement? I'm curious, because I've been attempting to develop a simple interpreter and the error handling is a bitch in C/C++. I imagine this "continuation" has a little more power in that it can jump back to where you exited, correct?

      I am mal-informed on these paradigms, as I was schooled in COBOL and Assembler, and I myself have learned C/C++ and a bunch of other languages, but not python/ruby/etc, and such a small amount of Lisp that it's laughable...

      --
      Slashdot is proof that Sturgeon's Law applies to mankind.
    9. Re:Does C# have continuations? by Piquan · · Score: 1
      Groovy!

      I never got around to reading On Lisp. I got started on Lisp with CLtL, and used AMOP, SICP, and Norvig's Paradigms to continue. None of these have good descriptions of continuation-based techniques. Only Paradigms mentions them, and there it's more of an obsticle to be overcome in writing a Scheme interpreter, than a tool that can be usefully applied. Since I do all my work in CL, it never really was that big of a deal to learn about them. I thought about them, of course, and realized that there's some cool stuff you can do, but didn't really spend a lot of time investigating theories and techniques.

      So anyway, On Lisp didn't ever really look that appealing from the descriptions, but I never took the time to check out the content. After I got your post, I looked over the TOC and forward, and it looks quite interesting.

      I'm mostly a CL guy. I've never written any huge bodies of Scheme; I think about 1500 lines is as much as I've done. One Scheme program I wrote, a clone of the card game Fluxx, used continuations to get around a bit of weird hair, but I never really went anywhere after the intial implementation on that one.

      At work, my big thing is a program with a nondeterministic search engine at its core. It's the sort of thing that would be perfect for Prolog, but my initial Prolog implementations were considerably less efficient than pure-Lisp implementations, and I didn't have time to learn Prolog well enough to write an efficient version.

      Presently, I'm simulating the nondeterminism by structuring the stack in a particular way and using catch/throw for backtracking. This leads to pretty hairy code, since I had to structure the implementation around the stack needs instead of vice versa. (It also ends up interleaving heap structure changes with the search, for that little bit of extra hair.)

      I was thinking of moving to a series- or stream-based implementation, but it looks like Graham's chapters on nondeterminism may be just the sort of thing I need. I'll have to check it out.

      Thanks for the pointer!

    10. Re:Does C# have continuations? by __past__ · · Score: 1
      Is that semi-analogous to a catch/throw statement?
      It is more general. You can implement catch/throw with continuations (quite easily).

      In many ways, continuations are the GOTO of functional programming - you can do just everything with it, but it's not guaranteed to improve readability.

    11. Re:Does C# have continuations? by John+Courtland · · Score: 1

      One thing I'm trying to figure out, do you have to define the jump point of the continuation before using it, or does the language usually know where you want to jump to? Maybe you could show me a simple example, so I can see better. (I will google for it also, but I would still appreciate a description :))

      If you have to define it in the first place, you could pretty easily implement that in a class in C++, maybe with a little assembler thrown in for fun, you could implement a simple jump point routine.

      --
      Slashdot is proof that Sturgeon's Law applies to mankind.
    12. Re:Does C# have continuations? by Gorobei · · Score: 1

      Semi-analogous. You can essentially jump back to some arbitrary point in your program and resume from there (multiple times if you wish.) This lets you write constructs like choose/fail in this pseudo-code example:

      int[2] choose2numbers()
      {
      return( [ choose( 0, 1, 2, 3, 4, 5 ), choose( 0, 1, 2, 3, 4, 5 ) ]);
      }

      void trick( int sum )
      {
      int nums[2] = choose2numbers();
      if( nums[0] + nums[1] == sum )
      printf( "%d is the sum of %d and %d\n", sum, nums[0], nums[1] );
      else
      fail();
      }

      Given a number from 0 to 10, trick() will find a pair of numbers that add up to sum.

      With constucts similar to the above, it is easy to write a general game player (for Chess, Go, TicTacToe etc.) A routine like choose2numbers() generates candidate moves, and the position evaluator just returns a goodness for any position , calling fail() for positions not worth investigating further. The game engine can just call these routines, supplying backtracking as needed, without any knowledge of what the move generator and position evaluator are actually doing.

    13. Re:Does C# have continuations? by joto · · Score: 1
      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.)

      First part correct. Second part wrong.

      Common Lisp knowingly sacrificed continuations, and in general, you can't add "something similar", as continuations are hard to implement. If you can add continuations to your Common Lisp implementation without modifying the runtime, chances are it already has them as an extension.

      The reasoning behind not adding continuations is that they make some optimizations harder, they are unintuitive and hard to use, and it's not really what people want. What people want is exceptions and co-routines, both which can be added with smaller overhead than continuations. Unfortunately, only exceptions are supported by the Common Lisp standard.

    14. Re:Does C# have continuations? by joto · · Score: 1
      In many ways, continuations are the GOTO of functional programming - you can do just everything with it, but it's not guaranteed to improve readability.

      In fact, they are even worse. Continuations are long goto's, you can jump from anywhere to anywhere, unrestricted by scopes and procedure invocations. In FORTRAN you could at least use your grep to find out where you ended up. Continuations are dynamic, and it's impossible to know where you end up unless you understand the logic of the program. Anyone using call/cc often deserve to be shot. But it has it's uses.

    15. Re:Does C# have continuations? by Anonymous Coward · · Score: 0
      No. Continuations (aka co-processes) are a Very Useful Thing, but many/most mainstream programming languages unfortunately don't have them. Main problem is that it requires more complicated call stack (or different implementation of scoping altogether, ie. non-stack, no linear call frames). I love Ruby's implementation; it helps a LOT with things like file or database access. Implementing library/framework that can prevent resource leaks is a breeze, using blocks (Ruby continuations).

      In case of Perl, it's not there mostly because there have been other features Larry has felt are more important. Would be nice to hear how he'd feel about request for continuations, though.

    16. Re:Does C# have continuations? by Doomdark · · Score: 1
      Continuations can be used to implement exceptions, user-level thread packages, "early exits" from recursive code, and other cool stuff.

      Potentially other useful things are safe ways to handle leakable resources like database connections or file handles; usually via iterator-like access (like Ruby code often does). The idea is that code that accesses such a resource (in case of DBs, up to 3 levels of things; from transaction/connection to result set to result row) makes something looking like normal method code, but called code that opens the resource still has a way to "get back" to be able to close connection, after original code goes out of scope (ie. retains its stack frame or whatever mechanism is used to store code execution state). It's bit difficult to explain without showing code, and for C/Java background people it's new enough concept to take a while to truly appreciate (and I count myself as one of those... even though back at school these were explained, I never got to really make use of them).

      --
      I like paying taxes. With them I buy civilization -- Oliver Wendell Holmes
    17. Re:Does C# have continuations? by hding · · Score: 1

      I've gotten the impression from some of Kent Pitman's postings in comp.lang.lisp that really what he felt was the most important factor in leaving out continuations was the desire to have unwind-protect, which doesn't necessarily interact very well with continuations. I'd hate not to have unwind-protect in Common Lisp.

    18. Re:Does C# have continuations? by John+Courtland · · Score: 1

      So then I guess that continuations cannot really be an after thought to a language design, but rather require some sort of language cooperation.

      I assume that the compiler handles all the stack unwinding and memory deallocation should you choose to jump out of a deeply nested block.

      And I am also assuming that Fail is your call/cc function correct?

      One more assumption: the function choose(), am I going too far by assuming that it is more than just a representation for a for loop?

      Thanks.

      --
      Slashdot is proof that Sturgeon's Law applies to mankind.
    19. Re:Does C# have continuations? by Gorobei · · Score: 1

      So then I guess that continuations cannot really be an after thought to a language design, but rather require some sort of language cooperation.

      Correct. Either 1) the language was designed to support them (Scheme,) or 2) the language is introspective enough to allow a user to implement them (CL, many modern scripting languages,) or 3) some clever person kludges up a machine specific implementation in a C-like language (e.g using setjmp/longjmp and various stack-saving tricks.)

      I assume that the compiler handles all the stack unwinding and memory deallocation should you choose to jump out of a deeply nested block.

      Yep. Most languages that support continuations also provide a garbage collector. If you think as continuations as "stack frames as first class objects," you can't go far wrong. In that case, the program stack just becomes a linked list or whatever, and the GC can handle freeing of dead stack frames.

      And I am also assuming that Fail is your call/cc function correct?

      I hope so. fail() is equivalent to Choose() [with no args], I.e. there is no possible value/path that can return success in this trial computation.

      One more assumption: the function choose(), am I going too far by assuming that it is more than just a representation for a for loop?

      Well, at some level it, is just a for loop. It does, however, let us abstract away a lot of backtracking and bookkeeping. E.g. I could write a maze solver as follows:

      (=defun solve (maze my-state)
      (if (at-exit maze my-state)
      (return t) ;; true - we solved it
      (choose ((rotate-left my-state) ;; turn 90 degrees.
      (rotate-right my-state)
      (if (is-wall-ahead maze my-state)
      (choose ()) ;; i.e. fail - no choice will succeed.
      (walk-1-step my-state))) ;; walk 1 in direction currently facing.
      (solve maze my-state)))

    20. Re:Does C# have continuations? by joto · · Score: 1

      If Kent Pitman said that, then it was very likely a real consideration. At the time those issues were discussed, I was still dreaming about getting a C64...

    21. Re:Does C# have continuations? by John+Courtland · · Score: 1

      One thing I'm having trouble grasping (and google sucked at explaining too), is the choose() statement. Is it a form of recursion that if it has no arguments it automatically triggers a jump back to the original choose()?

      And if it does contain arguments, it actually will run until choose() is called again?

      I must say, for being so fluent with Procedural and OO design I'm having some trouble grasping the whole continuation design. I'm probably going to download a Lisp compiler and screw around with it for a while to make sure I'm understanding all this. C's setjmp() and longjmp() make perfect sense to me, but that's like putting a freshwater fish in a saltwater tank, I can't get the full understanding until I write native code for it.

      --
      Slashdot is proof that Sturgeon's Law applies to mankind.
    22. Re:Does C# have continuations? by Gorobei · · Score: 1

      Shamelessly taken from Paul Graham's On Lisp again, here's what it looks like under the covers:

      (defmacro choose (&rest choices)
      (if choices
      `(progn ,@(mapcar #'(lambda (c)
      `(push #'(lambda () ,c) *paths*))
      (reverse (cdr choices))) ,(car choices))
      '(fail)))

      This says:
      choose is a macro (so all this code is nicely optimized at compile time) that takes an arbitrary number (&rest) of bits of code (choices.)
      If no choices, just fail, otherwise:
      Convert all (mapcar) but the first (cdr choices) choice into a function of 0 args (lambda (), c) and put them on a stack named *paths*.
      Finally, call the first choice.
      The creation of the 0-argument functions is our version of the setjmp().

      (defun fail ()
      (if *paths*
      (funcall (pop *paths*))
      failsym))

      fail just tries the next path, if one exists, or returns a special value (failsym) if no paths are left. Note that the call (funcall) to the next path is tail-recursive (i.e. a jump,) so this is effectively the longjmp().

      This is still somewhat of a toy example, but it demonstrates the meat of the idea: we are essentially creating our own stack frames (the closures we push onto *paths*,) and jump between them using our tail-recursive funcalls. The GC handles the freeing of unreachable stack frames (unlike C where the longjmp() does the callstack 'freeing.')

      I must say, for being so fluent with Procedural and OO design I'm having some trouble grasping the whole continuation design. I'm probably going to download a Lisp compiler and screw around with it for a while to make sure I'm understanding all this. C's setjmp() and longjmp() make perfect sense to me, but that's like putting a freshwater fish in a saltwater tank, I can't get the full understanding until I write native code for it.

      Good idea. Now you just need to choose between Scheme and Common Lisp. joto has an excellent summary of the two languages. My personal preference is CL, mainly because my code is practical rather than experimental/theoretical.

      Be warned, it takes 3 years or more to become an adept CLer. The language is big, the compilers' error messages tend to be cryptic at first, the macro system and CLOS are both so powerful it's hard to use them well initially. On the good side, it's a lot easier to post a 5 line program to comp.lang.lisp and ask why it throws you into the debugger than to post the equivalent 3 page program in C++ and ask why it segfaults.

    23. Re:Does C# have continuations? by John+Courtland · · Score: 1

      I just downloaded MIT's Scheme and I must say it takes a little getting used to (like starting vi for the first time I guess, it really needs a better editor, for newbies anyway).

      Not afraid of the time it takes, I've been actively writing C/C++ for about 6 years now (not bad for a 22yr old) and I can read it like it was my first language. Hopefully I can get that way with Scheme/Lisp, I know right now I have trouble following all the parentheses while writing lambdas, I keep forgetting one or I put too many in, etc...

      Hell yeah, I just finished a recursive multiply function (I know it's simple, but this editor really sucks).

      How much do you know about interpreter design and such? I have this project I've been working on and it's coming along, but I know jack about interpreter design, and everything that's there is what came out of my head, no real research into what has already been done, etc. I'll tell you more if you want to know. Any how thanks for the mini-lesson. Time to play with scheme.

      --
      Slashdot is proof that Sturgeon's Law applies to mankind.
    24. Re:Does C# have continuations? by Gorobei · · Score: 1

      I just downloaded MIT's Scheme and I must say it takes a little getting used to (like starting vi for the first time I guess, it really needs a better editor, for newbies anyway).

      Excellent choice. You might want to read SICP, it really shows what you can do with Scheme.
      An editor that supports parenthesis balancing and automatic indentation of Scheme is almost a requirement. As proficiency increases, you'll immediately see from the indentation that something is wrong.

      Hell yeah, I just finished a recursive multiply function (I know it's simple, but this editor really sucks).

      Have you tried emacs? It supports Scheme well, and is basically the ultimate programmer's editor.

      How much do you know about interpreter design and such? I have this project I've been working on and it's coming along, but I know jack about interpreter design, and everything that's there is what came out of my head, no real research into what has already been done, etc. I'll tell you more if you want to know. Any how thanks for the mini-lesson. Time to play with scheme.

      Humbly, quite a bit (though I'm currently mostly working on a compiler.) Yeah, I'd like to know more: my email is mmn@bellatlantic.net.

    25. Re:Does C# have continuations? by Sri+Lumpa · · Score: 1

      In Scheme you create continuations with call-with-current-continuation (often shortened to call/cc) and the point where you use it is the point where you jump back. For example:

      (define call/cc call-with-current-continuation) ; shortcut for the lazy

      (define my-continuation 0)

      (+ 5 (call/cc
      (lambda (cont)
      (set! my-continuation cont)
      6)) 10)

      It will create a continuation (containing (+ 5 [] 10) and call the unnamed function (created by lambda) passed to call/cc as an argument.

      That function received the continuation created as argument and set the value of my-continuation to be that continuation. It then returns the integer 6.

      The + function is then executed with the arguments: 5 6 10 which will return 21.

      You can now use the continuation in my-continuation like any other first class value (integers, pairs, symbols, functions...) and call the continuation with other arguments, like:

      (my-continuation 100)

      which will conceptually replace the (call/cc ...) part with 100 instead of 6 like the first time and jump back to the point in your code where you created the continuation and give the result 115.

      So if you have:

      (define a
      (+ 5 (call/cc
      (lambda (cont)
      (set! my-continuation cont)
      6)) 10)

      ;b will be 21

      b
      21

      (my-continuation 100)

      b
      115

      ;But if we try:

      (define c (my-continuation 345))

      b
      360

      c
      ERROR: Unbound Variable

      Because by calling the continuation we discarded the current continuation (define c []) for the called one (define b (+ 5 [] 10)) with 345 replacing the []. This is why another poster said that call/cc is the equivalent to goto for functional languages.

      I don't know if it makes things clearer or murkier but for more info on continuations and Scheme in general read "Teach Yourself Scheme in Fixnum Days": http://www.ccs.neu.edu/home/dorai/t-y-scheme/t-y-s cheme.html

      It's quite a good tutorial.

      --
      "The obvious mathematical breakthrough would be development of an easy way to factor large prime numbers." Bill Gates,
    26. Re:Does C# have continuations? by Sri+Lumpa · · Score: 1


      Unless he is deliberately trying to obfuscate something.

      --
      "The obvious mathematical breakthrough would be development of an easy way to factor large prime numbers." Bill Gates,
    27. Re:Does C# have continuations? by Sri+Lumpa · · Score: 1

      On Redhat Linux there should be Guile available (on one of the CD's if it is not installed).

      I like to start emacs type M-x shell (the Meta key is Escape on PC's) and type guile (you can use e-lisp code in their .emacs to automate it a bit but without it M-x shell and then guile from the shell works well).

      I then use one/many buffer(s) for my open files (in Scheme mode there is simple syntax highlighting and parentheses matching and tab allows you to indent properly, which helps a lot) and the shell buffer to test the code.

      An additional file allows me to load everything I need instead of writing a lot of (load "filename.scm") and a few xpdf/webbrowser windows for the doc I need and i am set up. It may be a bit rudimentary but it works well for me and it beats vi (unless you love it and hate emacs of course).

      --
      "The obvious mathematical breakthrough would be development of an easy way to factor large prime numbers." Bill Gates,
    28. Re:Does C# have continuations? by beerman2k · · Score: 1

      Yes. The next version of C# will have continuations.

    29. Re:Does C# have continuations? by John+Courtland · · Score: 1

      Thanks, I have Redhat 4-9 (inclusive) and although I've been too lazy to install 9 on my last computer (AMD 1.333GHz) and my 8 box is a P200 and my 4.2 box is a 486/40, I will stick with my WinXP install. I actually downloaded PLTScheme, and I like the editor far better. (I don't really like emacs very much, I am more used to vi, and even more used to pico/nano).

      --
      Slashdot is proof that Sturgeon's Law applies to mankind.
  10. Trying to..? by Anonymous Coward · · Score: 0

    Trying to capture some of the Perl 6 fanbase, I suppose, with the every-language-feature-ever thing?

    Just as well that this will probably be out by the same time Perl 6 is..

    That is to say 2010..

  11. Iterators by adrizk · · Score: 1

    Are they basically coroutines?
    If so, that seems like a useful feature to have built in to a language.. I remember a while ago wishing that C/C++/Java had standard/nice ways of doing this..

    Can someone who's more familiar with concurrent programming comment? (I haven't touched this kind of stuff in a while)

    1. Re:Iterators by Anonymous Coward · · Score: 0

      Uh, java has them already:

      given ArrayList a

      for(Iterator i = a.iterator(); i.hasNext();)
      my Object o = (Object) i.next();
      o.doStuff()
      }

      Unless i'm missing something.

    2. Re:Iterators by RogerWilco · · Score: 1

      Nah it's more a generic way of index/pointer into your data stucture
      Compare the C code:
      {
      int i;
      char Name[100];
      for (i = 0; i < 100; i++)
      (
      Name[i] += 1;
      )
      }
      With the C++ code:
      {
      std::vector<char, 100> Name;
      std::vector<char, 100>::iterator i;
      for (i = Name.begin(); i != Name.end(); i++)
      {
      *i += 1;
      }
      }
      This is a stupid example, but replace char with "AwfullyComplexObject" and += 1 with *i.MakeThisObjectSimple();
      And remember vector could be list, map, hashtable or any template abstract container you would like.
      One of it's functions is to have an index into an array/vector/list that knows how big the step to the next element is, where teh compiler solves differences in memory allignment accross processor architectures, etc.

      Adriaan

      --
      RogerWilco the Adventurous Janitor
    3. Re:Iterators by RogerWilco · · Score: 1

      Oh but please remember that a lot of C++ like this is not/not fully/correctly implemented in Visual Studio before VS.Net 2003, which according to C/C++ Users journal (iirc) finally has almost (97%) complete support for C++ (over 73% for VS.Net 2002). Check also "Comparing C/C++ Compilers" in the september number of Dr. Dobbs Journal oct. issue. Note that I am not saying that the actual cosde above will not compile.
      I have only used decent C++ compilers thusfar, like Borland C++ and gcc, which have done C++ correctly for as long as I use it (1998)

      Adriaan.

      --
      RogerWilco the Adventurous Janitor
    4. Re:Iterators by rumil · · Score: 1

      "I have only used decent C++ compilers thusfar, like Borland C++ and gcc, which have done C++ correctly for as long as I use it (1998)"

      I would hardly say Borland or gcc "do" C++ correctly. In fact, AFAIK, VS.NET2003 is one of the most standards compliant C++ compilers available.

      GCC has taken a considerable step forward with version 3 and up but, considering you cited 1998, I would assume you were using a version 2 GCC. All versions previous to 3, including the 2.9.5 compilers, were notorius for their poor C++ support.

    5. Re:Iterators by GnrcMan · · Score: 1

      Hmm...basically, an iterator makes it easy to create a class that allows this:

      {
      FooIteratable foo = new FooIteratable();
      foreach (int i in foo)
      {
      Console.WriteLine(i.ToString());
      }

      So, instead of implementing all the cruft that might be written to implement IEnumerable, you just implement FooIteratable like this:
      public class FooIteratable: IEnumerable
      {
      public IEnumerator GetEnumerator()
      {
      for (int i = 0;i = 10;i++) yield i;
      }
      }

    6. Re:Iterators by Anonymous Coward · · Score: 0

      Ahhh... but you forget the zealot's logic... anything non-MS is "correct" by default...

      I can't tell you how many times I've found when Borland output bad executables.... one of my favorites was when I told it to optimize for speed, it decided that the fastest way to execute my for() loop was to only do half the iterations.

    7. Re:Iterators by SirLestat · · Score: 1

      Nope they are not ... Yeah they look pretty much like coroutines, but they are restricted to enumeration/iterator. I was really looking forward coroutines so I'm a bit disapointed about that.
      "An iterator block produces a sequence of values, all of the same type. This type is called the yield type of the iterator block.
      The yield type of an iterator block used to implement a function member that returns IEnumerator or IEnumerable is object.
      The yield type of an iterator block used to implement a function member that returns IEnumerator or IEnumerable is T."

      Meaning: Function with yeild return must return iterator.

      "When a function member returning an enumerable interface type is implemented using an iterator block, invoking the function member does not immediately execute the code in the iterator block. Instead, an enumerable object is created and returned. The enumerable object's GetEnumerator method returns an enumerator object that encapsulates the code specified in the iterator block, and execution of the code in the iterator block occurs when the enumerator object's MoveNext method is invoked."

      So you really can only get an enumerator out of them ... maybe you could use it by hand and have something like coroutine ... but it's not meant to be.

      Generic, Anonymous and Partial types are very nice missing feature in C#. I can't wait to get those. Iterator is more like a trick to help with iterator implementation which will be used lot less than the 3 others.

    8. Re:Iterators by Anonymous Coward · · Score: 0

      You're right, .NET already had an option to control iteration by implementing IEnumerable end the GetEnumerator function.. However I usually return 'ArrayList.GetEnumerator' ;)

  12. More C++ by schouwl · · Score: 1

    It looks to me at the first glance at the spec as if they took a lot more in from the C++ standard into C#.
    The generic part is really just templates.
    Lars Schouw

    1. Re:More C++ by Anonymous Coward · · Score: 0

      Guess again on the templates - C# gnerics are *not* code generation macros; they are fully type-safe runtime elements.

    2. Re:More C++ by Anonymous+Brave+Guy · · Score: 1
      Guess again on the templates - C# gnerics are *not* code generation macros

      Neither are C++ templates.

      --
      If you disagree, post your argument. (-1, Overrated) isn't your personal censorship tool for views you don't like.
    3. Re:More C++ by Anonymous Coward · · Score: 0

      I've never seen so much misguided crap on C++.
      C++ is an very powerful tool, if you have a brain.

    4. Re:More C++ by Anonymous Coward · · Score: 0

      C++ is an very dangerous tool, if you think you have a brain.

    5. Re:More C++ by VertigoAce · · Score: 1

      The big difference is that in C++ the templates are compiled based on what's actually being used. A separate copy of the code is made for each type. Also, if a template class member function is not used, it isn't even compiled. From what I understand of C# generics, the code is compiled in a generic way that can be used like a template at runtime. Only one copy of the code exists. In C# you could make a library that contains a compiled "template", which is something that you can't do in C++.

      Without generics you can do this in C# with the object type. Of course, you would then need to implement the type checking yourself. In C++ you might be able to pull this off with void* and the RTTI capabilities, but it probably wouldn't be as robust as C++ templates, or the C# ways of doing it (passing around void* is a good way of losing an object, especially if this is in a library to be used by different developers).

    6. Re:More C++ by Anonymous+Brave+Guy · · Score: 1
      The big difference is that in C++ the templates are compiled based on what's actually being used.

      That's true. Actually, I find it quite ironic that the generics advocates slam C++ templates for "code bloat" and then compile everything, whether or not it's ever actually going to be useful. :o)

      --
      If you disagree, post your argument. (-1, Overrated) isn't your personal censorship tool for views you don't like.
    7. Re:More C++ by Anonymous Coward · · Score: 0

      You stopped reading right at the point where you found an opportunity to bash MS/c#?

    8. Re:More C++ by VertigoAce · · Score: 1

      As the AC said, the code bloat goes both ways. If you just have one instance of the template and you don't use all of its functions, the code will be smaller. However, if you use a template on multiple types, you end up with multiple copies of that code. It's just the same as if you had written out all of the different classes and functions by hand. Templates in C++ are basically macros with a lot of type checking. C# generics result in a single copy of the code. There are runtime penalties for doing the type checking, of course, but that's the cost of using generics. If you didn't want to be checking the type of an object as it's being added to a collection, you'd use a collection of object's.

    9. Re:More C++ by C+Joe+V · · Score: 1
      There are runtime penalties for doing the type checking, of course, but that's the cost of using generics.

      Not if the language does generics right, there aren't. The whole point is that you type-check a generic thing once, at compile time, and then know that no matter how it is instantiated the result will be well behaved. This way you can in principle avoid both (1) the code bloat you get in C++ due to different instances of a template being compiled separately, and (2) the run-time cost you incur in, say, Java when you try to fake generics using Object and have to cast things all the time.

      Now, if you're compiling to a "typed" bytecode format such as that of the JVM (or CLR?) and the bytecode's type system doesn't know about generics, then you will pay for type checking that you don't really need (cuz at the bytecode level you have to do the generics the fake way using Object, but none of the casts will ever fail). But that's a separate issue.

      But IDNKC#, and IDNRTA.

      CJV

    10. Re:More C++ by Anonymous Coward · · Score: 0

      So which university course do you teach?

  13. Version 7. by Anonymous Coward · · Score: 1, Insightful

    Will be Lisp.

    1. Re:Version 7. by Anonymous Coward · · Score: 0

      (((Except(((with(((a(((more(((readable(((syntax))) )))))))))))))))

    2. Re:Version 7. by Anonymous Coward · · Score: 0

      No, this is Microsoft.

      It'll be APL, and you'll have to get a new keyboard.

  14. Re:Who gives a shit about C# by henriksh · · Score: 1
    That language is even more vendor-tied than Java, and it's already bad enough there.

    Agreed. Java is very proprietary, and no decent free version of it exists, since some of the internals are undocumented. This is the reason I no longer code in Java, although I love some things about language (interfaces, for instance, and the API is generally documented very good).

    How is the situation with C#, can you use this in a free-as-in-rms environment?

  15. Sea Number/Sea Sharp by Anonymous Coward · · Score: 1, Funny

    C sharp? Wouldn't this be the same thing as C with a plus? A C# is C + a semitone.

    Me: "Hi, I Program in Sea Sharp!"
    Pianist: "That piece was played in D sharp actually."

    Ok, since I know they wouldn't name a programming language after a music note... It must be C Number

    Doesn't C Number conflict? You're naming a specific letter but using the generic word Number. I mean, shouldn't it either be Letter Number, or C 8 or something? But C Number?

    Me: "I program in Sea Number"
    Someone: "... Sea Number what? 1? 2?"

    1. Re:Sea Number/Sea Sharp by saden1 · · Score: 2, Funny

      I like to think of it has C Pound.

      --

      -----
      One is born into aristocracy, but mediocrity can only be achieved through hard work.
    2. Re:Sea Number/Sea Sharp by Anonymous Coward · · Score: 0

      OK, this name stuff is boring!!

    3. Re:Sea Number/Sea Sharp by AJWM · · Score: 4, Funny

      It's really C-Hash.

      Or as Microsoft execs like to pronounce it amongst themselves, cash.

      --
      -- Alastair
    4. Re:Sea Number/Sea Sharp by Anonymous Coward · · Score: 0

      Now that's funny

    5. Re:Sea Number/Sea Sharp by jjhlk · · Score: 1

      It's also a B# + a semitone, and a D flat (or D minus a semitone). And from my composition class I should know of the other couple ways to describe it.

    6. Re:Sea Number/Sea Sharp by Jeremy+Erwin · · Score: 3, Interesting

      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.

    7. Re:Sea Number/Sea Sharp by rnd() · · Score: 1, Offtopic

      The parent is probably the most unfunny comment ever moderated "funny" that I've ever seen. A new low has been reached.

      --

      Amazing magic tricks

    8. Re:Sea Number/Sea Sharp by AuMatar · · Score: 2, Funny

      Please. Its just C. The rest of the line is a comment.

      --
      I still have more fans than freaks. WTF is wrong with you people?
    9. Re:Sea Number/Sea Sharp by floydigus · · Score: 1

      You: "Hi, I Program in Sea Sharp!"
      Me: ?
      You: "C sharp? Wouldn't this be the same thing as C with a plus? A C# is C + a semitone."
      Me: "What?"
      You: "Doesn't C Number conflict? You're naming..."
      Me: "Yawn"
      You: "Drone, blab, And then I say X and then someone else says Y and I say but hey what about j# - what does *that* mean? blah..."
      Me: *snore*
      You: "twitter"

      --

      All things in moderation; including moderation

    10. Re:Sea Number/Sea Sharp by Anonymous Coward · · Score: 0

      It's correctly pronounced "See-Pound."
      As in "we're going to Pound this in to you."

      Rick DeBay

    11. Re:Sea Number/Sea Sharp by Overly+Critical+Guy · · Score: 1

      I'm sorry. This is so not funny. "+2 Funny?" Come on, moderators.

      --
      "Sufferin' succotash."
    12. Re:Sea Number/Sea Sharp by Anonymous Coward · · Score: 0

      On the contrary! Just write "C#" and tilt your monitor as necessary!

    13. Re:Sea Number/Sea Sharp by Anonymous Coward · · Score: 0

      Or write your code in C-hash.

    14. Re:Sea Number/Sea Sharp by hendrix69 · · Score: 1

      In hebrew it's "C Little Ladder".

      --
      The power of Christ compiles you!
    15. Re:Sea Number/Sea Sharp by buckhead_buddy · · Score: 1
      If it's an ECMA standard that using regional names for the # sign would be inappropriate.

      Coctothorpe must be the correct interpretation of C#

    16. Re:Sea Number/Sea Sharp by Christian+Engstrom · · Score: 1
      Oh, so that's how it's pronounced.

      I have always assumed it was just "C double cross".

      --
      Christian Engström, Former Member of the European Parliament 2009-2014 for The Pirate Party, Sweden
    17. Re:Sea Number/Sea Sharp by Anonymous Coward · · Score: 0

      Good one, made me laugh out loud!

    18. Re:Sea Number/Sea Sharp by man_of_mr_e · · Score: 1

      It's actually C++ ++, however, the ++'s are superimposed and slightly vertically offset. Notice how the # sympol is actually 4 +'s. This is a little known joke that the C# developers used that seems to not be very widespread.

    19. Re:Sea Number/Sea Sharp by joto · · Score: 1

      Yeah, but is it major or minor C sharp? *sigh*

    20. Re:Sea Number/Sea Sharp by Haeleth · · Score: 1

      No, that would be... oh damn, I forgot, /. uses 7-bit ASCII so I can't post a real pound sign. C&#163;, anyway.

      Or "Clb", perhaps?

  16. Why should I care? by lurker412 · · Score: 1

    I have ignored C# since its inception. I would be interested in hearing from slashdotters who have used it. What's good about it and what's bad? Of course, I expect nothing less than purely objective replies...

    1. Re:Why should I care? by Anonymous Coward · · Score: 0

      I have ignored C# since its inception. I would be interested in hearing from slashdotters who have used it. What's good about it and what's bad? Of course, I expect nothing less than purely objective

      Oh, this is simple.

      The good is, that it works.

      The bad is, that it is from Microsoft.

      Anonymous Cowards Unite

    2. Re:Why should I care? by funked · · Score: 5, Informative
      I've been using C# for about a year or so now. I started with Java, and made a clean switch to C# for a few projects that required it. I don't think that it will ever replace any of the three P languages, but is more targeted at taking Java down.

      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.

    3. Re:Why should I care? by ryepup · · Score: 1

      I'll try to be objective. Background: I do web programming in a ms environment and moved from vbscript ASP to C# and ASP.NET about a year ago. I run redhat at home (gonna switch to suse or gentoo once I get a weekend with nothing going on) and am trying to use open/free software as much as possble. I don't particularly like MS as a company, but some things (visual studio, SQL Server, C#) I think are done really well. (as long as you keep up with patches). I've done some Java in school, some perl, some php, some c, some c++. My opinion is that C# is Java, but cleaned up a little, and with a little more flexibility. You have interfaces, inheritance (but not multiple inheritance), reflection, enums, etc, etc. All the standard features of a modern programming languages. You can use delegates to pass functions as variables, and can pass arguments by reference as well as by value, the list is pretty big. My impression is that its a cross between Java and C++, as it allows a little more than Java, but doesn't make the programmer do as much as work as C++. Its much closer to Java. There are a few convenience keywords, such as "foreach" which improves upon Java, and the microsoft base classes are very fully featured. I've heard the comment made that programming with C# is more a research task than a programming task, since you spend a lot of time looking at the docs for the base classes. I think this happens with Java somewhat, too. Overall, I think C# is a good language, and enjoy using it, especially in conjunction with Visual Studio, which is an excellent, excellent IDE. I wish someone other than MS had created this, or that they would donate it to some other organization that would give it some more legitimacy among the programming public. The only bad thing I can think of it that all cases in a switch must have a break, and it doesn't have multiple inheritance, which i've wanted a handful of times. Other than that, I have no complaints, and programming tasks go much quicker thanks to the extent of the base classes. There are small bones to pick, like why the StringBuilder (StringBuffer in Java) class writers didn't overload +=, or how the bytecode produced can be de-compiled easily, but those are small compared with the amount of work thats done for you already. That could be a bad thing for some people, because the source of the base classes isn't readily available, so you have to trust that MS' implementation of Hashtable isn't horrible. If clock cycles aren't your primary concern, I recommend it, for me it saves a lot of programmer time.

    4. Re:Why should I care? by JamesOfTheDesert · · Score: 1
      don't think that it will ever replace any of the three P languages

      Prolog, Pascal, and Pike?

      --

      Java is the blue pill
      Choose the red pill
    5. Re:Why should I care? by Baavgai · · Score: 2, Informative

      C# is basically Java for Windows, take two. It does seem to have learned from the evolution of Java and cleaned some of the messier bits.

      Exception handling is a little looser, without the need to declare thrown exceptions or catch those declarations. There is a still an exception based error handling system, it's just more implicit than explicit.

      I really like the properties, an idea they took from Visual Basic. At some point in Java history (birth of EBJs?) it was concluded that public class variables were a bad idea. Java standardized on a getter / setter model that is more a convention rather than a language rule. C# uses a property, which has either a get, set, or both. If fills the same OOP niche, only more cleanly.

      There is also some neat static ( class level ) functionality. Interestingly, while exceptions aren't explicit, inheritance is. A method must be declared virtual to be overridden, a more C++ thing to do.

      Basically, there are many little changes from Java that make C# not Java. But, the changes do make sense and make C# an enjoyable language to program in.

    6. Re:Why should I care? by Keltus · · Score: 1

      > 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. you can write regular C++ apps in visual studio .net (2003) too. just don't choose to make .NET applications. the only thing not in VS.NET that was in VS6 is Visual Basic 6 and J++

    7. Re:Why should I care? by Bobbysmith007 · · Score: 3, Informative
      Background:
      I'm in web development ( full microsoft environment ) using C#, SqlServer2000, WinXP

      Pros:
      1. Great documentation (ala MSDN) for extensive, helpful base classes
      2. Very flexible and readable
      3. XML comments integrate with the Visual Studio .Net IDE to create developer time tooltip documentation
      4. Its very easy to create and manage many layers of abstraction such that any layer can be changed without needing to alter much code elseware.
      5. Very easy IO using the System.IO name space base classes. Great objects that are arranged fairly standardly that just take the frustration out of alot of the repetitive work.
      6. While I generally dont know the implementation of a base class object (see con 1), They do seem to be very well implemented in most cases
      7. While not useful to everyone, It has very good SqlServer classes in the System.Data.SqlClient namespace. The syntax used is standard, well documented, easy to pickup, fairly powerful, and very flexible. I deal with a decent sized database and there tools for every purpose, it seems.
      8. Because of the excellent auto-complete and tooltip comments, its a pretty quick language to pick up with just Visual Studio Help(MSDN) and the IDE.
      9. The property is a great addition to the standard syntax of the language. It allows the getter, setter functions to be treated a public variable. I think this helps realize a truly object based system a little better.


      Cons:
      1. As far as Ive found there is little documentation on the inner workings of the base classes
      2. Its from Microsoft who I generally consider money grubbing, domineering whores
      3. All .Net apps need the .Net Runtime in order to be run. This creates compatability issues even amongst older versions of windows (as the vast user base doesn't see the need to patch (ie older members of family))
      4. Its native source control (Visual Source Safe) is a pain in the ass to use, and I found it somewhat unreliable.
      5. Im not a terribly big fan of VSNet's HTML designer. To be objective about it though I must admit that after changing its default view to HTML instead of design, Ive never flipped back so I have very little experience with it.
    8. Re:Why should I care? by AuMatar · · Score: 2, Insightful
      I'd like to comment on some of your pros here.

      # Easier access to IO - just try it in Java and see. It's much faster in C#


      I'm the last man in the world to support Java, but C# is optimized to windows, and probably matches the OS's file system better. I'm not sure if C# would do as well in an non-MS environment


      # Improved XML support - also a lot simpler in c#


      This is a pet peeve of mine. LANGUAGES SHOULD NOT BE DEBATED BY THEIR STANDARD LIBRARIES. Don't like a library? Download another. Buy one. I'm sure theres 50 gadzillion XML libraries floating around. Chances are you'll like one better than the default. If you want to debate languages, debate the features of the language- what does one language enable you to do natively that another doesn't, or what does one make easier?

      This is why languages should NOT have huge libraries. The designers of a language do not get everything right, especially the first time through. Invariably, third party designers who can focus in on one area can make a better API. In languages where they have huge standard libraries, like Java and C#, people tend not to bother because there's one already there. Unfortunately, that makes people end up using terrible APIs (the original Java gui, anyone?), and leads to a lot of bad comparisons between languages that have nothing to do with the languages.

      # 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.


      They'll come, C# hasn't been around as long. ALthough what the hell those things are I don't know (and beign a C programmer, never will need to. Nah!)

      # MSDN - The help system inside VS.NET is better than most languages' will ever be.


      I've found a lot of inaccuracies in MSDN, although I admit the idea is nice. But comparing webpages about the two languages in a language comparison? Just plain inane. A nice help page or not has nothign to do with a language!

      # Not the best IDE in my opinon - IntelliJ smokes Visual Studio.NET in almost every respect(except for the help).


      Again- the IDE is not a language feature. Its not really a good way to compare two languages.
      --
      I still have more fans than freaks. WTF is wrong with you people?
    9. Re:Why should I care? by Daimaou · · Score: 1

      I'm probably an average programmer (at least there seems to be an equal number of people who are better than me as those who are worse), so don't read too much into this.

      I find C# to be a great replacement language for VB. I mean, if you are currently writing an application in VB, or are thinking of using VB, or have ever said the letters V and B within close proximity of each other, then I would strongly recommend abandoning VB for C#.

      If you are not using VB, then stick with what you're using.

    10. Re:Why should I care? by Anonymous Coward · · Score: 0

      But comparing webpages about the two languages in a language comparison? Just plain inane. A nice help page or not has nothign to do with a language!

      That's a beautiful idea that doesn't have much to do with how people really write code. As a developer, if you can't find good examples of code that does real work, then you're stuck rewriting it from scratch. If MSDN provides that, and JavaDoc doesn't, then that's certainly worth talking about.

    11. Re:Why should I care? by hamster+foo · · Score: 1

      # Easier access to IO - just try it in Java and see. It's much faster in C#

      I'm not the original poster obviously, but I THINK he's referring to coding speed when he says it's faster given the first part of that statement. I don't code in either language, so I have no idea if that's actually the case.

      The rest of the comments you address are basically referencing language tools. I understand where you are coming from with all your points, but the thread was started by somebody asking about language use. In a discussion regarding language use, I think the tools available i.e. libraries, help systems, IDEs, etc. all become very relevant to the discussion as they all play a role in the use of the language.

      --
      - b
    12. Re:Why should I care? by Anonymous Coward · · Score: 0
      If you've ignored it this long, your subject line is correct -- you don't care and don't want to know about it. That's fine, but what do you actually expect to get out of some friggin' slashdot comments about it? That's about the laziest way to "find out" about anything, C# or otherwise.

      Get off your fat ass and start doing something on your own for once.

    13. Re:Why should I care? by TheAncientHacker · · Score: 1

      LANGUAGES SHOULD NOT BE DEBATED BY THEIR STANDARD LIBRARIES.

      Spoken like a true C bigot. An equally good case could be made (and should be made) that the wildly inconsistant and incompatible libraries in C (and other "small language/lots of libraries" languages) that result from hundreds on uncoordinated libs adopted with no review make the languages unlearnable and needlessly difficult to use. They also create versioning hell and the built-up folklore becomes the basis of compatibility rather than best implementation.

      While the "C-style" languages became popular, they really are not inherently the right choices.

    14. Re:Why should I care? by TheAncientHacker · · Score: 1

      Let's see. VB.NET and C# are probably 99% identical. A VB programmer switching to C# needs to learn (for no good reason) case sensitivity and obscure notation with curly braces and semicolons that they don't need to learn in VB.NET. Now, why, exactly, should a VB programmer use C# rather than VB.NET?

    15. Re:Why should I care? by AuMatar · · Score: 1

      Thats what google is for. Search for examples. Most of the time, you'll find better ones than what you will in oficial documentation anyway

      --
      I still have more fans than freaks. WTF is wrong with you people?
    16. Re:Why should I care? by AuMatar · · Score: 1

      But in this case it is. By not providing a standard, you end up with competing implementations. With competing implementations, you get innovation and evolution. With one standard implementation, you may get incremental improvements, but you're stuck with that implementation for the rest of eternity. And while I don't doubt they try to make good APIs, you still end up with only the thoughts of a very few developers going into it, and probably part time at that.

      With C style, you end up with many more developers, and with many of those either specialists in a certain field already, and all of them zoomed in on one small part of a Java/C#/python/other style API, allowing them to spend all their time and inventiveness there. You'd be VERY hard pressed to find a case where the standard implementation is better than what the community would eventually implement. Its very much like open source vs proprietary software. Open source is better because you get many more ideas cross pollinating. And when you actually get open source libraries added into the mix as well, you get vastly improved libraries.

      The different libraries make C difficult to learn and use? Not at all. An api for something like XML, socket programming, something like that can be learned in an hour. What they're doing can be figured out just from the function names, most of the time. If the API is too hard to figure out from that, its a good sign that you need to use another. Meanwhile the ill thought out and poorly designed parts of libraries in Java/python/C#/other are hard to use, and do add a lot of needless complexity to the client code. Of the two, the C solution is by FAR easier to learn.

      --
      I still have more fans than freaks. WTF is wrong with you people?
    17. Re:Why should I care? by pHDNgell · · Score: 2, Interesting

      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.

      You would consider it a feature that there aren't third-party tools to improve development and deployment?

      I have no idea what Sophia is, but I used java for a long time before hearing of struts and ant (you know, you can use Make with java). Struts takes the generic specs and makes things a lot better. They're both optional. Like many other misguided souls, I've written apps completely in jsp as well.

      Third-party options that fit into standards, make things better, but are not required are an advantage, not a disadvantage.

      --
      -- The world is watching America, and America is watching TV.
    18. Re:Why should I care? by Tim+C · · Score: 1

      Not the best IDE in my opinon

      Agreed - having used JBuilder Enterprise (7) amongst others, I find myself wishing that VS.NET had refactoring support (I have the Enterprise Architect edition, too). If you have budget for a new IDE, you might want to take a look at Borland's C#Builder. I've only briefly used it, and can't remember what sort of features it has, but I'd expect them to mirror JBuilder's, being from the same company.

    19. Re:Why should I care? by Anonymous Coward · · Score: 0

      three P languages???

      python, perl and pascal?

      OR

      prolog, psuedocode, and phone-tones

      OR

      pimples, pumpkins and plastic?

    20. Re:Why should I care? by Tim+C · · Score: 1

      But that's the point - in my experience, the examples in the MSDN (at least those that I've used) are the best that are available, or at least no worse than any other. Now, that may just be because the .net framework and C# are so new that the community haven't had time to catch up yet, but that makes little to no practical difference.

    21. Re:Why should I care? by Unordained · · Score: 1

      a note on properties: Borland Builder defines 'property' to be a new keyword for (their) c++. you can replace it with a few dozen (at most) lines of c++ code, using templates, in normal c++. it's only more trouble because you get to associate the property with get/set functions yourself in the constructor, or define your own macros. properties are neat and interesting and a lot of programmers just don't understand them ("but it's just a public variable!") when all they've seen is a get/set system.

      the more interesting addition Borland Builder made to c++ keywords was 'closure' -- i have yet to find a good way to emulate that with an object in normal c++, as you would (as i see it) want a way to make a function object that is templatable with an unknown number of template classes, so you can say that the function being called takes -these- params, and returns -that-, without deriving a new function object for every combination of parameter types used in your program.

      object_pointer->*function_pointer(parameter_lis t) ... is fine, but it's a pain to pass the two pointers around and have to, in your code, re-associate them into that statement, rather than:

      my_closure(parameter_list);

      any ideas from people who have felt the need to do this more strongly than i have?

      and am i the only one to worry that anonymous code with access to local variables is a slight danger to encapsulation? i didn't see in the spec anything saying that a class's privates would remain hidden from code sent to it as an anonymous function, the way you'd expect having done that with named functions (where the parameter list really restricts what it sees.)

    22. Re:Why should I care? by jcr · · Score: 1

      I find C# to be a great replacement language for VB.

      That sure sounds like damning with faint praise to me..

      -jcr

      --
      The only title of honor that a tyrant can grant is "Enemy of the State."
    23. Re:Why should I care? by Glock27 · · Score: 1
      python, perl and pascal?

      I presume he meant Python, perl, and php. He should have just said. ;-)

      --
      Galileo: "The Earth revolves around the Sun!"
      Score: -1 100% Flamebait
    24. Re:Why should I care? by Glock27 · · Score: 1
      Easier access to IO - just try it in Java and see. It's much faster in C#

      Did you try using NIO? I suspect any C# speed advantage has been largely negated.

      Also, if I/O speed remained a serious concern, I could simply write JNI wrappers for the C open(), write(), close() etc. functions. That would be within a few percent of raw C I/O speeds, on all the platforms Java supports...instead of just Windows.

      --
      Galileo: "The Earth revolves around the Sun!"
      Score: -1 100% Flamebait
    25. Re:Why should I care? by TheAncientHacker · · Score: 1

      Nonsense. That would be the case if there were no dependancies built AND if all the effort put into competing libs weren't wasted on relgious wars AND if the egos involved would allow for best of each case revisions AND if there were total consistancy between each lib AND if each time you needed some functionality you didn't have to research 20 competing implementations and test each one for compatibility with each other.

      I'll stick with the assertion that a single unified language provides a simple integrated method of programming where improvements are driven not by "see how clever I am" but by actual need for product improvement.

    26. Re:Why should I care? by Daimaou · · Score: 1

      It was meant to.

    27. Re:Why should I care? by Daimaou · · Score: 1

      Well, let's see. Where I live, the difference between a VB programmer and a C# programmer is about $20,000.00 annually.

      Of course, you may code in whatever language pleases you, but if learning to use the shift key and the curly braces offers that kind of monetary return, I think it is well worth the effort.

    28. Re:Why should I care? by Anonymous Coward · · Score: 0

      Whidbey supports refactoring.

    29. Re:Why should I care? by Anonymous Coward · · Score: 0

      That $20K is easy to explain if you look at the programmer's responsibilities rather than the language.

      In other words, when Joe VB starts coding his simple form & grid DB frontends in C#, he's not magically going to get a larger wage. If anything this is going to be downword pressure on Joe Enterprise OO's salary.

    30. Re:Why should I care? by Anonymous+Brave+Guy · · Score: 1
      LANGUAGES SHOULD NOT BE DEBATED BY THEIR STANDARD LIBRARIES.
      A nice help page or not has nothign to do with a language!
      Again- the IDE is not a language feature.

      I think perhaps you're missing the point. Languages are just tools, and what matters to a developer (as opposed to an academic) isn't the fine print in a spec, it's what you can do with the the tool, and whether it helps you to do you job more or less effectively than any other.

      In this case, a good IDE including good reference material makes a huge difference. A lot of syntax and complexity that would be awkward if your only tool was a simple text editor can become useful and powerful when your development environment helps.

      The same goes for libraries. My long-held personal view is that a small "kernel" library to deal with basics and provide a framework for more advanced features works best, preferably combined with a public repository of extensions that integrate into those frameworks. Perl and CPAN is a good example; (La)TeX and CTAN is another.

      Nevertheless, let's not kid ourselves here. People didn't switch to Java because it had GC, at least not just because of that. They switched because it had an enormous library that let you do a great deal of common, routine programming tasks with almost no code, and they did it when C++ was still trying to work out what a string was. For most developers working on so-called business apps -- and that's a very significant fraction of the development world -- such a library can be a huge time-saver. It may not be the best idea, but sometimes things are good enough, and that's what matters to people in that position.

      I think reducing this discussion to merely comparing language technicalities would lose most of its value. Yes, the features of a language itself are important, but the relevant thing to developers is what you can do with the whole, not just theoretical advantages or disadvantages you see by comparing parts in isolation and out of context.

      --
      If you disagree, post your argument. (-1, Overrated) isn't your personal censorship tool for views you don't like.
    31. Re:Why should I care? by anomalous+cohort · · Score: 1

      I don't agree with the poster's pros or cons but the introductory remark, concerning targeting Java, seems to be correct.

      More accurately, C#/.NET is targeting the masses of VC++/COM developers who were abandoning their platform for Java.

    32. Re:Why should I care? by Daimaou · · Score: 1

      I don't believe that is the case. VB has a corporate stigma of sucking, and of being a beginning level language; both accurate evaluations in my opinion. That is why VB jobs don't pay very well. On the other hand, C# is seen as being a real language, and therefore C# jobs generally pay better; at least for now. If Joe VB can apply for and get a C# job, more likely than not Joe VB will see a big raise.

      Personally, I don't care much for either language because neither one of them do what I want; or at least fulfill my needs in the way I prefer.

  17. Code Name by boatboy · · Score: 2, Insightful

    Actually, Whidbey is the code name for the next release of Visual Studio and .NET Framework. C# is just a part of it. http://msdn.microsoft.com/vstudio/productinfo/road map.aspx#whidbey

  18. I think you can't spell. by Anonymous Coward · · Score: 0

    And I'm right. Look at your sig.

    1. Re:I think you can't spell. by Anonymous Coward · · Score: 0

      Maybe it was Henry Ford who couldn't spell?

  19. Re:That's great by eln · · Score: 1

    Microsoft is hardly the only company releasing proprietary programming languages. Software AG's Natural is the one that comes most readily to my mind, but there are several others.

  20. Re:Who gives a shit about C# by Anonymous Coward · · Score: 4, Insightful

    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.

  21. Does adding every ingredient make it better? by Qzukk · · Score: 1, Insightful

    Seriously, do they think that if they take every little feature of every other programming language, they are actually going to come out with something useful?

    All they are going to get is a language that nobody will understand all of because its just too complex. Are they just out to sell the massive books and training courses that will be needed in order to learn C#2? 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?

    --
    If I have been able to see further than others, it is because I bought a pair of binoculars.
    1. Re:Does adding every ingredient make it better? by user+no.+590291 · · Score: 1

      C#: The PL/I of the 21st century :).

    2. Re:Does adding every ingredient make it better? by Tom7 · · Score: 5, Insightful

      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.

    3. Re:Does adding every ingredient make it better? by Anonymous Coward · · Score: 0

      Good universities, that is.

    4. Re:Does adding every ingredient make it better? by saden1 · · Score: 1

      C++ - C-- = broken C++?

      --

      -----
      One is born into aristocracy, but mediocrity can only be achieved through hard work.
    5. Re:Does adding every ingredient make it better? by Qzukk · · Score: 3, Insightful

      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.
    6. Re:Does adding every ingredient make it better? by Zebbers · · Score: 1

      That's crazy. Universities don't teach programming languages except as tools to teach more important concepts.

      HAH

    7. Re:Does adding every ingredient make it better? by Laser+Lou · · Score: 1

      C++ - C-- = broken C++?

      C++ - C-- == 0

      --
      No data, no cry
    8. Re:Does adding every ingredient make it better? by rixstep · · Score: 1

      I think you got something there, Mr Qzukk...

    9. Re:Does adding every ingredient make it better? by yoshi_mon · · Score: 3, Insightful

      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!
    10. Re:Does adding every ingredient make it better? by dimator · · Score: 1

      C++ is insanely complicated and broken, and is popular. Perl is insanely broken and complicated, and it is popular.

      What do you mean by broken? Broken implies to me "not working," and last I checked, both of those languages work predictably.

      Complicated is mostly opinion-based, so I'd love you know what "not complicated" languages you're comparing them to.

      --
      python -c "x='python -c %sx=%s; print x%%(chr(34),repr(x),chr(34))%s'; print x%(chr(34),repr(x),chr(34))"
    11. Re:Does adding every ingredient make it better? by dolo666 · · Score: 1

      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?
      At first glance, this seemed like a troll. But then I got to thinking... you never know. It could be a plot by Microsoft to soak up all the time of programmers, so they don't have time for PHP & MySQL love.

    12. Re:Does adding every ingredient make it better? by Anonymous+Brave+Guy · · Score: 1

      No, he was right the first time. It's undefined behaviour, which is pretty much always broken.

      Sorry, couldn't resist.

      --
      If you disagree, post your argument. (-1, Overrated) isn't your personal censorship tool for views you don't like.
    13. Re:Does adding every ingredient make it better? by deranged+unix+nut · · Score: 4, Insightful

      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.

    14. Re:Does adding every ingredient make it better? by transiit · · Score: 1

      It's been done before. As far as I can tell, the current scoreboard is as follows:

      The good: Perl
      The bad: C#
      The ugly: PL/1

      -transiit

    15. Re:Does adding every ingredient make it better? by God!+Awful+2 · · Score: 1


      C++ - C-- == 0

      I doubt it. Try running this:

      int C;
      printf("%d\n", C++ - C--);

      I don't have a compiler on this machine, but I'll wager 10 to 1 the above code will print "-1". (At least if you run it on gcc.)

      -a

    16. Re:Does adding every ingredient make it better? by Randolpho · · Score: 4, Insightful

      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
    17. Re:Does adding every ingredient make it better? by delirium28 · · Score: 2, Informative
      >That's crazy. Universities don't teach programming languages except as tools to teach more important concepts.

      Not true. Check out University of Waterloo as an example of Microsofts approach to exposing C# to a new generation of developers. Well, engineer's, but close enough. ;-)

      --
      Who is John Galt?
    18. Re:Does adding every ingredient make it better? by Anonymous Coward · · Score: 0

      "That's crazy. Universities don't teach programming languages except as tools to teach more important concepts."

      You are kidding right? My college teaches every programming class from CS101 to CS412-GUI_design with Java. You can get your BSCS without ever using C, VB, scheme, etc. Just Java. And this is a major American university with over 15,000 students.

    19. Re:Does adding every ingredient make it better? by An+Onerous+Coward · · Score: 1
      "That's crazy. Universities don't teach programming languages except as tools to teach more important concepts."
      Which university do you go to? I'll transfer.

      Seriously, aside from the occasional muttering about "algorithmic complexity," I think most of my courses have focused entirely on the language being used. The system is boke. It would take a few million in grant money just to get the 'r' installed.
      --

      You want the truthiness? You can't handle the truthiness!

    20. Re:Does adding every ingredient make it better? by Anonymous Coward · · Score: 0

      Buffer overflows are insanely easy to avoid in new C++ code: use std::string.

      But then it's not terribly hard to avoid buffer overflows in C either, just so long as you're not drunk and you're aware that the standard library functions are moronic.

      Fixing them in existing code, now that's where things get tricky.

    21. Re:Does adding every ingredient make it better? by Anonymous Coward · · Score: 0

      So C and C++ are "broken" languages because programmers can introduce security flaws? Right. I'll have to remember that...blame the language instead of the ineptitude of the programmer.

      Remember that a programming flaw is still a flaw regardless of whether it's common or not. Anything exploitable can be exploited. It is on the shoulders of the programmer to code accordingly whether it's getting it right the first time or writing test cases to make certain he did get it right the first time.

    22. Re:Does adding every ingredient make it better? by linuxtuba · · Score: 0
      >That's crazy. Universities don't teach programming languages except as tools to teach more important concepts.

      I wish that was the case. I attend the University of Washington, and am in their computer science program. They have just transitioned their entire department to Java. Yes, they do teach general concepts, but most of your time is wasted making "cute little interfaces" in Swing/Java2D. In a perfect computer science class, the implementation language wouldn't matter as long the algorithm you wanted to implement was implementable. I am planning on writing some letters to the UW computer science department telling them that this was a bad idea. Languages like Java, although they show the OOP paradigm, are so high level that they do not lead to a good understanding of things. The TA for my computer science class, wasn't sure if things were passed by value or reference in Java. That is partially her fault, but also her education's fault for choosing a language that lends itself to not understanding what is going on. Another thing I dislike about college computer science is that everything operates under the implicit assumtion that OOP is the paradigm to end all paradigms, and that there is not a better way to solve a problem than with objects. But, back to the point. Most Universities, assuming from my experience at UW, waste a lot of time on the cruft of Java or other high level languages to make GUI's and displays for algorithms that are generally simple and understandable.

    23. Re:Does adding every ingredient make it better? by Laser+Lou · · Score: 1

      int C;
      printf("%d\n", C++ - C--);

      I don't have a compiler on this machine, but I'll wager 10 to 1 the above code will print "-1". (At least if you run it on gcc.)


      I get a 0 in Visual C++ 6. However, it returns 0 even if I use --C instead of C--. I suppose that it really is undefined behavior.

      Remember to intialize C.

      --
      No data, no cry
    24. Re:Does adding every ingredient make it better? by Anonymous Coward · · Score: 0

      Here is how old I am ... when in school we were taught that C was a HIGH level language, with all those cooky "functions" and things.
      BASIC (with manly line numbers and the `goto` statement) was a mid-level language.
      And, of course, insane macho people programed in a LOW level language like assembly.

    25. Re:Does adding every ingredient make it better? by lightsaber1 · · Score: 1
      Wow, I don't know where to begin.

      First of all, engineers don't do, care, or even think about software development. In an area where we care (computer science), we wouldn't even consider C# -- if our faculty had signed that deal there would have been riots (okay, whatever us geeks do instead of riot, I don't know, we'd frag them or something).

      All computer scientists (at UW anyways) would object to the "close enough" comment. We are not in any way engineers, nor would we want to be.

      In the school of computer science, we are not taught languages except as tools to teach more important concepts, as the parent of the parent suggests. Okay, there is one introductory course which you can skip just in case you haven't used the language (Java) that they want to use in the next few classes -- cuz they don't want to waste time on language specifics, so that still fits the statement.

      Engineers do not develop software, they don't care about the higher comments. Teaching them C# is, I'm guessing, simply to a) give them an idea of how software works so they know what the hardware needs to do, and b) appease MS so they can get some $$$

      Software Engineers are an exception. They are a hybrid of engineer and computer scientist. They have no one faculty, and they are not taught C# (yet). They don't actually matter anyways.

    26. Re:Does adding every ingredient make it better? by Arker · · Score: 1

      C is a low level language and makes no bones about it being such.

      /me rolls on the floor laughing, beer spurting from my nostrils.

      --
      =-=-=-=-=-=-=-=-=-=-=-=-=-=-
      Friends don't let friends enable ecmascript.
    27. Re:Does adding every ingredient make it better? by God!+Awful+2 · · Score: 1

      Hmmm... It shouldn't matter what the initial value of C is. Perhaps the optimizer messes with the results.

      I know on gcc that this code will print -10:

      int C=0;
      cout C++ C--;

      -a

    28. Re:Does adding every ingredient make it better? by TheAncientHacker · · Score: 1

      Absolutely correct. That a language could be developed in the late 1960s that had no native concept of a string or a fixed length input buffer is quite insane. That it could be "improved" in the 1980s without fixing that is even more insane. Of course, the best insanity was Netscape coming out with LiveScript (later renamed JavaScript) in the mid 1990s and not correctly handling the Y2K date math.

    29. Re:Does adding every ingredient make it better? by deranged+unix+nut · · Score: 1

      Yes, the programmer ultimately must bear responsibility, as they *could* write it correctly.

      My point is that even though a language may have the feature equivalent of a cross-cut saw, you wouldn't want to use that for finish work, and even though a language may have the feature equivalent of a dental probe, you wouldn't want to use that to cut down a tree.

      Use the right tools for the right problems.

      Sure, bad code can be written in any language, but the barriers can be lowered for writing good code.

      C is a great language for low level operating system code, I just wish people would stop writing end-user applications in it!

      C++ is an interesting language too, but I see too many people doing too many stupid things with it too.

      Frankly, the features of these lanuages are handy when you need them, but most programmers don't need most of the features most of the time. I still don't know if .NET helps keep the toys in the language from getting in the way of the work, but it can't be worse than some of the alternatives.

    30. Re:Does adding every ingredient make it better? by ibarrac · · Score: 1

      C++ is a power tool. It's main failing is that, in the tradition of C and Unix, it doesn't restrict you. Even from shooting yourself in the foot. But the power! The POWER! In C++, you can go as low level as you like and, using higher level libraries, as high as you like. Most people never really learn it well enough to use it properly, program in it at too low a level, treating it as a glorified C, and predictably blow off a leg. They come out shaken from the experience, and call it things like "insanely complicated" and "broken". Yes, the type declaration syntax is a bit insane, but can be tamed with the proper use of typedefs. Use of the preprocessor should be kept to a minimum. It doesn't help that compilers that don't fully implement the standard (like VC++ 6.0) often make it necessary to use the C preprocessor instead of templates for generic programming. Having to #include, then link is arguably less advanced than the Java or C# more elaborate methods of referencing other classes, and managing their dependencies. But with the proper level of abstraction, C++ becomes a much safer language, for those that want the safety. You don't have to use raw pointers if you don't want to. Use ref-counted or garbage collected pointers with the proper library. Use std::string instead of char[]. Don't use printf. C# and Java are nice, but there is still an imprenetrable veil between me and the machine that constrains me. I respect and will use these languages, but I am still addicted to the power of C++.

    31. Re:Does adding every ingredient make it better? by deranged+unix+nut · · Score: 1

      Then why are the "moronic" standard c libraries still standard?

      We have known that they are "moronic" for decades.

      If it is all insanely easy to avoid, why do so many people continually fall into the same traps over and over, even after months of training in how to avoid security problems?

      Why do universities still teach students to use the standard libraries, and why has the buffer overflow been a huge source of security problems for the past couple decades (probably longer) if it is so easy to avoid?

      It is stupid that languages force programmers to routinely manage tasks that they should be able to safely ignore. That is why we have high level languages and don't use assembler for everything anymore.

    32. Re:Does adding every ingredient make it better? by Anonymous Coward · · Score: 0

      Well, it's impossible to cause a buffer overflow in Perl. The entire Perl philosophy is to make the easy stuff easy and the hard stuff possible.

    33. Re:Does adding every ingredient make it better? by TheAncientHacker · · Score: 1

      I think that's actually: The Good: PL/AS The Bad: C The Ugly: C++

    34. Re:Does adding every ingredient make it better? by Anonymous Coward · · Score: 0

      It's amusing how ignorant you demonstrate yourself to be by your obviously fallacious claims. Superficial knowledge of the resources used to construct software is more harmful than helpful. Ignoring your philisophical babble, you've actually managed to not mention a single bit of insight as to what you perceieve to be important, but then I don't expect much from someone that hasn't written a program larger than 5kloc and needs to consult tutorials on the Internet on a regular basis just to cobble together half-assed programs that don't properly handle errors or non-obvious cases.

    35. Re:Does adding every ingredient make it better? by TheAncientHacker · · Score: 1

      No. C was designed as a structured assembler for an obsolete DEC PDP and makes no bones about being anything else. Now, of course, if you aren't using it as an assembler for a DEC PDP then perhaps you are using the wrong tool for the job.

    36. Re:Does adding every ingredient make it better? by jcr · · Score: 1

      C++ is insanely complicated and broken, and is popular. Perl is insanely broken and complicated, and it is popular.

      I agree with you on the former, but not the latter. Perl at least has real strings and arrays instead of pointers trying to pretend to be strings and arrays, and it really is up to you to decide how much of Perl's potential complications you want to use.

      --
      The only title of honor that a tyrant can grant is "Enemy of the State."
    37. Re:Does adding every ingredient make it better? by Tom7 · · Score: 1


      The point of a computer science education is no more to make you ready for a programming job than a degree in mathematics is to make you ready to be an accountant.

      Anyway, I didn't say you only need a superficial understanding of the language. A good program teaches you what you need to know to effectively make use of the concepts of the class (if the class is a programming class at all!) but does not waste time going through each feature in the language/toolkit like some tour of the zoo. With a solid foundation it's easy to pick that other stuff up.

    38. Re:Does adding every ingredient make it better? by Glock27 · · Score: 1
      The TA for my computer science class, wasn't sure if things were passed by value or reference in Java. That is partially her fault, but also her education's fault for choosing a language that lends itself to not understanding what is going on.

      First of all, the Java docs are quite clear on all Java entities being passed by value. It just happens that the "value" for each Java object is the reference to it. ;-) Java in no way discourages you from understanding all the details of how it works. It really doesn't "hide the machine" any more than straight C does.

      You can't write a "swap" function in Java to swap the values of two primitives. However, unless you write a "swap" function, things just pretty much work as you'd expect. That TA might still be a better programmer than you. :-)

      I'm guessing from the tone of your rant that you'd prefer C or other lower level languages to be taught in undergraduate CS studies. I disagree, mainly since 90%+ of all the grads will be working in a "high level language" where algorithms and data are the important issues, not instruction ordering or word size. There are classes outside the core curriculum, if you think you want to specialize in embedded programming or similar areas (many who go this route do an EE degree instead though).

      You might also consider a Computer Engineering degree - you'll get plenty of low-level exposure there. ;-)

      --
      Galileo: "The Earth revolves around the Sun!"
      Score: -1 100% Flamebait
    39. Re:Does adding every ingredient make it better? by Tom7 · · Score: 1

      What do you mean by broken? Broken implies to me "not working," and last I checked, both of those languages work predictably.

      Some examples of why C++ is broken:
      - Compilation is an impossible task. By that I mean that there are some legal programs that cannot be compiled, and some legal programs that can be compiled, and no compiler can tell them apart. (This is due to the Turing-complete template system.)
      - There is exactly 1 standard-compliant implementation of C++ that exists, and you probably don't use it. The standard is so convoluted that most implementors just make up their own C++-like language to implement instead.

      Why Perl is broken:
      - Compilation is impossible, as above.
      - There exists one implementation, which defines the language.
      - Seriously, you don't think perl is broken?? (I don't program in it, so I don't have any specific examples, but they always come up with my programming language friends who dare...)

      Complicated is mostly opinion-based, so I'd love you know what "not complicated" languages you're comparing them to.

      I think Java is a less complicated language. It's kind of tedious to program in, though, because it lacks certain useful features. (Two of which are apparently being added in C#) I think SML is a fairly simple language, but one that is quite powerful despite its simplicity. In fact, I like to program in it much more than in C++. (However, it remains difficult to learn for many programmers because there is not much that can be learned by analogy with, say, C.)

    40. Re:Does adding every ingredient make it better? by Tom7 · · Score: 1

      Power also includes the ability to isolate faults, something that C++ absolutely does not provide. Any module in your program can screw up the memory space of any other one. To me, this is more important than being able to "access the machine", something which is available anyway in any real implementation of a general purpose language, and something which is hardly ever necessary in an application.

    41. Re:Does adding every ingredient make it better? by Tom7 · · Score: 1

      Which university do you go to? I'll transfer.

      CMU. It's in my web link right there, man.

    42. Re:Does adding every ingredient make it better? by mattgreen · · Score: 1

      You must be new here, we don't let people insult C and walk out alive.

    43. Re:Does adding every ingredient make it better? by Tom7 · · Score: 1

      You are kidding right? My college teaches every programming class from CS101 to CS412-GUI_design with Java. You can get
      your BSCS without ever using C, VB, scheme, etc. Just Java.


      I said they don't teach languages except as tools to teach more important concepts. The fact that they never force you to use any language seems to support that claim--the language is just a tool, so they might as well standardize on a tool.

      However, it is hard to do system tasks like OS programming in Java, so it's a poor tool. If your program doesn't require any system level programming, that's kind of a bummer.

    44. Re:Does adding every ingredient make it better? by sosume · · Score: 1

      ...blame the language instead of the ineptitude of the programmer If there are litterally thousands of programmers using that language, all making this same error which is not intercepted by the language or the compiler, then yes: the language is flawed. And it is the fault of the programmer for choosing that language if things become messed up. Remember that a programming flaw is still a flaw regardless of whether it's common or not Again: if the flaw is very very common, tricking many programmers, then at least the compiler should warn. If the compiler cannot generate such a warning, the language is flawed and thus imperfect. And, as a result, people should continue developing new languages without any such flaws. Anything exploitable can be exploited Really? The fundamental flaw in C and C++, IMHO, is that most large projects, after a while, become really bloated with ugly hard-to-read code and many design issues which in time become harder and harder to tackle. The only reason to use C is for pure speed. C# is IMO a pretty elegant solution by wrapping all Win32 C functions and structures in 'guaranteed' safe objects.

    45. Re:Does adding every ingredient make it better? by Anonymous Coward · · Score: 0

      So don't use things that can corrupt memory like that.

      That's the thing about C++. If you want a nice safe place you can do that (smart pointers, garbage collector, etc.). You take a performance hit but it's not any slower than Java or C#. And if you don't want a safe environment you can have maximum performance (both in memory usage and raw speed) which is something Java and C# can only dream of.

      C++ can do anything in a clean way, you just have to know how to use it.

    46. Re:Does adding every ingredient make it better? by Tokerat · · Score: 0, Troll

      That's crazy. Universities don't teach programming languages except as tools to teach more important concepts.
      You've been out of school for a while, haven't you?
      --
      CAn'T CompreHend SARcaSm?
    47. Re:Does adding every ingredient make it better? by Tom7 · · Score: 1

      You've been out of school for a while, haven't you?

      No, I finished in CS undergrad in 2001 and have been a grad student since, and I have TA'd several classes since then.
      Perhaps it's not true at all schools, but it *should* be.

    48. Re:Does adding every ingredient make it better? by Tokerat · · Score: 1

      Perhaps it's not true at all schools, but it *should* be.
      Now I agree with you.
      --
      CAn'T CompreHend SARcaSm?
    49. Re:Does adding every ingredient make it better? by Nevyn · · Score: 1
      Some examples of why C++ is broken:
      Compilation is an impossible task.
      There is exactly 1 standard-compliant implementation of C++

      Well personally, I detest C++. And it is fair to be annoyed that it's only been had a standard for 4 years ... and almost noone has caught up with it fully yet, however most modern implementations are very close. As far as I know there are no legal programs that don't compile (there are ambiguities in the syntax, but they were known about and documented by the std. -- and so not legall IMO). And even if you considered something like "foo<bar<X>>" a legal program, that still doesn't make it impossible to compile (it's even possible someone could work out how to make a C++ compiler work out what to do with it).

      Why Perl is broken:
      Compilation is impossible, as above.
      There exists one implementation, which defines the language.

      However I use perl quite a lot, it is a nice languages that does what it aims to do well, very well. It is different in that it has a better defined goal than most languages, which nodoubt why it reaches a goal (certainly lisps goal of solve the same problems as everyone else, but in a different way and use lots of brackets doesn't impess as many people). As you say there is no std. and only one viable implementation, but as a difference to the C++ problem everyone uses that implementation. However the "compilation is impossible" statement makes no sense to me, I'm not sure if you are trying to complain about the syntax of the lanuage (which is the whole point of the language) or that the only implementation is mainly a bytecode interpreter.

      --
      ustr: Managed string API with ave. 44% overhead over strdup(), for 0-20B
    50. Re:Does adding every ingredient make it better? by Tom7 · · Score: 1

      As far as I know there are no legal programs that don't compile

      ???

      that still doesn't make it impossible to compile

      No, you don't understand what I'm saying. I am saying that some legal C++ programs (ie, those that use template metaprogramming) cannot be compiled (they instruct the compiler to loop forever) and that it is not possible for a compiler to distinguish those programs from the programs that can be compiled successfully.

      If you think perl is nice, well, perhaps there is no hope...

    51. Re:Does adding every ingredient make it better? by Nevyn · · Score: 1
      No, you don't understand what I'm saying. I am saying that some legal C++ programs (ie, those that use template metaprogramming) cannot be compiled (they instruct the compiler to loop forever) and that it is not possible for a compiler to distinguish those programs from the programs that can be compiled successfully.

      Those aren't legal C++ programs, the C++ std. places a limit on how much recursion you can use in a template. Anything over that limit is, by definition, not a legal std. compliant C++ program. The C std. places limits on the number of nested blocks allowed in a function, and the number of times a macro expansion can recurse. Lisp dialects place limits, either implicitly or otherwise, on recusion level of functions.

      Or maybe you're saying that the error message is't helpful when this happens? But that's also true if you forget to close a macro call in C or forget to close a string constant, in C or lisp.

      If you think perl is nice, well, perhaps there is no hope...

      You just said, "I don't program in it, so I don't have any specific examples". If someone said lisp is just python with too many brackets, that would be just as bad ... and there are a lot more perl programers and code out there.

      perl's idea of TIMTOWTDI does lead to a very free syntax compared to say scheme, however I have written a lot of nice readable code in perl ... and I've also read a lot of nice perl code. Sure I've also seen my share of unreadable crap in perl, but probably more so in plain C (which is only free in the use of whitespace, but some people don't even need that).

      C written in perl can be especially bad, more so than even lisp written in perl. But then C written in scheme isn't pretty either.

      --
      ustr: Managed string API with ave. 44% overhead over strdup(), for 0-20B
    52. Re:Does adding every ingredient make it better? by Anonymous+Brave+Guy · · Score: 1

      I have some sympathy for your point of view, but I'm afraid you give universities way too much credit.

      Universities are right to teach important concepts [...] like software engineering, project managment, [...]

      Yep, because academics are well-known for their firm grasp of both software engineering (do you appreciate what that term implies? -- they often don't) and project management. Not.

      Academics teaching within their research interests are usually the best guys in that particular business. Academics who've only read a couple of books in preparation for giving a lecture course to postgrads with industry experience are likely to get schooled in fairly short order.

      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.

      I'm sorry, but that simply isn't true. And I speak as someone with both a formal, academic CS background and plenty of experience in the trenches.

      Academics who claim they can get up to the standard of an old pro in a weekend are deluding themselves. Yes, general skills are very important, far more so than any specific language or tool. Yes, someone who's familiar with one imperative language can probably learn another with relative ease. But that still doesn't make up for the lack of experience with the things that matter in an industrial context: you won't know the idioms, the special cases, the gotchas, the workarounds for the gotchas, the sometimes vast and sometimes complicated standard libraries, where to go when those libraries are inadequate for your needs, where to find good quality reference material on the language, its library and ongoing developments in the industry...

      There is a difference between being familiar enough to knock up a basic program or maintain someone else's simple code, and having a sufficiently broad and deep knowledge of the tool to write good code in realistic contexts independently. That difference is about 1-2 years of regular use backed up by a reasonable amount of reading around the subject, IME.

      Any monkey with a keyboard can whip out a Visual Basic app.

      Any monkey with a keyboard can whip up "Hello, world!" in C++ as well, and usually with only two basic errors that will get past most compilers. The same monkey, asked to do a significant piece of work, would be a serious liability, particularly if they were arrogant enough to assume from their academic background that they understood the tool they were using and could do no wrong because they "knew how to program".

      --
      If you disagree, post your argument. (-1, Overrated) isn't your personal censorship tool for views you don't like.
    53. Re:Does adding every ingredient make it better? by Randolpho · · Score: 1
      I have some sympathy for your point of view, but I'm afraid you give universities way too much credit. ... Yep, because academics are well-known for their firm grasp of both software engineering (do you appreciate what that term implies? -- they often don't) and project management. Not.
      Perhaps I do give universities too much credit. I've only attended two in my own academic career, and although both CS departments only hired teachers with both a doctorate and several years of practical experience in the field of their specialty (which includes programming experience for those who teach programming-related theory classes like software engineering), I did rather extrapolate from their very good hiring practices to the rest of the country/world. My bad. I should not have assumed that Universities know what they're doing.
      There is a difference between being familiar enough to knock up a basic program or maintain someone else's simple code, and having a sufficiently broad and deep knowledge of the tool to write good code in realistic contexts independently. That difference is about 1-2 years of regular use backed up by a reasonable amount of reading around the subject, IME.
      I'll grant you that difference, and I believe I acknowledged it in my post. I disagree with your 1-2 year assesment, however. In my own experience, it's much smaller.
      --
      "Times have not become more violent. They have just become more televised."
      -Marilyn Manson
    54. Re:Does adding every ingredient make it better? by Tom7 · · Score: 1

      From what I understand, such a limit has nothing to do with compliance...

      (from the C++ ANSI/ISO std.) "The bracketed number following each quantity
      is recommended as the minimum for that quantity. However, these quantities are only
      guidelines and do not determine compliance.

      [...]

      - Recursively nested template instantiations [17]."


      In any case, you gotta admit, this is the worst kind of "fix" for such a problem.

      The problem with perl extends far beyond its syntax!

    55. Re:Does adding every ingredient make it better? by 4of12 · · Score: 1

      Amen. I agree: the right tool for the job.

      The best service that a good CS education could provide is a programmer that has been thrown into several different programming languages and environments. Where learning a language is an incidental journey on the way to solving a problem. I remember courses where I was expected to pick up all kinds of ancillary knowledge so that I could create a Turing machine in Pascal. (Such as learning Pascal, for example.)

      The strengths and weaknesses of languages become much more apparent after you've been experiencing more than one of them.

      The best of the Olympic programmers view the world from high, where they can see beyond the walls of what many take for granted as the comfortable walls of the maze they live in.

      We need more such programmers to help drive the industry in directions that make sense for programmers.

      Business programming, for the sake of cost, often simply drives along popular routes that were yesterday's frontiers. And certainly the businesses hiring CS grads will want people capable for running along those paths proficiently. But it would be a disservice to students if they were only given as much as what businesses want Right Now from programmers.

      If programmers only get trained for todays technology, they'll do great for some years, but will have a harder time adapting to the environment a couple of decades in the future which will look radically different (ask anyone that's been here in 1982).

      My advice to CS students:

      Look for fewer capital letters in course titles and lots of different capital letters in programming assignments.
      --
      "Provided by the management for your protection."
    56. Re:Does adding every ingredient make it better? by Tom7 · · Score: 1

      So don't use things that can corrupt memory like that.

      You can't just not use it, because it is easy to screw up, even when you program the way you suggest. Or, other programmers in your project can screw up. Or, the libraries you use can screw up. C++ does not provide a way to isolate faults to a specific module. (Unit testing can help, but that is not part of the language.)

      Also, garbage collection in C++ is typically worse than in languages with built-in support, because the GC has to be conservative. So you do indeed get worse performance than in a language built for it.

      C++ can do anything in a clean way, you just have to know how to use it.

      For example, C++ has terrible support for functional programming, because it lacks nested anonymous functions. Yes, you can code this up, like you can code up any feature in any language, but it is not clean. Simulating algebraic datatypes with class hierarchies is equally ridiculous.

    57. Re:Does adding every ingredient make it better? by Tom7 · · Score: 1

      Nobody is saying real-world experience isn't important, just that University is not the place to get it. (And nor should it be!)

  22. Re:Who gives a shit about C# by Anonymous Coward · · Score: 0

    Certainly not Boeing I can tell you that. The other major beast in Seattle area says no to .NET. Without a question, Boeing has taken sides and is a Java player.

  23. thats a lot of angle brackets by deputydink · · Score: 1

    i'm about a third of the way through the doc and it made me realize how much i hate reading language specs.

    That being said, the idea of "inference" of type arguments seems cool and usable, if not a bit abusable.
    I don't know if its just me, but when did templates get cool again? I love templates in C++ and its interesting that java's introducing them and C# now is really focusing on them. That being said, i can't see a place where Partial types (where you can break a classes implementation into move than one class) could be really so usefull.

    One thing i couldn't get over with C# is that its *so* much like C++, with all the syntax, keywords and such but with none of the speed. At work i'll use java to do simple stuff i could have done in C++ only cause java's just simpler. If java had the mass of features that C# has, i prolly wouldn't ever use them. but, then again, i'm a dba.

    1. Re:thats a lot of angle brackets by Anonymous Coward · · Score: 0

      type inference is 25+ years old. Hindley, Damas, Milner, and Girard are some relevant names.

    2. Re:thats a lot of angle brackets by Anonymous Coward · · Score: 0

      The one place that I think partial types will be very useful is in the implementation of graphical designers. The designer generated code can now be segregated from the user defined code for a class. While regions (and code folding) were introduced to aid with this, this would help further.

      Another functional example would be with ASP.NET specifically. Currently ASP.NET supports two models. You can either inline your code in the aspx file which derives from the Page class implicitly, or you can create a library that holds a class that derives from the Page class and then inherit that from the aspx file. The earlier model doesn't separate the logic from the presentation. The latter does, but at the expense of OOP since the aspx could only call a function if it is protected or public. With partial types the aspx and a cs would compile together which can seperate the logic from the presentation while preserving OOP since it will form one class and the aspx can call a private member of the cs.

    3. Re:thats a lot of angle brackets by Anonymous Coward · · Score: 0

      The designer generated code can now be segregated from the user defined code for a class. While regions (and code folding) were introduced to aid with this, this would help further.

      This sounds a lot like Objective-C categories. Does C# give you the ability to add implementation to an existing class at run-time, or is this entirely a compile-time feature?

    4. Re:thats a lot of angle brackets by Anonymous Coward · · Score: 0

      Partial types are used when machine generated code needs to be extended at compile-time by user-written code.

      For example, you could auto-generate C# drawing code based on the definitions in a XUL file. Once you have this auto-generated code, you may want to extend this with your own, custom-written code. One approach is to use inheritance and derive from the auto-generated file. However the interface to these files now has protected members which you never really wanted to make public - the members are only there so the subclass can access properties of the super-class. Partial types tidy this mess up by joining together several portions of code at compile time.

      Java doesn't care about this because it has never been high on Sun's agenda to produce a good Component-based language. Beans are a hack. C# introduced concepts such as the 'internal' accessibility modifier with the aim of creating a great language for writing components. Partial types are another way of keeping the component interface clean and pure.

    5. Re:thats a lot of angle brackets by Anonymous Coward · · Score: 0

      Type inference exists in at least two of the best type-safe languages around : Haskell and Objective Caml.

      For those of you who have never heard of them, Haskell has impressed Guido von Rossum ( the designer of Python ), and O'Caml is a variant of ML, and one of the fastest existing languages (faster than C++). Both are highly expressive, type-safe, faster and more compact than C#. Maybe it's time for you guys to have a look at them.

      Incidentally, the Haskell designers have all been hired by Microsoft Research. No wonder type inference begins to appear in C#2.

  24. Ruby Continuations by Llywelyn · · Score: 2, Informative

    I'm still not sure why one would use continuations for well-designed code (kind of like labels in C++). I think the Ruby FAQ has the best statement on continuations.

    -----
    Ruby's continuations allow you to create an object representing a place in a Ruby program, and then return to that place at any time (even if it has apparently gone out of scope). Continuations can be used to implement complex control structures, but are typically more useful as ways of confusing people.

    --
    Integrate Keynote and LaTeX
    1. Re:Ruby Continuations by saden1 · · Score: 1

      it's basically GOTOs....that is so 1970's.

      --

      -----
      One is born into aristocracy, but mediocrity can only be achieved through hard work.
    2. Re:Ruby Continuations by wjsteele · · Score: 1

      I don't know what Ruby is or what a Continuation is, but based on that defination, it sure sounds like some form of Function Pointer or Delegate to me.

      C# Definetly has Delegates.

      Bill

      --
      It's my Sig and you can't have it. Mine! All Mine!
    3. Re:Ruby Continuations by Piquan · · Score: 3, Informative

      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.

    4. Re:Ruby Continuations by Slime-dogg · · Score: 1

      heh... functional languages are usually confusing to imperative programmers in general. I remember learning Scheme for the first time. I had a hell of a time unlearning the imperative thought process. After that, I had to learn the thought process of the lambda calculus. The lambda calculus way of thinking is foriegn to most people, which in turn leads to confusion.

      I'm not saying that continuations are bad, but rather I understand where the statement about confusion came from.

      --
      You need to restart your computer. Hold down the Power button for several seconds or press the Restart button.
    5. Re:Ruby Continuations by joto · · Score: 1
      Imagine in C that you had a keyword callc taking two arguments, an identifier and an expression to be evaluated. The identifier would be assigned the current continuation of the expression where the callcc occured. Since C is typed, callcc would have to return the appropriate type, so let's use C++ template syntax, e.g. callcc<int> for a continuation that returns an int.

      void f() {
      printf("%d", 3 + callcc<int>(cont, g(cont)));
      }

      For this to work, g would have to accept a function pointer taking and returning an int.

      void g(int (*cont)(int)) {
      cont(7);
      printf("you never reach this");
      }

      Since cont in g is not a normal function, but in fact a continuation, calling cont is analoguous to returning the place where the continuation where created (the place we used callcc. In this example, it would be analogous to return 7; , (except that g is declared void), and f would print 10.

      This might not seem useful, and in fact, it isn't (at least if you have exceptions), but there's nothing stopping you from capturing a continuation and using it several times. Imagine the following extension (f is as before).

      int (*weirdo)(int) = NULL;

      void g(int (*cont)()) {
      weirdo = cont;
      cont(7);
      printf("you never reach this");
      }

      Calling weirdo later in the program would have the effect of rearranging the stack so that we would return to the (still) active instantiation of f, and print out 3 + the argument we gave to weirdo. When f returns, it would return to the function that originally called it (which is probably not what you expect at all, and not where you are now, but is why continuations are so powerful).

      It is certainly not like delegates... It is a really tricky goto, and should be looked at with the same suspicion. Also, continuations tend to be an all-or-nothing decision, you either pass them around everywhere, or you don't. Still it has it's uses.

  25. Haha by Anonymous Coward · · Score: 1, Funny

    All these fags whine because they can't open a .doc

  26. Re:this is fantastic by Anonymous Coward · · Score: 0

    Eh?

  27. Perl 6 will have continuations by Anonymous Coward · · Score: 3, Informative

    Perl 6 will have continuations...

    http://www.sidhe.org/~dan/blog/archives/000156.h tm l

    1. Re:Perl 6 will have continuations by Anonymous Coward · · Score: 0

      Yeah, but I'm expecting Armageddon first, after all the Apocalypses.

  28. Re:moving towards bloatware or are these important by wjsteele · · Score: 2, Interesting

    You can already develop in C# for Office with Visual Studio Tools for Office.

    Bill

    --
    It's my Sig and you can't have it. Mine! All Mine!
  29. Why C# doesn't Totally Suck by Pflipp · · Score: 5, Interesting

    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".

    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 .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..!

    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]
    1. Re:Why C# doesn't Totally Suck by the_2nd_coming · · Score: 1

      the diffrence is that Apple uses Obj-C rather than Owning it.

      --



      I am the Alpha and the Omega-3
    2. Re:Why C# doesn't Totally Suck by krumms · · Score: 4, Informative

      come on, where are the real differences

      I thought the same thing. It's actually lots of little things that make C# nicer all 'round (in comparison to Java): Most pleasant for me is the fact that I can use enumerations without (a) declaring a new class/interface (b) placing a ridiculously long "public static final int" before EACH member of the enumeration and (c) being able to use the newly declared enumeration's new type name for parameters instead of just "int" - remember semantics?

      Integrating legacy shit is also a snap with C#. Sure, managed C++ is better, but have you tried doing the same thing in Java? Yuck.

      Lots of little things like this, IMHO, make C# better than Java.

      I hate the fact that Microsoft charges an arm and a leg for Windows/MSVS/everything. But I like C#.

      If only it was cross platform from the word go. Mono's nice, but the MSVS IDE is what keeps Microsoft/Windows up and above Linux as far as ease of development goes.

      Python's better than everything else anyway. *hides* ;)

    3. Re:Why C# doesn't Totally Suck by jsse · · Score: 1

      First I'm not totally disagree with you so pls take it easy. :)

      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

      I don't understand, building for MS platform doesn't necesarily mean you must do it with MS tools.

      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).

      How about a language which is high-level enough to make debugging of said problem next to impossible? How many times do you've to use some external 'fixes', 'workaround' to deal with problems that can be solved by good programming practise, but some unknown problem that not even the vendor can figure out? Note I'm not picking on MS in this case.

      So with .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..!

      Agree. VS.NET is very nice but I think the arguement here is C#, right? :) It's true that C# on VS.NET save your days, it also limited you one development platform. That might not be an issue for you now, but in the future you'd get stuck in unforeseeable upgrade cycle which is out of your control but the vendor you'e chosen.

      Since you asked. Java in .NET is not Java. At least it's no way to get J2EE compliant with it. When we talk about Java we really talk about J2EE now, no one really care if you can make nice Java front end now. :)

      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.)

      Yeah, for Windows, and nothing else(don't get me started on Mono). Back to your orignal requirements: maintainable, manageable solution for an emergency system, I'd recommend Java. Ease of programming has little to do in mantainable and manageable, it just shorten programming time. Of course, it all depends on the skillset of your crews. You can have a better chance managing monkeys than to get a bunch of MCSE to do J2EE. :)

    4. Re:Why C# doesn't Totally Suck by Meddel · · Score: 1

      I hate the fact that Microsoft charges an arm and a leg for Windows/MSVS/everything. But I like C#.

      Don't know if you're aware, but you can grab the .NET SDK (which includes the runtime, command line compilers, and so on) for free from Microsoft's web site. That doesn't give you access to VS, obviously, but it is a really nice way to do some light-weight development in the language without having to shell out.

      --
      You just come along with me and have a good time. The Galaxy's a fun place. You'll need to have this fish in your ear.
    5. Re:Why C# doesn't Totally Suck by vagn · · Score: 1
      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)

      Don't do that, then. Real programmers have already coded the templates and class libraries you are likely to need.

    6. Re:Why C# doesn't Totally Suck by 110010001000 · · Score: 0

      I think its cool how you call them "M$". That is totally eleet.

    7. Re:Why C# doesn't Totally Suck by penguin7of9 · · Score: 2, Interesting

      If only it was cross platform from the word go. Mono's nice, but the MSVS IDE is what keeps Microsoft/Windows up and above Linux as far as ease of development goes.

      For some people, perhaps. I find the MS development tools so nauseatingly bad that they are one of the main reasons that I don't do anything with Windows.

      Fortunately, on Linux you get a choice: excellent command line tools and IDEs. On Windows, unfortunately, you don't: Windows command line tools simply are completely useless.

    8. Re:Why C# doesn't Totally Suck by Daimaou · · Score: 1

      I agree with you that C# is a decent language, but I completely disagree regarding VisualStudio. It's a slow pig.

      As far as IDEs go, I think that Borland's new C++Builder IDE is the best cross-platform IDE hands down (and as a bonus, it runs on Linux as opposed to Microsoft's definition of "cross-platform" - Win95/98/ME/NT/2000/XP/2003/etc.).

    9. Re:Why C# doesn't Totally Suck by lewp · · Score: 1

      I believe you meant to say "kool", "k00l", or "kewl".

      --
      Game... blouses.
    10. Re:Why C# doesn't Totally Suck by TheAncientHacker · · Score: 1

      hope I don't have to explain why I hate VB if only on very first sight

      Perhaps you should since there's nothing inherent to VB that doesn't solve exactly the problems you were citing (accurately) about C and most C derivatives.

    11. Re:Why C# doesn't Totally Suck by Anonymous Coward · · Score: 0

      I've been developing with c# for a few months now.

      But last week I had to do some java work and I decided to install eclipse.

      In first impression, the eclipse is much nicer to work with.

    12. Re:Why C# doesn't Totally Suck by jsteinfo · · Score: 1

      The compiler and libraries for C# are free right? Maybe if Eclipse (www.eclipse.org) could support it, your wish would be granted.

    13. Re:Why C# doesn't Totally Suck by Koyaanisqatsi · · Score: 1

      the MSVS IDE is what keeps Microsoft/Windows up and above Linux as far as ease of development goes.

      Have you tried #develop latelly? Free as in beer and as in speech;

      http://www.icsharpcode.net/OpenSource/SD/

    14. Re:Why C# doesn't Totally Suck by Teancum · · Score: 1

      As somebody very familiar with MS-DOS command line tools, I still use them on a regular basis in Windows 2000 Professional. There are a number of very good tools available, although I'll be the first to admit that many of the tools are ports of similar tools written for Unix. Indeed, several are open-source (with a BSD license) that Microsoft simply bundled with the OS.

      You can even get BASH for Windows with the Cygwin tools, if you are a Unix guru who has to occasionally dabble with Windows, including man pages (which is really unusual for hardcore Windows folks, but that is another story.)

      The unfortunately problem with these tools is the almost total lack of documentation and the fact that most Windows developers never take the time to learn them. There are tasks that are difficult if not impossible to accomplish from the Control Panel that are only a single command line to accomplish. The reason for this is partly due to Microsoft's insistance that Windows '95 was a whole new rewritten from scratch operating system, when in fact it was MS-DOS 7.0 with only slightly improved GUI shell placed over it. That culture that was fostered by Microsoft discouraged shell programming, which is still a very valuable skill.

      As far as IDE engines, I personally prefer the Borland suites (C++ Builder has been mentioned by somebody else here). All of the current Borland compilers will also target .NET, and many of these applications will run in Mono as long as you don't get too fancy. #Develop is also a very good IDE that is written entirely in C#, and released under the GPL. It isn't running under Linux, unfortunately, but the long-term roadmap for that IDE is to get there soon. I would agree that Visual Studio is a pile of smelly effulgant, with my biggest complaints regarding bloat in both the documentation as well as with the compiler itself. I mean, if you get Visual Studio, it comes on multiple DVD-ROM discs. Shouldn't that in itself act as a warning?

    15. Re:Why C# doesn't Totally Suck by darthscsi · · Score: 1

      > Lots of little things like this, IMHO, make C# better than Java.
      > Python's better than everything else anyway. *hides* ;)

      After using OCaml for a while, you start to fill the same way. Type inference, polymorphism that actually works, closures, parameratized modules, anonymous functions, etc all make programming much easier. Other languages have to add hacks (Java: nested classes, generics; C++: templates, anonymous structs that overload () ) to get what ML programmers have for free.

      And let us not forget about code speed and memory usage. Go check out the Great Language shoot out (mentioned some time ago here), or better, the Win32 version since that one includes C#. Java implementations are simply embarissingly memory greedy. C# looks much better there, but then look at the OCaml compiler. Code speed rivals gcc.

    16. Re:Why C# doesn't Totally Suck by Anonymous Coward · · Score: 0
      I hope I don't have to explain why I hate VB if only on very first sight.

      Actually, please DO explain your distate for VB. Otherwise, you're just slamming it for no particular reason and would appear to be a mindless zealot. But you aren't a mindless zealot, are you? I'm not saying it is perfect, but to hate it just at the sight of the characters "VB" is borderline zealotry.

    17. Re:Why C# doesn't Totally Suck by emarkp · · Score: 1
      I thought the same thing. It's actually lots of little things that make C# nicer all 'round (in comparison to Java): Most pleasant for me is the fact that I can use enumerations without (a) declaring a new class/interface (b) placing a ridiculously long "public static final int" before EACH member of the enumeration and (c) being able to use the newly declared enumeration's new type name for parameters instead of just "int" - remember semantics?
      So how happy are you with the fact that while Enum's don't implicitly convert to an int, they do implicitly convert to a string?
    18. Re:Why C# doesn't Totally Suck by gh · · Score: 1

      Enums do not implicitly convert to a string. To convert an enum value to a string, you must call the ToString method. When you pass it to a method like Console.WriteLine, the enum gets boxed into in object which the WriteLine calls the ToString on. To avoid the box, one could call the ToString directly on the enum value.

      Implicit conversion would mean the following would be possible:

      MyEnum x = MyEnum.Foo;
      string s = x;

      Fortunately, that does not work. :)

    19. Re:Why C# doesn't Totally Suck by aminorex · · Score: 1

      > a snap with C#. Sure, managed C++ is better,
      > but have you tried doing the same thing in
      > Java?

      I certainly agree about enums, although the
      issue is trivial, and in fact I prefer to
      use the type-safe enum idiom when I use Java.
      However, on the issue of integrating legacy
      code, I think Java's retro JNI is actually
      a positive boon to any multi-person project,
      and to the architectural imperatives implicit
      in the language.

      It creates a positive disincentive to doing
      evil. Mixing multiple languages in a single
      project is an enormous evil, because it means
      that all maintainers have to be fluent in
      both toolchains, and in the integration layer.

      But JNI manages to strick a balance by
      making the necessary possible. There *should*
      be a hurdle to tossing in crap willy-nilly.
      It *should not* be high enough to represent
      an obstacle to integrating an essential
      component using a well-designed bridge
      interface.

      If JNI fails, it fails on the basis of the
      toolchain support. In cases where the cost
      of maintaining your interface as native
      declarations is too high, you probably should
      be using IDL and RMI over IIOP anyhow.

      --
      -I like my women like I like my tea: green-
    20. Re:Why C# doesn't Totally Suck by JonnyQabbala · · Score: 0
      I hate the fact that Microsoft charges an arm and a leg for Windows/MSVS/everything. But I like C#.

      You dont actually need to purchase C#. You can download the .NET Framework for free and it has the C# and VB.NET compilers in there for you.

      There are also OSS IDE's for .NET

      All you have to pay for now is windows :P

      --
      This sig intentionally left blank
    21. Re:Why C# doesn't Totally Suck by Haeleth · · Score: 1
      Mixing multiple languages in a single
      project is an enormous evil, because it means
      that all maintainers have to be fluent in
      both toolchains, and in the integration layer.
      I'm tempted to apply reductio ad absurdum here, and in fact I think I will:

      Mixing multiple tools in a single carpentry project is an enormous evil, because it means that all carpenters have to know how to use planes as well as saws.

      Let's face it, different languages DO have different strengths and different uses. That's why Fortran is still popular in the scientific community.

      In fact, mixing multiple languages in a single project has been the standard practice ever since the first high-level languages appeared. We might no longer consider dropping as far as ASM, but it still makes a lot of sense to write speed-critical code in C or C++, and the main application framework in something higher-level.
    22. Re:Why C# doesn't Totally Suck by vikramjairam · · Score: 1

      I agree to this.
      Ideally, an Application Framework should let the programmer do everything on an Operating System, that the Operating System itself can do. This was true in the Win32 SDK where One can do everything that windows can do. In MFC, they gave us a class library and kinda abstracted the API. So programmers were less powerful. In C#... you can frankly do nothing - Programmers are End Users.

      I would consider C# to be a language hybrid that makes the programmer feel like an end user. You can design everything.. an NT Service, a GUI (Forms) Program... all using simple interfaces.

      It certainly is a great language in that every Tom Dick and Harry can start being productive on the Windows Platform. But all these Toms, Dicks and Harries can never do what a Win32 Programmer can do.

      Ever tried Writing a simple WinGUI program using C#... Crap. All that overhead... need I say more.

      Only place I like to use C# is to scrape out all that DIRTY ASP code and replace the blocks with some clean c# (ASP.NET) code. I HATE the VStudio Wizard and Project settings.

    23. Re:Why C# doesn't Totally Suck by vikramjairam · · Score: 1

      A small correction here, Though MFC abstracted most of the API.... one could still call Win32 functions from the MFC C++ code. C# is a disaster for low level programmers. Unsafe code is a pain...

  30. VB Programmers by deputydink · · Score: 1
    Wow dude. That document is going to confuse the fuck out of all those Visual Basic programmers after Microsoft deprecates their language.


    How is this deep level of generics gonna be realized in the Common Language Runtime? Or are these features just available in C#? And, if so, won't that break all the .NET libraries?

    1. Re:VB Programmers by DarkEdgeX · · Score: 0
      Wow dude. That document is going to confuse the fuck out of all those Visual Basic programmers after Microsoft deprecates their language.
      Seriously, the day Microsoft kills VB will be the happiest day of my life. VB should be a learning language and nothing more-- it absolutely should never ever, not even if you think it'll be easier to get shipped, be used in production code.

      Just to prove that I'm not being snotty or anything-- I learned how to program by using QuickBasic 4.5 and Visual Basic for DOS 1.0-- shortly after getting through that I moved to Turbo Pascal, learned some C/C++, and braved my way into assembly (which has been a mixed bag; I can write faster code generally than a compiler can come up with, but it's not a valued skill which goes to show the attitude of most software houses these days).

      In my case QB/VB had it's place-- a learning experience. IMHO, Microsoft should come up with a scaled back/simple Visual Basic .NET and include it with Windows (ala QBASIC which was included with Windows '9x/DOS) so people who are stuck with Windows can at least learn how to program if the mood strikes them. But otherwise, VB is worthless, a nice robust language like C# is where developers should be moving. My only gripe with C# is the lack of a native code compiler (rather than something that emits .NET bytecode).
      --
      All I know about Bush is I had a good job when Clinton was president.
    2. Re:VB Programmers by Anonymous+Brave+Guy · · Score: 1
      Wow dude. That document is going to confuse the fuck out of all those Visual Basic programmers after Microsoft deprecates their language.

      You're missing the point; the new VB.NET spec will be out just as soon as the search-and-replace has finished.

      --
      If you disagree, post your argument. (-1, Overrated) isn't your personal censorship tool for views you don't like.
    3. Re:VB Programmers by deputydink · · Score: 1

      LOL ... you're right... what was i thinking?

    4. Re:VB Programmers by djohnsto · · Score: 1

      Not sure about VB, but you can download a free C# compiler from microsoft as part of their .NET Framework SDK. You don't get visual studio (you'll probably need to download gvim/winemacs/some_other_code_editor as well). Instead you need to write everything by hand (which isn't quite as bad as you think, even for GUI apps) and compile with the command line (or make if you have cygwin). All in all, probably a better learning environment than QBasic, which was in turn better than TRS-80/C64/AppleII basic that I learned on (stupid crappy tape drives).

      --
      Dan
    5. Re:VB Programmers by DarkEdgeX · · Score: 1

      Well the idea is that whatever solution is deemed best for beginners that it be included with the OS and not be something that has to be sought for. This would make it a more ubiquitous learning language (be it VB or C#). And really, just to get your feet wet, being able to compile console programs (which I don't think VB can) might make C# the better learning language for Windows users.

      For someone who has absolutely no clue what a programming language is, or how applications are developed, seeking out the .NET Framework SDK would probably be beyond their reach as well. =)

      But in general I agree with you. Maybe a stripped down Visual Studio that only had C# and had no visual designer for GUI apps, but *did* include the language reference as well as the .NET Framework SDK reference (so the would-be learning developer could more easily find info on basic operations; opening a file, reading some data, etc). The IDE would be nice simply for the syntax highlighting and the "IntelliSense" (code completion). Seeing as MS gives VC# Standard away for $99, it doesn't seem unreasonable for a non-commercial non-visual GUI designer IDE to be included in the box for Windows XP or Longhorn.

      --
      All I know about Bush is I had a good job when Clinton was president.
    6. Re:VB Programmers by Anonymous Coward · · Score: 1, Informative

      VB.NET can compile console programs. VB5/6 could not, however it was possible to hack it to since VB5/6 were compiled using a syntax modified version of VC and the same linker as VC, so all you would have to do is override the /SUBSYSTEM switch to link.exe and you'd have a console application. I've done it several times.

      In the case of VB.NET and C#, there are very few things that C# can do that VB.NET cannot. Some examples are:

      1. Use of pointers/unmanaged code, which is useful in circumstances such as pixel-by-pixel image manipulation.
      2. Unsigned types, which aren't really used much within .NET anyways except in interop scenarios.
      3. Using disposal semantics, which is syntactical candy and VB.NET can perform the same duties, it just requires more typing.
      4. Lack of dependance on yet another library, Microsoft.VisualBasic.dll, although that lib is quite small and distributed with .NET so it's not a big deal.

      On the other hand VB.NET can do the following that C# cannot:

      1. Late bind to a class, by disabling strict typing VB.NET can create and use a class without knowing anything about that class, both .NET and COM classes. While I know and agree that this is a bad practice anyway, it can simplify COM programming significantly.
      2. With semantics, which is syntactical candy but very convenient for people who are used to Pascal and Visual Basic.
      3. Parametered properties. C# supports indexers, but only one of them. In VB.NET any property can require a parameter or any number of parameters.
      4. Option parameters. .NET completely supports this but the C# team avoided it because if an application referenced a class that had a method with an optional parameter the default value would be compiled into the calling class. The default could be changed on a latter version but the client would still use the old default.

      Really that's not a whole lot. The vast .NET framework is open to both languages equally. In Whidbey some of those differences will disappear and some new differences will surface. VB.NET will gain unsigned types, generics and also Edit & Continue (which is a mighty useful feature.)

      Not to be confused with a VB.NET thumper. I switch back and forth between the two like a confused Canadian.

    7. Re:VB Programmers by rumil · · Score: 1

      I'm pretty sure generics are supported in the 1.1 framework already. There just aren't any MS supported languages that take advantage of them yet. As for whether or not VB will support generics, I have no clue.

    8. Re:VB Programmers by darnok · · Score: 1

      You can download the Sharp #Develop IDE; in terms of functionality and robustness, it's sort of an early beta level Visual Studio equivalent, but it's free and certainly makes writing .NET code a lot more enjoyable than using Notepad.

      I'm sure Eclipse's C# support is pretty good too; just never had the need to use it personally.

    9. Re:VB Programmers by BurKaZoiD · · Score: 1

      VB should be a learning language and nothing more-- it absolutely should never ever, not even if you think it'll be easier to get shipped, be used in production code

      I...I...I think I love you. *Sniff* Seriously, I think VB (version 6 in particular) is a nice, elegant little language, but it makes too many "business people", especially MBAs, think they can program. Truthyfully, I'm sick and tired of explaining why I elect to use a language that is in the least little bit less English-like than VB. I'll get down on my knees and kiss Billy-boy's buttocks the day he kills off VB, VBScript, and VBA. Of course, we'll lose half our programming staff, 'cos I'm kicking them to the curb as soon as he does that, but WTF do I care? It's job security.

    10. Re:VB Programmers by Anonymous Coward · · Score: 0

      "Pretty sure" doesn't cut it.
      Generics are *not* supported in 1.1

    11. Re:VB Programmers by Anonymous Coward · · Score: 0

      To be fair, Microsoft did start to move to depreciate VB with the Visual J++ product, at least until they got into legal trouble with Sun.

      (It should be noted that even though MS lost, there was no way that Sun Java was going to replace VB.)

    12. Re:VB Programmers by jfollas · · Score: 1

      My only gripe with C# is the lack of a native code compiler (rather than something that emits .NET bytecode).

      You can generate a native image of an assembly, which allows you to bypass JIT'ing the code when it runs. The image is framework-version dependent, meaning that if you update the framework, you'll have to re-gen the native image (otherwise, the framework will revert back to JIT compiling).

      [From .NET Framework SDK Documentation]
      The Native Image Generator creates a native image from a managed assembly and installs it into the native image cache on the local computer. The native image cache is a reserved area of the global assembly cache. Once you create a native image for an assembly, the runtime automatically uses that native image each time it runs the assembly. You do not have to perform any additional procedures to cause the runtime to use a native image. Running Ngen.exe on an assembly allows the assembly to load and execute faster, because it restores code and data structures from the native image cache rather than generating them dynamically.

    13. Re:VB Programmers by Anonymous Coward · · Score: 1, Insightful

      People who say this shit are such idiots - the differences between VB.Net and C# are slight syntactical differences only.

    14. Re:VB Programmers by DarkEdgeX · · Score: 0, Troll

      Bring on... the trolls! Thanks for that, I knew I'd get one to bite eventually.

      --
      All I know about Bush is I had a good job when Clinton was president.
    15. Re:VB Programmers by DarkEdgeX · · Score: 1

      Yeah, that might work with the framework installed, but something that actually put out a standard Win32 binary with x86 instructions, etc. would be truly nice. I like C# as a language, not as a vehicle for Bill Gates to (try to) kill off Java.

      --
      All I know about Bush is I had a good job when Clinton was president.
    16. Re:VB Programmers by DarkEdgeX · · Score: 1

      Modding me down doesn't change the truth of what I said. Nice try.

      --
      All I know about Bush is I had a good job when Clinton was president.
  31. Re:That's great by Anonymous Coward · · Score: 0

    I thought C# was the one that had the public standards body (thus a public standard)... unlike Java...

  32. Oh how exciting! by rixstep · · Score: 1, Funny

    This is so exciting! Microsoft with their own language! I can hardly get the words out. Strains of Eiffel and Ada! Wow! How wonderful!

    Microsoft are continually at the pinnacle of innovation in our industry, as we all know. That they should donate yet another technological breakthrough is simply too amazing for words.

    Now anyone who believes a word of the above can get on a one-way Trailways to Redmond. In such case, they need you there.

    1. Re:Oh how exciting! by Doomrat · · Score: 1

      You could saved time by typing this instead:

      "OMG! Microsoft! GAY! Now tell me that I'm funny, please."

    2. Re:Oh how exciting! by mcpkaaos · · Score: 0, Troll

      All this coming from a kid who probably runs Gnome with the Windows theme.

      --
      It goes from God, to Jerry, to me.
  33. Re:this is fantastic by Anonymous Coward · · Score: 0

    java 1.5 will have generics and enumerator types. And the troll is not appreciated.

  34. Re:this is fantastic by requim · · Score: 1
    When will java get features like generics - no time soon i guess.


    http://developer.java.sun.com/developer/technicalA rticles/releases/generics/
  35. innovation by pizza_milkshake · · Score: 3, Insightful

    wow, that will they think of next?

    1. Re:innovation by Anonymous Coward · · Score: 0

      Very cool sig man. --MBCook

    2. Re:innovation by psxndc · · Score: 1

      whoa. That was sick. If you hadn't said anything, I never would have run it. sweet.

      --

      The emacs religion: to be saved, control excess.

    3. Re:innovation by Anonymous Coward · · Score: 0

      You're right. They should never implement anything that anyone else has done and proven to be a good idea. In fact, they should add experimental features to a language that nobody will understand or like, in order to be more clever and original (like yourself!). Good post.

    4. Re:innovation by qtp · · Score: 1

      No, I think the posters point is that they shopuld never implement anythink that anyone else has done and proven to be a good idea without being honest about the fact that the idea was not originally thiers , even if it might mean that a few of thier customers might happen to look at a competing product that they did not know would suit thier purposes.

      --
      Read, L
    5. Re:innovation by Tim+C · · Score: 1

      Have you read the specification document?

      "Anonymous methods are similar to lambda functions in the Lisp programming language."

      That's a direct quote from the second bullet point of the first section - it's the fifth sentence of the document. Hardly claiming to have invented them, are they?

    6. Re:innovation by ameoba · · Score: 1

      Production systems aren't supposed to innovate; they're supposed to implement the ideas that have been proven in more experimental systems, often in a somewhat dumbed-down/weakened/safer version. It would be pretty shocking if any major vendor implemented any radical, unheard of, unproven programming concepts into a commercial system.

      As a good example, look at garbage collection. How many years had non-mainstream languages been doing it well before it was adopted into 'serious' language used by a significant number of people doing 'real work'? If you want more examples of mainstream programing systems ignoring proven innovations just go to Lisp fanatic Paul Graham's webzit, even though he sounds like an Amiga user in many cases.

      --
      my sig's at the bottom of the page.
  36. Cheap update by Anonymous+Brave+Guy · · Score: 1

    The cheap update deal expired at the end of September IIRC, at least here in the UK. It was being featured fairly prominently on the MS web site and doesn't appear to be there now, so presumably it's gone elsewhere as well.

    --
    If you disagree, post your argument. (-1, Overrated) isn't your personal censorship tool for views you don't like.
  37. Re:this is fantastic by technomancerX · · Score: 0, Flamebait
    I realize the parent is flamebait, but I can't resist.

    Java already has generics, dumbass. They're in the 1.5 release, which is currently in beta (you know, as in a downloadable IMPLEMENTATION, as opposed to just on paper).

    --
    .technomancer
  38. 4 wordz on itz goodness by Anonymous Coward · · Score: 0

    niggaz can't program da shit. so sit yo punk ass down, b1atch.

    object to dis, neeeeegro.

  39. not a C++ Delegate by Anonymous Coward · · Score: 0

    It's more like a stack frame object; or iterators taken to an extreme.

  40. Re:That's great by Randolpho · · Score: 1, Insightful

    Um... the C# specification *is* a platform independent specification. Good to see that you got the "+1, Knee-jerk MS Basher" moderation.

    --
    "Times have not become more violent. They have just become more televised."
    -Marilyn Manson
  41. true dat, my nigggaaa. by Anonymous Coward · · Score: 0

    true dat, my nigggaaa.

  42. No, but by unsinged+int · · Score: 1

    It does make it a bitch for compiler writers. Writing one for C++ is difficult enough. I don't think I'd ever touch this one.

  43. Re:First Post? by Anonymous Coward · · Score: 0

    You must be mistaken. Real geeks don't touch C# or Microsoft by their own volition.

    Furthermore, Geekdom and sports are not mutually-exclusive.

  44. Re:Who gives a shit about C# by Anonymous Coward · · Score: 0

    People who're looking for a job for instance ? Get real -- a programming language is nothing more than a tool to get the job done and not everyone is in a position to give a shit about ...

  45. Re:moving towards bloatware or are these important by Sivaram_Velauthapill · · Score: 4, Informative

    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 ;)
  46. Re:That's great by the_2nd_coming · · Score: 1

    oh, yeah it is nice that C# the grammer and semantics are cross platform, but you will not get cross platform applications working. if you program for windows, it will only run on windows.

    --



    I am the Alpha and the Omega-3
  47. You are all worthless and weak by Anonymous Coward · · Score: 0
    Don't hand me your whiny, sniveling crap about C, C++.

    Whatever.

    If you don't code your windows apps in Assembly, then you're a pansy-ass bed-wetter.

  48. Re:moving towards bloatware or are these important by Anonymous Coward · · Score: 1, Insightful

    It sounds like it's moving towards Python with the addition of Lisp-ish functions and itterators.

    Any programmers looking at C#, I recommend also checking out Python, it is a wonderful language. Particularly with Win32 extensions (Windows-specific extensions, but most useful feature is an amazing editor / debugger, Pythonwin) Psyco runtime compiler and wxPython for cross-platform GUI building.

  49. MOD PARENT UP by Anonymous Coward · · Score: 0

    Funniest comment all day... too bad my mod points just expired...

  50. Re-inventing the wheel... but making it square... by oodl · · Score: 1

    Replace the references to Java below with C#:
    -------
    Sounds like they are adding a lot of features that the Dylan programming language has had since it's release (approximately 1995).

    But whereas the features were elegantly incorporated into Dylan since the beginning and are consistent and easy to use, I suspect that in Java they are a hack.

    Wasn't Java designed to be a simple language?

  51. DotGnu? by BigFootApe · · Score: 1

    Anybody using it?

  52. Re:Who gives a shit about C# by aled · · Score: 3, Informative

    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"
  53. Let's all sing together by Multics · · Score: 0, Flamebait
    Let's be sure to adopt and extend
    Let's be sure to adopt and extend
    lest someone come to close to us
    Let's be sure to adopt and extend!

    ;-)

    -- Multics

    1. Re:Let's all sing together by TaQ · · Score: 1

      You forgot the last part:

      Let's someone come to close to us
      Let's f*** them on the end
      No mercy, let's impose us over them.
      Hail m$!

      Don't be foolish, dudes, C# it's more a bait than a language ... embrace, extend, exterminate! ;-)

  54. Re:That's great by Randolpho · · Score: 1

    No, if you program for .NET, it will only work on .NET. If mono ever fully emulates the .NET API, a .NET application will be cross platform.

    But you don't have to use .NET to use C#, and if you don't it *will* be cross platform (provided you have a VM on that platform).

    --
    "Times have not become more violent. They have just become more televised."
    -Marilyn Manson
  55. I'm Sorry by Anonymous Coward · · Score: 0

    It seems C# is trying to grab everything that makes other programming languages great and clump them together in c#. Why not just use those languages Eiffel is kick ass, just not to many people use it or know of it, and I always loved programming in ADA, there are already solid languages, and have pretty solid philosophies behind them, what is C# philosophy anyway?

    1. Re:I'm Sorry by jjhlk · · Score: 1

      It's a good thing that languages borrow from each other.

  56. Re:That's great by Anonymous Coward · · Score: 0
    When does the platform independent spec come out?

    See here.

  57. more info by rabtech · · Score: 3, Informative

    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.

    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/productin fo/road map.aspx

    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)
    1. Re:more info by ratfynk · · Score: 1
      "Whether it will be a great tool or a bloody nuisance remains to be seen."

      If you cannot turn it off choice two is the obvious answer!

      --
      OH THE SHAME I fell off the wagon and use sigs again!
    2. Re:more info by owlstead · · Score: 1

      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.

      Ah, yes, so after grabbing everything from Java (and , as I must say, improved upon it in some ways) they now copy the popular Eclipse from IBM. It even catches syntactic & semantic errors in the wizards :)

      It's unfortunate that such a large company like MS comes up with some true inovation by itself, appart from copying bright ideas from others.

      Hmmm, appart from the hardware front that is, come to think of it...

    3. Re:more info by Anonymous Coward · · Score: 0
      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 [sic] underlines misspellings or grammar errors.

      Yes, and we all know how well that works in Word....

  58. the kitchen sink too? by ashultz · · Score: 2, Insightful


    The next version will of course have features from Esperanto, Mandarin, and Martian.

    I'm all for extending a language, but they haven't had C# around enough to be larding new stuff on. The language already had several ways to do most things, now they're adding more?

    If we wanted ten ways to do anything, we'd use perl. If we're not using perl, that usually means we like to be a little more constrained.

    -andy

    1. Re:the kitchen sink too? by addaon · · Score: 2, Funny

      Java supports chinese variable names. Don't ask me how I know this. Don't ask my coworkers, either.

      --

      I've had this sig for three days.
    2. Re:the kitchen sink too? by blibbleblobble · · Score: 1

      "Java supports chinese variable names. Don't ask me how I know this. Don't ask my coworkers, either."

      Perl also supports unicode variable names (i.e. any language), and some whisper that Perl 6 will even have unicode operators.

      That's what you get when you have a linguist for a language designer...

    3. Re:the kitchen sink too? by Haeleth · · Score: 1
      some whisper that Perl 6 will even have unicode operators.
      Excellent! At last we'll be able to write real code again - APL style!
    4. Re:the kitchen sink too? by Anonymous+Brave+Guy · · Score: 1
      Java supports chinese variable names.

      I had a great joke to put here, but unfortunately Slashdot doesn't...

      --
      If you disagree, post your argument. (-1, Overrated) isn't your personal censorship tool for views you don't like.
  59. informative by ClarkEvans · · Score: 1

    thanks! Your other post was also useful, especially the one about call/cc

  60. Re:this is fantastic by Billly+Gates · · Score: 1
    lol.

    If you were not who you were, you would me modded down faster then you can say goatse. hehe

    But seriously I am installing the c# learning edition now and plan to install your mono on FreeBSD4.8 or 4.9 if the rumors are true that Fbsd 4.9 will be done this monday!

    I use to hate Microsoft with a passion. Their products use to suck until quite recently. The win32 api is quite nasty compared to gtk+ but with .net things will be improved.

    What worries me is api closeness. Yes Mono the last time I liked supportes some winframe types but I feel uncomfortable being closed into a platform which is why I may not chose c# for an opensource project. Also the EULA for VS forbids GPL development due to its "viral" nature. This also limits portability.

    Also one of the benefits you described for Gnome before the mono project started that gtk can be used in different langauges. I would like to see java integrated with gnome. I believe in freedom and also Java 1.5 supports generics and other features of C# and other languages. I wonder if if Mono includes Bonoboo object support? Got to check that.

    Sun is not standing still.

    I bet with newer api's that focus on less code might help too. One of Microsoft's examples is the classic petstore program. ITs only 1/4th the amount of code from the Java version.

  61. Re:That's great by the_2nd_coming · · Score: 1

    but I think that most people will think that C# from .Net will run in Mono.

    --



    I am the Alpha and the Omega-3
  62. Re:moving towards bloatware or are these important by Anonymous Coward · · Score: 0

    In response to the MS using this for its own products. I recently talked to a MS employee and apparently C# is being used to write all their products and actually the majority of the MS OS is being converted to C#.

  63. Re:moving towards bloatware or are these important by Anonymous Coward · · Score: 1, Informative

    In response to the MS using this for its own products. I recently talked to a MS employee and apparently C# is being used to write all their products and actually the majority of the MS OS is being converted to C#.

    [snicker] [snort] I'm sorry, but you were misinformed. As a kernel dev (I'm part of the Core Technology team in building 27 at Microsoft's Redmond campus), I can tell you with all finality that we're not moving the OS over to C#. Our work is strictly in C, occasional C++, and assembly.

    That said, most of the higher level APIs for things like drawing, networking and so on will now have a managed wrapper, which means you can write C# that calls them.

    Also, many of our network servers like IIS, SQL Server, BizTalk and so on will support a managed assembly (that's just a managed DLL) that allows managed code to configure those servers. This, to me, is the biggest deal.

    Also, some non-OS products will be using some C#, though the Office team has stated emphatically that they won't be rewriting Office in C# anytime soon. There are pieces of the Office team that use C#, but that's a little bit different.

  64. It's already there in Java 1.5 by blamanj · · Score: 4, Informative

    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.

    1. Re:It's already there in Java 1.5 by krumms · · Score: 1, Flamebait

      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.

      1. I wasn't talking about Whidbey, I was talking about the current release of C#.
      2. JSRs are talk. C# is a reality.
      3. C# has already been implemented - further, its implementation is already production quality (irrespective of what Microsoft's definition of "production quality" is - if you disagree, break it for me will you?)
      4. How long has C# been production quality for?

      I don't mean to be rude, but I don't see what your point is. I'm saying C# is here. You're saying Java 1.5 is almost here, and has been prancing around in pre-production since forever.

      And?

    2. Re:It's already there in Java 1.5 by Anonymous Coward · · Score: 0

      Microsoft Research had released generics for the shared source version of the CLI almost half a month ago.

      Also, Java generics don't support value types or primitives, and they expand at compile time which can cause code bloat.

    3. Re:It's already there in Java 1.5 by godefroi · · Score: 1

      the prototype compiler with generic support has been available for months.

      Yeah, there's been one for c# for most of a year. Get it here.

      --
      Karma: Poor (Mostly affected by lame karma-joke sigs)
    4. Re:It's already there in Java 1.5 by bwt · · Score: 1

      2. JSRs are talk. C# is a reality.

      C# 1.0 is a reality. The posting is about the "design specifications document for C# 2.0". How would you classify that -- "talk or reality". (The correct answer is talk).

      On the other hand Java 1.5 is talk that is on the verge of release (weeks or months away), while C# 2.0 is just getting started.

      And while, .net is a reality, it isn't a very pretty one. It's about where JDK 1.2 was. Most people don't realize that C# is SLOWER than java on MS platforms, which is fscking SAD, given that java has to be cross platform which costs speed. (source: results from Aldo Calpini's windows port of Doug Bagley's Language shootout).

    5. Re:It's already there in Java 1.5 by gafter · · Score: 1

      > Also, Java generics don't support value types or
      > primitives, and they expand at compile time which
      > can cause code bloat.

      No, Java generics do not expand at compile time. Each class generates a single class file. And yes, with boxing/unboxing going into 1.5 you can use primitive types with collections.

    6. Re:It's already there in Java 1.5 by MrBlack · · Score: 1

      A prototype C# compiler and CLR with generics support has been out for ages too (based on the shared-source ROTOR distribution). It's called Gyro. The alpha versions of Widbey (CLR, C#/VB.NET compilers, VS.NET Widbey) all have generics support. Attendees at the Microsoft Professional Developers Conference (PDC) which starts today IIRR, will recieve an updated preview of Widbey (not sure if it is being called an alpha or a beta, but the alphas that are already out there are pretty stable, and it is getting a pretty wide release). It's good to see Java following Microsoft's lead (after MS borrowed so much from Java). I think strong competition is good.

    7. Re:It's already there in Java 1.5 by blamanj · · Score: 1

      It's good to see Java following Microsoft's lead...

      While Java is definitely borrowing from C# when it comes to autoboxing and enums, the generics work shouldn't be credited to MS. It came from a Java variant called GJ that was first written in 1998 as a collaboration between Sun and the University of SouthAustralia. Guy Steele was a champion, and there have been plans to get into Java ever since, and they have taken quite a while to get it out. I was hoping to see it way back in 1.3.

    8. Re:It's already there in Java 1.5 by MrBlack · · Score: 1

      I guess generics themselves are nothing new, but thanks for the info on the academic Java generics project. It seems like all-of-a-sudden Sun has decided to add some language features to Java that had perviously been on the back-burner because Sun had deemed them as un-necessary. As I said I like the rivalry between .NET and Java. Hopefully developers (and ultimately customers) will be the big winners.

    9. Re:It's already there in Java 1.5 by chicogeek · · Score: 1

      Do you have a link to an article that explicitly states that Java generics are not expanded at compile time? Everything I've read (including JSR-000014, is there something more recent?) says that they are expanded at compile-time.

  65. Ask a stupid programmer.... by emarkp · · Score: 2, Insightful
    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)
    It's not surprising that a poor programmer likes C#--it's designed for people who can't design and code well. It's a continuing trend of giving more band-aid's to a language to compensate for lazy and/or incompetent programmers.

    Here's a clue: null pointers and memory leaks are not "low level" problems--they're logic errors. Dereferencing a null pointer can happen in Java, and accessing a disposed object can happen in C#. Memory leaks and null pointers usually mean you aren't managing an object's lifetime correctly, and are typically symptoms of design errors (or minor bugs--off by one, etc.--which can happen in any language).

    C# is like most MS tools--great for 80% of the work, but the last 20% is difficult or nearly impossible because MS didn't think of the problem you were trying to solve, and the language isn't flexible enough to adapt.

    Finally, it is impossible to report errors in the implementation. When I found a serious error in the .Net runtime, I tried several ways to report it, getting no answer, or in the case of the microsoft.* newsgroups, assertions that I couldn't find bugs since the high-and-mighty MS and testers hadn't find it.

    Sigh. Compare that to the people who hang out in comp.lang.c++.* -- I ran screaming away from C# as quickly as possible.

    1. Re:Ask a stupid programmer.... by gfody · · Score: 1

      curious, of what serious error do you speak?

      --

      bite my glorious golden ass.
    2. Re:Ask a stupid programmer.... by Anonymous Coward · · Score: 0

      You took the bug to the wrong place usenet is the WORST place for ms problems even if they are MS 'sponsored' ones. Goto the source, MS. Plonk your 200 bucks down and report it. If it is a REAL problem you will get your 200 bucks back if its YOU they keep it. There are also TONS of ways on the msdn site to report bugs for free. They may not fix them RIGHT away. But they will fix em.

      'I posted to usenet and didnt get the answer I wanted' is a poor excuse. I currently got MS eng's to look at a serious critical problem they made in some of their security fixs in NT4 and they are depricating it! Once they actually reproduce it they are usually quite friendly and will look at it and help you. They will even give you band-aid work arounds till they fix it. You just need to be willing to work with them. They do not respond well to 'its broke fix it'. I know what the company I work for would do if our customers did that. We would fix it and charge em. If they didnt want to pay then no fix. I am a firm beliver of you broke it you pay for it, but if it was broke before you got here Ill help you out. But if you get an attitude well I might make you pay for it anyway.

      They are a busness not a charity.

    3. Re:Ask a stupid programmer.... by Unordained · · Score: 1

      and most of the time, C++ will help you with null pointers by letting you use references instead. does the same job, but it's much more of a pain to confuse it into passing a null pointer when it shouldn't. useful buggers, references are.

      and with C++, there's no garbage collector to do freaky things. either you destroy it or scope destroys it or you have a memory leak, but it's not much of a puzzle.

      i like some of the features of C#, and might not mind them being added to C++ ... i've liked the -concept- of anonymous functions, both in python and lisp. but what worries me is that they say these have access to local variables in the class using the anonymous function the way it could a callback or closure (by pointer) ... there's a possible violation of encapsulation that leaves me feeling a bit ill. and besides -- anonymous functions are only useful for throwaway uses. if you're going to do it several times, better to name it. at least you'll only have one place to fix it. i get the feeling people want them because they screw up callbacks too much (granted, the syntax, especially for closures, is nasty in C++ ... and passing closures around without a language construct like borland builder's closure keyword makes it even worse. but that's what function objects are for!)

      generics have been around in C++ for a while, eh? and although C#'s requirements thing sounds interesting, shouldn't the compiler be catching those as part of strict-type checking anyway?

      [somehow, this reminds me that C++, spec-wise, allows you to explicitely tell the compiler what you're likely to throw(), the way java does ... i believe MS VC 6 never got around to supporting that?]

      interesting functionality being added. but not necessary, and likely to get people using "cool toys" rather than programming carefully. that's just me.

    4. Re:Ask a stupid programmer.... by TheAncientHacker · · Score: 1, Insightful

      Ah, when asked to defend the indefensible (C's insane design) instead declare yourself an expert and attack the person raising the issue as " lazy and/or incompetent".

      The problems cited are language problems. Yes, you can do workarounds and never create a bug but a competent language should make it easier to write bug-free code not add land mines to swagger over.

    5. Re:Ask a stupid programmer.... by jcr · · Score: 1

      So, I take it you do all your coding in assembly language? After all, if you could design and code well, why would you need crutches like classes, templates, and the STL?

      -jcr

      --
      The only title of honor that a tyrant can grant is "Enemy of the State."
    6. Re:Ask a stupid programmer.... by emarkp · · Score: 2, Insightful
      Goto the source, MS. Plonk your 200 bucks down and report it. If it is a REAL problem you will get your 200 bucks back if its YOU they keep it. ...

      They do not respond well to 'its broke fix it'.

      Gee, and I thought my MSDN Enterprise subscription would be sufficient. Why should I plonk down $200 to report a bug? I didn't want an immediate fix, we already had a workaround. I just wanted to report a bug. I had sample data and exact steps to reproduce it.

      Instead I simply stopped using C# and went on to better things. I'd rather have a language and implementation that works, and has a useful community than one that MS is pushing as 'the next big thing'.

    7. Re:Ask a stupid programmer.... by emarkp · · Score: 1
      [somehow, this reminds me that C++, spec-wise, allows you to explicitely tell the compiler what you're likely to throw(), the way java does ... i believe MS VC 6 never got around to supporting that?]
      Exception specifications are not for declaring what you're "likely to throw" but rather what you're allowed to throw. Throwing something else results most likely in program termination. Indeed, if the spec is only what's likely, there's little point. Use a comment instead. If it is what's allowed, then there's the question of how it should behave if something else is thrown. Even the latest version of MSVC doesn't support it.

      In fairness, all of the articles I've read have suggested that exception specs aren't very useful and add significant compiler complexity and runtime overhead. Until I see why they are useful (or "export" as well, for that matter), I'm not going to seriously criticize an implementation that doesn't support them.

    8. Re:Ask a stupid programmer.... by emarkp · · Score: 2, Insightful
      It's amazing what gets marked as "Insightful" around here.
      Ah, when asked to defend the indefensible (C's insane design) instead declare yourself an expert and attack the person raising the issue as " lazy and/or incompetent".
      Um, no. I was responding to the so-called "low-level problems" of C++ (not C). Null pointers are useful in a function to represent an object, or the fact that an object is not available. Dereferencing a null pointer is a logic error, because it means the object isn't available. Dereferencing it means your logic doesn't know the difference between a valid object and a non-existant object. Failing to understand the difference is a mark of incompetence or laziness. Hence my comment. Most memory leaks can be eliminated with auto_ptr (now in the standard for 6+ years) or boost's smart pointers. Simply slapping garbage collection onto a language doesn't solve this. In the case of C#, you lose deterministic destruction, which means that you can't properly clean up objects that are owned by the object being destroyed. C# forces you to kludge around this by checking to see if the object is being disposed of manually, or by the system, e.g.:
      protected virtual void Dispose(bool disposing) {
      if (!_disposed) {
      if (disposing) DisposeManaged();
      DisposeUnmanaged();
      }
      _disposed = true;
      }
      Of course, this fails in a multithreaded program. So you have to lock the internal variable if you want thread safety.
      The problems cited are language problems. Yes, you can do workarounds and never create a bug but a competent language should make it easier to write bug-free code not add land mines to swagger over.
      Sorry, they are not language problems. Real language problems in C and C++ are e.g. integer promotion rules and syntax ambiguities which sometimes parse a function call (typically a constructor) as a function declaration. If you still think these are language problems, be honest and point out that C# has them too. For instance:
      SomeObject oops;
      using (SomeObject so = new SomeObject())
      {
      oops = so;
      }

      oops.DoSomething(); //BOOM!!!
      And the garbage collection doesn't help with database connections, graphics widgets, etc. You must manually dispose them if you want them to work reasonably. How, precisely is this any better than manual destruction?
    9. Re:Ask a stupid programmer.... by StrawberryFrog · · Score: 1

      It's amazing what gets marked as "Insightful" around here.

      Indeed it is. C and C++ programs are good in their place, but are not the right tool for every job. Java and C# (excuse me if I can't make a big whoop of the distinction right now) often are.

      BTW, you do know how C# blocks use of unitialised object references or do you just like throwing insults?

      --

      My Karma: ran over your Dogma
      StrawberryFrog

    10. Re:Ask a stupid programmer.... by William+Tanksley · · Score: 1

      Yes, null pointers are logic errors. Allowing them is a logic error. Putting them in an API is a logic error.

      Don't use null pointers.

      Unless you're stuck with C, of course.

      The problem with nulls is that they can hide for a LONG time before they finally reveal themselves. There are two replacements: exceptions and "null objects". Exceptions should be used when a null pointer would have been returned to indicate an error; null objects can be used when a object representation of "no such object" is actually needed.

      Both have their risks, but both are far safer than null pointers.

      -Billy

    11. Re:Ask a stupid programmer.... by Anonymous+Brave+Guy · · Score: 1

      I understand both arguments here, and I think there's an element of truth to each. NULL pointer problems are invariably logic errors, yes. But they should also be preventable logic errors; the reason they're not is that C (and, to an extent, C++) do not offer sufficiently powerful high-level features that programmers can avoid low-level nastiness like pointers unless they're really necessary.

      The solutions you mention -- exceptions and null objects -- both have their place. So do neat constructs in C++ like:

      if (derived *pDerived = dynamic_cast<derived*>(pBase)) {
      // Do something with derived types only
      }
      // pDerived no longer in scope, so can't use by accident

      However, NULL pointers are and always have been a nasty, low-level concept. They don't really mean anything in themselves, they're just used to indicate special cases. Consider a hypothetical language that has

      • a solid exception mechanism, for reporting errors
      • good support for both disjunctive and conjunctive types, for handling functions that can sensible return several related but different types of information (e.g., a search function that returns "didn't find anything" or information about one or more types of thing that were found)
      • a solid object lifetime model
      and you're just rendered NULL pointers irrelevant. Instead of risky dereferencing of pointers, you have pattern matching on disjunctive types, so you can only "dereference" in a context where it makes sense. Instead of using "signature values" to indicate errors, you either throw exceptions of as many types as are appropriate, or in non-exceptional cases such as a search not finding anything, you return a disjunctive type. There is no concept of an object disappearing, because you set up the rules such that objects can't disappear when they're still accesssible.

      Now consider that all of these features are available, today, in many different languages, and the argument that NULL pointers are a low-level problem also has a lot of merit.

      --
      If you disagree, post your argument. (-1, Overrated) isn't your personal censorship tool for views you don't like.
  66. Still no "throws" by flashbang · · Score: 1

    I didn't see it in the doc - the one thing that would really make this language a bit better - the "throws" keyword. Right now, you can't define an operation to throw an exception that the calling operation must catch. Blah.

    If you are going to copy Java, at least get the important stuff in there..

    --
    My sig left me for a younger user id.
    1. Re:Still no "throws" by Anonymous Coward · · Score: 0

      Try searching for "throw" instead of "throws". I've never understood why Java forces developers to catch exceptions they don't care about anyway.

    2. Re:Still no "throws" by Anonymous Coward · · Score: 0

      It's there. It's called "raise".

    3. Re:Still no "throws" by Anonymous Coward · · Score: 1, Informative

      C# does not support checked exceptions (so now "throws" declaration). Anders Hejlsberg, one of the C# language designers, discussed why this is in a recent interview:

      http://www.artima.com/intv/handcuffsP.html

      Basically, the C# designers have serious concerns about checked exceptions: they don't scale and can cause versioning problems. Read the interview, it is interesting.

    4. Re:Still no "throws" by Ancil · · Score: 0, Troll

      Goodness no. I always hated that about Java. It's a nightmare on big projects, and doesn't really serve to clarify code. Eventually, a lot of functions just end up with "throws Exception".. Either that or you start just throwing subclasses of RuntimeException. Blech.

    5. Re:Still no "throws" by Robb · · Score: 1
      Based on a lot of experience with exceptions in several languages my opinion is that exceptions that the calling operation must catch are a major design flaw.

      Most of the time the calling operation can't do anthing so you just clutter it up throwing the exception to the next level. If the calling operation can do something then this means that the calling operation most likely should have anticipated and prevented the exception in the first place.

    6. Re:Still no "throws" by jasonsingha · · Score: 1

      Java's checked exceptions are terrible! What I would like to have instead is a "doesn't throw" declaration. That way I could say a routine doesn't throw a certain type of exception and then I can have the compiler check this based on all of the information it has.

    7. Re:Still no "throws" by Anonymous Coward · · Score: 0

      He's wrong on the versioning issue, changing the exceptions thrown from a method doesn't change the signature.

      I find checked exceptions useful in some situations, so I'm glad they're there in Java. But they also have unchecked exceptions for the concerns the C# team have.

      So I guess I'd rather see both in a language and let the coders decide whether or not to use them.

      The real problem with checked exceptions is their overuse in the JavaAPI, which people tend to use as a model/example and so checked exceptions are overused.

  67. Re:this is fantastic by AstroDrabb · · Score: 1
    Miguel de Icaza? Did you hi-jack that nick or are you really Miguel de Icaza of Ximian fame? I hope not since it sounds like you are selling out to MS. You really think they are "true innovators"? How quickly you forget all the nasty acts of MS that has brought tons of anti-trust suits against them.
    No more hidden APIs or secret protocols from the boys at Redmond - from here on its all public domain open standards.
    Oh great, so where can I download the specs for the MS document formats, the Windows media formats, etc, etc.? Do you really think that .Net won't be "extended" in some way if it ever caught on big time? MS will just "enhance" it with some MS specifics and thus make most apps MS Only again.

    It sounds like the good ole greenback has caught your tongue.
    --
    If Tyranny and Oppression come to this land,
    it will be in the guise of fighting a foreign enemy. -James Madison
  68. Re:moving towards bloatware or are these important by Anonymous Coward · · Score: 0

    Yeah, well the old adage doesn't take into account backwards compatibility. The idea is that you're not finished until you've removed everything you can, and you assume that nobody will be using it until you're finished.

    Anyway, in this context, "remove" would roughly mean "deprecate."

  69. Not quite the same thing. by devphil · · Score: 3, Informative


    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)
    1. Re:Not quite the same thing. by BigGerman · · Score: 1

      Exupery was definitely not an "aircraft designer". Just a French pilot (commercial and later American military) and writer.
      And Little Prince is still available in US but translation was really bad.

    2. Re:Not quite the same thing. by devphil · · Score: 1


      I've seen pseudo-blueprints of airplane designs by him; he was definitely designing something.

      Good to hear that L.P. is still available, in some form at least.

      --
      You cannot apply a technological solution to a sociological problem. (Edwards' Law)
  70. Re:Who gives a shit about C# by Anonymous Coward · · Score: 0

    Insightful?

    C# is BOTH an ECMA and an ISO standard. No one here knocks ECMAScript (oh - I'm sorry - you probably know it as JavaScript), C or C++ because they have all been standardized by at least one of those bodies...

    While ECMA does allow for patent-encumbered standards it is my understanding that ISO does NOT. Anything standardized by ISO may be implemented by ANYONE - royalty-free.

    C# and .NET have been commercially available since Feb/02 - you'd think by now the "nerds" here at slashdot would have a clue.

  71. Well... by Anonymous Coward · · Score: 0

    If you're going to be all snotty about the whole thing, how about the fact that Enums are perfectly usable as-is in Java today? Read the section on enums in "Effective Java".

    If you want to, you can compile Generic in Java today using the pre-release compiler and use the bytecode in exiting VM's (there are a few more subtle things you can't do without 1.5, but even so). The Generics support in Java has actually been ready to go for a few years now, if you want to harp on "reality". .Net would have it now of course but they were waiting to steal the polish specs from Java's JSR's (Hmm, if MS is stealing from Java's JSR's, how much more "real" does that make generics in .Net?)

    C# is production quality, I guess... as long as you don't try to deploy it. Just ask Qwest about that (reason I'm posting anon). I think they might have an answer to your point three.

    As to point four - are they really there yet? Where are the large scale .Net sites? Sure for toy stuff it works just fine. Try doing anything real though...

    1. Re:Well... by krumms · · Score: 1

      If you're going to be all snotty about the whole thing, how about the fact that Enums are perfectly usable as-is in Java today? Read the section on enums in "Effective Java".

      Get over it. I noted that I wasn't trying to be rude, saying so won't make your argument any more objective. So get over it.

      The enums described in Effective Java are still a hack. Or a big work-around. Or whatever. They're an improvement, mind you, but they only answer the type safety argument. Couple the fact that each and every enum field requires an instantiation of a new object (fine for small projects, but this will adversely affect startup time on larger ones), and the fact you have to perform all sorts of clunkyness just to get them to work, and you have a patchwork solution. C#'s solution is better. Period.

      If you want to, you can compile Generic in Java today using the pre-release compiler and use the bytecode in exiting VM's (there are a few more subtle things you can't do without 1.5, but even so). The Generics support in Java has actually been ready to go for a few years now, if you want to harp on "reality". .Net would have it now of course but they were waiting to steal the polish specs from Java's JSR's (Hmm, if MS is stealing from Java's JSR's, how much more "real" does that make generics in .Net?)

      Where did I mention generics? Again, I was referring to the current release of C#. Microsoft is "stealing" from JSRs in the same manner that Sun "stole" from C++. Would Java look different if it wasn't for C++? Would it even exist? Would C# exist if not for Java? You're argument appears to be "But they're stealing from a thief". And hey, it wouldn't be the first time.

      C# is production quality, I guess... as long as you don't try to deploy it. Just ask Qwest about that (reason I'm posting anon). I think they might have an answer to your point three.

      I don't know what you're talking about here. I had a bit of a look around but was unable to find any further info. Elaborate? Sounds like you're bordering on the "ASP.NET" argument that follows ...

      As to point four - are they really there yet? Where are the large scale .Net sites? Sure for toy stuff it works just fine. Try doing anything real though...

      And here you step into the realm of ASP.NET - yeah, ASP.NET sucks! But I'm not talking about ASP.NET - I'm talking about C#, the language. ASP.NET itself is extremely awkward.

    2. Re:Well... by Anonymous Coward · · Score: 0

      Microsoft is "stealing" from JSRs in the same manner that Sun "stole" from C++. Would Java look different if it wasn't for C++? Would it even exist? Would C# exist if not for Java? You're argument appears to be "But they're stealing from a thief".

      One difference is that Sun have usually been quite open with who they "borrow" from. They acknowledge that JDBC is a copy of ODBC. They have always stated that Java builds on the syntax of C/C++ to make transition easy for programmers of those languages.

      Microsoft on the other hand, first tries to embrace and corrupt by adding MS specific code into the Windows version of the Java core, in the childhood of Java, killing off platform compatibility. Sun had to take them to court to stop, and have ever since been more paranoid about protecting Java. If not for MS they might have been much more open about it than they are, it is brave of them to do the JCP as it is. Then MS spread a lot of FUD, and in the meantime make a complete copy where even class names are similar, and nowhere acknowledge who they are copying except by constantly comparing with it and spreading more FUD.

      So no, Sun does NOT "steal" as MS steals (note lack of quotes here).

    3. Re:Well... by aminorex · · Score: 1

      I'm not trying to be violent, but (*bang*!)

      Kinda like waging war in the name of peace.

      --
      -I like my women like I like my tea: green-
  72. Re:moving towards bloatware or are these important by RetroGeek · · Score: 1

    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.

    Yup. Java does this. It is called "deprecated". For instance parts of the Date class have methods which are deprecated. The method's functionality has been moved to the Calendar class.

    It still works, but the compiler gives you a warning.

    --

    - - - - - - - - - - -
    I am a programmer. I am paid to produce syntax not grammar. Deal with it.
  73. Re:moving towards bloatware or are these important by Anonymous Coward · · Score: 0

    Its a spy *GET* him. /*pulling out the burnning torches*/

  74. still the biggest failure of C# by Anonymous Coward · · Score: 0

    is the recommendation in the examples and in the official guidelines to use shorthand style of writing code. On a project bigger than 2-3 people, having thorough and accurate comments and documentation is very important for integration and efficiency. Microsoft still doesn't get the biggest challenge of large corporations. Managing code. Keeping the same f-ed up coding recommendations has to change, if Microsoft really wants to gain serious tracking beyond their core customers.

  75. THIS IS A TROLL by Rob+Riggs · · Score: 1

    The real Miguel de Icaza is miguel (7116).

    --
    the growth in cynicism and rebellion has not been without cause
  76. Re:Linking to a .doc file is evil by Anonymous Coward · · Score: 0

    mmmmmm tasssssssssssty

  77. Re:Who gives a shit about C# by fikuvin · · Score: 0

    Actually, C# is an ISO standard (ISO/IEC 23270), which is far more open than Java ever will be under Sun. Oh, and before you accuse me of kissing Bill Gates' ass, be sure to take Scott McNealy's dick out of your mouth first.

  78. Parent is NOT Miguel de Icaza by revividus · · Score: 1
    If you click on his nick and look at his page you find this text:
    i play a pivotal role in a grand conspiracy to cripple the free software movement from within, by covertly embedding an unnecessary, yet seductively useful, patented technology in the very heart of the linux operating system's second most popular desktop environment.

    This is Miguel de Icaza? I don't think so. Look for miguel.

    1. Re:Parent is NOT Miguel de Icaza by Anonymous Coward · · Score: 0

      I would like to discuss this further. I think you are very insightful. Is it alright if I email you at pcrissman@comcast.net? Thank you. I look forward to our time together.

  79. Re:Who gives a shit about C# by User8201 · · Score: 3, Funny

    "C# is ECMA standardized"

    BWhahahaha, you fell for that, huh? Propaganda makes trolls all over the world.

  80. here comes more bugs by Anonymous Coward · · Score: 0

    From a commercial perspective i see this as a bad thing. just plain C is a fine language. c++ is really just encapsulation for C. Most people dont even use a small part of C++ or know how to use it correctly. The more extensions a language has , the more variation in coding styles there are and thus the harder code becomes to maintain increasing the probability of long term bugs. All these new language extensions just suck in the juniors into trying to learn everything without proper mentoring and thus ending in programming disasters.

    All the new extensions i see are really just something for product differentation in the marketing department. Otherwise what are these companies going to sell. The only other possibility is to add more plugins but that makes it harder to differentiate between personal, proffessional and enterprise editions.
    IT also allows discontinuation of old products which forces larger companies to buy more copies of the new compilers to keep things in the company consistent and maintain support.

    Of coarse universities will get sucked into this as they have to use something to teach. whats more this will frustraite many commercial entities because they want experienced programmers in the languages they know and USE. Otherwise its added cost of teaching a new language and YES it does matter if your working for a company in a competative market. Things like this will only add a couple of years to many development cycles.

    There are some areas where changes and extensions should be made. However this should be language refinement, not entire blocks of change to structure. Otherwise its a bit like chaos theory and who knows where we will end up.

    Areas for change might include things for switchable support modes for things like handel C(maybe inline even) , albiet most here wont know what thats about, but would provide exposure to a large audience of alternative computation techniquire and potentially open up new markets and vastely increase perfomance while simplifying program structure. But that would be to speculative for shortterm shareholder profit.

    All in all its just marketing, but too late the slippery slope is to slippery
    greg

  81. ugh by autopr0n · · Score: 1

    What a shitty school. What the hell is the point of learning Pascal->C? Pascal and C are basically equivalent, except hat Pascal is much more Obsolete. And what's the point of learning C before C++? You can do anything in C++ that you could do in C, and you often have to do crappy things in C that would be much cleaner in C++.

    At our school C# is an elective.

    --
    autopr0n is like, down and stuff.
    1. Re:ugh by Slime-dogg · · Score: 3, Insightful

      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++:

      void f(); /* argument types not mentioned */

      void g()
      {
      f(2); /* poor style C. Not C++ */
      }

      Or...

      void* malloc(size_t);

      void f(int n)
      {
      int* p = malloc(n*sizeof(char)); /* not C++. In C++, allocate using `new' */
      char c;
      void* pv = &c;
      int* pi = pv; /* implicit conversion of void* to int*. Not in C++ */
      }

      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.
    2. Re:ugh by jhunsake · · Score: 0

      Alright dipshit....

      f(2) would not compile in ANSI C.

      malloc() can be used in C++, it's right there in the standard library. How do you think new() is implemented?

      There is no pointer conversions in ANSI C except to void*.

      Stop trolling.

    3. Re:ugh by Anonymous Coward · · Score: 0
      f(2) would not compile in ANSI C.

      Yes is would. In ANSI C89 (not sure about C99, I think it's deprecated), writing void f() leaves the parameter list unspecified, and the compiler assumes ints when you pass parameters. In C++, writing void f() specifies no parameters. The equivalent in C89 is void f(void).

      Observe:
      $cat test.c
      void f()
      {
      }

      int main()
      {
      f(2);
      return 0;
      }

      $gcc test.c

      $cp test.c test.cpp

      $gcc test.cpp
      test.cpp: In function `int main()':
      test.cpp:2: too many arguments to function `void f()'
      test.cpp:7: at this point in file

      And for the record, a void* may be converted TO any other pointer type without a cast in C, but you technically need a cast in C++ to do the same thing. Writing {int* x = malloc(sizeof(int));} in C++ is technically an error because there is no cast from the void* returned by malloc, and it is not an error in C. G++ gives the warning, "ANSI C++ forbids implicit conversion from `void *' in initialization", or "... in assignment" depending on what you're doing.

    4. Re:ugh by Anonymous Coward · · Score: 0

      At my school, we were taught the science and the technique; they didnt waste their time teaching us languages. Whats the point??

      Languages are just tools, and not really overly difficult to pick up.

    5. Re:ugh by edalytical · · Score: 1

      Because Pascal is gentler for a first year CS student. Some students have had very little experience programming. Pascal is more english like and less cryptic than C. It is also a lot easier to get yourself into a mess with C. Pascal is used mostly to teach sequence, selection and repetition.

      Our C class was really C++ without objects. We used iostream instead of stdio.h so I guess you can call it a C++ class, although saying "C++ without objects" is kind of awkward. C is for when you start really getting into programming, algorithms, recursion, arrays of function pointers, and other fun things.

      As you might have guessed our C++ class introduced object oriented programming. C++ teaches object oriented programming, if thats no being over obvious.

      --
      Win a signed Stephen Carpenter ESP Guitar from the Deftones: http://def-tag.com/?r=0008781
    6. Re:ugh by Anonymous Coward · · Score: 0

      How do you think new() is implemented?

      With a function obj_mem_alloc() that does some type checking, then calls mem_res() which in turn directly calls malloc() from C. Three functions are better than one!

    7. Re:ugh by jhunsake · · Score: 0

      Moron...


      $gcc -std=c89 -pedantic test.c
      test.c: In function `int main()':
      test.c:2: too many arguments to function `void f()'
      test.c:7: at this point in file

    8. Re:ugh by Detritus · · Score: 1
      The Swiss are already spinning up the gyros in their ICBMs.

      Pascal was designed to teach programming to ignorant college students. It is a relatively small language that is easy to implement. Students hate it because of its "bondage and discipline" approach to type checking.

      C and C++ are inappropriate first languages for students. They assume a depth of knowledge, maturity and self-discipline that only comes with experience and education.

      --
      Mea navis aericumbens anguillis abundat
    9. Re:ugh by Darren+Winsper · · Score: 1

      Let me get this straight, they're teaching you language features of C++ whilst claiming to be a C class. What will all these people do when they actually have to code in C and suddenly discovered they don't actually know C, they know a subset of C++?

    10. Re:ugh by laa · · Score: 1

      Pascal is in no way obsolote, there's a milloin Delphi coders out there...

      But the point is not what language syntax is taught. Once a student knows how to program, that knowledge can be applied to almost any programming language that happens to be trendy at the time. Pascal is a good clean nice langauage to teach procedural programming with. Many prefer Java when teaching object-oriented programming (even if Object Pascal is a nice language, too). Functional programming is the same, learn the concept of functional programming and you can apply it to almost any functional programming language.

      Yes, there are differencies between languages, you have to learn the pitfalls och each language. But, learning how to really program is way more important than the syntax you used when doing so - the programming language will change during your time as a programmer several times anyway.

      --
      Why does the kernel go through stable and then unstable forks? Can't it always be a stable build, like with Windows?
    11. Re:ugh by sco08y · · Score: 1

      What will all these people do when they actually have to code in C and suddenly discovered they don't actually know C, they know a subset of C++?

      The whole point of learning it in a class is to learn the fundamentals. Once you understand I/O, it doesn't matter if you're using stdio or iostreams, the concepts are the same and you just look up what you need.

    12. Re:ugh by Doomdark · · Score: 1
      You also cannot do anything in C++ that you can in C.

      I take it you misspelled something in that sentence? I'm pretty sure I can think of a few things one can do in both languages, even using exactly same syntax :-)
      In fact, it would be hard to design a language that can not do anything C can.

      --
      I like paying taxes. With them I buy civilization -- Oliver Wendell Holmes
    13. Re:ugh by Darren+Winsper · · Score: 1

      Except they're being taught things like "C supports streams", which it clearly doesn't. It's misleading and likely to confuse the students. In fact, seeing as you're now labelling it as some sort of "fundamentals of programming" course, why isn't it called that? None of my modules have ever been named after the languages used to teach it. Sorry, I tell a lie, I had a 2-day "crash course in C" module.

    14. Re:ugh by autopr0n · · Score: 1

      What will all these people do when they actually have to code in C and suddenly discovered they don't actually know C, they know a subset of C++?

      I dunno? The same thing they might do when they actualy have to code in VB, or COBOL or scheme or Python? Like Learn it? Or do something else?

      --
      autopr0n is like, down and stuff.
    15. Re:ugh by jeremyp · · Score: 1

      Pascal is an excellent language for learning the fundamentals of programming. Fo a start, the syntax is a little more friendly to the beginner e.g. uses begin....end instead of {....} for blocks. Secondly you are more insulated from the underlying machine e.g. running off the end of an array will generate some sort of error instead of carrying on possibly with unexplained weird behaviour.

      Once somebody has picked up the fundamentals, then I'd move them on to the "real" langiuages.

      --
      All I want is a secure system where it's easy to do anything I want. Is that too much to ask ~~ Randall Munroe
    16. Re:ugh by Haeleth · · Score: 1

      > In fact, it would be hard to design a language that can not do anything C can.

      BASIC?
      COBOL?

    17. Re:ugh by Sique · · Score: 1

      They can do the same, it's just harder. Remember the times when you were doing OS coding with PEEK and POKE on a C= 64 ;)

      There is something called Turing equivalent, so every language you can implement an universal Turing machine in is able to implement every other Turing machine. For this you basicly need three instructions: Increase Field, Decrease Field and Jump, if last operation yield NULL as result.
      Of course you can limit a language by other means, sandboxing for instance, but this limit is not part of the language, rather a limit of the actual environment.

      --
      .sig: Sique *sigh*
    18. Re:ugh by Doomdark · · Score: 1
      The other poster gave tbe "definitive" proof, but consider the fact that I could easily create "hello world" app in both C and one of basic flavours of the day. I would also assume Cobol is capable of doing that task.

      Perhaps you read my statement to say "everything C can".

      --
      I like paying taxes. With them I buy civilization -- Oliver Wendell Holmes
    19. Re:ugh by marcovje · · Score: 1

      Pascal was meant for educational system, just like C was never meant for applications programming, but for systems programming.

      Pascal changed much more over time than C did. The most used Delphi languages are closer to C++ than to C.

  82. Also including several patents... by Anonymous Coward · · Score: 0

    Seriously. Anyone believes Microsoft didn't apply for a series of patents related to this whole C# thing? Regardless of merit, of course, which seems to be something the USPTO doesn't care about.

    And what's to become of Mono when their lawyers come asking for money?

  83. Who gives a shit about the ECMA? by qtp · · Score: 1

    Who the hell is the ECMA?

    Look at thier site.

    Aparently people cannot be members, only companies and universities (non-profit companies)

    Why not an IETF standard?

    They've served very well so far.

    Sun has repeatedly balked at standardizing Java due to the inherent loss of control.

    I was pretty sure that Sun had published a Java standard. How is a standards org comprised of Micriosoft and it's vassals any better? I was under the impression that the only company that had problems with the Java standard was the one company that had attemped to hijack the standard by implementing undocumented extensions and breaking Suns published standard in order to make users dependant on thier own crappy browser. (Before any of you attempt to defend IE, please try using at least one other modern browser.)

    Have things changed so much that we can trust Microsoft and its "standards body" largely consisting of companies dependent on Microsoft to keep all extensions to this "standard" in the open and available to all players? Can we trust them to not later replace the "standard" with propietary replacements requiring either licensing or a switch of platform to a Microsoft product?

    Microsoft has attempted to hijack widely accepted standards in the past, is there any indication that this copmpany even knows what the word means?

    --
    Read, L
    1. Re:Who gives a shit about the ECMA? by Arker · · Score: 3, Insightful

      Have things changed so much that we can trust Microsoft and its "standards body" largely consisting of companies dependent on Microsoft to keep all extensions to this "standard" in the open and available to all players?

      Of course not.

      But those who don't remember history are doomed to repeat it.

      --
      =-=-=-=-=-=-=-=-=-=-=-=-=-=-
      Friends don't let friends enable ecmascript.
    2. Re:Who gives a shit about the ECMA? by Anonymous Coward · · Score: 0

      > Why not an IETF standard?

      The Internet Engineering Task Force does not standardize programming languages, you subhuman dolt.

      And C# has actually also been standardized by ISO -- the same people who put the holy pee on C, C++, etc.

    3. Re:Who gives a shit about the ECMA? by Anonymous Coward · · Score: 0
      And C# has actually also been standardized by ISO

      This means shit.

      It does not mean the standard API is standardized.

      It does not mean the there are not propriatary patents.

      It does not mean the standard API doesn't have patents.

      It doesn't even mean that you know what you're getting.

      JavaScript is also an ECMA standard, and we all know how well it from browser to browser.

    4. Re:Who gives a shit about the ECMA? by Anonymous Coward · · Score: 0

      The class library is standardized.

      And, I bet you can't name one language feature of ECMAScript that varies from browser to browser. The problem is in non-standard DOMs.

    5. Re:Who gives a shit about the ECMA? by azaris · · Score: 5, Informative

      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?

    6. Re:Who gives a shit about the ECMA? by Zontar+The+Mindless · · Score: 1

      > JavaScript is also an ECMA standard, and we all know how well it from browser to browser.

      Bad example. Mozilla/Netscape let you access characters within strings using array notation and methods defined internally to classes as public methods, whereas Microsoft's implementation doesn't let you do these things. Those are the just about the only major differences in their JavaScript implementations. Otherwise, they both do an excellent job of supporting ECMA-262.

      So... you use charAt() and remember to bind all class members that you want regarded as public to prototypes, and move on.

      The various DOM implementations are a somewhat different story. However, there's now a higher degree of convergence between the version 6+ browsers in this regard than there's been since before NS 4 and MSIE 4 came out, and it's now possible to do quite a lot of interesting and/or useful stuff that works the same in NS, IE, and Opera without doing any branching whatsoever. (Particularly if you ignore NS 4 and MSIE 4, which I've been doing for about the last year and a half.) Some of the event-handling is a bit different, and so is retrieving computed style information. Hopefully MS will add support for the W3C ways of doing these things eventually.

      At any rate, don't confuse JavaScript language implementation with object model support. That's like saying that GTK and QT implement C++ differently.

      (BTW, JavaScript also supports lambda functions, and you can nest them as deep as you want, which IMO is one of the insanely cool things about it -- particularly where event handling is concerned.)

      We now return you to your regularly-scheduled flamefest.

      --
      Il n'y a pas de Planet B.
    7. Re:Who gives a shit about the ECMA? by blair1q · · Score: 1

      >>Why not an IETF standard?
      >
      >Hint: the "I" stands for Internet. What does C# >have to do with the Internet?


      C# was (intended to be) designed to be a portable language for internet applets. As such, it should be standardized by the same body that standardizes other Internet features, so that the several standards interoperate correctly.

    8. Re:Who gives a shit about the ECMA? by Anonymous Coward · · Score: 0

      Of interest - how open standard _is_ the "Common Internet Filesystem"? Thats the last MS Open Standard I remember, and just how open that is!

    9. Re:Who gives a shit about the ECMA? by Haeleth · · Score: 1

      I seem to remember being bitten a while back by the way IE's JavaScript implementation allowed array access with (), while Netscape required the standard []. Combine this with a programmer who thought that he was improving interoperability by moving away from VBScript (guess what that uses for array access?), and chaos ensues.

      Of course, that was a while back, like I said.

    10. Re:Who gives a shit about the ECMA? by Zontar+The+Mindless · · Score: 1

      > I seem to remember being bitten a while back by the way IE's JavaScript implementation allowed array access with (), while Netscape required the standard [].

      Oops, I forgot about that.

      (I learned JS first, so I never had that problem.)

      There are some additional differences in ASP, like where you have to use enumerators and the item() method to loop through what are implemented in VBScript as arrays, too, IIRC.

      --
      Il n'y a pas de Planet B.
  84. booooring by autopr0n · · Score: 1

    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.

    It's good to see commercial competition adding new features to commercial languages, although I hope they don't get so feature bloated they become like Perl.

    --
    autopr0n is like, down and stuff.
    1. Re:booooring by penguin7of9 · · Score: 3, Interesting

      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.

    2. Re:booooring by Anonymous Coward · · Score: 0

      Look, I actually like it that way. I don't really see the benefit of changing VM's for that kind of features. If you need it, you can allways go native. There's plenty of people that don't need or miss those that much in Java. And there are sure plenty of diferent VM's out there. I kind of respect Sun for that...lots of pressure to tweak, and hell lot of other vendors with investments in VM's, even hardware accelerated ones. MS choose to change their because they probably don't give a shit about others trying to implement it. And it isn't as widespread as Java. And don't think that they didn't piss of some people with that change.

    3. Re:booooring by Anonymous Coward · · Score: 1, Insightful

      The reason the change wasn't made wasn't only up to Sun. Java as a language is developed by the JCP. Java out of the box is built on the write one run everywhere premise. It's not just a simple change to one platform that Sun would have to make, but a change to every vendor's VM implementation, and backwards compatibility would break, meaning no existing VM could run the code.

      Now let's take MS and it's alturistic willingness to make choices that break compatibility and put it in context. Heads up, they want you to have to upgrade to the next version of Windows. They dont care if they break older versions because it means more money for them. I'd go as far as to say, if the language become the primary development language for windows look for big changes as often as the .net framwork or windows changes.

      Java is maturing as a fine language lead not by Sun, but by the comunity of users and developers and I have no doubt that when the time comes to clean out the cruft for Java 3 we'll see all of the type safty maintained. Java was designed from the start to be cross platform first and with type safety and the rest as secondary goals. They've maintained the bytecode compatibility because this is not a new version, it's supposed to become a part of the Java 2 platform.

      Only Java 3 will tell if I'm full of shit. :)

      See and join the JCP, if you care to do more than just complain that they didn't do what you wanted. http://www.jcp.org/en/home/index

    4. Re:booooring by kryps · · Score: 3, Informative
      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.
      You don't know what you are talking about. The JSR 14 generics proposal offers compile-time type-safety while retaining compatibility with old (i.e. not generified) libraries. That means as long as you do not use "raw" types (e.g. Vector instead of Vector<String>) type safety is guaranteed and the compiler will emit a warning (and probably even an error in future versions) if it encounters usage of a raw type.

      -- kryps
    5. Re:booooring by ChicagoDave · · Score: 1

      I think there's a pretty large assumption made by the anti-.NET folks that have never actually looked at how .NET functions.

      One of the things that seems abundantly clear is the misconception that if an API changes, this will break a lot of legacy .NET code. This is inherently not true. One of fundamental .NET design requirements was to specifically combat the complaint of broken API's.

      When 2.0 comes out, you could have three versions of the .NET environment coexisting on the same server (adding to 1.0 and 1.1). Not only that, but you will also be able to mix code as your systems grow. If you have code written for the 1.1 framework and need to add more code, you can write the new code in any of the available versions and have it work seemlessly. It's impossible to break compatibility in .NET.

      Of course the big assumption from MS-haters is that they will somehow make a patch to 1.0 or 1.1 that breaks some API. MS doesn't need to do this because they're not rewriting the same API structure over and over like they did with MFC. When they need to change an API, that gets rolled into the next release of .NET. Of course there have been patches to the current versions, but those have been very minor and I haven't heard of anyone being affected by those changes.

      A note here: All .NET assemblies (packages in Java) are signed with their associated .NET runtime. An assembly signed with 1.1 wouldn't run in 2.0 and vice versa. But as long as you have both runtimes, they will work perfectly fine _and_ be able to talk to each other.

      As for C# being an open process, it is. You'd be shocked at the level of responses you will get from the C# development team when asking about features. And they listen. The fact that it's only a handful of people at Microsoft shouldn't scare you. If you went to the PDC, they're going to be running around with C# Development Team t-shirts and have openly asked people to track them down with questions about the direction of C#.

      Try that with the JCP.

      --
      http://chicagodave.wordpress.com
    6. Re:booooring by bwt · · Score: 2, Informative

      on some theoretical JIT, might actually run faster than a snail.

      You do know that java is faster than C# for non-GUI apps, right? source. I suspect that if you dump swing and go with the eclipse SWT, you probably equalize the GUI speed issue too, which would mean that on windows platforms Java is faster than C#.

      The "java is slow" reputation was earned with java 1.1 and was fixed long ago when the JIT VM's came out (they are part of all modern JVM's). Memory use issues might give you a real issue to knock java on, but you really shouldn't repeat untrue lore.

    7. Re:booooring by penguin7of9 · · Score: 1
      You are quoting out of context. I wrote:
      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 was referring specifically to Java's multidimensional arrays.

      As for Java's speed in general, Sun's Java implementation is currently faster than Microsoft's C# implementation or Mono (Sun has had seven years to hack it, fater all). But Java-the-language has intrinsic limitations that make it dreadfully slow for many applications, among them the lack of multidimensional arrays and the lack of value classes. Try implementing an efficient complex number class in Java, for example.
    8. Re:booooring by penguin7of9 · · Score: 1

      You don't know what you are talking about. The JSR 14 generics proposal offers compile-time type-safety while retaining compatibility with old (i.e. not generified) libraries.

      No, you don't know what you are talking about. But people can just dig through the specs and papers themselves to find out.

    9. Re:booooring by kryps · · Score: 1

      No, you don't know what you are talking about. But people can just dig through the specs and papers themselves to find out.

      Yeah, right. Why don't you go and present some facts instead of spreading FUD?

      -- kryps

    10. Re:booooring by penguin7of9 · · Score: 1

      As I was saying, read the PolyJ papers and read the design info on C# generics, then come back. They tell you why VM changes are necessary. You yourself pointed out a glaring type loophole: compatibility with the existing collection classes.

      Java's generics are a lousy compromise, driven by Sun's fear of breaking backwards compatibility. C# got it right: you have to change the VM and the libraries in order for generics to work right.

    11. Re:booooring by Anonymous Coward · · Score: 0

      Your source is sort of amusing in this case, not only because of it's limited value due to an absence of standards for implementation, but also because it doesn't say what you think it says. Now before I continue to insult you and give you some statistics based upon the data provided by that site, I'll first mention that I am personally responsible for a number of the submissions and optimizations for submissions (not for C# submissions) in the used programs (technically I submitted them to Doug Bagely, but the site you referenced has taken all of the code from Doug's and I can still see my work there), so I'm no stranger to the limitations and varying quality of the submissions.

      Now to get to my point: If you could actually read (something I would expect from a university student), you would be able to take in and process the information provided for the testing results of the submissions. Since you obviously are incapable of doing this, I decided that I would present the data to you in terms that your limited mental faculties can comprehend. I do this not because I like C# (I have superficial knowledge of it at best), but because I find the sort of intellectual dishonesty that you're partaking in so personally offensive that I would castrate you and lock you in a cell to spend the rest of eternity alone, so that you couldn't possibly spread your mental dysfunction to others.

      First we simply go about comparing the submissions that both languages have, since an absence of a submission does not make either language slower at accomplishing the ascribed task, it simply means that no one has offered to write a solution.

      A cursory glance shows that at almost every task C# beats the results of Java. Surely there must be more here, after all a Slashbot told me that this site contains evidence that Java is faster than Microsoft's C# implementation! So now we work the numbers a little...

      We see that the mean execution speed of the Java solutions is 2.14 times slower and that the median execution speed of the Java solution is 2.62 times slower. Blazing!

      Of course we can also look and see the most harmful data point for Java, which is the re-execution of Hello World several times. Ok, we've shown that that starting up the JVM is so expensive that it's not worthwhile to do frequently. Let's just remove that data point from both languages.

      This puts the mean execution speed of the Java solutions at 0.0251 times faster than the provided C# solutions, and median execution speed of the Java solutions at 2.37 times slower than the C# solutions. Java is owning it up here!

      Now we can look at the C# data points and notice that glaringly poor time for threading. Hmm, maybe the implementation is poorly optimized or maybe C# is rather poor at this. I don't know, I'm certainly not qualified to analyze C# code. Let's just toss out that data point for both languages for the Hell of it.

      This gives us a mean Java execution that is 1.59 times slower than the mean C# execution, and a median Java execution that is 2.37 times slower than the median C# execution. Java pwns again!

      If we look at the memory-usage statistics we see that C# is regularly beating Java here as well. Yeah, your "source" certainly shows that Java has improved remarkably in terms of speed, and regularly beats C# at the assigned tasks.

      Try again, this time using your brain.

  85. Continuations are very useful in AI by MarkusQ · · Score: 1

    Continuations are very useful in AI; often they are the only clean way of implementing a "hold that thought", which comes up very frequently in (for example) natural language processing. If you are trying to evaluate a sentence "as the words are coming in" by building a semantic structure that represents the meaning so far, you generally will want to be able to rearrange the semantic fragments based on later information. For example, if asked to name "the tallest person you know" vs. "the tallest person you know of who was president of the US" or "the tallest person you know could exist", etc. the search algorithm you build after the first words have been processed will be much less efficient than what you can morph it into after you know more.

    Why would you want to do this instead of waiting till the whole sentence has been processed? Because it more closely models how people actually think. People don't wait for you to hit "send" before starting to figure out the meaning of what is being said.

    -- MarkusQ

    1. Re:Continuations are very useful in AI by Anonymous Coward · · Score: 0
      You're, right: Whenever I'm jerking off a horse to collect his semen, and I get a cell phone call or any other annoying distraction, I find continuations very useful for "putting the horse on hold" while I talk on the phone. They're the only clean way to keep the horse from ejaculating, or walking off in boredom. I use continuations very frequently in my day-to-day work as a manual horse penis stimulator.

      Oh, do you mean Artificial Intelligence, not Artificial Insemenation? Never mind.

      -Emily Litella

  86. Re:That's great by AntiOrganic · · Score: 1

    Most people think that Windows programs will run in Linux.

    Oh wait...

    ;)

  87. C# generics on built-in types do not use boxing... by truth_revealed · · Score: 4, Interesting

    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.

  88. Recap: by pr0ntab · · Score: 1

    Yankees lost.
    C# to also feature T-expressions.

    --
    Fuck Beta. Fuck Dice
  89. is it going to be unencumbered? by penguin7of9 · · Score: 1

    This is a specification coming out of Microsoft that hasn't gone through a standards body. Do we know whether there are any intellectual property restrictions on implementing the C# 2.0 specifiation?

    It is a good sign that this document only has a copyright on it and doesn't require a license agreement to download. In contrast, the Java specifications you can only access under a restrictive license agreement that impose contractual obligations on you that go far beyond patents or copyrights (note to open source developers: don't access Sun's Java specifications--you'll be tainted).

    But that still leaves patents for C# 2.0. Do we know whether there are any? ECMA C# (the previous version) appears to be free and clear, but what about this version?

    1. Re:is it going to be unencumbered? by Anonymous Coward · · Score: 0

      I think you better hold out, just to be sure. When the time comes, I'll launch a flare. One flare, start coding. Two, start running. Agreed?

    2. Re:is it going to be unencumbered? by Anonymous Coward · · Score: 0

      well, as you can see on the msdn page, this document is called a draft. I guess when it is finalized within the next months (or whenever) it will be submitted to ECMA as well, at least I hope so.

      I wouldn't worry about the fact, that it wasn't committed to ECMA yet, as the msdn page states, this is a draft of the C# 2.0 language specification.

  90. Iterators borrow from Python generators by elan · · Score: 1

    They even chose to use the "yield" keyword. This is a way-cool feature of Python and now C#.

    -elan

    1. Re:Iterators borrow from Python generators by chromatic · · Score: 1

      Coroutines go back a lot further than, say, 2001 (when Python 2.2 was released).

    2. Re:Iterators borrow from Python generators by Daimaou · · Score: 1

      That's exactly what I thought when I read the artcle.

    3. Re:Iterators borrow from Python generators by Robb · · Score: 1

      Python generators borrow from a lot of other previous work so unless the language designer said "We borrowed this from Python" then it is a bit difficult to say much about the lineage of iterators in C#. Of course I agree that it is a way-cool feature.

    4. Re:Iterators borrow from Python generators by Anonymous Coward · · Score: 0

      And Python borrowed it from Ruby (and ruby borrowed it from .....)

    5. Re:Iterators borrow from Python generators by Anonymous Coward · · Score: 0

      From skimming through C# 2 specs it seems to me, that the use of ``return yield'' in C# -2 iterators is closer to the yield in Ruby's inner iterators then Python iterators. Incidentally, another new ``way cool'' feature, closures (Python only supports a baby version) has also been a staple of the Ruby language for many years.
      That said I very much doubt that the C# development team was inspired by either Ruby or Python. Besides bread and butter, it is another must, to appear on the breakfast table of any language designer team.

  91. Re:Who gives a shit about C# by penguin7of9 · · Score: 1

    The language and virtual machine are fully documented,

    Yes, too bad that you can't make independent implementations of the language without violating Sun's patents and Sun's licenses on the specification (yes, the Java specification requires a license). (Of course, there are lots of third party Java implementations--Sun has been enforcing their intellectual property only selectively. But that doesn't change the fact that the specification is not open.)

    you can download the sources to jdk and libraries,

    If you are foolish enough to download and look at the sources to the JDK and the libraries, Sun has you in their pocket: any Java implementation you work on from then on may well be considered a "derivative work".

    and is much more open than C$, though less than others open source projects.

    That statement is implying that Java is somehow an "open source project". It is not. Java is a highly proprietary platform without even a free specification. And you are able to get the source code to Sun's Java implementation only under a restrictive, non-open source license.

    For ECMA C#, the specifications are open and (as far as anybody knows) without any legal restrictions on them. Furthermore, Mono is a fully open source implementation of ECMA C#.

    Microsoft .NET may be a proprietary platform, but so is Java. ECMA C# is an open and free language.

  92. Re:moving towards bloatware or are these important by penguin7of9 · · Score: 1

    These features are important: generics are needed for type safety, but they are also complicated. Lexical closures are really, really nice.

    In short, yes, any modern general purpose programming language needs these features, and Microsoft seems to have done a fairly good job in integrating them.

  93. Why C#? by Anonymous Coward · · Score: 0

    "If you can't do it in Fortran, do it in assembly language. If you can't do it in assembly language, it isn't worth doing." Read more: http://www.pbm.com/~lindahl/real.programmers.html

  94. don't you read telephone manuals!? by SHEENmaster · · Score: 2, Interesting

    It's Sea Octalthorpe. I would've called it ++C, but that implies that something is actually more advanced than C.

    Honestly why should one bother? It's neither portable nor natively executable. It's neither scalable to embedded systems nor to high-end servers. It has neither legacy code nor a bright future.

    Mono is a good start, but M$ will fight it when it starts to show results. .NET's pupose is not to allow Windows software to run on other platforms, but rather to help M$ capture more platforms. It's doomed from the beginning, and will be another forgotten buzzword within a few years.

    I like Java, I like C, and I like C++. Each of them rock and suck in different ways.

    --
    You can't judge a book by the way it wears its hair.
    1. Re:don't you read telephone manuals!? by zero_offset · · Score: 1
      0. The word is "octothorpe". I suppose you may have been trying to make a pun, but the funny part appears to be missing from your effort.

      1. Remind me what in C# makes it non-portable. It's highly non-platform-specific. You're probably thinking of .NET, which is not C#.

      2. NO language is natively executable except machine language. That's what compilers are for. Again, you're mixing up the C# language with parts of .NET. And incidentally, the .NET C# compiler DOES have the ability to produce fully native executables, so even the point you thought you were making is wrong.

      3. Your statement about .NET's purpose is pure babble. I believe .NET's purpose is to "capture" more platforms -- but it does that best by allowing Windows software to run on those platforms. I fail to see how it could capture other platforms in any other way. It's hardly doomed, Microsoft is using it extensively in-house, and MS development shops (of which there are many) are switching to it in droves.

      4. If you like Java, C, and C++, you'd probably like C# if you bothered to learn anything about it. It actually combines a lot of the good features of all three, and does a pretty good job of avoiding a lot of their problems.

      --

      Slashdot quality declines as the number of hot grits posts decreases. - Provolt's Law, Apr-09-2005

  95. Yes, I only use 200 English words too by Anonymous Coward · · Score: 0

    Because them only important words you use.
    You not need complicated words for talk.

  96. Re:moving towards bloatware or are these important by Slime-dogg · · Score: 1

    I think he was asking whether or not MS was going to write the office suite in C#, not just make it available as a peice-gluer. I read somewhere that MS was going to write .NET versions of most of their client software, but not do it for things like the OS, SQL Server, and various other projects that deal with internals.

    COM will never go away, but MS will do it's best to wrap .Net around it so that developers don't have to deal with COM.

    --
    You need to restart your computer. Hold down the Power button for several seconds or press the Restart button.
  97. Re:moving towards bloatware or are these important by Vic+Metcalfe · · Score: 1

    Um, vb.net pretty much destroys backwards compatibility with other vb code. I don't think MS is afread of breaking compatibility in the interests of code compatibility. There are many other examples. Just look at database API's. Breaking compatibility is a good thing that both Linux and Microsoft share.

  98. Java is standardized by Anonymous Coward · · Score: 0

    Java is standardized via the very open JCP process. Read more about it here:
    http://www.jcp.org/en/home/index

    Several open source projects including Apache and JBoss are on the JCP committee, so open source definitely has a say in Java's evolution, along with all the usual suspects like Sun, IBM, BEA, and Oracle. If you want to participate, you're free to.

    Now show me how I can participate in the Microsoft C# spec?

    C# version 1.0 may be an ECMA spec but not version 2.0. Microsoft will eventually submit C# 2.0 to the ECMA, but it'll get into Visual Studio.NET before that happens. The MS C# 2.0 will become so entrenched that all the ECMA will be able to do is to rubber stamp whatever Microsoft says. Some community process.

  99. Re:moving towards bloatware or are these important by TomV · · Score: 1

    One of the blogs I follow is Brad Abrams, the Lead Program Manager for the Common Language Runtime, and a lot of the posts are about programming interface guidelines and internal reimplementations, and the plusses and minuses thereof.

    So the original CLR features, and by implication their implementations in the various .net languages including C#, are certainly mutable already.

    Given the code-safety benefits of managed code, I'd imaging that Moft at least aspire to building their future headline products this way, and given the dogfooding tradition they're building, they've got plenty of incentive to make sure that .net rises to the challenge.

    tomV

  100. Kitchen sink not yet included.... yet by Anonymous Coward · · Score: 1, Insightful

    As is often the case with Microsoft, this *sounds* great. The reality typically turns out to be otherwise.

    Expect an over ambitious plan with a buggy implementation and confused metaphors which don't necessarily fit with each other or with themselves, for that matter. However, undoubtedly, they will *sound* fantastic in powerpoint slides and when spoken of by the press, "Microsoft only" developers, and, finally, when compared to the "other guys".

    The problem with Microsoft is, they market first, plan second, and then try to pick up the pieces third.

    It is really unfortunate, but Microsoft isn't good for the computing industry anymore. Microsoft is only good for Microsoft. And principally this is because, Microsoft only cares about Microsoft winning, at any cost.

    1. Re:Kitchen sink not yet included.... yet by Overly+Critical+Guy · · Score: 1

      I hate when Slashdot posters use FUD tactics, and then complain when Microsoft uses them in other instances.

      It is really unfortunate, but Microsoft isn't good for the computing industry anymore. Microsoft is only good for Microsoft. And principally this is because, Microsoft only cares about Microsoft winning, at any cost.

      Meanwhile, more and more people are using C# and enjoying the language. All your talk of Microsoft's alleged intentions (wow, a business that looks out for its interests, who'd have thunk it?) doesn't matter because, as usual, they're winning.

      All Slashdot posters can do is sit back and bitch about it instead of actually doing something about it. I'm sure we'll see more "M$" posts soon.

      --
      "Sufferin' succotash."
    2. Re:Kitchen sink not yet included.... yet by Anonymous Coward · · Score: 1, Insightful

      I hate when Slashdot posters use FUD tactics, and then complain when Microsoft uses them in other instances.

      First of all, the Slashdot poster complaining about Microsoft's FUD isn't necessarily the same as the one posting FUD.

      Secondly, can Anonymous Cowards really be placed into the category of "Slashdot Posters"? You're more of a "Slashdot Poster" than I'm being right now.

      Besides, Microsoft has a history of starting FUD wars that has been well-defined in legal records.

    3. Re:Kitchen sink not yet included.... yet by Da+Fokka · · Score: 1

      Have you ever used the language?! My experiences with it are mainly positive. C# already has several advantages over Java and this looks like a cool addition.
      I hope Mono will be quick on picking up this new spec.

  101. Re:moving towards bloatware or are these important by Anonymous Coward · · Score: 0

    And they've been there for like three point-releases. Are they ever going to clean those up?

  102. Re:That's great by Vladimus · · Score: 1
    So...

    When does the platform-independent, platform-independent spec come out?

    --

    A rolling stone is worth two in the bush!

  103. Re:moving towards bloatware or are these important by blowdart · · Score: 1

    Yup. Java does this. It is called "deprecated".

    As does .net, for example the switch from 1.0 to 1.1 changed XSL transforms, so using one of the old 1.0 methods would give

    'System.Xml.Xsl.XslTransform.Transform(System.Xml. XPath.IXPathNavigable, System.Xml.Xsl.XsltArgumentList, System.IO.TextWriter)' is obsolete: 'You should pass XmlResolver to Transform() method'
  104. Re:Who gives a shit about C# by Anonymous Coward · · Score: 0

    No one here knocks ECMAScript (oh - I'm sorry - you probably know it as JavaScript)

    Here, watch this: JavaScript is a moronic, useless language with almost nothing in common with any other sane languages. It is slow, ugly, and difficult to parse. It has nothing in common with Java despite its name (which, might I add, is also stupid). It is retarded that Mozilla would use JavaScript internally, and I think that is a big portion of what makes Mozilla slow, bloated, and cumbersome.

    There, do you feel better now?

  105. VB.NET Console App by TheAncientHacker · · Score: 1

    Module Module1

    Sub Main()
    Console.WriteLine("Hello, world!")
    End Sub

    End Module

  106. Re:this is fantastic by tunah · · Score: 1

    Can't tell if you're trolling or ignorant, but generics are coming in Java 1.5, and there's been an example implementation available from sun for about a year.

    --
    Free Java games for your phone: Tontie, Sokoban
  107. Re:Who gives a shit about C# by Anonymous Coward · · Score: 0

    But the C# 2.0 extensions are not part of that standard.

  108. Generics as an afterthought by Animats · · Score: 1
    It's annoying that C++, Java, and now C# started out without generics and had to have them retrofitted.

    In each case, the retrofit sucks. All the stuff that should be generic in the standard libraries, isn't.

    Can't anybody get this right the first time?

    1. Re:Generics as an afterthought by igomaniac · · Score: 1

      I recently had to extend an automated theorem prover written in Haskell for a school project. While my background as a games programmer (asm, C, C++, some Java) means I find functional languages alien, I have to say that Haskell's type system is the best I ever met... I'd like to see someone make a type system this powerful for an imperative language... Maybe I'll have a go at it myself ;-)

      --

      The interactive way to Go -- http://www.playgo.to/iwtg/en/
    2. Re:Generics as an afterthought by Anonymous+Brave+Guy · · Score: 1

      Sorry, I don't understand your complaint about C++. Pretty much all the standard library containers and algorithms C++ added to what it inherited from C are generic. Actually, a common criticism is that in some cases they're too generic.

      --
      If you disagree, post your argument. (-1, Overrated) isn't your personal censorship tool for views you don't like.
  109. Interesting point to this by Overly+Critical+Guy · · Score: 1

    You're bitching that they're adding too many ways to do things.

    Other people are bitching that Microsoft doesn't give you other ways to do things.

    The obvious conclusion is that people here at Slashdot just hate Microsoft for ANY reason. It's immature.

    --
    "Sufferin' succotash."
    1. Re:Interesting point to this by Glock27 · · Score: 1
      The obvious conclusion is that people here at Slashdot just hate Microsoft for ANY reason. It's immature.

      Well, many are looking for reasons to hate C#. For me, I won't consider it until it is much less of a single-vendor thing. I should start evaluating Mono, I hear it is almost usable these days. HOWEVER, that doesn't address some of the major problems, such as WinForms being closed.

      However, on the Java side I have many major vendors providing compilers and runtimes, as well as free implementations, running on all the major platforms. With C#/CLR I see a single vendor with a complete implementation, running on only one (substandard IMO) platform.

      It's an easy choice for now...

      --
      Galileo: "The Earth revolves around the Sun!"
      Score: -1 100% Flamebait
    2. Re:Interesting point to this by arthurs_sidekick · · Score: 1

      Lessee:

      Group A says "Microsoft is bad because they only give you one way to do things"

      Group B says "Microsoft is bad because they give you too many ways to do things"

      You say it's therefore obvious, since both A and B are subgroups of C, that the members of group C hate Microsoft "for any reason."

      Did you notice that it was different people in group A and group B? It's not like there's a party line everybody's supposed to adhere to!

      --
      "Oh, I hope he doesn't give us halyatchkies," said Heinrich.
  110. Re:Who gives a shit about C# by Anonymous Coward · · Score: 0

    Sorry to hear you have fallen for the M$ propaganda.

    Most of the functionality of C# is in the libraries. Most of those are not standardized or even documented well enough to be reimplemented without getting a swarm of M$ lawyers crawling all over you.

    "Standardization" of C# is a blindingly obvious propaganda joke. Have you noticed who is upgrading the C# in this very slashdot story? Hint: it ain't no independent standards body.

  111. c# and Stdin/Stdout anyone? by Zo0ok · · Score: 3, Interesting

    Ok, this is actually a .NET issue, not really a c# issue.

    StandardInput and StandardOutput, in .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).

    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 .NET, vim + .NET framework and the online MSDN reference is completely sufficient.

    1. Re:c# and Stdin/Stdout anyone? by rnd() · · Score: 1

      Why don't you write your own class(es) to do this easily with *N*X and make it freely available on SourceForge?

      --

      Amazing magic tricks

    2. Re:c# and Stdin/Stdout anyone? by GroovBird · · Score: 3, Informative

      You are misinformed.

      The Console class has indeed two properties: In and Out that are respectively TextReader and TextWriter objects, but there are also the OpenStandardInput and OpenStandardOutput methods that will return you a nice Stream that you can then write directly to (using byte arrays, for example).

      And this is all easily done using command line compilers included with the SDK, or in Mono.

      See, that wasn't too hard?

      Dave

    3. Re:c# and Stdin/Stdout anyone? by Anonymous Coward · · Score: 0

      Why not use binary streams insteadof text streams?

    4. Re:c# and Stdin/Stdout anyone? by Anonymous Coward · · Score: 0

      Microsoft's use of UTF-16 is idiotic. The space above 16-bits in Unicode was never apportioned till recently. Before then, Microsoft even tried to make the `char' datatype in C 16-bits, so they could get Unicode support for free. It never worked, obviously (too many people assume CHAR_BIT == 8).

      UTF is 32-bits now, period. Either use UTF-8 to get backwards compatibility w/ US-ASCII, or use UTF-32. UTF-16 gives you the multi-byte headaches of UTF-8 w/ none of the benefits of UTF-32.

      Java is stupid here, too.

    5. Re:c# and Stdin/Stdout anyone? by kahei · · Score: 1

      *sigh*

      1) Stdin and stdout are, as ever, streams.
      2) The Console.In and Console.Out methods get you TextWriters wrapped around those streams
      3) If you just want byte streams, you can use OpenStandardInput etc

      So easy. Not even a stream issue. Just a matter of whether you want the TextWriter or not.

      On the other hand, the problems associated with the blank-eyed belief, still common among those "thinking UNIX" as you put it, in 1 byte equalling 1 character, can be serious. These problems do not often occur in Windows, which has traditionally understood that characters are not bytes, although like everything else they are encoded as some sequence of bytes.

      I am ashamed to hear such an intense mixture of ignorance and prejudice from a vim user :( I may have to abandon my general 'the vim user is always right' rule of thumb :(

      --
      Whence? Hence. Whither? Thither.
    6. Re:c# and Stdin/Stdout anyone? by Anonymous Coward · · Score: 0

      Unicode will remain limited to U+0 .. U+10FFFF (the highest codepoint UTF-16 can represent via surrogates) for a long time, possibly forever. UCS-4 is absurdly wasteful (at least eleven bits per character are never used) so UTF-8 and UTF-16 are both reasonable compressed encodings, with different time/space tradeoffs (decoding UTF-8 is relatively expensive, almost as bad as LZW).

    7. Re:c# and Stdin/Stdout anyone? by Haeleth · · Score: 1
      Unicode will remain limited to U+0 .. U+10FFFF (the highest codepoint UTF-16 can represent via surrogates) for a long time, possibly forever.
      Definitely forever; it's inscribed on stone tablets kept in a hidden vault deep below the secret ISO headquarters on the dark side of the moon.

      UCS-4 is absurdly wasteful (at least eleven bits per character are never used) so UTF-8 and UTF-16 are both reasonable compressed encodings...
      Two points:

      1. UTF32 (what the Unicode consortium calls what you call UCS-4) is more efficient than the smaller encodings. Your arrays of 16-bit characters (if you're using UTF16 internally) are likely to be aligned on 32-bit boundaries anyway, so you're actually wasting space using UTF16 if you're using characters outside the BMP. Besides, for most applications, strings aren't that large anyway. Does it really matter if your data is using 100 kb instead of 60 kb?

      2. UTF-8 is absurdly wasteful. Not only is it slow to encode and decode, but it also uses more space than UTF16 for any far-Eastern script.

      See also the Unicode FAQ on UTFs.
    8. Re:c# and Stdin/Stdout anyone? by Zo0ok · · Score: 1

      Thanks a lot! ...if my employer ever has anything to say about me reading Slashdot I will tell him of this :)

    9. Re:c# and Stdin/Stdout anyone? by Zo0ok · · Score: 1

      Hi!

      Thanks for your answer.

      I know exactly the difference between a byte, a Char in C#, UTF-8 and friends. I was just confused stdin was a TextReader (and when looking into the problem, I obviously lacked the fantasy to check the Methods before looking elsewhere, where I found nothing).

      Sorry for being a shame among vim-users. I will do what I can to improve.

    10. Re:c# and Stdin/Stdout anyone? by Anonymous Coward · · Score: 0

      Thanks for the link. It still seems strange that they describe UTF-32 as a "transformation format", since (unlike UTF-7/8/16) it's 1:1 with characters.

      In the worst possible case (every codepoint is outside the BMP), UTF-16 needs 32 bits per character, so (barring something pointless like padding between each 16 bit array element) the size and alignment required should be exactly the same as UTF-32. UTF-8 can indeed be bigger than UTF-16 (if U+800 .. U+FFFF is more common than U+0 .. U+7F) but again it's never worse than UTF-32.

      As for whether it matters, I spend most of my time thinking about scalable servers, where a huge set of clients are contending for limited memory....

    11. Re:c# and Stdin/Stdout anyone? by TummyX · · Score: 1

      The Console class only has 3 properties and 10 methods. If you needed slashdot to work out something as simple as opening a binary stream or to understand the difference between TextWriters/Readers and Streams then I would seriously consider not telling your employer.

    12. Re:c# and Stdin/Stdout anyone? by Zo0ok · · Score: 1

      Hi again...

      Now that I look into the problem again I realise why I found it hard.

      I am not interested in the Console Class. I am interested in starting a process using System.Diagnosics.Process, and pipe binary data to/from that process. The methods you refer to are found in the Console class, but I do not find them in the Process class.

      Any ideas would be most welcome!

      Thanks in advance.

    13. Re:c# and Stdin/Stdout anyone? by Zo0ok · · Score: 1

      Hi again...

      Now that I look into the problem again I realise why I found it hard.

      I am not interested in the Console Class. I am interested in starting a process using System.Diagnosics.Process, and pipe binary data to/from that process. The methods you refer to are found in the Console class, but I do not find them in the Process class.

      Any ideas would be most welcome!

      Thanks in advance.

  112. Summary of changes: not much new by Baki · · Score: 1

    1. generics
    2. anonymous delegates
    3. partial types

    Compared to Java, 1 and 2 are not new. 3 is new, but I don't see the point of it (essentially you can define a class/type in multiple files, but all must be compiled together so it cannot be used to extend existing classes (which would be bad)).

    1 is only in the spec stage here, whereas for Java there is already a technology preview, i.e. a more or less working implementation.

    2 already exists for a long time in Java, the Java pendant of delegates being an adaptor class, and you can use anonymous classes to do exactly the same that anonymous delegates will provide.

    The spec for generics is (as is to be expected) quite complicated, there are more issues to be careful of than one might think at first sight. I really wonder how other .NET languages will deal with this. For VB.NET programmers, using .NET classes implemented using C# generics must be a nightmare. I assume they will extend the other language specs in a similar way, otherwise you would loose the ability to mix languages in .NET.

    The result is that VB.NET shall become a complex language too, to the point that most traditional VB programmers have to give up. In that case I wonder, what is the use of alternative languages then?

    1. Re:Summary of changes: not much new by Ancil · · Score: 1
      [generics are] only in the spec stage here, whereas for Java there is already a technology preview, i.e. a more or less working implementation
      Generics in Java will actually box primitive types. This makes them run about as fast as LISP, and forces you to write a "native" implementation -- which pretty much defeats the purpose of having template libraries in the first place.
    2. Re:Summary of changes: not much new by TummyX · · Score: 1

      You forgot iterators.

    3. Re:Summary of changes: not much new by TummyX · · Score: 2, Informative
      You forgot iterators which let you define more declarative how an enumerator/iterator works.

      IEnumerable<T> Test()
      {
      get
      {
      for (int i = 0; i < 10; i++)
      {
      yield i;
      }
      }
      }

      foreach (int i in Test())
      {
      Console.WriteLine(i);
      }

      1 is only in the spec stage here, whereas for Java there is already a technology preview, i.e. a more or less working implementation

      There has been a working implementation of generics for over a year now (for rotor).
    4. Re:Summary of changes: not much new by Jugalator · · Score: 1

      Compared to Java, 1 and 2 are not new. 3 is new, but I don't see the point of it...
      1 is only in the spec stage here, whereas for Java...
      2 already exists for a long time in Java...

      I wonder if someone is a Java developer or have a Java bias here. :-) Or at least someone looks at implementation of language features as a race between Microsoft and Sun...

      --
      Beware: In C++, your friends can see your privates!
    5. Re:Summary of changes: not much new by Zastai · · Score: 1
      3. partial types

      3 is new, but I don't see the point of it (essentially you can define a class/type in multiple files, but all must be compiled together so it cannot be used to extend existing classes (which would be bad)).

      There's two points to it:
      1. For really big classes, you can break them up (one file for the data, one file for each chunk of elated functionality).
        I'll agree that those cases could usually be solved by a refactoring, but that could require lots more work (and have more far-reaching effects).
        Enabling the code to be spread a bit certainly makes maintenance easier in such a case.
      2. Partial classes also make it easy to have some machine-generated code complemented by a set of user-supplied functions. It's then trivial to regenerate the generated parts without having to merge in the manual changes.
        The company I work for does legacy migration (mainly Wang/IDMS to Oracle currently) and a feature like this could make C# a very viable migration target.
      --
      When all other methods of communication fail, try words.
    6. Re:Summary of changes: not much new by JustKidding · · Score: 1

      The result is that VB.NET shall become a complex language too, to the point that most traditional VB programmers have to give up.

      You say it like that's a bad thing.

    7. Re:Summary of changes: not much new by ksorim · · Score: 1

      Generics in Java will actually box primitive types. This makes them run about as fast as LISP, and forces you to write a "native" implementation -- which pretty much defeats the purpose of having template libraries in the first place.

      Java with generics will probably still be a lot slower than Common Lisp. Despite common belief, common lisp is quite fast and can be compiled on a lot of platforms.

    8. Re:Summary of changes: not much new by Ben+Hutchings · · Score: 1

      These "iterators" are actually what were implemented a couple of years ago in Python, where they are called "generators". Python uses more sensible (but less compatible) syntax: "yield" instead of "yield return" and "return" instead of "yield break". So they're an advantage C# will have over Java but they certainly aren't an MS innovation.

    9. Re:Summary of changes: not much new by voodoo1man · · Score: 1
      Yes, as if type-inferencing Lisp compilers weren't available for several decades now*. Look for this exciting new Sun(R) innovation to become available in the next couple of Java revisions (maybe they'll find this reason enough to jump all the way to Java 3.0!) as generics become popular^.

      * - For the purpose of fair comparison, please disregard native code compilers - obviously Java is severely impeded by it's brain-damaged bytecode in this respect.

      ^ - Of course, by the time this happens, Sun could have saved itself all the trouble and made the language dynamically typed in the first place. But then it would automatically become 10 times as slow in the imaginations of what nowadays passes for "programmers."

      Here's an interesting link that speculates why speculating execution and overabundance of ALUs on modern IA32 (and soon 64) processors makes dynamic typing (practically) free.

      --

      In the great CONS chain of life, you can either be the CAR or be in the CDR.

    10. Re:Summary of changes: not much new by Baki · · Score: 1

      Is it really such a big deal that the compiler does a "cat file1.cs file2.cs file3.cs >file.cs" for you?!?

      OK, you can close the braces in C# now, in Java you'd have to leave them open. I don't really see the point. And I cannot believe that this might make the difference between a viable migration target or not.

    11. Re:Summary of changes: not much new by Anonymous Coward · · Score: 0

      Do you seriously believe that Microsoft Research was inspired by Python? Python, according to its advocates copied this idea from Icon (Icon is quite a bit older than C++), and Sather (sadly the language seems to be pretty much dead), whose generators implementation, on paper at least, looks really cool.
      Also it is rather amusing, or annoying, if your are Ruby zealot, that Python zealots seem to be making a point of not mentioning their direct niche competitor Ruby as an inspiring predecessor, even so Ruby featured both the concept and the keyword years earlier.

    12. Re:Summary of changes: not much new by avdi · · Score: 1

      Which got them from Ruby, which got them from Smalltalk, which got them from god knows where...

      I swear, the most annoying thing about Python is not the language, but it's users who are convinced that Python invented all things good. Ironically, Python's generators are unusably broken (they don't work with exceptions) compared to any other language's implementation. No doubt that this admitted failing will be touted as a "feature" by Pythonistas in a few years...

      --

      --
      CPAN rules. - Guido van Rossum
    13. Re:Summary of changes: not much new by Ben+Hutchings · · Score: 1

      I'm not familiar with those other languages, and I didn't claim that Python invented generators because I really don't know. A quick look around gives me the impression that Ruby and Smalltalk don't provide quite the same kind of automatic wrapping that Python and C# are doing. Correct me if I'm wrong.

    14. Re:Summary of changes: not much new by Ben+Hutchings · · Score: 1

      Ah, now I've found some better explanations and a comparison of Python generators and Ruby iterators. Regardless of their relative merits or precedence, I think C# is following Python not Ruby here, but I may have misunderstood the specification.

    15. Re:Summary of changes: not much new by Haeleth · · Score: 1

      > ...type-inferencing Lisp compilers...
      > Sun could have ... made the language dynamically typed in the first place...

      You're confusing type inference with dynamic typing. Type inference is a feature of statically typed languages such as ML and Haskell, whereby the static types are inferred from the uses of variables and functions, rather than being declared by the programmer. The end result is to provide most of the convenience of dynamic typing (easy generics, concise code, quicker prototyping), while retaining the speed* and compile-time type-checking of static typing.

      * Okay, in the case of Haskell "not retaining the speed" would be a more accurate way of putting it, but that's beside the point.

    16. Re:Summary of changes: not much new by voodoo1man · · Score: 1

      I'm referring to type inference the compiler optimization. The jargon seems to be confused on this issue (although it is not surprising, since both techniques basically do the same thing, albeit one is weaker).

      --

      In the great CONS chain of life, you can either be the CAR or be in the CDR.

  113. Re:this is fantastic - no GPL from VS.NET ?! by BillsPetMonkey · · Score: 1

    Question - does VS really forbid GPL releases?

    Isn't that practically impossible to prove? (Take out the VS.NET comments in the program and deny all knowledge ... ?)

    I'm lost as to how/why a dev environment can dictate the resulting release license.

    --
    "It's not your information. It's information about you" - John Ford, Vice President, Equifax
  114. So he can say "I'm a programmer" by Anonymous Coward · · Score: 0

    without everyone bursting out laughing at him. :>)

    1. Re:So he can say "I'm a programmer" by TheAncientHacker · · Score: 1

      As opposed to the other guy who actually IS a programmer and is concerned with getting programs written as opposed to looking fashionable to his friends. Sad isn't it when even geeks are more concerned with how they look than what they can do...

  115. Know what? by Anonymous Coward · · Score: 0

    I'm with you 99%.

  116. Re:Who gives a shit about C# by Anonymous Coward · · Score: 0

    How is the situation with C#, can you use this in a free-as-in-rms environment?

    DotGNU is an official GNU project and thus, has the full support of RMS and many others.

    RMS even once said (analogously): "everything that compiles with ms .net should compile under dotgnu and everything that runs under ms .net should run with dotgnu" (one of the guys who founded dotgnu once told me that when I asked them what RMS' view of .NET/Linux is)
  117. Re:Who gives a shit about C# by owlstead · · Score: 1

    Except that you cannot run C# with a standardized graphical user interface on anything other that Windows.

    Maybe the language itself is more open, but the API surely isn't. Many OO languages are relatively similar (otherwise the .net environment could not have happened). Therefore it's the API's that count.

    Pointer arithmetic is the next goto -- me.

  118. cutting edge or treadmill ? by DrSkwid · · Score: 1

    Aye well, that's the price you pay for being (or trying to be?) cutting edge I guess... *sigh*

    you can make you own knives for free

    --
    There are places where the networks are not touching,and there are places where they are-Boeing's Lori Gunter
  119. 'unsuitable for anyone "thinking UNIX"' by bani · · Score: 3, Interesting

    do you *really* think this design was an accident?

    1. Re:'unsuitable for anyone "thinking UNIX"' by Zo0ok · · Score: 1

      LOL

      No - did I imply that?

      I just find it annoying that at first c#/.NET seems fairly nice (quite similar to Java, much easier than Visual C++), but then this kind of "features" show up.

      Not that I really care - I only use c# at work. But since I am stuck with c# I try to do my best of it, thats why it annoys me that .NET is designed to make simple design impossible.

  120. interloafers: eyecon0meter won.won pre_big_flash by Anonymous Coward · · Score: 0

    that would be the fully pateNTdead & pre-liesensed eyecon0meter, already in use almost everywhere.

    that's right. this stuff is unbreakable, & wwworks on several (more than 3) dimensions.

    welcome to the gnu millennium. despite repeated/increased/ongoing attacks buy the fraudulent refudlicking payper liesense softwar gangsters, the hobbyists' kode base has been chosen for use in the creator's newclear power plan, the wildly popular planet/population rescue initiative, & several 1000 other projects.

    the daze of the felonious FUDgeLickers(tm) is WANing into coolapps/the abyss, at the speed of right (which may seem kind of slow at times). you know what they say about patience? get some, or be one.

    consult with/trust in yOUR creator.... get ready to see the light.

  121. M$ doesn't release ADA# !!! by Anonymous Coward · · Score: 0
    DoD: when ADA# for?

    open4free

    1. Re:M$ doesn't release ADA# !!! by blancolioni · · Score: 1

      DoD: when ADA# for?

      Here

  122. More innovation through copying by Anonymous Coward · · Score: 0

    So now that C# has aped Java, it is "borrowing" ideas from Eiffel, Ada, Lisp, etc.?

  123. anonymous crackxor hexdumping ... by Anonymous Coward · · Score: 1, Informative
    http://download.microsoft.com/download/8/1/6/81682 478-4018-48fe-9e5e-f87a44af3db9/SpecificationVer2. doc

    C# 2.0 Specification 1 C# 2.0 S 1 Anders Hejlsberg, Peter Golde, Shon Katzenberger .0 6 Generics, Anonymous Methods, Iterators, Partial Types e ene Normal.dot n Anders Hejlsberg us 130 Microsoft Word 10.0

    no more comments!

  124. Language wars back in vogue? by tjstork · · Score: 1


    It seems like after a decade or so of being stalled in the mainstream, new features are being added to commercial developmental languages and at a furious pace.

    --
    This is my sig.
    1. Re:Language wars back in vogue? by Anonymous+Brave+Guy · · Score: 1
      It seems like after a decade or so of being stalled in the mainstream, new features are being added to commercial developmental languages and at a furious pace.

      I think that's rather harsh.

      Ten years ago, several of today's most popular languages (Java, Python, Perl...) were toys if they existed at all. Others (C++, VB) were nowhere near the tools they are today. Many useful extras have been added into these languages during that period.

      As for new features being added now, my first response to that was, "What's new about any of these features? Many other languages have had them for years, and those behind Java and C# have just noticed that the critics were right all along."

      --
      If you disagree, post your argument. (-1, Overrated) isn't your personal censorship tool for views you don't like.
  125. Re:this is fantastic - Petstore!?! by harry_f · · Score: 1

    "One of Microsoft's examples is the classic petstore program. ITs only 1/4th the amount of code from the Java version."

    The .NET petstore is a joke and has probably done more to damage Microsoft's cause with Java developers they were hoping to convert.

    The Java Petstore is there to show how to apply J2EE design patterns to build a layered and maintainable application.

    The .NET Petstore disregards about 10 years of design theory and takes every short cut it can, hence less lines of code. Prime example is the SOAP interface, which instead of using an underlying data model layer, contains hard coded queries. Change the database schema with the .NET petstore and you'll be hunting through the code looking for what's been broken.

    More: Petshop.NET: An Anti Pattern Architecture

    There's alot of angry Java coders out there as a result, and these guys make alot of the decisions, these days, on where blue chip IT spending goes.

  126. Re:moving towards bloatware or are these important by joto · · Score: 1
    You've truely engineered something great not when you can't add anything more to it, but only when you can no longer remove anything from it.

    Well, what do you mean by "can no longer remove anything from it"?

    If you mean "can no longer remove anything from it, and still preserve the semantics of the language", you've just described Scheme. Suffice it to say that not everybody think Scheme is the end of all languages. Scheme is super-elegant, but so unpractical to program in that everybody uses their own dialect which adds the features you need to do real-world programming. In this sense, scheme is like Pascal.

    If you mean "can no longer remove anything from it that can't be simulated through other mechanisms with adequate performance", then you are basically looking at a minimal Forth. While great for embedded CPU's and programming for special Forth-chips, the language isn't exactly the ideal software engineering language. Chuck Moore's most recent forth, colorForth does for example not have any stack underrun checking. And no forth will ever have any kind of type system, you are always working on raw bits.

    If you are meaning "can no longer remove anything from it, without loosing the ability to do anything at all", then you are basically looking at an assembler for a one instruction set architecture chip. While useful as an april fools joke, it doesn't really have any practical purpose.

    There are plenty of languages that have "bloat" as part of their design. The idea is that features are useful, and users want them. Some classic examples are Common Lisp, C++, Java, Visual Basic, and Ada. All of these languages are either hugely successfull in the real world, or has a large academic following (or both). (PS: Yes I hate VB myself, but don't tell me it isn't important in the real world...)

  127. Re:Ruby Continua by abe+ferlman · · Score: 1

    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.

    I'm curious, but you definitely haven't persuaded me. You make it sound like there's even MORE stuff you have to manage with continuations than with GOTO.

    --
    microsoftword.mp3 - it doesn't care that they're not words...
  128. Java Community Process? You must be joking. by Anonymous Coward · · Score: 0

    Java's core language changes are decided unilaterally by Sun and no one else. All changes to the core language were done in this way: enums, generics, anonymous inner classes, to name a few. You're just buying into Sun's marketting machine if you believe otherwise. JCP is just a feel good group largely for proposing new libraries.

    1. Re:Java Community Process? You must be joking. by Anonymous Coward · · Score: 0
      Java's core language changes are decided unilaterally by Sun and no one else.


      You obviously have no experience what so ever with JCP. If you did, you would know that EJB 0-2.0 was primariy driven by BEA and IBM. Sun actually didn't contribute too much and is one of the reasons why SunOne server sucks compared to all the others. Contrary to what Sun says, the reason Weblogic, Websphere and JBoss are more popular is due to the fact that SunOne's implementation of the specs suck. One reason why BEA has been the first to release support for the latest spec is because they are a huge driver for EJB specs.


      The servlet spec like wise has been driven by outside source more than internal Sun forces. Look at the latest servlet and jsp specs and you'll realize why it's made such a big improvement the last few years. To a large extent, the java community has been driving the technology. Take for example the latest JMX/JMC management API's. Many of the improvements/refinements are the result of developers and participants in the JCP process. I couldn't even get a complete list of bug on C#/VB.net/J# on msdn when I posted a request for a complete list. Sun on the other has a public bug database which any developer can search and review without being related to bill gates.

  129. Reference for the C++ problems? by Anonymous Coward · · Score: 0

    Do you have any good references for the turing-completeness problem with C++? I've always hated that language, and would love to find a good rationalization... =) I'll google around a bit, but figure you might have a specific paper or website in mind.

    Oh, and thanks for the ever-cool fonts. I actually just made up a bunch of personal mailing labels by using tombots for a field in gLabels, so there's a random tombot (A-Z) on each one.

    -${NAME}@${NAME}isanerd.com, where NAME=josh (and ${$NAME} is too lazy to find his old slashdot account)

  130. Generic generics? by dalleboy · · Score: 2, Informative

    After reading this I'll understand that C# generics really suck, big time, compared to C++ templates.

    The constraints are really a pain in the butt, as you must specify what interfaces that the 'generic' type must implement, and not what specific methods of the interfaces that the generic type must implement. What you say, you may think: But if I wanted any type that has a method named 'void Print()' to be executed by my generic class, all of those types must implement a named interface (IPrintable). That is perhaps OK if I have full control over the source code, but whatif I'm using a library written by someone else?

    If you don't specify a constraint the 'generic' type will effectivly be of type Object, and we all know how much we can do with the type Object. Hmm, let me think, oh yeah: ToString. No need for generics there.

    The examples in the spec are also mostly container class examples, wonder why? Perhaps that the generics of C# can't do anything but (or mostly) container (or container like) classes.

    1. Re:Generic generics? by Anonymous Coward · · Score: 0

      Erk. You could do it on Java (a generic that calls Print() on anything passed in, as long as it has a Print()) using the reflection API, but the code is not excatly neat:

      theObject.getClass().getMethod("Print").invoke()

      I think, or something similar. You lose the advantage of Generic there though, as you're back to declaring a class that takes Object. I know Perl lets you do similat, but thats as loosely typed as can be. In Java it seems natural to declare an interface with a Print() method on it, and require that.

    2. Re:Generic generics? by Anonymous+Brave+Guy · · Score: 1

      I wondered about the same thing, and indeed the people behind C++ considered (and rejected) the explicit constraints idea long ago, for this among other reasons.

      Another good question is how do you write other plausible constraints, e.g., something generic in terms of two types, one of which can be converted to the other.

      --
      If you disagree, post your argument. (-1, Overrated) isn't your personal censorship tool for views you don't like.
  131. my school taught it by sbma44 · · Score: 1
    UVa -- I'm (almost) 2 years out, and they had java and C# while I was there. And UVa (while a great school) is not an engineering powerhouse. C++ is the workhorse of CS101, but the higher you go through the course offerings at a given college, I'd say the more likely you are to encounter something else. A friend of mine did a considerable amount of LISP programming on his way to a CS degree from Syracuse, for example.

    People will tend to use whatever language they already know, and what language they already know will be shaped by what their schools chose to teach them. A good OSS C# compiler would be a very good thing.

  132. M$ bitten by word format problems by tychoS · · Score: 1


    Try opening the word-format file in different wordprocessors.



    In Office XP on an XP machine the pagenumbers for the chapters in the table of content does not line up vertically!

    Also there are no space in between the chapter and sub-chapter numbers and their titles in the table of contents. This one can be either a file-format problem or plain bad taste ;-)


    They do line up in OpenOffice 1.1 on Windoss XP .


    In StarOffice 5.2 on Linux the "Table of Contents" header in on a page by itself before the page with the content of the table of contents!




    It is interesting that M$ thwmself cannot manage to create word documents that look correct on the most recent version of their own products ie. Office XP on a Windozz XP machine!

    1. Re:M$ bitten by word format problems by Anonymous Coward · · Score: 0

      You spelled Windows wrong.

    2. Re:M$ bitten by word format problems by Brewdles · · Score: 1

      Looks to me like you shouldn't be bashing other people's typing. Is your enter key stuck down by the drool produced in your rabid anti-MS state?

  133. Re:C# generics on built-in types do not use boxing by rnd() · · Score: 3, Informative

    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

  134. Bill's Waterloo by Anonymous Coward · · Score: 0

    Recall some time back a fiasco regarding the University of Waterloo and Microsoft? Basically, MS gave Waterloo $2.5 million to design a few new technologies for them, as wel as integrate C# into its core curriculum. Well for the time being, C++ and Java remain the primary languages of instruction (remains to be seen what happens with Sun). What Waterloo did is offer a pre-introduction to computing for all students (engineering and otherwise) as they're coming out of high school. This course is taught in C# and covers such mathematical puzzles as counting to 10, counting to 10 by 2's, and counting backwards from 10. When the students in engineering actually get into the program, it's right back to C++ for the real work.

  135. very nice features, but... by HiThere · · Score: 1

    Those are very nice feature. I particularlly like "generics similar to those found in Eiffel and Ada", but I'm not even going to look at it.

    Why? Because of patents. I don't know just what patents MS has, but they have said that they will use them to contol "their property" in response to a question about C# migrating to other platforms. I don't necessarily believe them, but on this kind of statement I tend to give them the benefit of the doubt. Of course, they'll wait until it's most advantageous to act, so their not having done anything yet doesn't prove anything. They don't need to do anything until the code is nearing release quality.

    --

    I think we've pushed this "anyone can grow up to be president" thing too far.
    1. Re:very nice features, but... by Anonymous Coward · · Score: 0

      They don't need to do anything until the code is nearing release quality.

      Given their sterling record, that means it will never be a problem :)

      Seriously, though, all arcane programming details aside, doesn't anyone have a concern that this is a commercial standard? C and C++ are ANSI standards, to be used by all for compiler development and programming baselines.

      C# is a Microsoft standard, to be patented, protected and locked to a Windows environment. Even as a Microsoft "standard", it likely to be filled with little unspecified details of implementation that Microsoft will tailor to protect their environment (Windows).

      Why isn't anyone else concerned about this? Or am I wrong? Is this an "open" standard? subject to review and approval of anyone besides Microsoft?

    2. Re:very nice features, but... by HiThere · · Score: 1

      Parts of it are open... as in submitted to a languge committee for approval, and perhaps even approved. But not all of it. And it's not clear exactly which patents the MS spokesman was asserting would apply. (I read the report, which was informal anyway, so I wasn't in any position to ask questions.)

      The gist was (paraphrased): It's OUR intellectual property, and we WILL protect it. And we've got patents. (Note that I put the comment about patents in a separate sentence. It wasn't absolutely clear what the referent of the comment about patents was.)

      My suspicion, similar to several other people (and shaped by theirs) is that the patents, or copyright, or trade secrets, or whatever flavor of IP they have reside in certain libraries that almost all C# code uses, but which isn't a part of the officially approved standard. As in, this subversion was intentionally designed into the language...though perhaps during a late stage of refactoring.

      --

      I think we've pushed this "anyone can grow up to be president" thing too far.
  136. Re:Who gives a shit about C# by Anonymous Coward · · Score: 0
    This is a pretty funny thing to say under a story about Microsoft releasing a new version of the C# language specification.

    Note carefully that it really is Microsoft that is specifying the language, not any independent standards body.

  137. Hum... by autopr0n · · Score: 1

    Thanks to slashdot's idiotic comment nesting, I thought you were replying to something else.

    --
    autopr0n is like, down and stuff.
  138. How to do typesafe enumerations in Java by j7953 · · Score: 1
    declaring a new class/interface

    I don't know C#, but you have to write something like enum Name { ... } in C# as well, don't you? I don't really see how this is an advantage over having to write class Name { ... } in Java.

    being able to use the newly declared enumeration's new type name for parameters instead of just "int" - remember semantics?

    You can do typed enumerations in Java by using the typesafe enumeration pattern.

    Basically a typesafe enum is a class with a private constructor (so no new instances can be created) and all the actualy constants are declared as final class members. Like this:

    public class Example {

    // private constructor
    private Example() {
    }

    // the constants
    public final static Example A = new Example();
    public final static Example B = new Example();
    ...
    }

    This allows you to do really nice things. For example, you could add some instance variables and methods to the class to add additional information to the constants (of course, initialize all the variables in the constructor and don't have any set methods, or your constants won't be constant any more!).

    You have to be careful if you want to use serialization or similar stuff. You might want to take a look at Martin Fowler's great book "Effective Java," which describes this pattern and a huge number of other useful things. The typesafe enum description is in chapter 5, which is available online as one of four sample chapters.

    Of course, even with typesafe enums, you still have to do lots of typing (even more, actually), so your point (b) might still be an advantage of C#. I think the JDK 1.5 will add support for creating typesafe enums in a more simple way, though.

    Lots of little things like this, IMHO, make C# better than Java.

    As I said, I don't really know C#, but still, from what I've heard about it, that's also the impression I got. I think Microsoft took a look at all the things Java didn't quite get right, and did them in a slightly better way. If I wanted to write a Windows-only application, it's very likely that I would use C# for the task. Or Python :-)

    --
    Sig (appended to the end of comments I post, 54 chars)
  139. Re:Who gives a shit about C# by sadiklis · · Score: 2, Insightful
    C# is ECMA standardized. Java is wholly owned by Sun.

    The biggest chunk of any language is it's vocabulary. In this case it's API.

    There are OSS J2EE projects (Jboss, Jonas, Jakarta's new project).

    And then there is this purely proprietary thing called MBF - Microsoft Business Framework.

    BTW to emphasise that the beef is in API, not language, let me remind you that .NET Framework can be programmed in many languages (C#, VB.NET, Managed C++, etc.).

    What other nearly-irrelevant subset of the beef is standartized by ECMA? Ones-and-zeores maybe? You know: "our systems are open, 'cause they are based on "ones-and-zeroes" standard" ;-)

    Anyway, ECMA seems to be almost a joke in terms of freedom of their standards: http://techupdate.zdnet.com/techupdate/stories/mai n/0,14179,2832719,00.html:

    But getting the stamp of approval from TC39 and the General Assembly doesn't mean that Microsoft is in any way ceding its ownership of C# and CLI. As part of the ECMA process, Microsoft, like any other company or organization seeking standardization of its technology, must make a declaration related to licensing the technology that complies with ECMA's Code of Conduct in Patent Matters. "The role of a standards body in this context is to warrant that licensing is possible on RAND (reasonable and non-discriminatory) conditions," explained van den Beld. So while Microsoft wouldn't be able to do whatever it wishes to C# itself, apparently the company would have plenty of latitude in terms of licensing.

    And it appears that ISO (C#/CLI are ISO standards too) is no better: http://www.imaging-resource.com/NEWS/1027527673.ht ml (JPEG no more?):

    'Register' article suggests the standards body may formally withdraw the JPEG standard altogether if Forgent continues with its patent claims...

    ISO rules require that its standards be implementable free, or under "reasonable and non-discriminatory" (RAND) terms.

    So what is a safer bet, OSS Java or .NET? Of course .NET, because it's closed and thus patent-torpedoes-invincible - can license patented technology, unlike all those open J2EE projects...

    I'm sure it's better to suffer proprietary lock-in than potentially-deadly patent threat. Right?

    Yet, even MS can be torpedoed successfully once in a while (e.g. that plugins patent hitting IE).


    Software world seems to be a mess with no clear future perspective.

    [Sorry for a somewhat-messy/offtopickish post.]

  140. argv[] passing (was Re:c# and Stdin/Stdout anyone? by Anonymous Coward · · Score: 0

    For people thinking UNIX - have Microsoft fixed argv[] passing yet? Its seriously broken under every MS platform I've tried. Its a legacy of DOS, where apps got the whole command line and each implemented its own way of handling quotes. In UNIX I can

    system('a_command','arg','arg with spaces',
    'a quote \" here',
    'oh look \" another one')

    and expect the called program to get the arguments that I passed correctly. On Windows - its completely useless.

  141. C# can support coroutines by jhannes · · Score: 1

    My (limited) understanding of continuations is that they are the same as coroutines. There was a very interesting article in MSDN Magazine about extending .NET with coroutines by using fibers and native (C) interop.

  142. Binary footprint bloat by yerricde · · Score: 1

    Don't like a library? Download another.

    And bloat your executable size. And fill up RAM with various applications' competing libraries that do roughly the same thing. Not everybody can afford 512 MB of RAM, especially on a handheld, battery-powered device.

    --
    Will I retire or break 10K?
    1. Re:Binary footprint bloat by AuMatar · · Score: 1

      And having a huge standard library, 99% of which isn't used by any app at the moment, doesn't do so more? Especiall when considering the size of a compiled library is pretty damn small, this is a non factor at worst, a gain for C style at best.

      --
      I still have more fans than freaks. WTF is wrong with you people?
  143. Re:C# generics on built-in types do not use boxing by AndyS · · Score: 1

    Granted, Microsoft's offers scope for efficiency, but all of the 'boxed' java types are final, so you could, with extra work, do exactly the same for Java. If you had a good inliner then a call to a List that immediately called intValue() could be optimised away, and equally, when an Integer was explicitly needed one could be generated as needed.

    But, yes, it would take a LOT of work to get a Java implementation to be this efficient.

  144. Re:C# generics on built-in types do not use boxing by cananian · · Score: 1

    For collections of primitives *only*. And the cost is run-time bloat (in C#). Pretty much a wash, I'd say.

    --
    [ /. is too noisy already -- who needs a .sig? ]
  145. Re:Who gives a shit about C# by aled · · Score: 1

    Microsoft .NET may be a proprietary platform, but so is Java. ECMA C# is an open and free language.
    But to most people want to use the platform, not just the language. Microsoft thinks so, otherwise would not give C# to ECMA. I'm not telling C# is not good, I mean that by market presure most users will go to .Net or other alternatives rather than use C# alone.
    Java the platform may not be an open source but still is "more open" than .Net.

    --

    "I think this line is mostly filler"
  146. Continuation examples by Piquan · · Score: 1

    You make it sound like there's even MORE stuff you have to manage with continuations than with GOTO.

    In a way, there is. There's also more you have to manage with function calls than with GOTO.

    Continuations let you capture an object that remembers "where am I going next". This includes not just the instruction pointer, but also the return stack. Common applications exceptions, coroutines, and nondeterminism. I'll present some examples, using a mythical, vaguely C-like language with the following syntax for continuations:

    // I have to include some long lines in my ecode sections to get around a slashdot lameness filter.
    // I have no idea why slashdot would require a long average line length, particularly with ecode, since you usually don't want long lines in code.
    // Sorry about the distraction, but if slashdot is going to be lame, there's not much I can do about it.
    something = with_continuation(varname) {
    ...body...
    }

    This saves the continuation of the block in varname. It will return the result of the block in something. The continuation can be invoked with invoke_continuation(varname,value). Note that this would store value in something.

    Now, let's use this to implement exceptions. We're navigating a file tree, and want to find the first corefile.

    // I have to include some long lines in my ecode sections to get around a slashdot lameness filter.
    // I have no idea why slashdot would require a long average line length, particularly with ecode, since you usually don't want long lines in code.
    // Sorry about the distraction, but if slashdot is going to be lame, there's not much I can do about it.
    function find_first_corefile()
    {
    continuation found_it;
    string first_corefile = NULL;
    first_corefile = with_continuation(found_it) {
    find_corefile_in("/", found_it);
    };
    if (first_corefile == NULL)
    print("No corefiles!");
    else
    print("First corefile is %s", first_corefile);
    }
    // I have to include some long lines in my ecode sections to get around a slashdot lameness filter.
    // I have no idea why slashdot would require a long average line length, particularly with ecode, since you usually don't want long lines in code.
    // Sorry about the distraction, but if slashdot is going to be lame, there's not much I can do about it.
    function find_corefile_in(string directory, continuation when_found)
    {
    string filename;
    for (filename = first_file_in(directory);
    filename != NULL;
    filename = next_file_in(directory)) {
    if (is_directory(filename)) {
    find_corefile_in(filename, when_found);
    } elsif (is_corefile(filename)) {
    invoke_continuation(when_found, filename);
    }
    }
    }

    This looks similar to the try/catch/throw that some languages provide, and that's what we're implementing here. I know, you could use return values to do the same in this case. Remember that I'm making short examples.

    Now let's implement something that exceptions don't allow: nondeterminism. This example is similar one in Paul Graham's On Lisp, but has been heavily adapted for an imperative language.

    // I have to include some long lines in my ecode sections to get around a slashdot lameness filter.
    // I have no idea why slashdot would require a long average line length, particularly with ecode, since you usually don't want long lines in code.
    // Sorry about the distraction, but if slashdot is going to be lame, there's not much I can do about it.
    function parlor_trick (int sum)
    {
    int first_number = magically_determine_number();
    int second_number = magically_determine_number();
    if (first_number + second_number == sum)
    print("%i is the sum of %i and %i", sum, first_number, second_number);

  147. Re:Who gives a shit about C# by gafter · · Score: 2, Insightful

    > C# is ECMA standardized. Java is wholly owned by Sun. Sun has repeatedly balked at standardizing Java due to the inherent loss of control.

    I suggest you write the following lists side-by-side:

    On the left, list the companies with members on the standards committe participating in defining the specification of upcoming versions of the Java language (JSRs 14, 175, 176 and 201). Count how many times each company appears on these lists, too.

    On the right, list the companies with members on the standards committe participating in defining the specification of upcoming versions of the C# language.

  148. What, again? by kahei · · Score: 1


    Sorry, I've been told that everything will be great in the next version of Java since 1995 now and ignoring it has become automatic.

    But don't let that stop you from telling me all about how Swing will be realllll fast and responsive in 1.5. While you're doing that, I'll catch up on some TV.

    --
    Whence? Hence. Whither? Thither.
  149. Re:moving towards bloatware or are these important by tektor · · Score: 1

    I believe that the quote is "You know you've achieved perfection in design, not when you have nothing more to add, but when you have nothing more to take away." ("La perfection est atteinte non quand il ne reste rien a ajouter, mais quand il ne reste rien a enlever.") It is my favorite quote, by Antoine de Saint-Exupery. See http://www.westegg.com/exupery/#quotes

  150. Re:moving towards bloatware or are these important by Bodrius · · Score: 1

    Remember that old idea of backwards compatibility?

    Removing features of any significance usually means turning the language into a new one.

    Remove pointers, multiple inheritance, enumerations, templates, structs, and some other stuff from C++ and what do you get? Java minus garbage collection.

    --
    Freedom is the freedom to say 2+2=4, everything else follows...
  151. They need to... by kashmirzoso · · Score: 1

    fix the god damn IDE and release a decent source control solution before upgrading this language!

  152. Exception Handling via "throw" by Toddimer · · Score: 1
    Although I haven't RTFA, I suspect you couldn't find anything about "throws" because of your atrocious spelling, or a dependency on language-specific keywords instead of base concepts. C# includes a full suite of Exception-handling mechanisms. You can find various tutorials online with a simple google search.

    I find it interesting that the new C# language is really streamlining the implementation of common design patterns. Use of patterns like an Iterator, Facade, Observer, etc. is simplified through language constructs like collections, interfaces, events, and more. You'd do well to read up on a topic before resorting to criticism.

    1. Re:Exception Handling via "throw" by flashbang · · Score: 1

      You'd do well to read up on a topic before resorting to criticism.

      You have never used C#? I have & still do. Yes C# has many exception handling mechanisms, but my point is that C# doesn't enforce a "checked" exception. You'd do well to use the language before resorting to criticism.

      --
      My sig left me for a younger user id.
  153. Scheme vs. Lisp by alexo · · Score: 1

    I know I am getting a bit off topic here but can anybody tell me (or point me to) what are the important differences between the two and how do they affect programming in these languages?

    1. Re:Scheme vs. Lisp by joto · · Score: 1
      Except for using lots of silly parentheses, the differences are akin to Pascal and C++.

      Scheme is small, elegant, orthogonal, and unpractical. Every user uses their own dialect, and there are about a gazillion different implementations (one per user, perhaps), none of which are perfect, and all having incompatible features.

      It grew up in the academic environment, and was originally based on Algol 68, with a lispish syntax. It is a great language, with lot's of great ideas. The only problem is that it's a small language with a small community of users, each of which works on their own implementation, and with an incomplete standard. As a result, you don't write scheme-programs, you write programs for your particular implementation (DrScheme is a good one to start with).

      Common Lisp is a larger language, with more practical considerations. It also includes a large library of useful functions. Because the full common lisp spec is huge (although manageable compared to C++ or java), if you want a full implementation, you'd better go for a commercial implementation (although sbcl is pretty nice).

      It is more of a direct descendant of the original lisp 1.5 than Scheme (or to be more correct, based on three different commercial lisps, which in turn were pretty much based on 1.5), and therefore includes a little bit more weirdness due to backwards compatibility. But the little bits of weirdness that exists usually turn out to be quite practical, so most users don't worry too much about it (in any case, it is certainly *far* from being comparable to C++ or Perl).

      In general, if you are interested in creating a working program, you choose Common Lisp. If you like programming in Scheme, you choose Scheme. There might be other considerations, such as memory footprint.

    2. Re:Scheme vs. Lisp by varjag · · Score: 1

      Because the full common lisp spec is huge (although manageable compared to C++ or java), if you want a full implementation, you'd better go for a commercial implementation (although sbcl is pretty nice).

      I'd say SBCL and CMUCL are fairly complete implementations in terms of ANSI compliance.

      Commerical implementations have their advantages, of course: variety of extensions, support, quality documentation, fancy IDEs are the most notable.

      --
      Lisp is the Tengwar of programming languages.
  154. Re:Who gives a shit about C# by luisdom · · Score: 1

    Yeah, being ECMA standarized is a being very standarized. Like ECMAscript, that, like everyone knows, works the same everywhere :|
    Frankly, I prefer java's way in which 99'99% of applications work the same in sun's vm, ibm's vm, linux, windows, ...

  155. Re:Who gives a shit about C# by Anonymous Coward · · Score: 0

    Offtopickish? Ooh, I *like* "offtopickish".

  156. Coroutines? by Burb · · Score: 1

    So, putting aside the syntax, this would be a little like coroutines or even WinAPI Fibers?

    --

  157. Cool by jamie(really) · · Score: 1
    Since I use .NET on Windows XP to write applications for Windows XP and Windows XP Embedded I'm quite looking forward to the new language features.

    That some people here think it is important that Java has had two of these features already, albeit in a far less efficient form for generics, is neither here nor there. I do not use Java. I'd have to pay for a decent IDE for it, while Visual Studio .NET includes all the languages I need for serious windows development. Eclipse, in case you were going to mention it, doesnt function usably on two monitors.

    However, since I used to be a compiled-code snob (i.e. ASM,C or C++ but no byte code!), C# has opened my mind to Java, and I'm looking forward to gnu's own byte code implementation. C# will remove many barriers in peoples minds to using Java. Personally, I find C# easier to use, and I look forward to nice, fast generics.

  158. LOL ! Genericity ;-) by Anonymous Coward · · Score: 0

    Yet MS has find a way not to say they are building a Java clone :o)

    AFAIK, genericity is something that Java is already about to offer in 1.5 (begin of next year). Early implementation are already offered for test on java.sun's site.

    So again, MS is pushing FUD ;-)

    Like at the time that starcraft was going out, they push some "mighty" picutre of the new age of empire that was "about" to be released. But that proactically never came to life but 2 years later !!!

    Reality is not MS but FUD is.

    By the way, who cares about C# ;-)

  159. Non-sense ! by Anonymous Coward · · Score: 0

    If i were you i will just go back at my books and read the JSR, and test the implementation before pushing posts like this ey ;-)

    "We all know Bill will be the next pope as he is god on earth, and C# is the bible, and VS.net the salvation for a better world that will be peacefull and perfect without war, terrorism !

    In a way, if C# has come 4 years before, Irak civilian would not have collapse under US bombs, and newyorkers will still enjoy the twins !!!"

    I told you ... this is non-sense, so please stop pushing it.

    MS .net is a Java platform clone, that was pushed by MS because they could not lockdown the original. It has some advantages, but the fact it is windows only and supported only by MS make it future-less (on a middle term basis).

    Java might not be the future, but what i am sure is that MS .net will not be anymore in IT memory within 10 years (but at redmond's museum with MSX & OS/2 success stories ...)

    Poor bill !
    By the way, did you know that Windows 2003 is out ? (because it seemse that nobody carez !)

  160. NOT the REAL Miguel by chochos · · Score: 1

    That's not the real Miguel de Icaza.

    This guy's journal entries give him away (clippy a good idea? come on...) and besides, the entries in Spanish were obviously done using some lousy translation software since they barely make any sense, and Miguel's native language is Spanish.

    1. Re:NOT the REAL Miguel by AstroDrabb · · Score: 1

      Thanks for the tip. I thought something was strange with his Hi userID. I don't speak Spanish so I couldn't pick that up. What kind of looser would come on /. and pretend to be someone else?

      --
      If Tyranny and Oppression come to this land,
      it will be in the guise of fighting a foreign enemy. -James Madison
    2. Re:NOT the REAL Miguel by chochos · · Score: 1

      Well, in this case it might not be too paranoid to think that MS could have someone posting in /. pretending to be Miguel, to spread some FUD.

  161. you might be suprised.... by Miguel+de+Icaza · · Score: 1

    "clippy a good idea? come on..."

    check out this message in the gnome archives:

    http://mail.gnome.org/archives/gnome-list/1998-S ep tember/msg00817.html
    clippy es una idea fantastica

    --
    Before adopting WHATWG, read the moonlight.NET EULA [http://www.microsoft.com/interop/msnovellcollab/moonlight.mspx]
    1. Re:you might be suprised.... by chochos · · Score: 1

      O sea que tienes dos usuarios en este sitio? para que? ya me confundiste.

      Y que onda con eso de la patente oculta y no se que tanto choro de darle en la torre a linux... Aunque lo que menos entiendo son los diarios en spanglish tan malo. O ya se te olvido el espanol?

      Por ultimo, tu conociste a la_morsa? cuando yo estaba en la uni alguna vez me hablo de ti.

    2. Re:you might be suprised.... by Miguel+de+Icaza · · Score: 1

      el pescado de Babel no puede hacer el gato con su mensaje

      --
      Before adopting WHATWG, read the moonlight.NET EULA [http://www.microsoft.com/interop/msnovellcollab/moonlight.mspx]
  162. Re:C# generics on built-in types do not use boxing by TummyX · · Score: 1


    And the cost is run-time bloat (in C#).


    Not really cause the type bloat is small. There only needs to be one type for all reference types and one for each value type. Also, you don't have the overhead of boxing and unboxing with *every* access to the collection. That's not just a memory overhead, that's a performance overhead that java has to deal with. It can be reduced by caching common values, but still will be higher than C#'s generics implementation.

  163. Re:moving towards bloatware or are these important by Anonymous Coward · · Score: 0

    Microsoft do do one thing better than anyone else, and that is backwards compatibility.

    They won't be removing anything.

  164. partially reserved words by efuzed · · Score: 1

    Doesn't anyone else (if anyone is still reading this thread) find the fact that the new reserved words, are context sensitive? That yield may still be used as an identifier in non-sensitive places. Just me, but I thought that language class I took years ago would have said thats a 'bad thing' for readability.

  165. C++ is just eccentric! by commie_pig · · Score: 1

    No, I cannot agree with you at all that C++ is broken.

    It is "complicated" due to its expressiveness. The STL is generally well designed (and the folks at Boost are continually improving upon it).

    It is popular because its templates allow generation of high quality code that matches C for speed, but is light years beyond in type checking (provided that you tell your compiler to do it). It's also popular because it's OO works well - it's a common misconception to cite C++'s lack of a single root object hierarchy as a flaw - Bjarne Stroustrup gives some compelling reasons for C++'s lack of it (in his FAQ - can't remember the URL).

    I do admit that I miss anonymous classes and functions in C++, and I often find it easier to write a for loop than to use something like foreach (which takes a start and end iterator and a function to apply) simply because writing a function is a pain if you just want to print names in a list!

    The final reason for C++'s success is that it is not bound to a particular vendor, and this is a major deficiency of C#. I'm not blasting M$ here - this is true for any vendor.

    --

    "I hate people who fabricate unintelligent quotes to add to their work seemingly by some 'anon' sage" -- anon

  166. Re:Who gives a shit about C# by marcovje · · Score: 1


    While I agree with you fully, the practice is different.

    I'm no Java/Sun zealot, but Sun simply commits to Java being multiplatform, and works with other vendors to do so.

    It seems microsoft's only multi platform interest is in getting the avg windows app less x86 dependant, and some WinCE experiments. (which is still WinCE)

    Mono is very fun to watch, but unless the avg windows generated app actually works on it, it is useless. If I need to specially craft the app by not using certain constructs and assemblies, I might as well keep using C/C++, which is also portable when I specially craft them