Skip to content

Commit bf6b4aa

Browse files
mill1000sean-mcmanus
authored andcommitted
Fix regex to allow non-recursive includePath (#3122)
* Fix regex to allow non-recursive includePath when constructing browse.path from includePath
1 parent f978719 commit bf6b4aa

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

Extension/CHANGELOG.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,8 @@
33
## Version 0.22.0-insiders February 5, 2019
44
* Fix signature help active parameter selection when parameter names are missing or subsets of each other. [#2952](https://github.com/Microsoft/vscode-cpptools/issues/2952)
55
* Render macro hover expansions as C/C++. [#3075](https://github.com/Microsoft/vscode-cpptools/issues/3075)
6+
* Allow * in includePath to apply to browse.path when browse.path is not specified. [#3121](https://github.com/Microsoft/vscode-cpptools/issues/3121)
7+
* Tucker Kern (@mill1000) [PR #3122](https://github.com/Microsoft/vscode-cpptools/pull/3122)
68

79
## Version 0.21.0 January 23, 2019
810
### New Features

Extension/src/LanguageServer/configurations.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -481,7 +481,7 @@ export class CppProperties {
481481
// If the user doesn't set browse.path, copy the includePath over. Make sure ${workspaceFolder} is in there though...
482482
configuration.browse.path = configuration.includePath.slice(0);
483483
if (-1 === configuration.includePath.findIndex((value: string, index: number) => {
484-
return !!value.match(/^\$\{(workspaceRoot|workspaceFolder)\}(\\|\\\*\*|\/|\/\*\*)?$/g);
484+
return !!value.match(/^\$\{(workspaceRoot|workspaceFolder)\}(\\\*{0,2}|\/\*{0,2})?$/g);
485485
})) {
486486
configuration.browse.path.push("${workspaceFolder}");
487487
}

0 commit comments

Comments
 (0)