4 ms·
My problems with the readability of Rust is related to the syntax and not so much about the code structure. For example, Smalltalk has the most readable syntax
by JepZ 10y ago
My problems with the readability of Rust is related to the syntax and not so much about the code structure. For example, Smalltalk has the most readable syntax I know, while I find it's code structure average.
I know that error handling in Go can be tedious, but to some extent, it is also the programmer's job to utilize the features of the language to write clean code: https://blog.golang.org/errors-are-values https://blog.golang.org/errors-are-values
Regarding your type problem I find very few cases where I need an empty interface (mainly container types). Most of the time I use real interfaces and the most code I have seen used non-empty Interfaces too.
- vertex-four 10y agoI tend to find that Rust's syntax warts are primarily in function headers (primarily due to lifetimes), and less so in the bodies. > Regarding your type problem I find very few cases where I need an empty interface (mainly container types). I've run into the issue with quite a few "generic" libraries, since Go doesn't have a generics system. For example, https://github.com/manyminds/api2go https://github.com/manyminds/api2go requires a few of them in common cases. My alternative is writing the same code over and over, and hoping that I've not missed something in one instance of it.