On Sun, Jun 06, 2010 at 17:02:26 +0100, Eric Kow wrote: > > Sun Jun 6 16:21:25 CEST 2010 Petr Rockai <[email protected]> > > +renameChanged from to = modify $ \st -> st { changed = rename' $ changed > > st } > > + where rename' = S.fromList . map renameone . S.toList
There's S.map if you're interested. > > + renameone x | from `isPrefix` x = to `catPaths` relative from x > > + | otherwise = x > > + relative (AnchoredPath from) (AnchoredPath x) = AnchoredPath $ > > drop (length from) x > Do we have to worry about things like initial/trailing slashes in from > and x? Also, will this do the right thing if from is something like "foo" and x is something like "foobar"? -- Eric Kow <http://www.nltg.brighton.ac.uk/home/Eric.Kow> PGP Key ID: 08AC04F9
pgpylXNYqEkUe.pgp
Description: PGP signature
_______________________________________________ darcs-users mailing list [email protected] http://lists.osuosl.org/mailman/listinfo/darcs-users
