aboutsummaryrefslogtreecommitdiffhomepage
path: root/System/Posix/Process
diff options
context:
space:
mode:
authorGravatar Herbert Valerio Riedel <hvr@gnu.org>2016-01-30 23:14:23 +0100
committerGravatar Herbert Valerio Riedel <hvr@gnu.org>2016-01-31 00:19:53 +0100
commit2a49ad87b7b5d92bf62035d410c4bcde817d30a6 (patch)
tree6cba2a97efac7cea6153e6dd10bdc04cd6e669c6 /System/Posix/Process
parent716eccb11f324abc120c24ce0344b7094f1aa435 (diff)
Drop redundant __GLASGOW_HASKELL__ conditionals for GHC>=7.4
Diffstat (limited to 'System/Posix/Process')
-rw-r--r--System/Posix/Process/ByteString.hsc4
-rw-r--r--System/Posix/Process/Common.hsc10
-rw-r--r--System/Posix/Process/Internals.hs2
3 files changed, 2 insertions, 14 deletions
diff --git a/System/Posix/Process/ByteString.hsc b/System/Posix/Process/ByteString.hsc
index 64fc71e..39da5ba 100644
--- a/System/Posix/Process/ByteString.hsc
+++ b/System/Posix/Process/ByteString.hsc
@@ -1,6 +1,6 @@
#if __GLASGOW_HASKELL__ >= 709
{-# LANGUAGE Safe #-}
-#elif __GLASGOW_HASKELL__ >= 703
+#else
{-# LANGUAGE Trustworthy #-}
#endif
@@ -23,10 +23,8 @@ module System.Posix.Process.ByteString (
-- * Processes
-- ** Forking and executing
-#ifdef __GLASGOW_HASKELL__
forkProcess,
forkProcessWithUnmask,
-#endif
executeFile,
-- ** Exiting
diff --git a/System/Posix/Process/Common.hsc b/System/Posix/Process/Common.hsc
index d0d2b09..59212e4 100644
--- a/System/Posix/Process/Common.hsc
+++ b/System/Posix/Process/Common.hsc
@@ -1,8 +1,7 @@
{-# LANGUAGE CApiFFI #-}
{-# LANGUAGE InterruptibleFFI, RankNTypes #-}
-#ifdef __GLASGOW_HASKELL__
{-# LANGUAGE Trustworthy #-}
-#endif
+
-----------------------------------------------------------------------------
-- |
-- Module : System.Posix.Process.Common
@@ -22,10 +21,8 @@ module System.Posix.Process.Common (
-- * Processes
-- ** Forking and executing
-#ifdef __GLASGOW_HASKELL__
forkProcess,
forkProcessWithUnmask,
-#endif
-- ** Exiting
exitImmediately,
@@ -82,11 +79,9 @@ import System.Posix.Process.Internals
import System.Posix.Types
import Control.Monad
-#ifdef __GLASGOW_HASKELL__
import Control.Exception.Base ( bracket, getMaskingState, MaskingState(..) ) -- used by forkProcess
import GHC.TopHandler ( runIO )
import GHC.IO ( unsafeUnmask, uninterruptibleMask_ )
-#endif
-- -----------------------------------------------------------------------------
-- Process environment
@@ -271,7 +266,6 @@ foreign import ccall unsafe "setpriority"
-- -----------------------------------------------------------------------------
-- Forking, execution
-#ifdef __GLASGOW_HASKELL__
{- | 'forkProcess' corresponds to the POSIX @fork@ system call.
The 'IO' action passed as an argument is executed in the child process; no other
threads will be copied to the child process.
@@ -311,8 +305,6 @@ foreign import ccall "forkProcess" forkProcessPrim :: StablePtr (IO ()) -> IO CP
forkProcessWithUnmask :: ((forall a . IO a -> IO a) -> IO ()) -> IO ProcessID
forkProcessWithUnmask action = forkProcess (action unsafeUnmask)
-#endif /* __GLASGOW_HASKELL__ */
-
-- -----------------------------------------------------------------------------
-- Waiting for process termination
diff --git a/System/Posix/Process/Internals.hs b/System/Posix/Process/Internals.hs
index 970bc9f..fd0e68d 100644
--- a/System/Posix/Process/Internals.hs
+++ b/System/Posix/Process/Internals.hs
@@ -1,8 +1,6 @@
{-# LANGUAGE CApiFFI #-}
{-# LANGUAGE CPP #-}
-#ifdef __GLASGOW_HASKELL__
{-# LANGUAGE Trustworthy #-}
-#endif
module System.Posix.Process.Internals (
pPrPr_disableITimers, c_execvpe,