packages feed

tilia-0.1.0.0: corpora/vendored/other/cpp/imports-written-in-different-branches.hs

{-# LANGUAGE CPP #-}

module Terminal.Errors (isUnsupported) where

import Control.Exception (IOException)
#ifndef __MHS__
import           GHC.IO.Exception
#else
import           System.IO.Error
#endif
  ( ioe_type, IOErrorType(..) )
import Data.Bool (bool)

isUnsupported :: IOError -> Bool
isUnsupported e  =  ioe_type e == UnsupportedOperation