| 1 |
package html |
| 2 |
|
| 3 |
import "fmt" |
| 4 |
|
| 5 |
// This file is tested by html_test.go. |
| 6 |
// The comments below are markers for extracting the annotated source |
| 7 |
// from the HTML output. |
| 8 |
|
| 9 |
// This is a regression test for incorrect sorting of boundaries |
| 10 |
// that coincide, specifically for empty select clauses. |
| 11 |
// START f |
| 12 |
func f() { |
| 13 |
ch := make(chan int) |
| 14 |
select { |
| 15 |
case <-ch: |
| 16 |
default: |
| 17 |
} |
| 18 |
} |
| 19 |
|
| 20 |
// END f |
| 21 |
|
| 22 |
// https://golang.org/issue/25767 |
| 23 |
// START g |
| 24 |
func g() { |
| 25 |
if false { |
| 26 |
fmt.Printf("Hello") |
| 27 |
} |
| 28 |
} |
| 29 |
|
| 30 |
// END g |