Closed cclauss closed 2 years ago
Interesting, I didn't know about this syntax!
At least in this specific case, where the suffixes are a single character, I find the code with multiple strings kind of confusing. I would expect it to be trying to match a list-of-tuples and matching if the last element of the list was the given tuple. Or, it could also be misinterpreted as being the same as raw.endswith(":!?")
or something.
So, I would lean towards not merging this. But maybe I am just old-fashioned? I do really appreciate your taking the time to look over the code base and do cleanups. I'm tempted to just merge-by-default.
https://docs.python.org/3/library/stdtypes.html#str.endswith