Stories
Slash Boxes
Comments

SoylentNews is people

posted by janrinok on Saturday March 15 2014, @10:07PM   Printer-friendly
from the we-always-need-new-languages dept.

An anonymous coward writes:

"Mozilla is using work on it's next generation layout engine, Servo, to fine tune a new language used for writing that layout engine. The new language, called Rust, started as a personal project of Greydon Hoare and has since grown to be sponsored by Mozilla and Samsung. From the article:

The Rust language will power Mozilla's new browser, Servo, and its big selling point is efficiency. Because C++ crashes when it runs into memory allocation issues, it weakens any browser that uses the language. Mozilla designed Rust to be superior to C++ this way, more easily isolating tasks and promote a process known as "work stealing," which is when tasks from an overloaded processor are shifted over to another one.

Rust is a general purpose, multi-paradigm, compiled programming language developed by Mozilla Research. It is designed to be a "safe, concurrent, practical language", supporting pure-functional, concurrent-actor, imperative-procedural, and object-oriented styles."

 
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: 4, Insightful) by SlimmPickens on Saturday March 15 2014, @10:13PM

    by SlimmPickens (1056) on Saturday March 15 2014, @10:13PM (#16971)

    Great work guys, just chuck it over there on the pile.

    Starting Score:    1  point
    Moderation   +2  
       Insightful=1, Funny=1, Total=2
    Extra 'Insightful' Modifier   0  
    Karma-Bonus Modifier   +1  

    Total Score:   4  
  • (Score: 1, Informative) by Ethanol-fueled on Saturday March 15 2014, @10:30PM

    by Ethanol-fueled (2792) on Saturday March 15 2014, @10:30PM (#16976) Homepage

    Speaking of piles, the idea was pretty exciting until I saw how goddamn ugly the language is. Utterly hideous. I haven't seen anything that ugly since SCALA. Even PHP's prettier than RUST.

    • (Score: 2, Funny) by ticho on Saturday March 15 2014, @10:56PM

      by ticho (89) on Saturday March 15 2014, @10:56PM (#16986) Homepage Journal

      But this one comes with a plateful of buzzword soup. Therefore, it can't not be good, ask any PHB!

    • (Score: 4, Informative) by forsythe on Sunday March 16 2014, @05:23AM

      by forsythe (831) on Sunday March 16 2014, @05:23AM (#17093)

      Any language I've seen looked ugly, the first time I saw it. Quite a few still do.

      That said, lots of people have found Rust ugly, which probably stems from the way syntax conventions are inspired by very different sources (I've heard Rust described as "What C would look like if it were designed by somebody who had only ever known Haskell"). Ugliness isn't a sin for a language, but it may mean that newcomers to the language will have trouble finding parallels to other languages, and that it will therefore be rather difficult to pick up.

      Given that new languages are almost impossible to get adoption for anyway, that's a valid and very harsh criticism of Rust.

      (I've been picking it up a little myself over the past few months. As a language with no mandatory GC, it promises to be actually useful for systems programming. Given more time, I think I wouldn't have any more problems with format! and ~ than with C's *.)

    • (Score: 1) by Hairyfeet on Sunday March 16 2014, @07:41AM

      by Hairyfeet (75) <reversethis-{moc ... {8691tsaebssab}> on Sunday March 16 2014, @07:41AM (#17115) Journal

      Hey if it gets rid of the "bandaids on bullet wounds" that is JavaScript? Then I don't care if its the ugliest damned thing on the planet YES PLEASE!!!

      I mean do you have ANY idea how much the net is slowed down by JavaScript malware? I know at the shop that is pretty much ALL I see anymore is JS malware infections. Hell since Adobe made "update automatically" the default setting for Flash I've been seeing Flash infections go down, not JS though and if you think about it the reason is obvious....it was just never made with security in mind and instead of starting over and doing it right bandaids have just been bolted onto a broken mess.

      So if it gets rid of the "Hey we'll just run third party code from anywhere, whats the harm?" of JS and gives us a web language built from the ground up with best practices and least permissions in mind? All for it. Sadly considering that while Webkit had support for Low Rights mode 6 months after Vista came out while Moz has had SEVEN YEARS and still hasn't implemented it in FF? Really doesn't give me much hope of them making anything but a mess, but maybe Google or the Webkit guys can give us something to replace JS..

      --
      ACs are never seen so don't bother. Always ready to show SJWs for the racists they are.
      • (Score: 2, Informative) by sjames on Sunday March 16 2014, @08:08AM

        by sjames (2882) on Sunday March 16 2014, @08:08AM (#17119) Journal

        Sorry, it won't do that. Rust will be used to write the browser which will, in turn, support Javascript.

        I can sure sympathize with your position though. I can and do code in Javascript when it needs to run in the browser, but much of the functionality feels bolted on and then mysteriously restricted to paper over a gaping security hole that resulted from security not really being a priority when the runtime was designed.

        It would be nice if Javascript would just implement declared domains of trust and be done with it.

        It could use a good syntax cleanup as well.

  • (Score: 1) by No.Limit on Sunday March 16 2014, @04:24PM

    by No.Limit (1965) on Sunday March 16 2014, @04:24PM (#17200)
    A programming language is the most fundamental tool of a coder. Every advancement in programming languages is a blessing to all of us coders!

    Of course we already have languages with really great features (C, C++, Java, C#, Python, Haskell, Ruby etc). But while they're good, there is always room for improvement as can be seen by language updates.

    The _recent_ C++11 standard introduced many awesome features to C++. Simple and easy ones like inferred types or syntax for iterations (for (auto myIterator: myContainer) { /*...*/ }).
    Highly flexible ones like lambda expressions (also new in Java 8). Important concepts such as move semantics and more.

    But there are limits to how much we can improve existing languages. These languages always have to try to keep as much backwards compatibility as possible and that severely limits how much they can really change and improve.

    A good example is the null reference or also the 'Billion Dollar Mistake' (that actually comes from the inventor). At this point we know we can guarantee null-pointer safety by for example extending the type system to distinguish between references that could be possibly null and references that are guaranteed not to be null.

    Here an example:

    reference? couldBeNull = null; // denoted by a question mark after the type
    reference guaranteedNotToBeNull = new SomeClass(); // no question mark, so always non-null

    if (couldBeNull != null) {
      // here the type of couldBeNull changes, because here it's guaranteed not to be null
      // here we can dereference both couldBeNull and guaranteedNotToBeNull safely
    }
    // here we can only dereference guaranteedNotToBeNull safely.

    And this goes beyond forcing coders to do null pointer checking. With this we can also guarantee that functions get non-null references with the type system.
    In fact we can prove that there will never be a null pointer exception in the whole program!

    And there are so many more awesome features that languages could have and that guarantee safer programs. I for one embrace every exploration of language design hoping that in the future we'll have even better and safer languages!