Skip to content

Commit 6fff1af

Browse files
dmitshurgopherbot
authored andcommitted
go/analysis/passes/errorsas: update testdata for new warning
A new testdata file was added since CL 339889 was authored. Update it in the same way for the new warning. Updates golang/go#47528. Fixes golang/go#52613. Change-Id: I17d06c602eeabcc4ddc8514d5e444acdb714ab94 Reviewed-on: https://go-review.googlesource.com/c/tools/+/403034 Auto-Submit: Dmitri Shuralyov <[email protected]> TryBot-Result: Gopher Robot <[email protected]> Reviewed-by: Dmitri Shuralyov <[email protected]> Reviewed-by: Tim King <[email protected]> Run-TryBot: Dmitri Shuralyov <[email protected]> gopls-CI: kokoro <[email protected]>
1 parent 115b454 commit 6fff1af

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

go/analysis/passes/errorsas/testdata/src/typeparams/typeparams.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ func _[E error](e E) {
2828
errors.As(nil, &e)
2929
errors.As(nil, &m) // *T where T implemements error
3030
errors.As(nil, &tw.t) // *T where T implements error
31-
errors.As(nil, perr[error]()) // *error, via a call
31+
errors.As(nil, perr[error]()) // want `second argument to errors.As should not be \*error`
3232

3333
errors.As(nil, e) // want `second argument to errors.As must be a non-nil pointer to either a type that implements error, or to any interface type`
3434
errors.As(nil, m) // want `second argument to errors.As must be a non-nil pointer to either a type that implements error, or to any interface type`

0 commit comments

Comments
 (0)