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

Remove some named returns #228

Merged
merged 1 commit into from
Oct 5, 2023

Conversation

glibsm
Copy link
Contributor

@glibsm glibsm commented Oct 5, 2023

Named returns should only be used with naked returns, or a deferred function. And in general are better avoided

@tklauser
Copy link
Collaborator

tklauser commented Oct 5, 2023

Good catch. Looks like the build failure is related though: https://github.com/google/gops/actions/runs/6421052805/job/17434527909?pr=228#step:5:13

@glibsm
Copy link
Contributor Author

glibsm commented Oct 5, 2023

Good catch. Looks like the build failure is related though: https://github.com/google/gops/actions/runs/6421052805/job/17434527909?pr=228#step:5:13

Oops, let me fix it. I did go build . and not go build ./... :(

@glibsm glibsm force-pushed the pr/glibsm/remove-named-returns branch 2 times, most recently from 044d212 to 4950b45 Compare October 5, 2023 17:12
agent/agent.go Outdated Show resolved Hide resolved
Named returns should only be used with naked returns, or a
deferred function. And in general are better avoided
@glibsm glibsm force-pushed the pr/glibsm/remove-named-returns branch from 4950b45 to b30bf6a Compare October 5, 2023 19:34
Copy link
Collaborator

@tklauser tklauser left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks

@tklauser tklauser merged commit 22cdba1 into google:master Oct 5, 2023
10 checks passed
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

Successfully merging this pull request may close these issues.

2 participants