in reply to /s option modifier in regex substitution

Beside the token that marks the start of what you want to delete, you're using no more than two characters, which together form one of the most used regexp idioms, and an often used modifier. All together, you have a trivial regexp, easy to understand, no backtracking required, and one that the optimizer can deal with.

Why do you think there might be a nicer way?

  • Comment on Re: /s option modifier in regex substitution