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

Standalone command-line option to typecheck a .sw file #2284

Open
byorgey opened this issue Jan 10, 2025 · 1 comment
Open

Standalone command-line option to typecheck a .sw file #2284

byorgey opened this issue Jan 10, 2025 · 1 comment
Labels
Z-Feature A new feature to be added to the game.

Comments

@byorgey
Copy link
Member

byorgey commented Jan 10, 2025

We have swarm format, and we have the LSP, but sometimes it might be nice to have a quick command-line-friendly way to fully parse + typecheck a .sw file. Concretely, I propose adding a new subcommand swarm check which is similar to swarm format but also typechecks the indicated file, and prints any errors (or a brief "OK" message) to stdout.

@byorgey byorgey added the Z-Feature A new feature to be added to the game. label Jan 10, 2025
@kostmo
Copy link
Member

kostmo commented Jan 12, 2025

That would be nice. FYI there does currently exist a webserver-dependent option introduced in #1142:

curl --silent -H "Content-Type: text/plain; charset=utf-8"  -i http://localhost:5357/code/render --data @data/test/language-snippets/warnings/unused-vars/multiple-lambda-first-unused.sw

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Z-Feature A new feature to be added to the game.
Projects
None yet
Development

No branches or pull requests

2 participants