mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-10-25 01:17:45 +00:00
Fix remaining tslint suggestions
This commit is contained in:
parent
4d62cfccbb
commit
62b1b05a0d
15 changed files with 82 additions and 78 deletions
|
|
@ -5,7 +5,7 @@ import { Decoration } from '../highlighting';
|
|||
import { Server } from '../server';
|
||||
|
||||
export async function handle(editor: TextEditor | undefined) {
|
||||
if (!Server.config.highlightingOn || !editor || editor.document.languageId != 'rust') { return; }
|
||||
if (!Server.config.highlightingOn || !editor || editor.document.languageId !== 'rust') { return; }
|
||||
const params: TextDocumentIdentifier = {
|
||||
uri: editor.document.uri.toString(),
|
||||
};
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@ import { syntaxTreeUri, TextDocumentContentProvider } from '../commands/syntaxTr
|
|||
export function createHandler(textDocumentContentProvider: TextDocumentContentProvider) {
|
||||
return (event: vscode.TextDocumentChangeEvent) => {
|
||||
const doc = event.document;
|
||||
if (doc.languageId != 'rust') { return; }
|
||||
if (doc.languageId !== 'rust') { return; }
|
||||
afterLs(() => {
|
||||
textDocumentContentProvider.eventEmitter.fire(syntaxTreeUri);
|
||||
});
|
||||
|
|
|
|||
7
editors/code/src/events/index.ts
Normal file
7
editors/code/src/events/index.ts
Normal file
|
|
@ -0,0 +1,7 @@
|
|||
import * as changeActiveTextEditor from './change_active_text_editor';
|
||||
import * as changeTextDocument from './change_text_document';
|
||||
|
||||
export {
|
||||
changeActiveTextEditor,
|
||||
changeTextDocument,
|
||||
};
|
||||
Loading…
Add table
Add a link
Reference in a new issue