Skip to content

fix hidden errors#163

Open
mgoeppe wants to merge 1 commit intojordan-wright:masterfrom
mgoeppe:fix-hidden-errors
Open

fix hidden errors#163
mgoeppe wants to merge 1 commit intojordan-wright:masterfrom
mgoeppe:fix-hidden-errors

Conversation

@mgoeppe
Copy link
Copy Markdown

@mgoeppe mgoeppe commented Apr 23, 2026

Hello,

thank for this neat library! Just stumbled over some swallowed errors. IMHO named returned values are always a little bit dangerous. In your case the returned named error was not set as a new one was defined, i.e.:

func foo() (err error) {
  err := barReturningAnErrror()
  if err != nil {
    return
  }
}

will not return anything. Hopefully I got all occurrences of the issue.

Best regards

Mathias Zeller mathias.zeller@mercedes-benz.com Mercedes-Benz Tech Innovation GmbH (ProviderInformation)

@matoubidou matoubidou mentioned this pull request Apr 23, 2026
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.

1 participant