logoalt Hacker News

chr15mtoday at 12:02 AM2 repliesview on HN

Good point. The number of times is zero. Probably something that should be implemented defensively at the library level. I guess most developers don't realise this can happen (I did not).


Replies

simonreifftoday at 2:23 AM

I actually did add a timer as a final "if all else fails" for my regex implementation rather recently, maybe 6 months ago. I don't even know of any scenario that could reach the timer because I have a robust allowlist/denylist and a ton of unit tests. But I would rather just be certain and it wasn't hard.

inigyoutoday at 12:39 AM

No you don't actually want a regex library that randomly fails when someone runs one of Chris Domas's pathological stall instructions on a different core.

show 2 replies