Mozilla releases Rust 0.1

From Visual Basic to GNU C, this is the place to talk programming.

Moderators: SecretSquirrel, just brew it!

Mozilla releases Rust 0.1

Postposted on Thu Feb 09, 2012 12:27 pm

WOW!!! :o

Mozilla releases Rust 0.1, the language that will eventually usurp Firefox’s C++

http://www.extremetech.com/computing/11 ... firefoxs-c

A bit more about the language itself: Rust is a compiled, statically-typed, object-oriented programming language (and objects are immutable by default). The compiler is supported on Windows, Linux, and Mac. Feature-wise, Rust intentionally avoids any novel ideas, and instead builds upon existing, known features that are present in other languages. Syntax-wise, Rust uses curly braces {} like C, C++, or JavaScript, but as you can see in the code block below, the syntax is actually quite funky.
Code: Select all
    use std;
    fn main(args: [str]) {
         std::io::println("hello world from '" + args[0] + "'!");
    }
thegleek
Darth Gerbil
Gold subscriber
 
 
Posts: 7360
Joined: Tue Jun 10, 2003 11:06 am
Location: Detroit, MI

Re: Mozilla releases Rust 0.1

Postposted on Thu Feb 09, 2012 12:44 pm

I guess they figured if Google could have their own programming language, they needed one too?
(this space intentionally left blank)
just brew it!
Administrator
Gold subscriber
 
 
Posts: 37632
Joined: Tue Aug 20, 2002 10:51 pm
Location: Somewhere, having a beer

Re: Mozilla releases Rust 0.1

Postposted on Thu Feb 09, 2012 8:06 pm

Guess I am just too used to programming constructs. The arguments don't look all that odd to me. I'll have to look up and see if the array has a way to query its size.

--SS
SecretSquirrel
Gerbil Jedi
Gold subscriber
 
 
Posts: 1697
Joined: Tue Jan 01, 2002 7:00 pm
Location: The Colony, TX (Dallas suburb)

Re: Mozilla releases Rust 0.1

Postposted on Thu Feb 09, 2012 11:32 pm

Why everyone insists on developing their own stupid language (tm)?

There should be like 5 languages in total. C++, Pyhon, Javascript, SQL, HTML. That's it. People would at least learn them properly, the libraries for those few languages would be widely used/tested/developed, and it would be better for everyone.

But no, everyone thinks that they can invent some stupid language that will be idiot-proof, which never happens. And in the end, there are a lot of half baked languages with half baked libraries and half baked professionals in each of them.
Core 2 Duo E6300, MSI P45 NEO-F, Club 3D GTX 260, 4Gb DDR2-800Mhz, Audigy X-Fi Fatal1ty Champ1on ed., 0.5Tb+1Tb Seagate Barracuda 7200.12, 630W AXP, Samsung SyncMaster BX2450, ViewSonic VP171b
Madman
Minister of Gerbil Affairs
 
Posts: 2317
Joined: Tue Apr 01, 2003 4:55 am
Location: Latvia

Re: Mozilla releases Rust 0.1

Postposted on Fri Feb 10, 2012 12:26 am

Madman wrote:Why everyone insists on developing their own stupid language (tm)?

There should be like 5 languages in total. C++, Pyhon, Javascript, SQL, HTML. That's it. People would at least learn them properly, the libraries for those few languages would be widely used/tested/developed, and it would be better for everyone.

But no, everyone thinks that they can invent some stupid language that will be idiot-proof, which never happens. And in the end, there are a lot of half baked languages with half baked libraries and half baked professionals in each of them.

Well... you need some sort of shell scripting language too. Sure, Python can be used for that; but it's massive overkill for simple tasks. There's a lot of overhead involved in starting up the Python interpreter, making it non-optimal in many cases.

Even C++ is too bloaty for low-end embedded control devices (think the chip that runs your microwave oven, or the embedded processor on the logic board of your hard drive). C++'s complexity also makes safety certification of critical embedded control systems (e.g. fly-by-wire avionics) difficult. So you still need C (or possibly even assembly language, but even the lowliest microcontrollers are generally capable of supporting C these days).

The only language out of the ones you listed that can be used effectively for multithreaded programming is C++, and coding parallel algorithms in C++ is a bitch. We need a language that has better support for multithreaded (and GPU) computing.

There are certain classes of problems which are most effectively solved using functional programming (e.g. Haskell, Mathematica).

The syntax of a make dependency file is arguably a programming language in its own right, and the operations it embodies could not be specified anywhere near as succinctly in any other "normal" programming or scripting language.

If you're going to call HTML a language, then XML qualifies too -- it serves a purpose which is not addressed by any of the other languages you mentioned.

Way, way back in the day (late 1980s) I invented my own language for scripting text-based adventure games. :wink:

I could give more examples, but I think you get the idea.
(this space intentionally left blank)
just brew it!
Administrator
Gold subscriber
 
 
Posts: 37632
Joined: Tue Aug 20, 2002 10:51 pm
Location: Somewhere, having a beer

Re: Mozilla releases Rust 0.1

Postposted on Fri Feb 10, 2012 12:28 am

I don't get it. What's the point?

C++11 is amazing. Java is quick to develop and well established. Python and Ruby kick butt in the script world. There are some outliers like Erlang that solve specific problems. Why do we need Yet Another Language?
Buub
Maximum Gerbil
Silver subscriber
 
 
Posts: 4195
Joined: Sat Nov 09, 2002 11:59 pm
Location: Seattle, WA

Re: Mozilla releases Rust 0.1

Postposted on Fri Feb 10, 2012 12:42 am

Everyone goes through life using different examples either by self-practice or taught by a teacher-scenario.

