3 ms·
For me the big surprise is that we still have languages where we have to write things like func setupBucket(ctx context.Context) (*blob.Bucket, error) {
by pmontra 8y ago
For me the big surprise is that we still have languages where we have to write things like
func setupBucket(ctx context.Context) (*blob.Bucket, error) {
sess, err := session.NewSession(&aws.Config{
Region: aws.String("us-east-2"),
})
full of ( ) { } * and & as if we were still in the 80s. So Go is a very surprising language, but this is highly subjective. No hard feelings.
- didip 8y agoFor a statically typed language, the number of sigils Go have is surprisingly low.
- tapirl 8y agoMost popular languages are full of (). Most popular languages are full of {}, except python. All C family languages are full of *. I can't see any surprises here.
- robbrit 8y agoYou're right, it is dependent on your perspective. Go is intended to be unsurprising to developers who want to just be able to look at code and have a good idea of what it does. Punctuation is very useful to get rid of ambiguity. Contrast this with a language like Ruby which tries very hard to make punctuation optional, and often ends up with ambiguous cases where you aren't 100% certain how the interpreter will parse some code and so you end up throwing in all the punctuation anyway.
- deleted 8y ago[deleted]
- notdang 8y agoI prefer it like this instead of relying on indentation