Hacker News new | ask | show | jobs
by coldtea 3370 days ago
Month aside, it would be a great thing to actually happen...

Instead of e.g. Google investing tens of millions on BS like Dart.

1 comments

What's so bad about Dart, if you disregard the "Google is trying to subvert the web" angst from people who have invested heavily in the javascript world? I quite like the optional typing in the language, for instance.

I just wish there was more serverside-development happening in Dart - it seems 95% client-side focused at the moment (dart2js and flutter).

>What's so bad about Dart, if you disregard the "Google is trying to subvert the web" angst? I quite like the optional typing in the language, for instance.

A new language that doesn't solve anything better than Smalltalk did.

It does provide the feature of optional typing, as I just said. I spent my formative years developing in a language with optional typing and really grew to like it. I think it's a great concept that has missed the mainstream somehow.

Besides from that the syntax is completely different, being inherited from C.

Dart is moving away from optional typing towards static typing with inference. (It's useful for ahead-of-time compilation.) Take a look at strong mode. But since you can leave out the types in simple situations, it often looks the same.
Is optional typing the same thing as gradual typing in Perl6 as in you can specify types, but don't have to?
I don't know much about Perl, but this describes Dart's approach to optional typing:

https://www.dartlang.org/articles/language/optional-types

(But meh, it's not really innovative/new as this page says, just not popular.)

Basically, it's a language that allows you to choose the level of type checking. You can be super strict all the time, or only when it matters. Or not at all.

Like all other modern languages it naturally has the basic collection data types built in so that you don't have to reinvent them.

Decent static typing with inference has also missed the mainstream
Dart is just a Java-clone by some of the same people and hasn't really incorporated any lessons from 20 years of Java. For example, their answer to Tony Hoare's billion-dollar mistake is... "The Elvis operator"