microsoft/language-server-protocol

Feature request: prepare paste request.

Open

#767 aberto em 1 de jun. de 2019

Ver no GitHub
 (10 comments) (0 reactions) (0 assignees)HTML (956 forks)batch import
feature-requesthelp wantedidea

Métricas do repositório

Stars
 (12.810 stars)
Métricas de merge de PR
 (Mesclagem média 19h 29m) (12 fundiu PRs em 30d)

Description

For languages having types it would be very useful to get a list of all "symbols" and their respective reference types for a given range.

My use case comes from a Java project where I'm pasting a snippet from one file to another within the same project. When copying the code the editor could make a request to the LS and receive the types. Then upon pasting in a new document the LS could automatically import those types. That is in a Java project add import statements based on any the pasted code.

An even wilder suggestion is to implement a paste request indicating a source and target file and source range for files within the same project.

This kind of types request could be useful in many other situations.

Guia do colaborador