Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

goreturns don't add zero-value return values when formatting #22

Open
bruceauyeung opened this issue May 28, 2016 · 0 comments
Open

goreturns don't add zero-value return values when formatting #22

bruceauyeung opened this issue May 28, 2016 · 0 comments

Comments

@bruceauyeung
Copy link

bruceauyeung commented May 28, 2016

i have a file pks1/pkg1.go in my codebase

package pkg1

import (
"errors"
"fmt"
)

func Test3() {
fmt.Println("pkg1")
}
func Test1() (string, error) {

return errors.New("aaa")

}

when i run goreturns pkg1.go, the output is:

D:\GoStudy\src\suselinks.us\gostudy\pkg1>goreturns pkg1.go
package pkg1

import (
"errors"
"fmt"
)

func Test3() {
fmt.Println("pkg1")
}
func Test1() (string, error) {

    return errors.New("aaa")

}

the output show goreturns didn't add zero-value return values at all when formatting

goreturns code commit id:6937071b7e1702a52f31a199c2ebb3796475494f
os : windows 7 64bit

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant