code: func typeDefinition() (*design.UserTypeDefinition, bool) {
  	m, ok := dslengine.CurrentDefinition().(*design.UserTypeDefinition)
  	if !ok {
  		dslengine.IncompatibleDSL()
  	}
  	return m, ok
  }
docs: // typeDefinition returns true and current context if it is a UserTypeDefinition,
  // nil and false otherwise.