Russ Cox | 8080384 | 2012-02-16 23:49:59 -0500 | [diff] [blame] | 1 | // run |
Russ Cox | 77817e0 | 2010-04-29 16:07:14 -0700 | [diff] [blame] | 2 | |
Emmanuel Odeke | 53fd522 | 2016-04-10 14:32:26 -0700 | [diff] [blame] | 3 | // Copyright 2010 The Go Authors. All rights reserved. |
Russ Cox | 77817e0 | 2010-04-29 16:07:14 -0700 | [diff] [blame] | 4 | // Use of this source code is governed by a BSD-style |
| 5 | // license that can be found in the LICENSE file. |
| 6 | |
Brad Fitzpatrick | 2ae7737 | 2015-07-10 17:17:11 -0600 | [diff] [blame] | 7 | // https://golang.org/issue/749 |
Russ Cox | 77817e0 | 2010-04-29 16:07:14 -0700 | [diff] [blame] | 8 | |
| 9 | package main |
| 10 | |
| 11 | func f() (ok bool) { return false } |
| 12 | |
| 13 | func main() { |
| 14 | var i interface{} |
| 15 | i = f |
| 16 | _ = i.(func()bool) |
| 17 | _ = i.(func()(bool)) |
| 18 | } |