]> Cypherpunks repositories - gostls13.git/commit
token: more descriptive panics
authorJean de Klerk <deklerk@google.com>
Tue, 13 Oct 2020 22:16:24 +0000 (16:16 -0600)
committerJean de Klerk <deklerk@google.com>
Wed, 14 Oct 2020 22:35:32 +0000 (22:35 +0000)
commit8cd75f3da094931c59636b85a87b4f680a208799
treea9eaa048c48bcac7bb394c5c2f74da984a58c33e
parente4ec30965b9ca629922e83b8d335224ae4bdf062
token: more descriptive panics

Currently, there are several panics in token that simply say "illegal!". This CL
adds the values.

This is valuable when the token call is wrapped under several layers and you
can't easily see which value is being passed to token.

Change-Id: Ib04b55cafcd9b9ec6820dcf416fc4d49afaea15f
Reviewed-on: https://go-review.googlesource.com/c/go/+/262017
Reviewed-by: Robert Griesemer <gri@golang.org>
Run-TryBot: Robert Griesemer <gri@golang.org>
Trust: Robert Griesemer <gri@golang.org>
Trust: Jean de Klerk <deklerk@google.com>
TryBot-Result: Go Bot <gobot@golang.org>
src/go/token/position.go