refactor: better names for TrapInfo^WTrapCause
[mate.git] / Mate / X86TrapHandling.hs
index f383c2d3635afdec98079b70931d7101cf929374..882a541f1eefb7b5fe89eed22285d7a2d4cf524e 100644 (file)
@@ -21,15 +21,15 @@ getTrapType :: CUInt -> CUInt -> IO CUInt
 getTrapType signal_from from2 = do
   tmap <- getTrapMap
   case M.lookup (fromIntegral signal_from) tmap of
-    (Just (MI _)) -> return 0
-    (Just (SFI _)) -> return 2
+    (Just (StaticMethod _)) -> return 0
+    (Just (StaticField _)) -> return 2
     (Just _) -> error "getTrapMap: doesn't happen"
     -- maybe we've a hit on the second `from' value
     Nothing -> case M.lookup (fromIntegral from2) tmap of
-      (Just (VI True _)) -> return 1
-      (Just (VI False _)) -> return 5
-      (Just (II True _)) -> return 4
-      (Just (II False _)) -> return 8
+      (Just (VirtualMethod True _)) -> return 1
+      (Just (VirtualMethod False _)) -> return 5
+      (Just (InterfaceMethod True _)) -> return 4
+      (Just (InterfaceMethod False _)) -> return 8
       (Just _) -> error "getTrapType: abort #1 :-("
       Nothing -> error $ "getTrapType: abort #2 :-(" ++ show signal_from ++ ", " ++ show from2 ++ ", " ++ show tmap