From 162f1bf7c21116d218c41b085f844dcd75ef6544 Mon Sep 17 00:00:00 2001 From: Ian Lance Taylor Date: Thu, 9 Apr 2020 17:34:07 -0700 Subject: [PATCH] test: add test case that gccgo failed to compile Change-Id: I08ca5f77b7352fe3ced1fbe3d027d6f5b4828e35 Reviewed-on: https://go-review.googlesource.com/c/go/+/227783 Run-TryBot: Ian Lance Taylor TryBot-Result: Gobot Gobot Reviewed-by: Than McIntosh --- test/fixedbugs/bug508.go | 14 ++++++++++++++ 1 file changed, 14 insertions(+) create mode 100644 test/fixedbugs/bug508.go diff --git a/test/fixedbugs/bug508.go b/test/fixedbugs/bug508.go new file mode 100644 index 0000000000..69b1adaf95 --- /dev/null +++ b/test/fixedbugs/bug508.go @@ -0,0 +1,14 @@ +// compile + +// Copyright 2020 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. + +// Gccgo mishandles composite literals of map with type bool. + +package p + +var M = map[bool]uint8{ + false: 0, + true: 1, +} -- 2.50.0