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

[#36] Add new content provider using LSP #54

Merged
merged 1 commit into from
May 10, 2023

Conversation

ghentschke
Copy link
Contributor

Uses the LSP to fetch the children of a TU in the project explorer view.

fixes #36

@ghentschke
Copy link
Contributor Author

This is a first draft based on on a not yet stable LSP4E API. The content provider delivers the children of a ITranslationUnit when Prefer C/C++ Editor (LSP) has been selected:

image

Currently the children consist of the symbols delivered by the LSP textDocument/documentSymbol command. They are identical to the outline view symbols from a document.

Perspectiveley the includes and macros could be added and a new CModelBuilder should be implemented to get rid of the old internal AST based data model.

@jonahgraham
Copy link
Member

This looks good @ghentschke I can try it out later. Does it need a specific LSP4E PR, or does it work with current master branch of LSP4E?

@ghentschke
Copy link
Contributor Author

This looks good @ghentschke I can try it out later. Does it need a specific LSP4E PR, or does it work with current master branch of LSP4E?

This works with the current master of of LSP4E

@ghentschke ghentschke force-pushed the new-content-provider branch 2 times, most recently from 1f115c1 to 3473fc8 Compare May 10, 2023 09:34
Uses the LSP to fetch the children of a TU in the project explorer view.

fixes eclipse-cdt#36
Copy link
Member

@ruspl-afed ruspl-afed left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for considering my comments @ghentschke

@ghentschke
Copy link
Contributor Author

@ruspl-afed thank your for your very constructive review!

@ghentschke ghentschke merged commit 30cc7ed into eclipse-cdt:master May 10, 2023
@ghentschke ghentschke deleted the new-content-provider branch May 10, 2023 12:17
@jonahgraham jonahgraham added this to the 1.0.0 milestone Sep 18, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Fetch children for TU from clangd
3 participants