Stories
Slash Boxes
Comments

SoylentNews is people

posted by martyb on Friday November 13 2015, @10:24AM   Printer-friendly
from the Obfuscated-Rust-Competition-doesn't-sound-right dept.

In spite of my status and obvious bias as co-creator of D, I'll do my best to answer candidly; I follow Go and Rust, and I also definitely know where D's dirty laundry is. I'd encourage people with similar positions in the Rust and Go communities to share their honest opinion as well. So here goes.

First off, C++ needs to be somewhere in the question. Whether it's to be replaced alongside C, or be one of the candidates that's supposed to replace C, the C++ language is a key part of the equation. It's the closest language to C and the obvious step up from it. Given C++'s age, I'll assume in the following that the question also puts C++ alongside with C as a target for replacement.

Each language has a number of fundamental advantages (I call them "10x advantages" because they are qualitatively in a different league compared to at least certain baselines) and a number of challenges. The future of these languages, and their success in supplanting C, depends on how they can use their 10x advantages strategically, and how they overcome their challenges.

[Another way to look at this is to ask "What is wrong with C?" and then assess how well these languages solve those problems. -Ed.]


Original Submission

 
This discussion has been archived. No new comments can be posted.
Display Options Threshold/Breakthrough Mark All as Read Mark All as Unread
The Fine Print: The following comments are owned by whoever posted them. We are not responsible for them in any way.
  • (Score: 2) by bzipitidoo on Saturday November 14 2015, @12:33AM

    by bzipitidoo (4388) on Saturday November 14 2015, @12:33AM (#262910) Journal

    A few I don't like arise from some confusing and inconsistent syntax. Normally, the scope of a variable is confined to the block containing the definition-- between the matching curly braces, nice and simple, right? Except when the variable is declared in the condition section of an if statement or the definition part of a loop. Or in the start of a function body. In fact, it was a bug in old versions of gcc (back in version 2) that

    for (int i=0; i99; i++) { i; } if (i99) puts("exited loop early!");

    actually compiled, with "i" not being declared outside the loop. Was annoying to have to rewrite code that originally depended on that bug, and which generated hundreds of compiler errors when they fixed the bug.

    And how about an exception to the idea of lvalues? Shouldn't code like "++i=i*2;" be illegal? Especially since "i=++i*2;" does the same thing?

    Then there's the newbie gotcha "if (a=b)".

    Starting Score:    1  point
    Karma-Bonus Modifier   +1  

    Total Score:   2