| What I mean with bloated is that Golang has great limitations in how flexible the syntax is. This is not inherently bad, but it causes bloat. Scala on the other side is very flexible on the syntax side, but that causes a steeper learning curve to some degree, both in general for the language but also each time this flexibility is used. A simple example would be datetimes. Let's say you have a Datetime library and you have to write "currentTime.plusMinutes(1).plusSeconds(5)". In Scala you can adapt it to be able to write "currentTime + 1.minute + 1.second" without even changing the original library, for better or worse. In Golang you cannot, for better or worse. > But it's readable and maintainable, and will be that for the next decade Well, you could say the same about Scala.
The thing is: each line of Golang-code might be easy to understand and readable. But in the end what matters is the understand the whole system or at least the part where you need to make a change. And while in Scala you pay the price of a much steeper learning curve, you also have the benefit of more concise code (see example above) which makes understanding the whole picture easy, even if every single line is harder. But as I said, not only does it not come for free because of the learning curve. The freedom and power also can cause problems when it used correctly, so it also requires greater discipline than, say, Java or Golang. > With Scala, and I've worked with the language and some Scala oriented developers, I get the feeling that each individual developer styles themselves an artisan, and their code is not for the likes of mortals to comprehend. Unfortunately it is hard to tell if that is because you were not experienced enough in Scala at that time, or if someone really just messed up and abused the language (it definitely happend, even more so in the past). > I mean the one project failed and they went back to C# / .NET after a few years because they couldn't find developers and the other one probably muddles on because of sunk cost, but still. Yeah, you can't scala a Scala project to the next Google. That's not gonna work. But then again, I think that it makes perfect sense to have multiple languages, even in the same company. People who start out might want to use go because it's easy to learn it and get started (and still has some strong points for certain concurrency problems etc.). Eventually you want to move on and go for Rust or Scala or others. And even then, some people just prefer dynamic typing, some prefer static typing, just like some prefer pizza and some prefer pasta. |