Live Diagnostics
About 260 wordsLess than 1 minute
2025-01-08
What are diagnostics
Diagnostics are the errors and warnings in the editor. As you edit HDL, the language service analyzes the code in real time, including unsaved changes. Problem code is underlined in red or yellow and listed in the Problems panel; hover the squiggle to see the reason and the diagnostic code.
Demo
Turn off a diagnostic
When a kind of diagnostic does not apply to your project, you can turn it off by its code:
- Hover the squiggle and click Quick Fix in the tooltip.
- Choose Disable this error.
Digital IDE adds a rule to the workspace settings.json that sets the diagnostic code to off:
{
"digital-ide.function.lsp.diagnostics.overrides": {
"MissingTimeScale": "off"
}
}You can also edit this setting directly to add or remove rules; delete the key to show the diagnostic again. Note that:
- rules apply per diagnostic code, hiding every diagnostic with that code in the workspace, not just the current line;
- rules are written only to the workspace
settings.json; HDL files andproperty.jsonare not modified; - they affect editor diagnostics only, not errors in vendor synthesis or simulation logs.
Language standards
Diagnostics depend on the language standard, set with digital-ide.standard.systemverilog and digital-ide.standard.vhdl. include paths, macros and libraries also affect parsing.
Troubleshooting
Fix the earliest syntax error in the file first, then check whether later diagnostics remain. Editor diagnostics and the actual output of synthesis and simulation tools are separate: an empty Problems panel does not mean the project will build.