bindist comparison tool: Improve way-difference behaviour
authorIan Lynagh <igloo@earth.li>
Wed, 16 Mar 2011 22:13:38 +0000 (22:13 +0000)
committerIan Lynagh <igloo@earth.li>
Wed, 16 Mar 2011 22:13:38 +0000 (22:13 +0000)
distrib/compare/compare.hs

index 14e83b6..7d52609 100644 (file)
@@ -198,6 +198,8 @@ findFileWay :: FilePath -> Maybe String
 findFileWay fp
  | Just [way] <- re "\\.([a-z_]+)_hi$" fp
     = Just way
+ | Just [_, _, way] <- re ("libHS.*-" ++ versionRE ++ "_([a-z_]+).a$") fp
+    = Just way
  | otherwise = Nothing
 
 compareTarLine :: TarLine -> TarLine -> [Problem]