file-io 0.1.4 → 0.1.5
raw patch · 6 files changed
+45/−13 lines, 6 filesdep ~bytestringdep ~deepseqdep ~unixPVP ok
version bump matches the API change (PVP)
Dependency ranges changed: bytestring, deepseq, unix
API changes (from Hackage documentation)
Files
- CHANGELOG.md +5/−0
- LICENSE +30/−0
- System/File/OsPath/Internal.hs +0/−1
- file-io.cabal +6/−5
- posix/System/File/Platform.hs +1/−4
- windows/System/File/Platform.hsc +3/−3
CHANGELOG.md view
@@ -1,5 +1,10 @@ # Revision history for file-io +## 0.1.5 -- 2024-11-26++* Don't use QuasiQotes+* Remove redundant imports+ ## 0.1.4 -- 2024-08-10 * fix build on GHC <= 8.10
+ LICENSE view
@@ -0,0 +1,30 @@+Copyright Julian Ospald 2024.+All rights reserved.++Redistribution and use in source and binary forms, with or without+modification, are permitted provided that the following conditions are+met:++ * Redistributions of source code must retain the above copyright+ notice, this list of conditions and the following disclaimer.++ * Redistributions in binary form must reproduce the above+ copyright notice, this list of conditions and the following+ disclaimer in the documentation and/or other materials provided+ with the distribution.++ * Neither the name of Neil Mitchell nor the names of other+ contributors may be used to endorse or promote products derived+ from this software without specific prior written permission.++THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS+"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT+LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR+A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT+OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,+SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT+LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,+DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY+THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT+(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE+OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
System/File/OsPath/Internal.hs view
@@ -2,7 +2,6 @@ {-# LANGUAGE TypeApplications #-} {-# LANGUAGE BangPatterns #-} {-# LANGUAGE ViewPatterns #-}-{-# LANGUAGE QuasiQuotes #-} module System.File.OsPath.Internal where
file-io.cabal view
@@ -1,16 +1,17 @@ cabal-version: 2.4 name: file-io-version: 0.1.4+version: 0.1.5 synopsis: Basic file IO operations via 'OsPath' description: Basic file IO operations like Prelude, but for 'OsPath'. homepage: https://github.com/hasufell/file-io bug-reports: https://github.com/hasufell/file-io/issues license: BSD-3-Clause+license-file: LICENSE author: Julian Ospald maintainer: hasufell@posteo.de copyright: Julian Ospald 2022 category: System-extra-source-files:+extra-doc-files: CHANGELOG.md tested-with: GHC==9.8.1, GHC==9.4.8,@@ -37,13 +38,13 @@ else hs-source-dirs: posix- build-depends: unix >=2.8.0.0+ build-depends: unix >=2.8.0.0 && <3 hs-source-dirs: . build-depends: , base >=4.13.0.0 && <5- , bytestring >=0.11.3.0- , deepseq+ , bytestring >=0.11.3.0 && <1+ , deepseq >=1 && <2 if flag(os-string) build-depends: filepath >= 1.5.0.0, os-string >= 2.0.0
posix/System/File/Platform.hs view
@@ -26,10 +26,7 @@ import GHC.IORef (atomicModifyIORef'_) import Foreign.C (getErrno, eEXIST, errnoToIOError) -#if MIN_VERSION_filepath(1, 5, 0)-import "os-string" System.OsString.Internal.Types (PosixString(..), PosixChar(..))-import qualified "os-string" System.OsString.Data.ByteString.Short as BC-#else+#if !MIN_VERSION_filepath(1, 5, 0) import Data.Coerce (coerce) import "filepath" System.OsString.Internal.Types (PosixString(..), PosixChar(..)) import qualified "filepath" System.OsPath.Data.ByteString.Short as BC
windows/System/File/Platform.hsc view
@@ -1,19 +1,19 @@ {-# LANGUAGE CPP #-} {-# LANGUAGE TypeApplications #-}-{-# LANGUAGE QuasiQuotes #-} {-# LANGUAGE PackageImports #-} module System.File.Platform where import Control.Exception (bracketOnError, try, SomeException, onException) import Data.Bits+import Data.Maybe (fromJust) import System.IO (IOMode(..), Handle) import System.OsPath.Windows ( WindowsPath ) import qualified System.OsPath.Windows as WS import Foreign.C.Types import qualified System.OsString.Windows as WS hiding (decodeFS)-import System.OsString.Windows ( pstr, WindowsString )+import System.OsString.Windows ( encodeUtf, WindowsString ) import qualified System.Win32 as Win32 import qualified System.Win32.WindowsString.File as WS import System.Win32.WindowsString.Types (withTString, peekTString)@@ -160,7 +160,7 @@ findTempName (prefix, suffix) loc tmp_dir mode = go where go = do- let label = if prefix == mempty then [pstr|ghc|] else prefix+ let label = if prefix == mempty then fromJust (encodeUtf "ghc") else prefix #if MIN_VERSION_Win32(2, 14, 0) withFilePath tmp_dir $ \c_tmp_dir -> #else