Jump to page: 1 24  
Page
Thread overview
Rust and D
Sep 28, 2012
bearophile
Sep 28, 2012
bearophile
Sep 28, 2012
Paulo Pinto
Sep 28, 2012
Froglegs
Sep 28, 2012
Paulo Pinto
Sep 28, 2012
mist
Sep 28, 2012
Peter Alexander
Sep 28, 2012
Nick Sabalausky
Sep 29, 2012
Nick Sabalausky
Sep 29, 2012
Peter Alexander
Sep 29, 2012
Nick Sabalausky
Sep 29, 2012
Peter Alexander
Sep 29, 2012
Paulo Pinto
Sep 29, 2012
Peter Alexander
Sep 29, 2012
Paulo Pinto
Sep 29, 2012
Nick Sabalausky
Sep 29, 2012
Walter Bright
Sep 29, 2012
Thiez
Sep 29, 2012
Peter Alexander
Sep 29, 2012
Nick Sabalausky
Sep 29, 2012
Peter Alexander
Sep 29, 2012
Nick Sabalausky
Sep 29, 2012
Jesse Phillips
Sep 29, 2012
Walter Bright
Sep 29, 2012
Timon Gehr
Sep 29, 2012
Peter Alexander
Sep 29, 2012
Nick Sabalausky
Sep 29, 2012
Peter Alexander
Sep 29, 2012
Nick Sabalausky
Sep 29, 2012
Walter Bright
Sep 29, 2012
Peter Alexander
Sep 29, 2012
Nick Sabalausky
Sep 29, 2012
jerro
Sep 30, 2012
Froglegs
Sep 29, 2012
Nick Sabalausky
Sep 30, 2012
BLM768
September 28, 2012
Most comparisons between Go and D on Reddit aren't good, but this time there is an almost decent comparison between D and Rust:

http://www.reddit.com/r/programming/comments/10k9ao/why_i_think_rust_is_the_language_of_the_future/

