From 5b75384820aef1828b1714cc1d876f70ed545089 Mon Sep 17 00:00:00 2001 From: Ian Lance Taylor Date: Sun, 21 Nov 2021 17:52:17 -0800 Subject: design/43651-type-parameters: use ~ in SliceConstraint Change-Id: Ifb4c3bcdc382d64b469616f311399af6fbe180f1 Reviewed-on: https://go-review.googlesource.com/c/proposal/+/366014 Trust: Ian Lance Taylor Reviewed-by: Ian Lance Taylor --- design/43651-type-parameters.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/design/43651-type-parameters.md b/design/43651-type-parameters.md index 64f29ea..454059e 100644 --- a/design/43651-type-parameters.md +++ b/design/43651-type-parameters.md @@ -2074,7 +2074,7 @@ There are no constraints on the second type parameter. // SliceConstraint is a type constraint that matches a slice of // the type parameter. type SliceConstraint[T any] interface { - []T + ~[]T } // Map takes a slice of some element type and a transformation function, -- cgit v1.3