6 ms·
Consider a scenario where you're editing a function: function foo() { return a*2.1^2+0.52/2 } So you do a find-all regex "1.*5" and delete all matching occu
by jayyhu 2y ago
Consider a scenario where you're editing a function:
function foo() { return a*2.1^2+0.52/2 }
So you do a find-all regex "1.*5" and delete all matching occurrences (à la CRISPER) to get:
function foo() { return a*2.2/2 }
But unbeknownst to you, the code is littered with a bunch of commented out versions of the same function you're trying to edit:
/* function foo() { return a*1.5/2.1 } */
/* function foo() { return a*1.95/2.4 } */
And now those commented out versions now become:
/* function foo() { return a*/2.1 } */
/* function foo() { return a*/2.4 } */
And now the whole program doesn't compile anymore--or your patients get Leukemia. Oops.
- kps 2y agoYou can't parse DNA with regex¹. ¹ https://stackoverflow.com/questions/1732348/regex-match-open-tags-except-xhtml-self-contained-tags https://stackoverflow.com/questions/1732348/regex-match-open...
- deleted 2y ago[deleted]
- abc_lisper 2y agoExcellent point. But it works for bacteria I guess, because viral dna is small.
- duskwuff 2y agoAnd when it doesn't work... well, bacteria die all the time. Humans are less tolerant of random death.
- Kailhus 2y agoSo good, thanks for resurfacing this one!