]> Cypherpunks repositories - gostls13.git/commit
go/scanner: accept 'i' suffix orthogonally on all numbers
authorRobert Griesemer <gri@golang.org>
Fri, 15 Feb 2019 01:53:14 +0000 (17:53 -0800)
committerRobert Griesemer <gri@golang.org>
Tue, 19 Feb 2019 22:44:43 +0000 (22:44 +0000)
commitc3b49186a6781de58a07bc49ae289354ae98e3be
tree45460314e9d5c60c1cdbdd3d5c3d79b9206db0d4
parent041d31b8820b62996cf1aa7b6fff77a818f2d94d
go/scanner: accept 'i' suffix orthogonally on all numbers

This change accepts the 'i' suffix on binary and octal integer
literals as well as hexadecimal floats. The suffix was already
accepted on decimal integers and floats.

See also the respective language in the spec change:
https://golang.org/cl/161098

Change-Id: I0c182bdf58f8fd1f70090e581b3ccb2f5e2e4e79
Reviewed-on: https://go-review.googlesource.com/c/162880
Reviewed-by: Ian Lance Taylor <iant@golang.org>
src/go/scanner/scanner.go
src/go/scanner/scanner_test.go