flintrocks / flint

The Flint Programming Language for Smart Contracts
MIT License
2 stars 0 forks source link

Research LSP format and dependencies #23

Closed nvgrw closed 6 years ago

nvgrw commented 6 years ago

Research the way that the LSP format works and what libraries might be available for Swift to run an LSP server. https://langserver.org/

ethanluoyc commented 6 years ago

Update Use the LSP implemented. Instead try: https://github.com/RLovelett/langserver-swift. and https://github.com/RLovelett/vscode-swift. They are no longer maintained. This is the one used by VSCode.

Official website:

https://langserver.org/

Official guide for implementing a LSP server/client for VSCode:

https://code.visualstudio.com/docs/extensions/example-language-server

My conclusion: Note that there is a Swift-version of the LSP protocol here (MIT licensed). I assumed it to be a programatic implementation of the protocol (and yes it is). They also have a LSP server implemented based on that. We can reuse the LSP protocol and implement our server for Flint on top of that. We can also hack this vscode extension (which targets Swift) and make it usable with Flint.

ethanluoyc commented 6 years ago

swift build -Xswiftc -framework -Xswiftc sourcekitd -Xswiftc -F -Xswiftc /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib -Xlinker -rpath -Xlinker /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib

nvgrw commented 6 years ago

Created #42 #43 #44