SALT

Documentation
Source

The module boundaries used to grow SALT without changing reporters.

Add or refine a rule

Core modules

ModuleResponsibility
config.py Defaults, YAML loading, option merging, and severity validation.
scanner.py Lightweight source representation.
registry.py Rule registration and construction.
rules/ Base contract plus style, naming, SV, and UVM implementations.
runner.py Discovery, scanning, rule execution, and result assembly.
reporters/ Text, JSON, and HTML rendering.

Extension workflow

  1. 1 Choose a narrow rule name, stable diagnostic ID, default severity, and precise message.
  2. 2 Implement it under the correct rule family using the shared violation model.
  3. 3 Register it and define conservative defaults in config.py if it should be on by default.
  4. 4 Add positive and negative fixtures, including comments and strings that resemble the pattern.
  5. 5 Run pytest and the demo linter before opening a change.

Development checks

./.venv/bin/python -m pytest
./.venv/bin/python -m salt check examples/demo --config examples/salt.yaml