 import Control.Monad (liftM2, when, (>=>), (<=<))
 import Control.Monad.Catch (MonadThrow, throwM)
 import Control.Monad.Trans (lift)
+import Control.Monad.Trans.Resource (unprotect)
 import Control.Monad.IO.Class (MonadIO(liftIO))
 
 import Data.Bits ((.&.), (.|.))

                                (GDALBindingException NullDataset) exc)
      | otherwise       = Nothing
    free = {#call GDALClose as ^#}

createMem
  :: Size -> Int -> DataType d -> OptionList

  , datasetGCPs
  , setDatasetGCPs
  , datasetBandCount
  , unsafeFromHandle
  , adoptHandle

  , bandDataType
  , bandProjection
