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

Language Server Protocol for sclang #36

Open
crucialfelix opened this issue Sep 27, 2017 · 7 comments
Open

Language Server Protocol for sclang #36

crucialfelix opened this issue Sep 27, 2017 · 7 comments

Comments

@crucialfelix
Copy link
Owner

This would be a separate project. LSP (language server protocol) would mean that sclang can be connected to most IDEs (atom, vscode, emacs, vim) and would support:

Code completion | Hover | Jump to def | Workspace symbols | Find references | Stream reference results | Diagnostics

http://langserver.org/

My initial idea is to have supercollider dump a JSON file with all classes, methods and help strings (derived from the help files). A language server would answer requests using that dump as data. It could be written in go to make it more portable and easier to install.

@widp
Copy link

widp commented Mar 21, 2018

For anyone who wants to pick this up, I have a better idea. Communication like this has already been implemented in the Qt based IDE. It uses yaml and a custom protocol instead. The sc developers seem open to the idea of implementing lsp instead of that. Supercollider has enough introspection built in already to support these features.
I'll probably try to implement this if I get the time, if I don't I hope someone will.

@crucialfelix
Copy link
Owner Author

The benefit to implementing LSP is that large numbers of editors and IDEs already support it. High quality interfaces and usages of that protocol are being developed all the time.

The Super Collider IDE supports a custom protocol, so the only thing that connect to that is SC IDE. The only advancement that will ever happen is by this very tiny SC community. I think it would be better to concentrate on music features unique to SC.

@widp
Copy link

widp commented Mar 21, 2018

Agree completely, My point was to replace the existing protocol with LSP.

@crucialfelix
Copy link
Owner Author

Oh, I misunderstood your previous comment then !

@madskjeldgaard
Copy link

did any of you guys make progress on this?

@widp
Copy link

widp commented Nov 10, 2020

Current setup:
- qtIDE has a class sc_introspection.hpp which talks to ScIDE.sc file in scide_scqt
- from where it gets all information, such as method names, class names.
- Also look at the Document.sc class.
Relevant directories:
- scide_scqt
- editors/sc-ide

@madskjeldgaard
Copy link

madskjeldgaard commented Nov 10, 2020 via email

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

No branches or pull requests

3 participants