Visualize lifetime-related Rust compiler errors. This extension focuses on errors with a "timeline" that can be visualized.
The extension needs the diagnostics information from rust-analyzer.
Install the VSCode extension rust-analyzer and add the following to settings.json
:
"rust-analyzer.diagnostics.useRustcErrorCode": true
The configuration can be automatically set when you use the extension for the first time.
Just click "Allow" when the warning prompt appears.
The configuration will be added to .vscode/settings.json
under the project root.
Right-pointing red triangles will be displayed for supported errors after the source file is saved.
To display/hide the visualization, move the text cursor to the line with the red triangle and execute command revis.toggleVisualization
or use the keyboard shortcut Ctrl+Shift+V.
To clear all visualizations, execute command revis.clearAllVisualizations
.
To refresh the visualizations, save the current file.
This extension is still in an early stage. Please file an issue or contact Ruochen ([email protected]) if you find any bugs/confusing points.