Skip to content

Commit 7caff09

Browse files
authored
fix #17: remove standard as setting + remove xml version 2 flag (#19)
1 parent e7c917c commit 7caff09

File tree

2 files changed

+1
-19
lines changed

2 files changed

+1
-19
lines changed

package.json

Lines changed: 0 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -52,22 +52,6 @@
5252
],
5353
"default": "info",
5454
"description": "Minimum severity of issues to report (info, warning, or error)."
55-
},
56-
"cppcheck-official.standard": {
57-
"type": "string",
58-
"enum": [
59-
"<none>",
60-
"c89",
61-
"c99",
62-
"c11",
63-
"c++03",
64-
"c++11",
65-
"c++14",
66-
"c++17",
67-
"c++20"
68-
],
69-
"default": "c++20",
70-
"description": "C/C++ standard to use for cppcheck (`--std=<id>`). Select `<none>` to specify it in `cppcheck-official.arguments` or let `cppcheck` use its default setting."
7155
}
7256
}
7357
},

src/extension.ts

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@ export function activate(context: vscode.ExtensionContext) {
9696
const isEnabled = config.get<boolean>("cppcheck-official.enable", true);
9797
const extraArgs = config.get<string>("cppcheck-official.arguments", "");
9898
const minSevString = config.get<string>("cppcheck-official.minSeverity", "info");
99-
const standard = config.get<string>("cppcheck-official.standard", "c++17");
99+
const standard = config.get<string>("cppcheck-official.standard", "c++20");
100100
const userPath = config.get<string>("cppcheck-official.path")?.trim() || "";
101101
const commandPath = userPath ? resolvePath(userPath) : "cppcheck";
102102

@@ -197,7 +197,6 @@ async function runCppcheckOnFileXML(
197197
const args = [
198198
'--enable=all',
199199
'--xml',
200-
'--xml-version=2',
201200
'--suppress=unusedFunction',
202201
'--suppress=missingInclude',
203202
'--suppress=missingIncludeSystem',
@@ -210,7 +209,6 @@ async function runCppcheckOnFileXML(
210209
const args = [
211210
'--enable=all',
212211
'--xml',
213-
'--xml-version=2',
214212
'--suppress=unusedFunction',
215213
'--suppress=missingInclude',
216214
'--suppress=missingIncludeSystem',

0 commit comments

Comments
 (0)