You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Match whole word doesn't work in search for non-latin characters #27280
feature-requestRequest for new features or functionalityhelp wantedIssues identified as good community contribution opportunitiesinfo-neededIssue requires more information from postersearchSearch widget and operation issuessearch-api
Got the same problem. Searching for whole words does not work when word contains Swedish characters.
It should not had a hit on 'rs' in the word 'körs'.
Wouldn't it be better to use the same (?:^|\W)(?:<your pattern>)(?:$|\W) pattern?
Now that there's unicode support in vscode, it's possible to implement \W (unicode aware) which is defined as [^\p{Alphabetic}\p{M}\p{Nd}\p{Pc}\p{Join_Control}] using Unicode property escapes (not sure if this is supported) or could be transpiled to unicode blocks/sub-ranges using this
Thanks for creating this issue! We figured it's missing some basic information or in some other way doesn't follow our issue reporting guidelines. Please take the time to review these and update the issue.
For Copilot Issues, be sure to visit our Copilot-specific guidelines page for details on the necessary information.
This issue has been closed as it has been labeled with info-needed and has not received the additional information that was requested from the issue author. It has been labeled as info-needed for 7 days.
feature-requestRequest for new features or functionalityhelp wantedIssues identified as good community contribution opportunitiesinfo-neededIssue requires more information from postersearchSearch widget and operation issuessearch-api
Activity
johlju commentedon May 27, 2017
Got the same problem. Searching for whole words does not work when word contains Swedish characters.
It should not had a hit on 'rs' in the word 'körs'.
roblourens commentedon May 27, 2017
Is this the insiders build? This was just fixed for find.
jeanp413 commentedon Sep 6, 2019
roblourens Maybe this can be fixed by using the
--word-regexpflag in ripgrep again.There were some issues before:
but the pattern for whole word has been updated from
\b(?:<your pattern>)\bto(?:^|\W)(?:<your pattern>)(?:$|\W)with\Wbeing unicode aware.roblourens commentedon Sep 9, 2019
To match the editor, this has to take the
editor.wordSeparatorssetting into account, so I think it will still have to be a regex built by vscode.jeanp413 commentedon Sep 10, 2019
Wouldn't it be better to use the same
(?:^|\W)(?:<your pattern>)(?:$|\W)pattern?Now that there's unicode support in vscode, it's possible to implement
\W(unicode aware) which is defined as[^\p{Alphabetic}\p{M}\p{Nd}\p{Pc}\p{Join_Control}]usingUnicode property escapes(not sure if this is supported) or could be transpiled to unicode blocks/sub-ranges using thisroblourens commentedon Sep 10, 2019
I understand that but the point is that the definition of a "word" is customizable by the user via that setting.
dmitrivMS commentedon Dec 21, 2025
Osvaldo Ortega (@osortega) FYI - I cannot repro this with Russian or Swedish examples above or from linked bugs.
If anyone has a repro, please share.
Version: 1.108.0
Commit: Unknown
Date: Unknown
Electron: 39.2.7
ElectronBuildId: undefined
Chromium: 142.0.7444.235
Node.js: 22.21.1
V8: 14.2.231.21-electron.0
OS: Windows_NT x64 10.0.26200
vs-code-engineering commentedon Jan 5, 2026
Thanks for creating this issue! We figured it's missing some basic information or in some other way doesn't follow our issue reporting guidelines. Please take the time to review these and update the issue.
For Copilot Issues, be sure to visit our Copilot-specific guidelines page for details on the necessary information.
Happy Coding!
vs-code-engineering commentedon Jan 13, 2026
This issue has been closed as it has been labeled with
info-neededand has not received the additional information that was requested from the issue author. It has been labeled asinfo-neededfor 7 days.