From ed832ed353f6386c4f1ce061d8048e31873e0439 Mon Sep 17 00:00:00 2001 From: Russ Cox Date: Fri, 21 Apr 2023 10:31:34 -0400 Subject: [PATCH] go/types: add test case for CL 486398 Forgot to 'git add' this test case in the CL. Change-Id: Idde1d3d4525a99bdab0d3d69ac635a96a7cd5d73 Reviewed-on: https://go-review.googlesource.com/c/go/+/487335 Auto-Submit: Russ Cox TryBot-Result: Gopher Robot Run-TryBot: Russ Cox Reviewed-by: Robert Findley --- src/internal/types/testdata/check/go1_xx_19.go | 15 +++++++++++++++ 1 file changed, 15 insertions(+) create mode 100644 src/internal/types/testdata/check/go1_xx_19.go diff --git a/src/internal/types/testdata/check/go1_xx_19.go b/src/internal/types/testdata/check/go1_xx_19.go new file mode 100644 index 00000000000..01f6b7d2ebb --- /dev/null +++ b/src/internal/types/testdata/check/go1_xx_19.go @@ -0,0 +1,15 @@ +// Copyright 2022 The Go Authors. All rights reserved. +// Use of this source code is governed by a BSD-style +// license that can be found in the LICENSE file. + +// Check Go language version-specific errors. + +//go:build go1.19 + +package p + +type Slice []byte +type Array [8]byte + +var s Slice +var p = (Array)(s /* ok because Go 1.X prior to Go 1.21 ignored the //go:build go1.19 */)