summaryrefslogtreecommitdiff
path: root/Annex
diff options
context:
space:
mode:
authorGravatar Joey Hess <joey@kitenet.net>2013-05-19 12:43:44 -0400
committerGravatar Joey Hess <joey@kitenet.net>2013-05-19 12:43:44 -0400
commitf33acb1b95f1afd896b5ee00f99c178ac2ef770f (patch)
tree57f273d9d291710938a90ae716d72cbab0ead87f /Annex
parent31faff565f6f1d804bd56d5bde380c48467541c8 (diff)
warning
Diffstat (limited to 'Annex')
-rw-r--r--Annex/Exception.hs6
1 files changed, 5 insertions, 1 deletions
diff --git a/Annex/Exception.hs b/Annex/Exception.hs
index 4d21297b1..de6a23611 100644
--- a/Annex/Exception.hs
+++ b/Annex/Exception.hs
@@ -18,7 +18,11 @@ import Control.Exception hiding (handle, try, throw)
import Common.Annex
-{- Runs an Annex action, with setup and cleanup both in the IO monad. -}
+{- Runs an Annex action, with setup and cleanup both in the IO monad.
+ -
+ - Warning: Currently if the Annex action fails, any changes it has made
+ - to Annex state are discarded.
+ -}
bracketIO :: IO c -> (c -> IO b) -> Annex a -> Annex a
bracketIO setup cleanup go =
liftBaseOp (Control.Exception.bracket setup cleanup) (const go)