// newpcpSingletonMetric creates a new instance of pcpSingletonMetric.
newpcpSingletonMetric creates a new instance of pcpSingletonMetric.
// newpcpSingletonMetric creates a new instance of pcpSingletonMetric .
func newpcpSingletonMetric(val interface{}, desc *pcpMetricDesc) (*pcpSingletonMetric, error) {
	if !desc.t.IsCompatible(val) {
		return nil, errors.Errorf("type %v is not compatible with value %v(%T)", desc.t, val, val)
	}
	val = desc.t.resolve(val)
	return &pcpSingletonMetric{desc, val, nil}, nil
}
func newpcpSingletonMetric ( val interface { } , desc * pcpMetricDesc ) ( * pcpSingletonMetric , error ) { if ! desc . t . IsCompatible ( val ) { return nil , errors . Errorf ( " " , desc . t , val , val ) } val = desc . t . resolve ( val ) return & pcpSingletonMetric { desc , val , nil } , nil }
newpcpSingletonMetric creates a new instance of pcpSingletonMetric.
newpcpSingletonMetric creates a new instance of pcpSingletonMetric .