Hacker News new | ask | show | jobs
by greenhouse_gas 2925 days ago
The thing is that the longer you wait, the harder it will be to migrate, as the codebase size grows (and once you leave beta, people assume that the language is finalized and won't be too happy being forced to refactor their code when Dart 3 comes out). But as it is, I doubt that the nice parts of Kotlin will ever make it to Dart.
2 comments

> The thing is that the longer you wait, the harder it will be to migrate.

Definitely preaching to the choir on that one. I pressed my case as hard as I could before 1.0.

We do still have more freedom to make breaking changes than many post 1.0 languages do because, frankly, we don't have that many users. But every day, the cost to make that change goes up.

> people assume that the language is finalized and won't be too happy being forced to refactor their code when Dart 3 comes out

I was worried about that with the transition to the new type system in Dart 2, but users — internal and external — were surprisingly accepting of the breakage. We don't want to be cavalier about breaking them, of course, but my impression is that there is more room for significant changes than I'd initially assumed.

> But as it is, I doubt that the nice parts of Kotlin will ever make it to Dart.

Dart will never be Kotlin, but I hope we can get to a point where most users don't consider it to be deficient compared to Kotlin and where we have some features to make Kotlin users jealous.

Yes, it's really sad that a language as young as Dart already has such problems :/
It's because the language was made to compile to JS, and competition to JS, so appropriate tradeoffs were made.

For example:

1. JS is single-threaded, with extremely heavy threads only recently made available. So Dart is single threaded, with extremely heavy threads available.

2. JS is weak-typed, so Dart was made optional typed. Remember, it was made before typescript, so they probably didn't expect that such type-heavy features as ADT would interest people.

Kotlin does the same (for example, internal immutability would be much nicer, but since the JVM doesn't support that, neither does Kotlin).