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

Initial prototype implementation #8

Open
wants to merge 4 commits into
base: main
Choose a base branch
from

Conversation

msujew
Copy link

@msujew msujew commented Sep 4, 2024

This is an initial implementation of the PL/I language server using Langium. It supports most (as far as we can tell) of the base language. Missing prominent features:

  • Macro language (preprocessor)
  • Compiler flags

packages/language/src/parser/pli-grammar.ts Outdated Show resolved Hide resolved
scripts/merge-tmlanguage.mjs Outdated Show resolved Hide resolved
@asatklichov asatklichov self-assigned this Sep 4, 2024
@msujew msujew force-pushed the feature/langium-project branch from b06d804 to 9b0ecae Compare September 4, 2024 13:03
Copy link

@asatklichov asatklichov left a comment

Choose a reason for hiding this comment

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

Code is nice 👍, now will check tests and do some testing

package.json Show resolved Hide resolved
packages/extension/src/extension/builtin-files.ts Outdated Show resolved Hide resolved
packages/language/src/parser/pli-lexer.ts Outdated Show resolved Hide resolved
vitest.config.ts Show resolved Hide resolved
@KUGDev KUGDev self-requested a review September 5, 2024 18:36
@KUGDev
Copy link
Contributor

KUGDev commented Sep 6, 2024

LGTM, works the same way in IntelliJ IDEA

@VitGottwald
Copy link

Please, add .nvmrc file with expected node version (e.g. v20.17.0).

.vscode/launch.json Outdated Show resolved Hide resolved
@VitGottwald
Copy link

Can we replace pl-one everywhere in the code and package.json(s) with pli to have single word language name like we do for the other extensions (hlasm, cobol, rexx, jcl, ...)?

code_samples/CHART.pli Outdated Show resolved Hide resolved
code_samples/MACROS.pli Outdated Show resolved Hide resolved
@asatklichov
Copy link

  • adding CI build, vsix gen, and browser exec
  • dummy validation and semantic class

@msujew msujew force-pushed the feature/langium-project branch 7 times, most recently from 8aa2a54 to a6e1b12 Compare November 18, 2024 13:20
packages/extension/README.md Outdated Show resolved Hide resolved
packages/language/README.md Outdated Show resolved Hide resolved
@KUGDev KUGDev self-requested a review November 21, 2024 12:14
@KUGDev
Copy link
Contributor

KUGDev commented Nov 21, 2024

From the repo perspective, it would be better to separate the actual solution between different folders. The implementation is intended to be supported both in VS Code and IntelliJ IDEA. Can I ask the team to bring all the VS Code related things into the "vscode-extension" folder? So that it would be a clear separation between the VS Code and IntelliJ IDEA parts in the future

@azatsatklichov
Copy link

From the repo perspective, it would be better to separate the actual solution between different folders. The implementation is intended to be supported both in VS Code and IntelliJ IDEA. Can I ask the team to bring all the VS Code related things into the "vscode-extension" folder? So that it would be a clear separation between the VS Code and IntelliJ IDEA parts in the future

It is a good idea, I agree.

@msujew msujew force-pushed the feature/langium-project branch from cfe3f94 to d5bf1a6 Compare November 21, 2024 16:23
Copy link

@azatsatklichov azatsatklichov left a comment

Choose a reason for hiding this comment

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

💯

@msujew msujew force-pushed the feature/langium-project branch 2 times, most recently from 1f0d1c2 to cfcd5bf Compare November 26, 2024 17:37
package.json Outdated Show resolved Hide resolved
@msujew msujew force-pushed the feature/langium-project branch from cfcd5bf to 6b5d434 Compare December 11, 2024 13:19
@msujew msujew force-pushed the feature/langium-project branch 3 times, most recently from aaae68e to 183a00e Compare January 15, 2025 15:26
@msujew msujew force-pushed the feature/langium-project branch 2 times, most recently from 91e9352 to 4e07d32 Compare January 16, 2025 13:19
Co-authored-by: Benjamin Wilson <[email protected]>
Co-authored-by: Markus Rudolph <[email protected]>
Signed-off-by: Mark Sujew <[email protected]>
"sourceMaps": true,
"outFiles": [
"${workspaceFolder}/packages/language/out/**/*.js",
"${workspaceFolder}/packages/vscode-extension/out/**/*.js"

Choose a reason for hiding this comment

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

Suggested change
"${workspaceFolder}/packages/vscode-extension/out/**/*.js"
"${workspaceFolder}/packages/vscode-extension/out/**/*.cjs"

The generated main file is main.cjs and with the current pattern it does not get matched and debugging does not work.

Copy link
Author

Choose a reason for hiding this comment

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

It makes sense, but I'm nevertheless able to debug both the language server and the VS Code extension. Have you had trouble debugging the language server? Make sure to run the Attach to Language Server configuration after the language server has started up (i.e. after opening a .pli file).

Signed-off-by: Mark Sujew <[email protected]>
Signed-off-by: Mark Sujew <[email protected]>
Signed-off-by: Mark Sujew <[email protected]>
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.

6 participants