code: func (q *Quantity) Cmp(y Quantity) int {
  	if q.d.Dec == nil && y.d.Dec == nil {
  		return q.i.Cmp(y.i)
  	}
  	return q.AsDec().Cmp(y.AsDec())
  }
docs: // Cmp returns 0 if the quantity is equal to y, -1 if the quantity is less than y, or 1 if the
  // quantity is greater than y.