Skip to content

Comment on Let Regexes Write Your Code For Youparent

Comments

This. I don't mind writing this code from a mechanical perspective (copy, paste, and a few single-token replacements per line) nearly as much as I mind reading, debugging, and being forced to rewrite this kind of nauseatingly boilerplate code.

Ironically, my most recent use of regexps has been finding such boilerplate and simplifying it by using newer, cleaner APIs so I can remove the old terrible ones. Let Regexes Delete that code for you.

AboutSource Built by g1lg1l

Hackerly is an independent reader for Hacker News, built on the public HN API. Not affiliated with Y Combinator.