diff options
author | Joey Hess <joeyh@joeyh.name> | 2015-04-01 23:14:59 -0400 |
---|---|---|
committer | Joey Hess <joeyh@joeyh.name> | 2015-04-01 23:14:59 -0400 |
commit | e7549aac67bfb89f3f7e229e11c30ae02f1cdf10 (patch) | |
tree | a11abfa9e9f17cb04f6f4025e48efb4c135099bf /Utility/Path.hs | |
parent | 14df22fa31b43441232e18ec9112d7c2ce2e0905 (diff) |
micro-opt
Diffstat (limited to 'Utility/Path.hs')
-rw-r--r-- | Utility/Path.hs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Utility/Path.hs b/Utility/Path.hs index 6ecec2c5f..755436448 100644 --- a/Utility/Path.hs +++ b/Utility/Path.hs @@ -178,7 +178,7 @@ prop_relPathDirToFile_regressionTest = same_dir_shortcurcuits_at_difference segmentPaths :: [FilePath] -> [FilePath] -> [[FilePath]] segmentPaths [] new = [new] segmentPaths [_] new = [new] -- optimisation -segmentPaths (l:ls) new = [found] ++ segmentPaths ls rest +segmentPaths (l:ls) new = found : segmentPaths ls rest where (found, rest)=partition (l `dirContains`) new |