Imports #
"internal/bytealg"
"internal/stringslite"
"syscall"
"errors"
"internal/stringslite"
"io/fs"
"slices"
"internal/bytealg"
"internal/stringslite"
"internal/bytealg"
"internal/stringslite"
"internal/bytealg"
"internal/stringslite"
"syscall"
"errors"
"internal/stringslite"
"io/fs"
"slices"
"internal/bytealg"
"internal/stringslite"
"internal/bytealg"
"internal/stringslite"
const ListSeparator = ';'const ListSeparator = '\000'const ListSeparator = ':'const Separator = '\\'const Separator = '/'const Separator = '/'var errInvalidPath = *ast.CallExprA lazybuf is a lazily constructed path buffer. It supports append, reading previously appended bytes, and retrieving the final string. It does not allocate a buffer to hold the output until that output diverges from s.
type lazybuf struct {
path string
buf []byte
w int
volAndPath string
volLen int
}Base is filepath.Base.
func Base(path string) stringClean is filepath.Clean.
func Clean(path string) stringDir is filepath.Dir.
func Dir(path string) stringExt is filepath.Ext.
func Ext(path string) stringFromSlash is filepath.ToSlash.
func FromSlash(path string) stringIsAbs reports whether the path is absolute.
func IsAbs(path string) boolIsAbs reports whether the path is absolute.
func IsAbs(path string) (b bool)IsAbs reports whether the path is absolute.
func IsAbs(path string) boolIsLocal is filepath.IsLocal.
func IsLocal(path string) boolfunc IsPathSeparator(c uint8) boolfunc IsPathSeparator(c uint8) boolfunc IsPathSeparator(c uint8) boolLocalize is filepath.Localize.
func Localize(path string) (string, error)Split is filepath.Split.
func Split(path string) (dir string, file string)ToSlash is filepath.ToSlash.
func ToSlash(path string) stringVolumeName is filepath.VolumeName.
func VolumeName(path string) stringVolumeNameLen returns the length of the leading volume name on Windows. It returns 0 elsewhere.
func VolumeNameLen(path string) intfunc (b *lazybuf) append(c byte)cutPath slices path around the first path separator.
func cutPath(path string) (before string, after string, found bool)func equalFold(a string, b string) boolfunc (b *lazybuf) index(i int) bytefunc isLocal(path string) boolfunc isLocal(path string) boolfunc isLocal(path string) boolfunc isReservedBaseName(name string) boolisReservedName reports if name is a Windows reserved device name. It does not detect names with an extension, which are also reserved on some Windows versions. For details, search for PRN in https://docs.microsoft.com/en-us/windows/desktop/fileio/naming-a-file.
func isReservedName(name string) boolisUNC reports whether path is a UNC path.
func isUNC(path string) boolfunc localize(path string) (string, error)func localize(path string) (string, error)func localize(path string) (string, error)pathHasPrefixFold tests whether the path s begins with prefix, ignoring case and treating all path separators as equivalent. If s is longer than prefix, then s[len(prefix)] must be a path separator.
func pathHasPrefixFold(s string, prefix string) boolpostClean adjusts the results of Clean to avoid turning a relative path into an absolute or rooted one.
func postClean(out *lazybuf)func postClean(out *lazybuf)func (b *lazybuf) prepend(prefix ...byte)func replaceStringByte(s string, old byte, new byte) stringfunc (b *lazybuf) string() stringfunc toUpper(c byte) byteuncLen returns the length of the volume prefix of a UNC path. prefixLen is the prefix prior to the start of the UNC host; for example, for "//host/share", the prefixLen is len("//")==2.
func uncLen(path string, prefixLen int) intfunc unixIsLocal(path string) boolvolumeNameLen returns length of the leading volume name on Windows. It returns 0 elsewhere.
func volumeNameLen(path string) intvolumeNameLen returns length of the leading volume name on Windows. It returns 0 elsewhere. See: https://learn.microsoft.com/en-us/dotnet/standard/io/file-path-formats https://googleprojectzero.blogspot.com/2016/02/the-definitive-guide-on-win32-to-nt.html
func volumeNameLen(path string) intvolumeNameLen returns length of the leading volume name on Windows. It returns 0 elsewhere.
func volumeNameLen(path string) intGenerated with Arrow