From cc915f9d775ad37eaab77e68ab570c58ee87dbf6 Mon Sep 17 00:00:00 2001 From: Simon Marlow Date: Tue, 5 Feb 2008 09:04:29 +0000 Subject: [PATCH] matchesPkg: match against the pkg Id (foo-1.0) not just the package name (foo) Fixes the ghcpkg01 test. --- utils/ghc-pkg/Main.hs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/utils/ghc-pkg/Main.hs b/utils/ghc-pkg/Main.hs index 936b309..866c9fe 100644 --- a/utils/ghc-pkg/Main.hs +++ b/utils/ghc-pkg/Main.hs @@ -624,7 +624,7 @@ pid `matches` pid' matchesPkg :: PackageArg -> InstalledPackageInfo -> Bool (Id pid) `matchesPkg` pkg = pid `matches` package pkg -(Substring _ m) `matchesPkg` pkg = m (pkgName (package pkg)) +(Substring _ m) `matchesPkg` pkg = m (showPackageId (package pkg)) compPkgIdVer :: PackageIdentifier -> PackageIdentifier -> Ordering compPkgIdVer p1 p2 = pkgVersion p1 `compare` pkgVersion p2 -- 1.7.10.4