2012-02-16 21:49:30 -07:00
|
|
|
// errorcheck
|
2009-10-28 18:09:24 -06:00
|
|
|
|
|
|
|
// Copyright 2009 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.
|
|
|
|
|
|
|
|
package main
|
2009-11-09 00:22:06 -07:00
|
|
|
type I int
|
2009-10-28 18:09:24 -06:00
|
|
|
type S struct { f map[I]int }
|
2009-11-02 12:58:47 -07:00
|
|
|
var v1 = S{ make(map[int]int) } // ERROR "cannot|illegal|incompatible|wrong"
|
|
|
|
var v2 map[I]int = map[int]int{} // ERROR "cannot|illegal|incompatible|wrong"
|
2009-10-28 18:09:24 -06:00
|
|
|
var v3 = S{ make(map[uint]int) } // ERROR "cannot|illegal|incompatible|wrong"
|