Code Inspection: Structured message template problems
This inspection works in combination with the [StructuredMessageTemplateAttribute] from JetBrains.Annotations. It helps ensure that methods designed to accept non-interpolated strings with placeholders are used correctly. Here is an example:
void LogNewUser([StructuredMessageTemplate] string message, params string[] args)
{
// Log new user
}
void Test()
{
// Warning: Non-existing argument in structured string
LogNewUser("User created: {username}");
}
Last modified: 21 March 2024