3 ms·
This is well thought out, especially the “Omissions” section that explains what’s not in scope. I wish they had defined a constraint for types that have a usabl
by erik_seaberg 6y ago
This is well thought out, especially the “Omissions” section that explains what’s not in scope. I wish they had defined a constraint for types that have a usable zero value that doesn’t immediately blow up (like maps and struct pointers).
> That may in turn lead to pressure to modify the language to add some mechanism for using an Iterator with the range clause.
Yes please, there’s so much grammar that just refuses to support any user-defined type.
- ignoramous 6y ago> Yes please, there’s so much grammar that just refuses to support any user-defined type. Nothing embodies "the tale of two cities" esque paradox like Go does. If you're a programmer, Go is so simple that it isn't easy to do anything but the simplest thing.
- tptacek 6y agoGo is so simple that it usually doesn't make sense to express things in anything but simple terms. What surprised me about working in that kind of environment was how much it freed me to be creative about my algorithms and problem domain, rather than how concisely I was describing boring algorithms. I work mostly in Rust now, and that's a property I miss about Go.
- ignoramous 6y ago> ...freed me to be creative about my algorithms and problem domain, rather than how concisely I was describing boring algorithms. Agree. I dabble in Kotlin and Golang at work. Those languages can't be further apart. I occasionally need to read Rust code, but it has been a struggle compared to how easy it is to read Go.
- kibwen 6y agoFascinated to hear that you're using Rust in any capacity, from your comment history I assumed you were mostly Go. What domain, can I ask? Security research, cryptography?
- tptacek 6y agoI'm part of the development team at Fly.io. Actually, most of what I've been writing lately has been C, with the BPF verifier. But the rest of it has largely been Rust, and Rust is the language our proxies are written in.
- huhtenberg 6y ago> No specialization That's pretty limiting when writing optimized code, i.e. when (much) faster versions of generic functions are available for specific types. > No currying Not sure why they decided not to support this, seems like a fairly logical feature to allow. Perhaps they couldn't figure out a good syntax to express this?