]> Cypherpunks.ru repositories - gostls13.git/commit
[dev.regabi] go/types: use 512 bits as max. integer precision
authorRob Findley <rfindley@google.com>
Tue, 9 Feb 2021 03:37:48 +0000 (22:37 -0500)
committerRobert Findley <rfindley@google.com>
Tue, 9 Feb 2021 14:17:01 +0000 (14:17 +0000)
commit168d6a49a5ecbdd6a1eb039b2398c2821b3d3865
treec3b7eae8698c8683005c201bb2d40cf647fddce8
parent0a62067708938020e10b8142b4017edeac1b1f52
[dev.regabi] go/types: use 512 bits as max. integer precision

This is a port of CL 288633 to go/types. It differs from that CL
in the implementation of opName, which now uses ast Exprs.

Additionally, a couple tests had to be updated:
 + TestEvalArith is updated to not overflow.
 + stmt0.src is updated to have an error positioned on the '<<'
   operator.

Change-Id: I628357c33a1e7b0bb5bb7de5736f1fb10ce404e4
Reviewed-on: https://go-review.googlesource.com/c/go/+/290630
Trust: Robert Findley <rfindley@google.com>
Run-TryBot: Robert Findley <rfindley@google.com>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Robert Griesemer <gri@golang.org>
src/go/types/eval_test.go
src/go/types/expr.go
src/go/types/stdlib_test.go
src/go/types/testdata/builtins.src
src/go/types/testdata/const0.src
src/go/types/testdata/const1.src
src/go/types/testdata/stmt0.src