compiler: give error for non-int arguments to make

This implements a requirement of the language spec.

While we're here fix the value returned by the type method of a
builtin call expression to make, although this doesn't seem to make
any difference anywhere since we lower this to a runtime call before
the determine_types pass anyhow.

There is already a test for this error in the master repository:
test/fixedbugs/issue16949.go. It just hasn't made it into the gccgo
testsuite yet.

Fixes golang/go#16949

Change-Id: Ib1891bcdd889eb082a08ecd712e0cb67cec6a66a
Reviewed-on: https://go-review.googlesource.com/91697
Reviewed-by: Than McIntosh <thanm@google.com>
1 file changed