Hoogle Search
Within LTS Haskell 24.3 (ghc-9.10.2)
Note that Stackage only displays results for the latest LTS and Nightly snapshot. Learn more.
asFilePath :: (System os, AbsRel ar) => String -> FilePath os arpathtype System.Path.Generic Deprecated: Use filePath instead.
equalFilePath :: System os => Tagged os (String -> String -> Bool)pathtype System.Path.Generic Check whether two strings are equal as file paths.
Posix.equalFilePath "abc/def" "abc/def"
Posix.equalFilePath "abc/def" "abc//def"
Posix.equalFilePath "/tmp/" "/tmp"
Posix.equalFilePath "/tmp" "//tmp"
Posix.equalFilePath "/tmp" "///tmp"
not $ Posix.equalFilePath "abc" "def"
not $ Posix.equalFilePath "/tmp" "tmp"
Windows.equalFilePath "abc\\def" "abc\\def"
Windows.equalFilePath "abc\\def" "abc\\\\def"
Windows.equalFilePath "file" "File"
Windows.equalFilePath "\\file" "\\\\file"
Windows.equalFilePath "\\file" "\\\\\\file"
not $ Windows.equalFilePath "abc" "def"
not $ Windows.equalFilePath "file" "dir"
asFilePath :: AbsOrRel ar => String -> FilePath arpathtype System.Path.Posix Deprecated: Use filePath instead.
equalFilePath :: String -> String -> Boolpathtype System.Path.Posix Deprecated: Use System.FilePath.equalFilePath instead.
asFilePath :: AbsOrRel ar => String -> FilePath arpathtype System.Path.Windows Deprecated: Use filePath instead.
equalFilePath :: String -> String -> Boolpathtype System.Path.Windows Deprecated: Use System.FilePath.equalFilePath instead.
-
Use RawFilePath instead of FilePath A fast and safe API with high-level features on RawFilePath, instead of FilePath, to avoid the encoding issues or performance penalties. Please see README.md
module Data.ByteString.
RawFilePath A drop-in replacement of Data.ByteString from the bytestring package that provides file I/O functions with RawFilePath instead of FilePath.
-
rawfilepath Data.ByteString.RawFilePath A literal POSIX file path
fromFilePath :: FilePath -> IO ByteStringrawfilepath Data.ByteString.RawFilePath Convert a FilePath to a ByteString. The FilePath type is expected to use the file system encoding as reported by getFileSystemEncoding. This encoding allows for round-tripping of arbitrary data on platforms that allow arbitrary bytes in their paths. This conversion function does the same thing that openFile would do when decoding the FilePath. This function is in IO because the file system encoding can be changed. If the encoding can be assumed to be constant in your use case, you may invoke this function via unsafePerformIO.