code: func readDirInfos(dirPath string) ([]os.FileInfo, error) {
  	names, err := readDirNames(dirPath)
  	if err != nil {
  		return nil, err
  	}
  	sort.Strings(names)
  
  	infos := make([]os.FileInfo, 0, len(names))
  	for _, n := range names {
  		info, err := os.Stat(path.Join(dirPath, n))
  		if err != nil {
  			return nil, err
  		}
  		infos = append(infos, info)
  	}
  	return infos, nil
  }
docs: // readDirInfos returns a list of os.FileInfo structures for the dirents under
  // dirPath.  The result list is sorted by name.  This is very similar to
  // ioutil.ReadDir, except that it follows symlinks.