SaC Language Support adds first-class editing support for SaC (Single Assignment C) in Visual Studio Code.
It provides:
- SaC language registration for
.sacfiles - Syntax highlighting and language configuration
- Compiler-backed diagnostics via
sac2c(Problems panel + editor squiggles)
- Faster feedback while writing SaC code
- Clear diagnostics integrated into the editor
- Flexible compiler execution (
local,wsl,docker)
SaC keywords, operators, comments, and language constructs are highlighted out of the box.
Diagnostics from sac2c are shown as VS Code Problems and inline squiggles.
Choose how diagnostics are displayed:
expandedsmarthybrid
Syntax highlighting works without external tools.
For diagnostics, sac2c must be available through one of:
sac.compiler.path(explicit executable path)- bundled compiler in
vendor/sac2c/<channel>/<platform-target>/ - system
sac2conPATH
Supported execution backends:
localwsl(Windows host only)docker
Common settings:
sac.languageServer.enablesac.diagnostics.mode(onSave,onType,manual)sac.diagnostics.presentation(expanded,smart,hybrid)sac.diagnostics.includeRelatedInformationsac.diagnostics.includeStackInMessagesac.diagnostics.maxStackFramessac.diagnostics.workspaceScan.enabledsac.compiler.channel(stable,develop,system)sac.compiler.pathsac.compiler.executionBackend(local,wsl,docker)sac.compiler.extraArgs
Default structured messaging args:
-cti-no-color -cti-no-source -cti-no-hint -cti-no-explain -cti-message-length 0 -cti-primary-header-format "%s: " -cti-continuation-header-format "%.0s"
If your sac2c version uses different flags, override sac.compiler.messaging.args.
- Install the extension.
- Open a
.sacfile. - Ensure diagnostics mode is enabled (for example
onSave). - Configure compiler path/backend if needed.
int main() {
return 0;
}
Create a small typing or semantic error in a .sac file and save to see diagnostics in the Problems panel.
If you are on Windows and do not have a native sac2c binary, recommended options are:
- Use VS Code Remote WSL and run backend
localinside WSL - Use backend
wsl - Use backend
docker
- Diagnostics pipeline:
docs/diagnostics-pipeline.md - Editor-agnostic diagnostics notes:
docs/editor-agnostic-diagnostics.md - Support:
SUPPORT.md - Contributing:
CONTRIBUTING.md
Issues and feature requests are welcome:


