code: func (r *Resource) ProviderConfigAddr() addrs.ProviderConfig {
  	if r.ProviderConfigRef == nil {
  		return r.Addr().DefaultProviderConfig()
  	}
  
  	return addrs.ProviderConfig{
  		Type:  r.ProviderConfigRef.Name,
  		Alias: r.ProviderConfigRef.Alias,
  	}
  }
docs: // ProviderConfigAddr returns the address for the provider configuration
  // that should be used for this resource. This function implements the
  // default behavior of extracting the type from the resource type name if
  // an explicit "provider" argument was not provided.