blob: 51df9b8ae869ac5cd955c005a64a77ad16b74edf [file] [log] [blame]
Ian Lance Tayloreb63c3f2009-10-28 17:09:24 -07001// errchk $G $D/$F.go
2
3// Copyright 2009 The Go Authors. All rights reserved.
4// Use of this source code is governed by a BSD-style
5// license that can be found in the LICENSE file.
6
7package main
Russ Cox71983af2009-11-08 23:22:06 -08008type I int
Ian Lance Tayloreb63c3f2009-10-28 17:09:24 -07009type S struct { f map[I]int }
Ian Lance Taylor6358cac2009-11-02 11:58:47 -080010var v1 = S{ make(map[int]int) } // ERROR "cannot|illegal|incompatible|wrong"
11var v2 map[I]int = map[int]int{} // ERROR "cannot|illegal|incompatible|wrong"
Ian Lance Tayloreb63c3f2009-10-28 17:09:24 -070012var v3 = S{ make(map[uint]int) } // ERROR "cannot|illegal|incompatible|wrong"