File tree 1 file changed +3
-3
lines changed 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -658,15 +658,15 @@ function askForAllCurrentConfiguration() {
658
658
send ( req ) ;
659
659
}
660
660
661
- function semanticTokens ( msg : p . RequestMessage ) {
661
+ async function semanticTokens ( msg : p . RequestMessage ) {
662
662
// https://microsoft.github.io/language-server-protocol/specifications/specification-current/#textDocument_semanticTokens
663
663
let params = msg . params as p . SemanticTokensParams ;
664
664
let filePath = fileURLToPath ( params . textDocument . uri ) ;
665
665
let extension = path . extname ( params . textDocument . uri ) ;
666
666
let code = getOpenedFileContent ( params . textDocument . uri ) ;
667
667
let tmpname = utils . createFileInTempDir ( extension ) ;
668
668
fs . writeFileSync ( tmpname , code , { encoding : "utf-8" } ) ;
669
- let response = utils . runAnalysisCommand (
669
+ let response = await utils . runAnalysisCommand (
670
670
filePath ,
671
671
[ "semanticTokens" , tmpname ] ,
672
672
msg ,
@@ -1242,7 +1242,7 @@ async function onMessage(msg: p.Message) {
1242
1242
} else if ( msg . method === p . CompletionResolveRequest . method ) {
1243
1243
send ( await completionResolve ( msg ) ) ;
1244
1244
} else if ( msg . method === p . SemanticTokensRequest . method ) {
1245
- send ( semanticTokens ( msg ) ) ;
1245
+ send ( await semanticTokens ( msg ) ) ;
1246
1246
} else if ( msg . method === p . CodeActionRequest . method ) {
1247
1247
send ( codeAction ( msg ) ) ;
1248
1248
} else if ( msg . method === p . DocumentFormattingRequest . method ) {
You can’t perform that action at this time.
0 commit comments