This is an archive of the discontinued Mercurial Phabricator instance.

rust: Generalize the `trim_end_newlines` utility of byte strings
ClosedPublic

Authored by SimonSapin on Sep 3 2021, 10:38 AM.

Details

Summary

… into trim_end_matches that takes a callack.

Also add trim_start_matches.

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.