@@ -241,17 +241,17 @@ data IsOrVs = Is [POption] | Vs [Ver] deriving Show
241
241
-- instances if any of the options is linked (installed). Singleton lists or
242
242
-- empty lists are always converted to Is.
243
243
-- >>> tryVs [v0, v1]
244
- -- Vs [mkVersion [1,0,0 ],mkVersion [1,0, 1]]
244
+ -- Vs [mkVersion [0 ],mkVersion [1]]
245
245
-- >>> tryVs [v0]
246
- -- Is [POption (I (mkVersion [1,0, 0]) InRepo) Nothing]
246
+ -- Is [POption (I (mkVersion [0]) InRepo) Nothing]
247
247
-- >>> tryVs [i0, i1]
248
- -- Is [POption (I (mkVersion [1,0,0 ]) (Inst (UnitId "foo-1.0.0 -inplace"))) Nothing,POption (I (mkVersion [1,0,1 ]) (Inst (UnitId "foo-1.0. 1-inplace"))) Nothing]
248
+ -- Is [POption (I (mkVersion [0 ]) (Inst (UnitId "foo-0 -inplace"))) Nothing,POption (I (mkVersion [1]) (Inst (UnitId "foo-1-inplace"))) Nothing]
249
249
-- >>> tryVs [i0, v1]
250
- -- Is [POption (I (mkVersion [1,0,0 ]) (Inst (UnitId "foo-1.0.0 -inplace"))) Nothing,POption (I (mkVersion [1,0, 1]) InRepo) Nothing]
250
+ -- Is [POption (I (mkVersion [0 ]) (Inst (UnitId "foo-0 -inplace"))) Nothing,POption (I (mkVersion [1]) InRepo) Nothing]
251
251
-- >>> tryVs [v0, i1]
252
- -- Is [POption (I (mkVersion [1,0,0 ]) InRepo) Nothing,POption (I (mkVersion [1,0,1 ]) (Inst (UnitId "foo-1.0. 1-inplace"))) Nothing]
252
+ -- Is [POption (I (mkVersion [0 ]) InRepo) Nothing,POption (I (mkVersion [1]) (Inst (UnitId "foo-1-inplace"))) Nothing]
253
253
-- >>> tryVs [i0]
254
- -- Is [POption (I (mkVersion [1,0,0 ]) (Inst (UnitId "foo-1.0. 0-inplace"))) Nothing]
254
+ -- Is [POption (I (mkVersion [0 ]) (Inst (UnitId "foo-0-inplace"))) Nothing]
255
255
-- >>> tryVs []
256
256
-- Is []
257
257
tryVs :: [POption ] -> IsOrVs
@@ -266,15 +266,15 @@ tryVs xs
266
266
-- | Shows a list of versions in a human-friendly way, abbreviated. Shows a list
267
267
-- of instances in full.
268
268
-- >>> showIsOrVs fooQPN $ tryVs [v0, v1]
269
- -- "foo; 1.0.1, 1.0. 0"
269
+ -- "foo; 1, 0"
270
270
-- >>> showIsOrVs fooQPN $ tryVs [v0]
271
- -- "foo-1.0. 0"
271
+ -- "foo-0"
272
272
-- >>> showIsOrVs fooQPN $ tryVs [i0, i1]
273
- -- "foo-1.0.1 /installed-inplace, foo-1.0. 0/installed-inplace"
273
+ -- "foo-1/installed-inplace, foo-0/installed-inplace"
274
274
-- >>> showIsOrVs fooQPN $ tryVs [i0, v1]
275
- -- "foo-1.0.1 , foo-1.0. 0/installed-inplace"
275
+ -- "foo-1, foo-0/installed-inplace"
276
276
-- >>> showIsOrVs fooQPN $ tryVs [v0, i1]
277
- -- "foo-1.0.1 /installed-inplace, foo-1.0. 0"
277
+ -- "foo-1/installed-inplace, foo-0"
278
278
-- >>> showIsOrVs fooQPN $ tryVs []
279
279
-- "unexpected empty list of versions"
280
280
showIsOrVs :: QPN -> IsOrVs -> String
@@ -347,7 +347,7 @@ showConflictingDep (ConflictingDep dr (PkgComponent qpn comp) ci) =
347
347
-- >>> import Distribution.Types.Version
348
348
-- >>> import Distribution.Types.UnitId
349
349
-- >>> let fooQPN = Q (PackagePath DefaultNamespace QualToplevel) (mkPackageName "foo")
350
- -- >>> let v0 = POption (I (mkVersion [1,0, 0]) InRepo) Nothing
351
- -- >>> let v1 = POption (I (mkVersion [1,0,1 ]) InRepo) Nothing
352
- -- >>> let i0 = POption (I (mkVersion [1,0,0 ]) (Inst $ mkUnitId "foo-1.0. 0-inplace")) Nothing
353
- -- >>> let i1 = POption (I (mkVersion [1,0,1 ]) (Inst $ mkUnitId "foo-1.0. 1-inplace")) Nothing
350
+ -- >>> let v0 = POption (I (mkVersion [0]) InRepo) Nothing
351
+ -- >>> let v1 = POption (I (mkVersion [1]) InRepo) Nothing
352
+ -- >>> let i0 = POption (I (mkVersion [0 ]) (Inst $ mkUnitId "foo-0-inplace")) Nothing
353
+ -- >>> let i1 = POption (I (mkVersion [1]) (Inst $ mkUnitId "foo-1-inplace")) Nothing
0 commit comments