Comment

Comment by drivebyacct2

Conversely, this is a huge upside of Go. I enjoy the explicit error handling. It's a very conscious decision. There is panic/recover style "exceptions" but that's for truly exception states and not just error states.

It seems a rather bad example anyway, not sure why I'd prefer:

    try {
        http.ListenAndServe(":8080", nil);
    } catch(ServeException se) {
        // handle se
    }
over the Go alternative.
parent drivebyacct2 14 years ago

Discussion

Live from the official Hacker News API

A modern reader for Hacker News · SvelteKit + Skeleton