|
|
|
|
|
by nostrademons
3721 days ago
|
|
Interesting, because (reading up on this) value types can not be nil. How often does typical Go code use values vs. interfaces or pointers? It seems like the situation is pretty similar to modern C++, which also does not allow null for value or reference types (only pointers) and encourages value-based programming. Nil is still a problem there, but less of one than in, say, Java, where everything is a reference. |
|
The code that I've written regularly uses interfaces and pointers, but I'd guess 80% works directly with values.