code: func (m *Meta) loadConfig(rootDir string) (*configs.Config, tfdiags.Diagnostics) {
  	var diags tfdiags.Diagnostics
  	rootDir = m.normalizePath(rootDir)
  
  	loader, err := m.initConfigLoader()
  	if err != nil {
  		diags = diags.Append(err)
  		return nil, diags
  	}
  
  	config, hclDiags := loader.LoadConfig(rootDir)
  	diags = diags.Append(hclDiags)
  	return config, diags
  }
docs: // loadConfig reads a configuration from the given directory, which should
  // contain a root module and have already have any required descendent modules
  // installed.