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

feat(client): remove force wantDiagnostics #2

Merged
merged 2 commits into from
Feb 19, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,6 @@ You need [clangd](https://clangd.github.io/installation.html) installed already,
- `clangd.enabled`: enable `coc-clangd`, default `true`
- `clangd.path`: path to `clangd` executable, default `clangd`
- `clangd.arguments`: arguments for `clangd` server
- `clangd.wantDiagnostics`: force diagnostics generation, default `false`

## License

Expand Down
5 changes: 0 additions & 5 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -70,11 +70,6 @@
"type": "string"
},
"description": "Arguments for clangd server"
},
"clangd.wantDiagnostics": {
"type": "boolean",
"default": false,
"description": "Force diagnostics generation"
}
}
},
Expand Down
4 changes: 0 additions & 4 deletions src/config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,4 @@ export class Config {
get arguments() {
return this.cfg.get<string[]>('arguments', []);
}

get wantDiagnostics() {
return this.cfg.get('wantDiagnostics', false);
}
}
7 changes: 0 additions & 7 deletions src/ctx.ts
Original file line number Diff line number Diff line change
Expand Up @@ -62,13 +62,6 @@ export class Ctx {
initializationOptions: { clangdFileStatus: true },
outputChannel,
middleware: {
didChange: params => {
if (this.config.wantDiagnostics) {
// @ts-ignore
params.wantDiagnostics = true;
}
client.sendNotification(DidChangeTextDocumentNotification.type.method, params); // eslint-disable-line
},
handleDiagnostics: (uri: string, diagnostics: Diagnostic[], next: HandleDiagnosticsSignature) => {
for (const diagnostic of diagnostics) {
// @ts-ignore
Expand Down