This is an archive of the discontinued Mercurial Phabricator instance.

templatefilters: rename commonprefix to commondir
ClosedPublic

Authored by martinvonz on Jun 13 2018, 6:06 PM.

Details

Summary

Two reasons:

  • It makes it clearer that it's not a generic common string prefix (e.g. commonprefix(["bar", "baz"]) is not "ba", but "")
  • If we ever want a filter for generic common string prefix, then the name is now available for that.

"commondir" does not describe the prefix-ness, however. I'm happy to
rename it "commondirprefix" or "commonprefixdir" if others prefer.

Diff Detail

Repository
rHG Mercurial
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

martinvonz created this revision.Jun 13 2018, 6:06 PM
This revision was automatically updated to reflect the committed changes.