Characteristics of Go
This lesson discusses the aspects that make Go a successful language in the programming world.
Features of Go
Go is essentially an imperative (procedural, structural) language, built with concurrency in mind. It is not truly object-oriented like Java and C++ because it doesn’t have the concepts of classes and inheritance. However, it does have a concepts of interfaces, with which much of the polymorphism can be implemented. Go has a clear and expressive type-system, but it is lightweight and without hierarchy. So in this respect, it could be called a hybrid language.
Some features of modern OOP languages were intentionally left out. Because, object orientation was too heavy often leading to cumbersome development constructing big type-hierarchies, and so not compliant with the speed goal of the language. As per the decision made by the Go-team, the following OOP features are missing from Golang. Although, some of them might still be implemented in its future versions.
- To simplify the design, no function or operator overloading was added.
- Implicit conversions were excluded to avoid the many bugs and confusion arising from this in languages like C/C++.
- No classes and type inheritance is supported in Golang.
- Golang does not support variant types. However, almost the same functionality is realized through