5 ms·
> Go is a "principle of least surprise" language, based on a vision of simplicity for C that hasn't existed among actual C implementations (outside of maybe Pla
by lloeki 6y ago
> Go is a "principle of least surprise" language, based on a vision of simplicity for C that hasn't existed among actual C implementations (outside of maybe Plan 9) for decades now. It's yet more suckless idiocy
Have you considered that this Go opinion might not be “idiocy” but desirable qualities in some use cases?
It seems quite inappropriate to bash on Go for realising a vision that solves such a use case, in turn assuming no such use case exists, just as it is inappropriate to vilify Ruby or Python for for having a very dynamic object model and method calling/message passing, witch results in non-optimisable call paths because they have to be resolved every single time.
Go’s consistency, reliability, and ease in debugging and exploring is definitely a really good feature that I gladly trade a few microseconds for.
- jashmatthews 6y ago> Ruby or Python for for having a very dynamic object model and method calling/message passing, witch results in non-optimisable call paths because they have to be resolved every single time. The Ruby implementations don't really do that. They use "inline caches" so this lookup normally only happens once per call-site.
- monocasa 6y agoIf there's only one backing type being looked up. If there's more than one, the inline cache thrashs like they're saying.
- jashmatthews 6y agoJRuby has had polymorphic inline caches for like a decade and CRuby will actually cache multiple types in the method cache as long as they cache the same method since https://github.com/ruby/ruby/pull/2583 https://github.com/ruby/ruby/pull/2583
- monocasa 6y agoJRuby is JVM and not really what I'm talking about. And still on CRuby if you have any dynacism, you thrash your cache.