code: func (parent *ErrorClass) NewClass(name string,
  	options ...ErrorOption) *ErrorClass {
  
  	ec := &ErrorClass{
  		parent: parent,
  		name:   name,
  		data:   make(map[DataKey]interface{})}
  
  	for _, option := range options {
  		option(ec.data)
  	}
  
  	if !boolWrapper(ec.data[disableInheritance], false) {
  		// hoist options for speed
  		for key, val := range parent.data {
  			_, exists := ec.data[key]
  			if !exists {
  				ec.data[key] = val
  			}
  		}
  		return ec
  	} else {
  		delete(ec.data, disableInheritance)
  	}
  
  	return ec
  }
docs: // NewClass creates an error class with the provided name and options. The new
  // class will descend from the receiver.