| Summary: | Replace in "Search and Replace" does not work when the search regex contains lookahead or lookbehind part | ||
|---|---|---|---|
| Product: | [Applications] kate | Reporter: | Atanas Uzunov <atanasuzunov> |
| Component: | part | Assignee: | KWrite Developers <kwrite-bugs-null> |
| Status: | RESOLVED FIXED | ||
| Severity: | major | CC: | kare.sars |
| Priority: | NOR | ||
| Version First Reported In: | 21.12.0 | ||
| Target Milestone: | --- | ||
| Platform: | unspecified | ||
| OS: | All | ||
| Latest Commit: | https://invent.kde.org/utilities/kate/commit/cb759994beb24b119492e588147be1916390d017 | Version Fixed/Implemented In: | 22.04 |
| Sentry Crash Report: | |||
|
Description
Atanas Uzunov
2022-02-03 08:40:56 UTC
I can confirm this bug. A possibly relevant merge request was started @ https://invent.kde.org/utilities/kate/-/merge_requests/587 Git commit cb759994beb24b119492e588147be1916390d017 by Kåre Särs. Committed on 09/02/2022 at 20:14. Pushed by sars into branch 'master'. S&R: Fix Look-ahead & behind highlighting & replace Strip the look-ahead and look-behind from the regular-expression that checks if a string has been modified after search and returns the possible captures. We strip the look-ahead/behind because we only match against the previously found range. M +27 -1 addons/search/MatchModel.cpp M +6 -0 addons/search/MatchModel.h A +48 -0 addons/search/autotest/input/LookaheadLookbehindTestFile.txt A +22 -0 addons/search/autotest/input/MultilineStartEndOfLineMatch.txt M +2 -9 addons/search/plugin_search.cpp https://invent.kde.org/utilities/kate/commit/cb759994beb24b119492e588147be1916390d017 |