Exemple #1
0
// ZeroValue works like types.Type.SafeZeroValue, but unlike the types.Type
// version, this method can also return zero values for types in this
// package.
func ZeroValue(t types.Type) (interface{}, error) {
	if t == types.Dist {
		return (*Distribution)(nil), nil
	} else {
		return t.SafeZeroValue()
	}
}