Page 1 of 1

unstable regex as replace all freezes textpad

Posted: Wed Nov 30, 2005 6:45 am
by ilovetextpad
there are certain regular expressions that match zero width ,
like a pipe '|' at the beginning/end of a statement, or two with nothing between.

if an expression like this is used in the replace dialog, and the replace all function is used, textpad freezes in a busy loop (because the expression continuously matches without seeking forward in the string)

example:
start textpad,
type a character,
search->replace
find what: |
replace with: doesnt matter
regex enabled
replace all

textpad is frozen.

maybe a check for a zero width expression could be introduced in the next version.

Posted: Wed Nov 30, 2005 9:22 am
by ben_josephs
There was a discussion about this at http://www.textpad.info/forum/viewtopic.php?t=6395.