summaryrefslogtreecommitdiffstats
path: root/src/cmd/go/testdata/script/test_bad_example.txt
blob: 1d147b663fe62af62ab320b7baa9516a6a14f833 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
# Tests that invalid examples are ignored.
# Verifies golang.org/issue/35284
go test x_test.go

-- x_test.go --
package  x

import "fmt"

func ExampleThisShouldNotHaveAParameter(thisShouldntExist int) {
	fmt.Println("X")
	// Output:
}