Repository navigation
Serilog Syntax Highlighting v0.5.2
Installation
Download the attached VSIX file and double-click to install in Visual Studio 2022.
What's Changed
Fixed
- Multi-line ForContext patterns now correctly highlighted (#3)
- Properties in templates like
{@Items}are now highlighted when ForContext is on one line and logging method on the next - Added SyntaxTreeAnalyzer fallback for complex multi-line patterns
- Enhanced regex detection for ForContext chains split across lines
- Properties in templates like
- Multi-line outputTemplate patterns now correctly highlighted (#5)
- Properties like
{Timestamp}are now highlighted whenoutputTemplate:parameter is on one line and template string on the next - Enhanced concatenated template fragment detection
- Added dedicated regex for multi-line outputTemplate detection
- Properties like
- ForContext logger variables now correctly detected (#7)
- Template properties like
{ListenUri}are now highlighted when using logger variables from ForContext calls (e.g.,var program = log.ForContext<Program>()) - Enhanced SerilogCallDetector with dotted method patterns (
.Information,.Debug, etc.) - Added duplicate processing detection to prevent overlapping matches between regex patterns
- Separated quick check patterns into logical arrays for better maintainability
- Template properties like
Added
- Performance benchmarking infrastructure for overlap detection algorithms
- Benchmarks comparing O(n²) vs binary search vs SortedSet approaches
- Empirical validation showing original O(n²) algorithm performs best for typical usage patterns
Requirements
- Visual Studio 2022 (17.0) or later
- .NET Framework 4.7.2 or later
Full Changelog: https://github.com/willibrandon/serilog-syntax/blob/main/CHANGELOG.md