3 ms·
> trading language surface complexity and readability for programmer convenience I would say the question mark improves readability, compared to having to chec
by ntoskrnl 4y ago
> trading language surface complexity and readability for programmer convenience
I would say the question mark improves readability, compared to having to check/return error codes by hand after every function call.
To your more general point, the language is pretty much established and syntax features are added very rarely. I think one more feature, let guards, is coming down the pipe soon, but other than that I wouldn't be surprised if the surface syntax never changes again.
- mmarq 4y ago> I would say the question mark improves readability, compared to having to check/return error codes by hand after every function call. Which is one of my complaints about Go. result, err = doSomething(); if err != nil { ... } result, err = doSomething2(); if err != nil { ... }