[Git][ghc/ghc][wip/T24978] Wibbles

Simon Peyton Jones (@simonpj) gitlab at gitlab.haskell.org
Tue Jun 11 20:35:04 UTC 2024



Simon Peyton Jones pushed to branch wip/T24978 at Glasgow Haskell Compiler / GHC


Commits:
777c1ad6 by Simon Peyton Jones at 2024-06-11T21:34:37+01:00
Wibbles

- - - - -


3 changed files:

- compiler/GHC/Core/TyCo/Rep.hs
- compiler/GHC/Iface/Type.hs
- compiler/GHC/Types/Var.hs


Changes:

=====================================
compiler/GHC/Core/TyCo/Rep.hs
=====================================
@@ -990,6 +990,22 @@ instance Outputable FunSel where
   ppr SelArg  = text "arg"
   ppr SelRes  = text "res"
 
+instance Binary UnivCoProvenance where
+  put_ bh PhantomProv         = putByte bh 1
+  put_ bh ProofIrrelProv = putByte bh 2
+  put_ bh (PluginProv a) = do { putByte bh 3
+                              ; put_ bh a }
+
+  get bh = do
+      tag <- getByte bh
+      case tag of
+           1 -> return PhantomProv
+           2 -> return ProofIrrelProv
+           3 -> do a <- get bh
+                   return $ PluginProv a
+           _ -> panic ("get UnivCoProvenance " ++ show tag)
+
+
 instance Binary CoSel where
    put_ bh (SelTyCon n r)   = do { putByte bh 0; put_ bh n; put_ bh r }
    put_ bh SelForAll        = putByte bh 1


=====================================
compiler/GHC/Iface/Type.hs
=====================================
@@ -2477,22 +2477,6 @@ instance Binary IfaceCoercion where
                    return $ IfaceAxiomRuleCo a b
            _ -> panic ("get IfaceCoercion " ++ show tag)
 
-instance Binary UnivCoProvenance where
-  put_ bh PhantomProv         = putByte bh 1
-  put_ bh ProofIrrelProv = putByte bh 2
-  put_ bh (PluginProv a) = do { putByte bh 3
-                              ; put_ bh a }
-
-  get bh = do
-      tag <- getByte bh
-      case tag of
-           1 -> return PhantomProv
-           2 -> return ProofIrrelProv
-           3 -> do a <- get bh
-                   return $ PluginProv a
-           _ -> panic ("get IfaceUnivCoProv " ++ show tag)
-
-
 instance Binary (DefMethSpec IfaceType) where
     put_ bh VanillaDM     = putByte bh 0
     put_ bh (GenericDM t) = putByte bh 1 >> put_ bh t


=====================================
compiler/GHC/Types/Var.hs
=====================================
@@ -377,7 +377,7 @@ instance NamedThing Var where
 
 instance NFData Var where
   rnf v = v `seq` ()
-  
+
 instance Uniquable Var where
   getUnique = varUnique
 



View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/commit/777c1ad62f6aa3d1738644d23ea8fa67993603d2

-- 
View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/commit/777c1ad62f6aa3d1738644d23ea8fa67993603d2
You're receiving this email because of your account on gitlab.haskell.org.


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.haskell.org/pipermail/ghc-commits/attachments/20240611/db1d939b/attachment-0001.html>


More information about the ghc-commits mailing list