go.tools/go/types: print local types unqualified in error/debugging output

LGTM=adonovan
R=adonovan
CC=golang-codereviews
https://golang.org/cl/57630044
This commit is contained in:
Robert Griesemer 2014-01-28 09:22:53 -08:00
parent 7ecad5bf71
commit ffc6416213
1 changed files with 2 additions and 0 deletions

View File

@ -34,6 +34,8 @@ func (check *checker) sprintf(format string, args ...interface{}) string {
args[i] = check.fset.Position(a).String()
case ast.Expr:
args[i] = ExprString(a)
case Type:
args[i] = TypeString(check.pkg, a)
}
}
return fmt.Sprintf(format, args...)