Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUG] Individual replacements don't work with regex lookbehind #2216

Closed
aaaxx opened this issue Aug 27, 2016 · 2 comments
Closed

[BUG] Individual replacements don't work with regex lookbehind #2216

aaaxx opened this issue Aug 27, 2016 · 2 comments

Comments

@aaaxx
Copy link

aaaxx commented Aug 27, 2016

Description of the Issue

If there's a lookbehind in the search string, clicking the "Replace" button will skip to the next match without replacing anything. (Using "Replace All", however, works fine and replaces all matches.)

Steps to Reproduce the Issue

Try searching for something like (?<=a). and replacing it with something by clicking the "Replace" button.

Debug Information

Notepad++ v6.9.2
Build time : May 18 2016 - 00:34:05
Path : D:_D - apps\Notepad++ Portable\App\Notepad++\notepad++.exe
Admin mode : OFF
Local Conf mode : ON
OS : Windows 8.1
Plugins : combine.dll ComparePlugin.dll DSpellCheck.dll ElasticTabstops.dll IndentByFold.dll mimeTools.dll NppConverter.dll NppExport.dll NppFTP.dll NppTextFX.dll PluginManager.dll ScrollPastEOFUni.dll SnippetPlus.dll

@MetaChuh
Copy link

please update your notepad++ to the latest version Notepad++ 7.6.6 and migrate or reinstall your plugins if you update from version 7.5.9 or below.
if your issue still persists, and it is still of relevance to you, please feel free to file a new issue as easy to understand and reproducible as possible.

thank you for your help and best regards.


general notes:

please close your issues as soon as you are satisfied, to help
keeping the notepad++ issue tracker clean.

when creating a new issue, please provide all information as shown at the issue template.
your notepad++ debug info is part of the minimum requirements.
(? > Debug Info... > Copy debug info into clipboard).

please also conduct a search at the issue tracker beforehand, to check if a similar issue
already exists.

for general questions, or if it is not sure, whether your issue is directly related to
the notepad++ source code, please visit us at the notepad++ community forum, and
search if related topics exists. you are welcome to post either at similar
topics, or to create a new topic at Help Wanted or General Discussion.
(no extra account is needed, just use your github account to sign in)

                        Click here to visit the Notepad++ Community Forum                         

@sasumner
Copy link
Contributor

Lookbehind can't reasonably work when finding matches one at a time. Replace All is the best strategy here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants