News for hackers. Stuff that matters.
Re:From Node.js to Go by sagichmal on Thursday February 05, 2015 @04:44PM (#9006336)
...the happy path there is intend level 0?

    if err := doSomething(); err != nil {
        return fmt.Errorf("something failed: %v", err)
    }
Or,

    x, err := doSomething()
    if err != nil {
        return fmt.Errorf("something failed: %v", err)
    }
    
    log.Print(x)

There are no comments on this comment yet.