[Pkg-haskell-commits] [SCM] haskell-testpack branch, master, updated. debian/1.0.2-1-4-gb0d6b36

John Goerzen jgoerzen at complete.org
Fri Apr 23 14:52:22 UTC 2010


The following commit has been merged in the master branch:
commit 6639cec7fe22d0f78a3fbcb22ebf876a6c7c5046
Author: John Goerzen <jgoerzen at complete.org>
Date:   Tue Dec 21 05:38:42 2004 +0100

    Checkpointing (compiles)
    
    Keywords:
    
    
    (jgoerzen at complete.org--projects/missingh--head--0.7--patch-116)

diff --git a/ChangeLog b/ChangeLog
index 1b82cd2..9510641 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -2,6 +2,18 @@
 # arch-tag: automatic-ChangeLog--jgoerzen at complete.org--projects/missingh--head--0.7
 #
 
+2004-12-20 22:38:42 GMT	John Goerzen <jgoerzen at complete.org>	patch-116
+
+    Summary:
+      Checkpointing (compiles)
+    Revision:
+      missingh--head--0.7--patch-116
+
+
+    modified files:
+     ChangeLog libsrc/MissingH/IO/HVFS/InstanceHelpers.hs
+
+
 2004-12-20 22:34:42 GMT	John Goerzen <jgoerzen at complete.org>	patch-115
 
     Summary:
diff --git a/libsrc/MissingH/IO/HVFS/InstanceHelpers.hs b/libsrc/MissingH/IO/HVFS/InstanceHelpers.hs
index 4ea50cb..8e79cfa 100644
--- a/libsrc/MissingH/IO/HVFS/InstanceHelpers.hs
+++ b/libsrc/MissingH/IO/HVFS/InstanceHelpers.hs
@@ -116,7 +116,7 @@ findMelem x path =
         in do
            c <- readIORef $ content x
            case walk (MemoryDirectory c) (sliced2) of
-              Left err -> fail err
+              Left err -> vRaiseError x doesNotExistErrorType err Nothing
               Right result -> return result
 
 -- | Find an element on the tree, normalizing the path first
@@ -124,7 +124,8 @@ getMelem :: MemoryVFS -> String -> IO MemoryEntry
 getMelem x s = 
     do base <- readIORef $ cwd x
        case absNormPath base s of
-           Nothing -> fail $ "Trouble normalizing path " ++ s
+           Nothing -> vRaiseError x doesNotExistErrorType
+                        ("Trouble normalizing path " ++ s) (Just s)
            Just newpath -> findMelem x newpath
 
 instance HVFS MemoryVFS where
@@ -134,10 +135,14 @@ instance HVFS MemoryVFS where
            -- Make sure new dir is valid
            newdir <- getMelem x fp
            case newdir of 
-               (MemoryFile _) -> fail $ "Attempt to cwd to non-directory " ++ fp
+               (MemoryFile _) -> vRaiseError x doesNotExistErrorType 
+                                 ("Attempt to cwd to non-directory " ++ fp)
+                                 (Just fp)
                (MemoryDirectory _) -> 
                    case absNormPath curpath fp of
-                       Nothing -> fail $ "Bad internal error"
+                       Nothing -> -- should never happen due to above getMelem call
+                                  vRaiseError x illegalOperationErrorType
+                                              "Bad internal error" (Just fp)
                        Just y -> writeIORef (cwd x) y
     vGetFileStatus x fp = 
         do elem <- getMelem x fp

-- 
haskell-testpack



More information about the Pkg-haskell-commits mailing list