I think the most direct competitor of D is going to become Rust (beside of course C# and C++), because Go has different enough purposes.


From the thread I have also learnt that some months ago they have removed typestate from Rust, because it doesn't pull its weight, as Andrei says (I think Rust was the first serious attempt at using this language feature, and now it will be hard to see another language with it):

https://mail.mozilla.org/pipermail/rust-dev/2012-July/002094.html

https://github.com/mozilla/rust/issues/1805

https://github.com/mozilla/rust/issues/2178

Bye,
bearophile
September 28, 2012
From the Reddit thread:

Walter:

> D has the @safe annotation, which prevents unsafe pointer operations.

Rust has a statically enforced borrow/lend management system, and other things like memory regions, that make it smarter (and probably harder to use).

The Rust type system extends what can be made "safe". On such things the Rust type system looks more complex and refined than the D type system, so unless the Rust designers have done something very wrong (like adding lot of complexity for no gain), I expect such type system to give more back, that is not present in D.

-------------------------

Abscissa256:

> D has ADT: http://dlang.org/phobos-prerelease/std_variant.html#Algebraic

Algebraic doesn't currently support recursion, and even when it does, "having ADTs" means having both a nice way to define them, and a good way to de-structure them. D doesn't have pattern matching, so the D usage of ADTs is less well supported and less good.

I think adding a full featured pattern matching in D is too much complex, but I think supporting structs in switch statements (and maybe also auto assignment to variables in such case structs) adds only a small amount of complexity while giving back a good amount of usefulness.

It was discussed a little here:
http://d.puremagic.com/issues/show_bug.cgi?id=596


> Also, D supports manual memory management.

But Rust is designed to work well without a GC, unlike D. Rust has several features that make it safer even when you are not using a GC. Rust also seems to appreciate stack allocation more than D. In D stack-allocated arrays are second class citizens in Phobos (and there are no VLAs like Ada, but I don't know if Rust has them), and seem generally underused. In D to allocate classes on the stack you can't use a native feature of the language, while in Rust it's a built-in, and doing this in Rust is safe enough.

Bye,
bearophile
September 28, 2012
On Friday, 28 September 2012 at 00:17:43 UTC, bearophile wrote:
> Most comparisons between Go and D on Reddit aren't good, but this time there is an almost decent comparison between D and Rust:
>
> http://www.reddit.com/r/programming/comments/10k9ao/why_i_think_rust_is_the_language_of_the_future/
>
> I think the most direct competitor of D is going to become Rust (beside of course C# and C++), because Go has different enough purposes.
>
>
> From the thread I have also learnt that some months ago they have removed typestate from Rust, because it doesn't pull its weight, as Andrei says (I think Rust was the first serious attempt at using this language feature, and now it will be hard to see another language with it):
>
> https://mail.mozilla.org/pipermail/rust-dev/2012-July/002094.html
>
> https://github.com/mozilla/rust/issues/1805
>
> https://github.com/mozilla/rust/issues/2178
>
> Bye,
> bearophile

I like Rust specially due to the ML influence the language has.

Currently I only have two issues with the language:

- funny characters a la Perl for the pointer types scattered everywhere
- their tendency to shorten reserved words (already discussed here)

Other than that it seems a nice language.

Go can be a systems programming language, as others have proven in research. Oberon, Modula-3, Sing# and so on.

But the language is nothing more than an improved C, and we don't need to throw away all the nice abstractions that are now mainstream in computing. Plus if you pay attention, Go talks are always about Web/REST servers.

I already can do that with JVM/.NET languages, with better performance as Go, without giving up all the nice abstractions the languages offer. Go would have been dead already, if it wasn't developed inside Google.

I am looking forward to D and Rusts future.

--
Paulo
September 28, 2012
  The Rust website says this:

Generic types	yes, only simple, non-turing-complete substitution

  After seeing that I just assumed the language was worthless and
ignored it..  is there something more to this?

September 28, 2012
On Friday, 28 September 2012 at 17:42:07 UTC, Froglegs wrote:
>   The Rust website says this:
>
> Generic types	yes, only simple, non-turing-complete substitution
>
>   After seeing that I just assumed the language was worthless and
> ignored it..  is there something more to this?

As far as I understand it, Rust supports generic types a la C#, Modula-3, Eiffel, Ada, among others.

Meaning you cannot play meta-programming tricks with them.

For me that is ok, sometimes in D I think we suffer from meta-programming overdose.
September 28, 2012
On Friday, 28 September 2012 at 17:42:07 UTC, Froglegs wrote:
>   The Rust website says this:
>
> Generic types	yes, only simple, non-turing-complete substitution
>
>   After seeing that I just assumed the language was worthless and
> ignored it..  is there something more to this?

Relevant: http://commandcenter.blogspot.co.uk/2011/12/esmereldas-imagination.html
September 28, 2012
There are also some people that think that compile time metaprogramming is the single best thing happened to programming languages. And, hey, what language will I use if you tear it apart from D? :P

On Friday, 28 September 2012 at 18:21:32 UTC, Paulo Pinto wrote:
> On Friday, 28 September 2012 at 17:42:07 UTC, Froglegs wrote:
>>  The Rust website says this:
>>
>> Generic types	yes, only simple, non-turing-complete substitution
>>
>>  After seeing that I just assumed the language was worthless and
>> ignored it..  is there something more to this?
>
> As far as I understand it, Rust supports generic types a la C#, Modula-3, Eiffel, Ada, among others.
>
> Meaning you cannot play meta-programming tricks with them.
>
> For me that is ok, sometimes in D I think we suffer from meta-programming overdose.


September 28, 2012
On Fri, 28 Sep 2012 23:54:10 +0200
"Peter Alexander" <peter.alexander.au@gmail.com> wrote:

> On Friday, 28 September 2012 at 17:42:07 UTC, Froglegs wrote:
> >   The Rust website says this:
> >
> > Generic types	yes, only simple, non-turing-complete
> > substitution
> >
> >   After seeing that I just assumed the language was worthless
> > and
> > ignored it..  is there something more to this?
> 
> Relevant: http://commandcenter.blogspot.co.uk/2011/12/esmereldas-imagination.html

Meh, a meta-complaint.

I love the quotes in the first paragraph about actresses, but mostly it strikes me as an elaborate way to dismiss, or at least overly downplay:

1. The importance of metaprogramming.

2. The impracticality of judging the myriad of languages out there these days by going hands-on with all of them, and not having some way to narrow things down to a realistic level first.

(My apologies if the article's author is reading this, no offense was
intended.)

September 29, 2012
On Fri, Sep 28, 2012 at 3:21 PM, Nick Sabalausky < SeeWebsiteToContactMe@semitwist.com> wrote:

> (My apologies if the article's author is reading this, no offense was
> intended.)


Doubt it. I believe the author was Rob Pike.


September 29, 2012
On Fri, 28 Sep 2012 18:33:31 -0700
José Armando García Sancio <jsancio@gmail.com> wrote:

> On Fri, Sep 28, 2012 at 3:21 PM, Nick Sabalausky < SeeWebsiteToContactMe@semitwist.com> wrote:
> 
> > (My apologies if the article's author is reading this, no offense
> > was intended.)
> 
> 
> Doubt it. I believe the author was Rob Pike.
> 

(Had to look up that name) Ahh, I see. That explains the dismissal of
metaprogramming and generics, and the dismissal Go's objectors
via a roundabout strawman (Ie by complaining about the act of
complaining, and by categorizing of Go's complaints as merely
programmers loving to complain for the sake of complaining).

(And yea, I see the "[generics] are a fine thing", but he's still overall very dismissive of their importance.)


« First   ‹ Prev
1 2 3 4