From: Ian Lance Taylor Date: Tue, 1 Aug 2017 22:06:36 +0000 (-0700) Subject: test: add test that caused gccgo compiler crash X-Git-Tag: go1.10beta1~1492 X-Git-Url: http://www.git.cypherpunks.su/?a=commitdiff_plain;h=6711fa70cecce261662c20613cc63eec0c21a16a;p=gostls13.git test: add test that caused gccgo compiler crash Updates #21253 Change-Id: Iece71a27207b578618cafb378dac2362517363d0 Reviewed-on: https://go-review.googlesource.com/52531 Run-TryBot: Ian Lance Taylor TryBot-Result: Gobot Gobot Reviewed-by: Than McIntosh Reviewed-by: Brad Fitzpatrick --- diff --git a/test/fixedbugs/issue21253.go b/test/fixedbugs/issue21253.go new file mode 100644 index 0000000000..3531b2b81f --- /dev/null +++ b/test/fixedbugs/issue21253.go @@ -0,0 +1,27 @@ +// compile + +// Copyright 2017 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 crashed compiling this code due to failing to finalize +// interfaces in the right order. + +package p + +type s1 struct { + f m + I +} + +type m interface { + Mm(*s2) +} + +type s2 struct { + *s1 +} + +type I interface { + MI() +}