An OpenQASM 3.0 language server and runtime written in Rust.
- Statevector Quantum Simulation: Multi-qubit simulation with parallelized gate operations via
rayon - Full LSP Server:
qasm-lspprovides diagnostics, go-to-definition, references, hover, completions, signature help, rename, document symbols, and semantic tokens - Static Type Checking: Type inference, error/warning/hint diagnostics, and cross-file reference tracking
- Gate Modifiers:
ctrl,negctrl,inv, andpowgate composition - Pretty Error Reporting: Color-coded diagnostics with source snippets via
ariadne
Download the latest binary for your platform from the releases page.
git clone https://github.com/wiji1/QuantumVM
cd QuantumVM
cargo build --releaseThe build produces two binaries: QuantumVM (CLI runtime) and qasm-lsp (LSP server).
quantumvm program.qasm
quantumvm program.qasm --input n=5 --input theta=3.14
quantumvm program.qasm --inputs params.json
See docs/input-system.md for details on input declarations and value formats.
- VS Code: Install the QASM Language Support extension.
- JetBrains: Install the QASM Language Support plugin.
Both plugins launch qasm-lsp automatically and provide diagnostics, go-to-definition, references, hover, completions, signature help, rename, document symbols, and semantic tokens.
cargo test # Run all tests
cargo clippy # Lint
cargo build # Build (debug)The CI workflow (.github/workflows/ci.yml) runs tests and clippy on every push to main and on pull requests. Builds are tested on Linux, macOS, and Windows.
Contributions are welcome. Open an issue or pull request on GitHub.