What Makes Go So Different?
By: Timothy Yalugin
Tags: Golang, Software Development, Go, Programming, Programming Languages

Distinct Features

However, that does not necessarily mean that Go is deficient or missing some important functional features. This would, in fact, make programming useless, since why not use an assembly language in the first place. But this isn’t the case with Go. It surely has some features. The thing is, though, that in order to stay simple, Go is very deliberate about not having features that bring more complexity without solving the problem. This is, in fact, one of those things that makes Go “idiomatic,” as it famously used to be called.

Needless features bring complexity without clarity (Drawing by Renee French)

So what about features that have managed to become a part of Go? Well actually, the rule of intentional simplicity is very much acting for them too. And by saying that, I mean that Golang’s creators have done an incredible job of creating what seems to be something so simple and easy to use, while under the hood is actually highly complicated.

“Go is actually complex. It is, in fact, one of the most complicated things I ever worked on, and yet, it feels simple … It requires a lot of design, thinking, implementation work, refinement. Simplicity is the art of hiding complexity!”— Rob Pike, creator of Golang

Let’s have a look at a few “simple” things in Go:

Garbage collector is, in fact, the most simple feature of Go, since it doesn’t have any control interface. Yet also it is reasonably its most complex one because it manages to provide complete memory safety while saving an exceedingly high runtime speed and providing surprising resource efficiency. Bravo to the creators!

Yes, by all means, Go isn’t the fastest programming language, since we have Rust, Julia, C++, and C for sure. But none of these languages have GC and therefore aren’t even close to being as simple as Go — and it isn’t that slow, actually. In most cases, though, this is possible also due to the next exceptionally simple feature.

Concurrent gophers (Illustration by the author using Renee French’s drawings)

Concurrency aka Goroutines is generally known to be the easiest and most straightforward implementation of the concurrency model so far. The process of spawning a new subprocess is, in fact, so simple that it feels more like doing nothing at all. All you need to do is just type go . It just can’t get easier than that, right?

aka is generally known to be the easiest and most straightforward implementation of the concurrency model so far. The process of spawning a new subprocess is, in fact, so simple that it feels more like doing nothing at all. All you need to do is just type . It just can’t get easier than that, right? Interfaces are clearly one of Golang’s most distinct and recognizable features. Their unique design solution addresses most of OOP criticism on its own, enables orthogonality and true component architectures while being just a valueless set of methods, which still hides few ingenious design tricks.

are clearly one of Golang’s most distinct and recognizable features. Their unique design solution addresses most of OOP criticism on its own, enables orthogonality and true component architectures while being just a valueless set of methods, which still hides few ingenious design tricks. Packages . Simply put, they are just awesome. They work seamlessly, without any surprises, and it feels great to use them, too, especially to import ones. By using the go get tool, you can do it from just about anywhere: Gopkg, GitHub, GitLab, BitBucket, even your own hosted repository source since “vanity” imports was introduced. But I guess, you already know the drill … Yep, they are secretly also pretty complicated in order to enable componentization, modularity, scalability, sharing, data hiding, and isolation, and so on.

. Simply put, they are just awesome. They work seamlessly, without any surprises, and it feels great to use them, too, especially to import ones. By using the tool, you can do it from just about anywhere: Gopkg, GitHub, GitLab, BitBucket, even your own hosted repository source since “vanity” imports was introduced. But I guess, you already know the drill … Yep, they are secretly also pretty complicated in order to enable componentization, modularity, scalability, sharing, data hiding, and isolation, and so on. Standard library of Go contains a ton of great handy features, which proves that Golang is, in fact, a pretty feature-rich language. However, the way they are implemented is something that makes it so unique. For instance, with the use of import “net/http" magic package, you’re at once getting all of the above features implemented in an awesome, highly concurrent, crazy easy to use, through a fully production-ready web-server.

of Go contains a ton of great handy features, which proves that Golang is, in fact, a pretty feature-rich language. However, the way they are implemented is something that makes it so unique. For instance, with the use of magic package, you’re at once getting all of the above features implemented in an awesome, highly concurrent, crazy easy to use, through a fully production-ready web-server. Reflection — This one, in particular, isn’t as simple to use as others in this list since it isn’t the most straightforward concept of any programming languages. Go still manages to make most of it, though, while keeping it relatively easy to use.

Reflection can sometimes be intentionally avoided in favor of Golang’s other paradigm, code generation, which in terms of Go ideology is less magical but more clear and efficient. I personally think of it as white magic, though, and surely will advocate its deliberate use, since sometimes, despite being less efficient, reflection can in fact provide some truly magical capabilities.

And there you have it. Golang’s feature set is a result of a thoughtful solution for yet another major language design problem, which requires selecting only the right features without increasing overall language complexity and with keeping its clarity.