@@ -11,6 +11,7 @@ where
12import Ormolu.Printer.Combinators
12import Ormolu.Printer.Combinators
13import Ormolu.Printer.Meat.Declaration.Data
13import Ormolu.Printer.Meat.Declaration.Data
14+import Ormolu.Printer.Meat.Declaration.Instance
14import Ormolu.Printer.Meat.Declaration.Signature
15import Ormolu.Printer.Meat.Declaration.Signature
15import Ormolu.Printer.Meat.Declaration.Type
16import Ormolu.Printer.Meat.Declaration.Type
16import Ormolu.Printer.Meat.Declaration.TypeFamily
17import Ormolu.Printer.Meat.Declaration.TypeFamily
@@ -22,6 +23,7 @@ p_hsDecl = \case
22 TyClD NoExt x -> p_tyClDecl x
23 TyClD NoExt x -> p_tyClDecl x
23 ValD NoExt x -> p_valDecl x
24 ValD NoExt x -> p_valDecl x
24 SigD NoExt x -> p_sigDecl x
25 SigD NoExt x -> p_sigDecl x
26+ InstD NoExt x -> p_instDecl x
25 _ -> notImplemented "certain kinds of declarations"
27 _ -> notImplemented "certain kinds of declarations"
27p_tyClDecl :: TyClDecl GhcPs -> R ()
29p_tyClDecl :: TyClDecl GhcPs -> R ()
@@ -30,3 +32,9 @@ p_tyClDecl = \case
30 SynDecl {..} -> p_synDecl tcdLName tcdTyVars tcdRhs
32 SynDecl {..} -> p_synDecl tcdLName tcdTyVars tcdRhs
31 DataDecl {..} -> p_dataDecl tcdLName tcdTyVars tcdDataDefn
33 DataDecl {..} -> p_dataDecl tcdLName tcdTyVars tcdDataDefn
32 _ -> notImplemented "certain kinds of declarations"
34 _ -> notImplemented "certain kinds of declarations"
36+p_instDecl :: InstDecl GhcPs -> R ()
38+ ClsInstD NoExt x -> p_clsInstDecl x
39+ TyFamInstD NoExt x -> p_tyFamInstDecl Free x
40+ _ -> notImplemented "certain kinds of declarations"