@@ -99,14 +99,14 @@ getModuleEdit recorder env cabalFilePath stanza targetFieldStr modulePath =
9999 cabalFilePath
100100 mkConfig
101101 where
102- mkConfig :: (ByteString -> [Field Position ] -> GenericPackageDescription -> ExceptT PluginError m Config )
102+ mkConfig :: (ByteString -> [Field Position ] -> GenericPackageDescription -> ExceptT PluginError m AddConfig )
103103 mkConfig cnfOrigContents fields packDescr = do
104104 let compName =
105105 case Add. resolveComponent cabalFilePath (fields, packDescr) $ Just $ CabalPretty. prettyShow stanza of
106106 Right x -> x
107107 Left _ -> error " "
108108 pure $
109- Config
109+ AddConfig
110110 { cnfOrigContents = cnfOrigContents
111111 , cnfFields = fields
112112 , cnfComponent = compName
@@ -149,7 +149,7 @@ getDependencyEdit ::
149149getDependencyEdit recorder env cabalFilePath buildTarget dependency =
150150 mkCabalAddConfig recorder env cabalFilePath mkConfig
151151 where
152- mkConfig :: (ByteString -> [Field Position ] -> GenericPackageDescription -> ExceptT PluginError m Config )
152+ mkConfig :: (ByteString -> [Field Position ] -> GenericPackageDescription -> ExceptT PluginError m AddConfig )
153153 mkConfig cnfOrigContents fields packDescr = do
154154 let specVer = specVersion $ packageDescription packDescr
155155 (deps, compName) <-
@@ -158,7 +158,7 @@ getDependencyEdit recorder env cabalFilePath buildTarget dependency =
158158 compName <- resolveComponent cabalFilePath (fields, packDescr) buildTarget
159159 pure (deps, compName)
160160 pure $
161- Config
161+ AddConfig
162162 { cnfOrigContents = cnfOrigContents
163163 , cnfFields = fields
164164 , cnfComponent = compName
@@ -180,7 +180,7 @@ mkCabalAddConfig ::
180180 ( ByteString ->
181181 [Field Position ] ->
182182 GenericPackageDescription ->
183- ExceptT PluginError m Config
183+ ExceptT PluginError m AddConfig
184184 ) ->
185185 ExceptT PluginError m WorkspaceEdit
186186mkCabalAddConfig recorder env cabalFilePath mkConfig = do
@@ -211,7 +211,7 @@ mkCabalAddConfig recorder env cabalFilePath mkConfig = do
211211
212212 cabalAddConfig <- mkConfig cnfOrigContents fields packDescr
213213
214- case executeConfig (validateChanges packDescr) cabalAddConfig of
214+ case executeAddConfig (validateChanges packDescr) cabalAddConfig of
215215 Nothing ->
216216 throwE $
217217 PluginInternalError $
0 commit comments