3 ms·
>Go types are structural. C# types are nominal. Go's type system is also nominal. If it were structural, it would allow you to have two types `type foo struct
by Arnavion 7y ago
>Go types are structural. C# types are nominal.
Go's type system is also nominal. If it were structural, it would allow you to have two types `type foo struct { id string }` and `type bar struct { id string }`, and let you assign a value of type `foo` to a binding of type `bar`, which it does not.