aboutsummaryrefslogtreecommitdiff
path: root/src/go/types/expr.go
diff options
context:
space:
mode:
authorRobert Griesemer <gri@golang.org>2020-11-19 16:38:11 -0800
committerRobert Griesemer <gri@golang.org>2020-11-20 00:54:43 +0000
commitc72a44888174947dfb010a636d89dc8bdd61183c (patch)
treee3b3ce9b0a4e1fcbefd9fa6f919c0ec2669d62cd /src/go/types/expr.go
parent7eed73f36f14cfb2f49b0ef95beb2ae94a64f66e (diff)
downloadgo-c72a44888174947dfb010a636d89dc8bdd61183c.tar.gz
go-c72a44888174947dfb010a636d89dc8bdd61183c.zip
go/types: fix error message for consistency
Follow-up on https://golang.org/cl/271706 . (Missed a review comment.) Change-Id: Ibff542f43d721600a2452907c0a20941961e793f Reviewed-on: https://go-review.googlesource.com/c/go/+/271766 Trust: Robert Griesemer <gri@golang.org> Run-TryBot: Robert Griesemer <gri@golang.org> Reviewed-by: Robert Findley <rfindley@google.com> TryBot-Result: Go Bot <gobot@golang.org>
Diffstat (limited to 'src/go/types/expr.go')
-rw-r--r--src/go/types/expr.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/go/types/expr.go b/src/go/types/expr.go
index 5bf9c81460..4e19f30477 100644
--- a/src/go/types/expr.go
+++ b/src/go/types/expr.go
@@ -890,7 +890,7 @@ func (check *Checker) binary(x *operand, e *ast.BinaryExpr, lhs, rhs ast.Expr, o
// TODO(gri) We should report exactly what went wrong. At the
// moment we don't have the (go/constant) API for that.
// See also TODO in go/constant/value.go.
- check.errorf(atPos(e.OpPos), _InvalidConstVal, "constant result not representable")
+ check.errorf(atPos(e.OpPos), _InvalidConstVal, "constant result is not representable")
// TODO(gri) Should we mark operands with unknown values as invalid?
}
// Typed constants must be representable in