File tree 2 files changed +2
-3
lines changed
cabal-install/Distribution/Client/Dependency/Modular 2 files changed +2
-3
lines changed Original file line number Diff line number Diff line change @@ -512,7 +512,7 @@ lgMerge blame lg lg' = do
512
512
)
513
513
514
514
varsToConflictSet :: Set (Var QPN ) -> ConflictSet QPN
515
- varsToConflictSet = M. fromSet ( const ConflictAll )
515
+ varsToConflictSet = S. foldr ( \ var -> M. insert var ConflictAll ) M. empty
516
516
517
517
lgConflictSet :: LinkGroup -> Set (Var QPN )
518
518
lgConflictSet lg = S. fromList (map aux (S. toList (lgMembers lg)) ++ lgBlame lg)
Original file line number Diff line number Diff line change @@ -9,7 +9,6 @@ import qualified Data.Traversable as T
9
9
#if !MIN_VERSION_base(4,8,0)
10
10
import Control.Applicative
11
11
#endif
12
- import qualified Data.Set as S
13
12
import Prelude
14
13
import Control.Monad.Reader
15
14
import Data.Ord
@@ -443,5 +442,5 @@ enforceSingleInstanceRestriction = (`runReader` M.empty) . cata go
443
442
local (M. insert inst qpn) r
444
443
(Nothing , Just qpn') -> do
445
444
-- Not linked, already used. This is an error
446
- let cs = M. fromSet ( const ConflictAll ) ( S. fromList [P qpn, P qpn'])
445
+ let cs = M. fromList [(var, ConflictAll ) | var <- [P qpn, P qpn']]
447
446
return $ Fail cs MultipleInstances
You can’t perform that action at this time.
0 commit comments