3 ms·
"In real-world code, you don’t actually end up casting interface{} to something else that often" I have to disagree here, and I've had trouble finding any seri
by slantedview 11y ago
"In real-world code, you don’t actually end up casting interface{} to something else that often"
I have to disagree here, and I've had trouble finding any serious argument that this is an OK thing to have to do. When we accept the benefit of not allowing users to create generic abstractions, we also have to recognize the very real cost of not allowing users to create generic abstractions.
Software/technology trends go in cycles. Several years from now, a generation of Golang programmers will be preaching the benefits of DRY, having learned from the painful mistakes of maintaining the large and complex Golang codebases yet to come without the benefit of creating appropriate abstractions, just as Golang was partially an answer to the painful mistakes of maintaining large and complex dynamic codebases. And so the pendulum will swing again.