Commit df58f336 authored by Robert Griesemer's avatar Robert Griesemer
Browse files

[dev.typeparams] cmd/compile/internal/types2: don't report two errors for bad strings

If the parser reported an error for (string) literals, don't report
a second error during type checking.

This should have a couple of tests but they are tricky to arrange
with the current testing framework as the ERROR comment cannot be
on the line where the string. But the change is straightforward
and we have test/fixedbugs/issue32133.go that is passing now.

Change-Id: I0cd7f002b04e4092b8eb66009c7413288c8bfb23
Reviewed-on: https://go-review.googlesource.com/c/go/+/277993


Trust: Robert Griesemer <gri@golang.org>
Run-TryBot: Robert Griesemer <gri@golang.org>
Reviewed-by: default avatarRobert Findley <rfindley@google.com>
TryBot-Result: Go Bot <gobot@golang.org>
parent 91803a2d
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment