IDE as a Front-end and Fast time-to-market
language support in Eclipse IDE relying on LSP,
TextMate and CLI
C# and Rust case studies
Mickael Istria - @mickaelistria CC0 – No rights reserved
Language Server Protocol
Request/response/notifications based between client (IDE) and LS
Dedicated to text edition
Standardized messages and protocol.
IDE /
Text Editor
Language and code
Analysis smartness
Provides:
● Validation
● Quickfixes
● Completion
● Hover
● Outline
● References
● Rename
● ….
Java JS TS C# XText JSon Ceylon Rust ...
Eclipse IDE
VSCode
Eclipse Che
Emacs
Eclipse Theia
Gnome-Builder
...
Eclipse IDE
VSCode
Eclipse Che
Emacs
Eclipse Theia
Gnome-Builder
...
Java
JS
TS
C#
XText
JSON
Ceylon
Rust
...
Language Server Protocol
M languages (12)
N IDEs/Editors (63)
x
Complex and specific
Integrations (756)
M languages (12)
N IDEs/Editors (63)
+ Simpler and reusable
Integrations (75)
LSP @Eclipse
● 1 SDK
– Eclipse LSP4J
● 4 clients IDEs
– Eclipse IDE (LSP4E)
– Eclipse Che
– Eclipse Theia
– Eclipse Orion
● 3 language servers
– Eclipse JDT.LS (used by VSCode)
– Eclipse Xtext
– Eclipse Ceylon
● 2 integrations
– Eclipse aCute (C#)
– Eclipse Corrosion (Rust)
● 1 discovery solution
– Eclipse LSPHub
At least, 11 related
Eclipse.org projects
TextMate for syntax highlighting
A grammar file configures syntax highlighting for one language
TextMate ecosystem
● 240 repos under https://github.com/textmate
● At least 4 clients: Eclipse IDE (TM4E),
TextMate, VSCode, Atom
N x M
960 specific integrations
N + M
244 reusable integrations
TextMate @Eclipse
● 1 SDK
– Eclipse TM4E (provides plain Java API for parsing
TextMate files + integration in Eclipse IDE)
● 2 integrations
– Eclipse aCute
– Eclipse Corrosion
language-configuration.json
● Configures
– matching brackets
(highlight, auto-close, jump
to...)
– comments
● Semi-standard from
VSCode
● Supported by
Eclipse TM4E
● Hundreds on GitHub
Eclipse IDE – Generic Editor
Pure legacy JFace interfaces → old and new
code reusable in whole Eclipse Platform
Generic Editor
...
completion
hover
Mark occurences
Syntax highlighting / presentation reconciler
2 new integrations
New
in
Photon!
C# with Eclipse aCute
Uses OmniSharp LS +
TextMate grammar
+ New wizard w/ dotnet CLI
+ Build config w/ dotnet CLI
+ Run config w/ dotnet CLI
+ Export wizard w/ dotnet CLI
Rust with Eclipse Corrosion
Use RustLS +
TextMate Grammar
+ New wizard w/ cargo CLI
+ Build config w/ cargo CLI
+ Run config w/ cargo CLI
+ Export wizard w/ cargo CLI
+ Debug with cargo + gdb (use
CDT integration)
+ EPP package Eclipse IDE for
Rust developers
Low code Architecture
org.eclipse.ui.
genericeditor
...
completion
autoedit
hover
presentation reconciler
org.eclipse.core.
resources
Org.eclipse.ui.ide
...
...
markers
markerResolution
TM4E
language-
configuration.json
LSP4E
TextMate
Grammar
Language
Server
(Provider)
Rich editor integration
from 35 lines!
LSP integration
● 5 lines of Java to start the server + 11 lines of
XML to bind the server
TextMate integration
Languageconfiguration.json integration
17 lines of XML
6 lines of XML
Where is my LS? Mulitple strategies
Assume it’s a pre-requisite and find it on filesystem,
or
Ship it inside a plugin/fragment (aCute),
or
Provision it on user’s machine
from the IDE (Corrosion)
IDE as a “front-end” vs
reimplementing language logic
Easier to implement +++
As feature rich ===
Consistent UX across plugins ++
Reusability of various layers ++++++
Factorization ++++
Faster time to market ++++
What now?
● Applies to so many languages
● Applies to other IDEs (including Eclipse Che,
Eclipse Theia, Eclipse Orion..)
● ADOPT NOW!
What’s next?
Debug Adapter Protocol (already supported in
LSP4E)
Test Server Protocol (experimental WIP)
Provisioning Project Protocol (experimental
WIP)
Build Server Protocol (experimental WIP)
…
Mickael Istria - @mickaelistria CC0 – No rights reserved
TL (seriously?); DR:
● ADOPT existing standardized devtools artifacts
(LS, TextMate,…)
● CREATE reusable standard-ish artifacts for you
languages
● CREATE clients for these artifacts
● INTEGRATE more language in your favorite
IDEs!

IDE as a Front-end and Fast time-to-market language support in Eclipse IDE relying on LSP, TextMate and CLI

  • 1.
    IDE as aFront-end and Fast time-to-market language support in Eclipse IDE relying on LSP, TextMate and CLI C# and Rust case studies Mickael Istria - @mickaelistria CC0 – No rights reserved
  • 2.
    Language Server Protocol Request/response/notificationsbased between client (IDE) and LS Dedicated to text edition Standardized messages and protocol. IDE / Text Editor Language and code Analysis smartness Provides: ● Validation ● Quickfixes ● Completion ● Hover ● Outline ● References ● Rename ● ….
  • 3.
    Java JS TSC# XText JSon Ceylon Rust ... Eclipse IDE VSCode Eclipse Che Emacs Eclipse Theia Gnome-Builder ... Eclipse IDE VSCode Eclipse Che Emacs Eclipse Theia Gnome-Builder ... Java JS TS C# XText JSON Ceylon Rust ... Language Server Protocol M languages (12) N IDEs/Editors (63) x Complex and specific Integrations (756) M languages (12) N IDEs/Editors (63) + Simpler and reusable Integrations (75)
  • 4.
    LSP @Eclipse ● 1SDK – Eclipse LSP4J ● 4 clients IDEs – Eclipse IDE (LSP4E) – Eclipse Che – Eclipse Theia – Eclipse Orion ● 3 language servers – Eclipse JDT.LS (used by VSCode) – Eclipse Xtext – Eclipse Ceylon ● 2 integrations – Eclipse aCute (C#) – Eclipse Corrosion (Rust) ● 1 discovery solution – Eclipse LSPHub At least, 11 related Eclipse.org projects
  • 5.
    TextMate for syntaxhighlighting A grammar file configures syntax highlighting for one language
  • 6.
    TextMate ecosystem ● 240repos under https://github.com/textmate ● At least 4 clients: Eclipse IDE (TM4E), TextMate, VSCode, Atom N x M 960 specific integrations N + M 244 reusable integrations
  • 7.
    TextMate @Eclipse ● 1SDK – Eclipse TM4E (provides plain Java API for parsing TextMate files + integration in Eclipse IDE) ● 2 integrations – Eclipse aCute – Eclipse Corrosion
  • 8.
    language-configuration.json ● Configures – matchingbrackets (highlight, auto-close, jump to...) – comments ● Semi-standard from VSCode ● Supported by Eclipse TM4E ● Hundreds on GitHub
  • 9.
    Eclipse IDE –Generic Editor Pure legacy JFace interfaces → old and new code reusable in whole Eclipse Platform Generic Editor ... completion hover Mark occurences Syntax highlighting / presentation reconciler
  • 10.
  • 11.
    C# with EclipseaCute Uses OmniSharp LS + TextMate grammar + New wizard w/ dotnet CLI + Build config w/ dotnet CLI + Run config w/ dotnet CLI + Export wizard w/ dotnet CLI
  • 12.
    Rust with EclipseCorrosion Use RustLS + TextMate Grammar + New wizard w/ cargo CLI + Build config w/ cargo CLI + Run config w/ cargo CLI + Export wizard w/ cargo CLI + Debug with cargo + gdb (use CDT integration) + EPP package Eclipse IDE for Rust developers
  • 13.
    Low code Architecture org.eclipse.ui. genericeditor ... completion autoedit hover presentationreconciler org.eclipse.core. resources Org.eclipse.ui.ide ... ... markers markerResolution TM4E language- configuration.json LSP4E TextMate Grammar Language Server (Provider) Rich editor integration from 35 lines!
  • 14.
    LSP integration ● 5lines of Java to start the server + 11 lines of XML to bind the server
  • 15.
  • 16.
    Where is myLS? Mulitple strategies Assume it’s a pre-requisite and find it on filesystem, or Ship it inside a plugin/fragment (aCute), or Provision it on user’s machine from the IDE (Corrosion)
  • 17.
    IDE as a“front-end” vs reimplementing language logic Easier to implement +++ As feature rich === Consistent UX across plugins ++ Reusability of various layers ++++++ Factorization ++++ Faster time to market ++++
  • 18.
    What now? ● Appliesto so many languages ● Applies to other IDEs (including Eclipse Che, Eclipse Theia, Eclipse Orion..) ● ADOPT NOW!
  • 19.
    What’s next? Debug AdapterProtocol (already supported in LSP4E) Test Server Protocol (experimental WIP) Provisioning Project Protocol (experimental WIP) Build Server Protocol (experimental WIP) …
  • 20.
    Mickael Istria -@mickaelistria CC0 – No rights reserved TL (seriously?); DR: ● ADOPT existing standardized devtools artifacts (LS, TextMate,…) ● CREATE reusable standard-ish artifacts for you languages ● CREATE clients for these artifacts ● INTEGRATE more language in your favorite IDEs!