a customization of Theia from the Eclipse fondation for Modula-2 use, specifically (for the moment) GNU Modula-2

Eric Streit 329f229610 Semantic diagnostics: duplicates, unknown identifiers, enum literals пре 1 недеља
apps 494d458c98 Outline view: wire in Theia outline-view for program structure пре 1 недеља
examples 2ef7c3ad13 Modula-2 IDE on Eclipse Theia (Phase 1 done, Phase 2 started) пре 2 недеља
extensions 329f229610 Semantic diagnostics: duplicates, unknown identifiers, enum literals пре 1 недеља
grammars 2ef7c3ad13 Modula-2 IDE on Eclipse Theia (Phase 1 done, Phase 2 started) пре 2 недеља
scripts 2ef7c3ad13 Modula-2 IDE on Eclipse Theia (Phase 1 done, Phase 2 started) пре 2 недеља
.gitignore 3bdf3aa503 Package the Electron desktop app пре 2 недеља
README.md 3df556009d Phase 2 complete: find references and rename пре 2 недеља
SOURCE-TREE.txt 2ef7c3ad13 Modula-2 IDE on Eclipse Theia (Phase 1 done, Phase 2 started) пре 2 недеља
package-lock.json 2ef7c3ad13 Modula-2 IDE on Eclipse Theia (Phase 1 done, Phase 2 started) пре 2 недеља
package.json ef87a86be4 Release 0.8.0: program outline in the side panel пре 1 недеља
yarn.lock 3bdf3aa503 Package the Electron desktop app пре 2 недеља

README.md

Modula-2 IDE

A starting point for a dedicated GNU Modula-2 IDE built on Eclipse Theia.

Included

  • Browser and Electron Theia applications
  • Native Theia modula2-workbench extension
  • VS Code-compatible modula2-language extension
  • .mod and .def support
  • TextMate syntax highlighting
  • Modula-2 comments, brackets and indentation
  • Modula-2 snippets
  • Keyword-only automatic uppercasing
  • AST-backed document outline, completion, hover, go-to-definition, find references and rename (lenient declaration parser with cross-file .def resolution)
  • GNU Modula-2 compiler service: async Build/Build File/Clean/Rebuild/Run plus compiler detection, driven by the workspace modula2.json
  • Initial Modula-2 commands/menu
  • Project/example/grammar placeholders

Requirements

The current project targets Eclipse Theia 1.75.0, whose current stable release uses Node.js 24 as its minimum. Use Yarn Classic (1.x).

node --version
yarn --version
yarn
yarn build

Run browser:

yarn start:browser

Run Electron:

yarn start:electron

The language extension is intentionally a VS Code-compatible extension because Theia recommends VS Code extensions for language support. Native Theia extensions are used for product-specific workbench features.

Roadmap

  1. Stabilize the GNU Modula-2/Coco/R grammar against gm2 (see GNU-grammar).
  2. Add AST, symbols and semantic analysis AST/symbols done (lenient parser); semantic analysis pending.
  3. Add LSP LSP live (diagnostics bridge + outline/completion/hover/definition).
  4. Add modula2.json project support.
  5. Add GNU Modula-2 build/run/diagnostics.
  6. Add debugger integration.

Local VS Code language extension

The Modula-2 language extension is a VS Code-compatible extension. The build synchronizes it into plugins/modula2-language, and the Browser/Electron applications start Theia with --plugins=local-dir:../../plugins. The plugin directory must contain the extension folder; pointing --plugins directly at the extension folder does not provide the expected container layout.

Coco/R language-server bridge (0.1.7)

The language extension now contains a real LSP client/server pair. The server can invoke a GNU Modula-2 executable generated from a Coco/R grammar and turn its editor-oriented diagnostics into LSP diagnostics. See extensions/modula2-language/COCOR-LSP.md.