这个咱就看go官网的说辞就好了,他们自己说是Yes and No。明显go是允许OO的编程风格的,但又缺乏一些Java和C++中的常见类型继承结构。Go的interface也和Java中的用法大相径庭, 这也是我经常吹捧的隐式继承。Go自己觉得这一套挺好的,更加的容易使用且通用性更强。很多时候我们用OO的思想来组织我们的项目,但需要注意的是java的继承关系是一种非常强的耦合,有时候会给以后的升级带来麻烦(这个可以看为什么java8的升级带来了interface的default method)。我觉得隐式继承在超大型的monorepo项目中是非常有帮助的,当然小型的项目可能好处不是很明显。

Is Go an object-oriented language?

Yes and no. Although Go has types and methods and allows an object-oriented style of programming, there is no type hierarchy. The concept of “interface” in Go provides a different approach that we believe is easy to use and in some ways more general. There are also ways to embed types in other types to provide something analogous—but not identical—to subclassing. Moreover, methods in Go are more general than in C++ or Java: they can be defined for any sort of data, even built-in types such as plain, “unboxed” integers. They are not restricted to structs (classes).

Also, the lack of a type hierarchy makes “objects” in Go feel much more lightweight than in languages such as C++ or Java.

如果题主是从java过来,那么完全照搬java的oo设计思想在go中会比较痛苦,你可能要大量的使用一些挺别扭的方式来实现自己的应用。这个很多答主都给出了例子,是好是坏大家可以自己看。怎么用好Go的OO特性其实是个挑战,刚开始大家谁都不适应,有这一系列文章我早先读过,我觉得对初学者很有帮助。