Skip to content

Commit eac341c

Browse files
authored
Merge branch 'main' into bobbrow/codeAnalysisChanged
2 parents 3bc1597 + 127166d commit eac341c

File tree

3 files changed

+15
-5
lines changed

3 files changed

+15
-5
lines changed

Extension/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3744,7 +3744,7 @@
37443744
},
37453745
"svdPath": {
37463746
"type": "string",
3747-
"description": "%c_cpp.debuggers.cppdbg.visualizerFile.description",
3747+
"description": "%c_cpp.debuggers.cppdbg.svdPath.description%",
37483748
"default": ""
37493749
},
37503750
"showDisplayString": {

Extension/src/LanguageServer/configurations.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1574,9 +1574,11 @@ export class CppProperties {
15741574
quoted = true;
15751575
result = result.slice(1, -1);
15761576
}
1577+
// On Windows, isAbsolute does not handle root paths without a slash, such as "C:"
1578+
const isWindowsRootPath: boolean = process.platform === 'win32' && /^[a-zA-Z]:$/.test(result);
15771579
// Make sure all paths result to an absolute path.
15781580
// Do not add the root path to an unresolved env variable.
1579-
if (!result.includes("env:") && !path.isAbsolute(result) && this.rootUri) {
1581+
if (!isWindowsRootPath && !result.includes("env:") && !path.isAbsolute(result) && this.rootUri) {
15801582
result = path.join(this.rootUri.fsPath, result);
15811583
}
15821584
if (quoted) {

Extension/tools/OptionsSchema.json

Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -477,7 +477,11 @@
477477
"allOf": [
478478
{
479479
"if": {
480-
"properties": { "type": { "const": "scp" } }
480+
"properties": {
481+
"type": {
482+
"const": "scp"
483+
}
484+
}
481485
},
482486
"then": {
483487
"properties": {
@@ -491,7 +495,11 @@
491495
},
492496
{
493497
"if": {
494-
"properties": { "type": { "const": "rsync" } }
498+
"properties": {
499+
"type": {
500+
"const": "rsync"
501+
}
502+
}
495503
},
496504
"then": {
497505
"properties": {
@@ -672,7 +680,7 @@
672680
},
673681
"svdPath": {
674682
"type": "string",
675-
"description": "%c_cpp.debuggers.cppdbg.visualizerFile.description",
683+
"description": "%c_cpp.debuggers.cppdbg.svdPath.description%",
676684
"default": ""
677685
},
678686
"showDisplayString": {

0 commit comments

Comments
 (0)