Oct. 13, 2021
9:10 p.m.
13.10.21 22:03, Marc-Andre Lemburg пише:
Some examples: - removal of file extensions - removal of end tags - removal of units - removal of currencies - removal of standard suffixes - removal of wildcard patterns etc.
I find lots of such uses in the code bases I work with.
I did not have opportunity to use removesuffix yet. The problem is that almost always when I need to remove a suffix or prefix, I need to know whether it was removed or no. removesuffix does not help, it does not even make the code shorter. And I need to support versions older than 3.9.