Myself, I've gone through life without EVER coding 1 single line of Python. I consider Python and Ruby the new-age hipster languages.

I stick with Java, C++, C#, Perl, TCL, PHP, XMLl, winbatch (vbscript, WIL), shell scripting (bash, tcsh), Pascal, JSON/JavaScript, etc... Not sure if you can call HTML a valid language, but I'll throw in SQL too if you want. But throwing in such basics as SQL/HTML/JS is like saying your proficient in GW_BASIC. :P

I haven't really found the need to ever learn any new languages (yet). But if the job is right and I'm paid for it, I'll pick anything up fairly quickly. I'm quite partial to languages that are object-oriented and have libraries included.
thegleek
Darth Gerbil
Gold subscriber
 
 
Posts: 7360
Joined: Tue Jun 10, 2003 11:06 am
Location: Detroit, MI

Re: Mozilla releases Rust 0.1

Postposted on Fri Feb 10, 2012 8:09 am

thegleek wrote:Myself, I've gone through life without EVER coding 1 single line of Python. I consider Python and Ruby the new-age hipster languages.

:lol:

Well you gotta love a language invented by someone named "Guido"!

I learned Python mainly because the guy I work for is a huge fan of the language, and he decided that all of our testing tools would be written in it. I'm still more of a C/C++ guy at heart, but Python is good.
(this space intentionally left blank)
just brew it!
Administrator
Gold subscriber
 
 
Posts: 37632
Joined: Tue Aug 20, 2002 10:51 pm
Location: Somewhere, having a beer

Re: Mozilla releases Rust 0.1

Postposted on Fri Feb 10, 2012 11:02 am

Python (and Ruby [and even PHP]) is the anti-perl. Perl is great for really simple scripts, say only a few lines long, that simply parse lines in a file. Anything more than that and it gets so unreadable relative to Python that it has to be asked: why AREN'T you using Python, and sticking to a far inferior tool?

Considering I was doing Python more than ten years ago, I'm not sure you can really refer to it as hipster. The fact is, both Python and Ruby are vastly superior scripting languages than perl, which is why they are popular.
Buub
Maximum Gerbil
Silver subscriber
 
 
Posts: 4195
Joined: Sat Nov 09, 2002 11:59 pm
Location: Seattle, WA

Re: Mozilla releases Rust 0.1

Postposted on Fri Feb 10, 2012 11:04 am

just brew it! wrote:I learned Python mainly because the guy I work for is a huge fan of the language, and he decided that all of our testing tools would be written in it. I'm still more of a C/C++ guy at heart, but Python is good.

Considering the boost (the premier C++ library repository) guys use Python for much of their build scripting, I'd say it has a pretty solid endorsement for guys like us. :-)
Buub
Maximum Gerbil
Silver subscriber
 
 
Posts: 4195
Joined: Sat Nov 09, 2002 11:59 pm
Location: Seattle, WA

Re: Mozilla releases Rust 0.1

Postposted on Fri Feb 10, 2012 4:27 pm

thegleek wrote:Myself, I've gone through life without EVER coding 1 single line of Python. I consider Python and Ruby the new-age hipster languages.


Python and Ruby are really nice; they fit neatly between Bash and C/C++.
Flatland_Spider
Gerbil Elite
 
Posts: 824
Joined: Mon Sep 13, 2004 8:33 pm
Location: The 918/539

Re: Mozilla releases Rust 0.1

Postposted on Sun Feb 26, 2012 5:32 pm

Buub wrote:Python (and Ruby [and even PHP]) is the anti-perl. Python , Ruby, and PHP are great for really simple scripts, say only a few lines long, that simply parse lines in a file. Anything more than that and it gets so unreadable relative to Perl that it has to be asked: why AREN'T you using Perl, and sticking to a far inferior tool?
... The fact is, Perl is a vastly superior scripting language than Python and Ruby, which is why Perl is so popular.


There. Fixed that for you. I never knew someone could make so many errors in one post. :D
The best things in life are free.
http://www.gentoo.org
Guy 1: Surely, you will fold with me.
Guy 2: Alright, but don't call me Shirley.
titan
Grand Gerbil Poohbah
 
Posts: 3276
Joined: Mon Feb 18, 2002 7:00 pm
Location: Great Smoky Mountains

Re: Mozilla releases Rust 0.1

Postposted on Sun Feb 26, 2012 6:48 pm

@titan -

My take: Perl is only popular because it was the first widely used scripting language with the sort of expressive power it has. In other words, inertia. Kind of like how FORTRAN and COBOL still refuse to die.
(this space intentionally left blank)
just brew it!
Administrator
Gold subscriber
 
 
Posts: 37632
Joined: Tue Aug 20, 2002 10:51 pm
Location: Somewhere, having a beer

Re: Mozilla releases Rust 0.1

Postposted on Mon Feb 27, 2012 1:27 am

just brew it! wrote:@titan -

My take: Perl is only popular because it was the first widely used scripting language with the sort of expressive power it has. In other words, inertia. Kind of like how FORTRAN and COBOL still refuse to die.

Precisely.
Buub
Maximum Gerbil
Silver subscriber
 
 
Posts: 4195
Joined: Sat Nov 09, 2002 11:59 pm
Location: Seattle, WA

Re: Mozilla releases Rust 0.1

Postposted on Fri Dec 21, 2012 6:39 pm

no sig
muyuubyou
Grand Gerbil Poohbah
 
Posts: 3231
Joined: Wed Aug 28, 2002 6:19 am
Location: London, UK or Tokyo/Yokohama, Japan or Madrid, Spain


Return to Developer's Den

Who is online

Users browsing this forum: No registered users and 0 guests