This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.
Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
---|---|---|
Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |
Other format: | [Raw text] |
f := func(a ...string) error {switch t := mv.CallSlice([]reflect.Value{reflect.ValueOf(a)})[0].Interface().(type) {
case error: return t default: return nil } } On 02/06/2015 05:05 PM, Ian Lance Taylor wrote:
On Fri, Feb 6, 2015 at 12:36 PM, Lynn A. Boger <laboger@linux.vnet.ibm.com> wrote:I was told by the testers that this patch did not work. The error message was:panic: interface conversion: interface is nil, not error goroutine 1 [running]: client.$nested1 /home/ubuntu/docker.mainline/src/github.com/docker/docker/api/ client/cli.go:66 github_com_docker_docker_api_client.Cmd.pN45_github_com_docker_docker_api_client.DockerCli /home/ubuntu/docker.mainline/src/github.com/docker/docker/api/ client/cli.go:84 main.main /home/ubuntu/docker/docker/docker.go:126That's easy to fix.... Ian
Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
---|---|---|
Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |