usethesource / rascal-language-servers

An LSP server for Rascal which includes an easy-to-use LSP generator for languages implemented in Rascal, and an interactive terminal REPL.
BSD 2-Clause "Simplified" License
10 stars 7 forks source link

Feature: multiple extensions for single language #344

Closed DavyLandman closed 8 months ago

DavyLandman commented 8 months ago

As discussed in #343 we want to better align with LSP & VS Code by allowing multiple extensions for a single language.

The biggest change was in our multiplexer, which used to work by extension alone, but now maps extensions to language, and then continues as before.

I've tested that the old DSLs still work without requiring changes.

DavyLandman commented 8 months ago

Thanks.

Well, I updated the pico example to use the new constructor. And the test fail, but that's just UI test jank, since only the first DSL test fails.

In general there is not difference between how a language with 1 extension or more is handled now.

jurgenvinju commented 8 months ago

Right. So if the tests work, then we are sure of that. But we should add a test for a language with two extensions right? Otherwise, this feature will break the next time someone does something "quickly". Like me :-)

DavyLandman commented 8 months ago

Otherwise, this feature will break the next time someone does something "quickly". Like me :-)

that seems wise, I added a test for it.

sonarcloud[bot] commented 8 months ago

Quality Gate Passed Quality Gate passed

Kudos, no new issues were introduced!

0 New issues
0 Security Hotspots
0.0% Coverage on New Code
0.0% Duplication on New Code

See analysis details on SonarCloud