I see one example of a message with placeholders and it wasn't where I expected to find it (either in the description of message.arguments or in the section titled 'messages with placeholders'
Also the example that does exist should use apostrophes to help indicated the replacement value. Will help the example pop more. Also suggest using a variable name of greater length.
See example below for my suggested improvements, changed name of var 'n' to 'pBuffer' and added apostrophes in text and format string
"results": [ # See §3.11.15.
{ # A result object (§3.19).
"ruleId": "CA2101", # See §3.19.4.
"message": { # See §3.19.7.
"text": "Variable 'pBuffer' is uninitialized.", # See §3.9.7.
"arguments": [ "pBuffer" ] # See §3.9.11.
},
"ruleMessageId": "default" # See §3.19.8.
}
],
"resources": { # See §3.11.16.
"rules": { # See §3.35.3
"CA2010": { # A rule object (§3.36).
"messageStrings": { # See §3.30.7.
"default": "Variable '{0}' is uninitialized."
}
}
I see one example of a message with placeholders and it wasn't where I expected to find it (either in the description of message.arguments or in the section titled 'messages with placeholders'
Also the example that does exist should use apostrophes to help indicated the replacement value. Will help the example pop more. Also suggest using a variable name of greater length.
See example below for my suggested improvements, changed name of var 'n' to 'pBuffer' and added apostrophes in text and format string
"results": [ # See §3.11.15.
{ # A result object (§3.19).
"ruleId": "CA2101", # See §3.19.4.
"message": { # See §3.19.7.
"text": "Variable 'pBuffer' is uninitialized.", # See §3.9.7.
"arguments": [ "pBuffer" ] # See §3.9.11.
},
"ruleMessageId": "default" # See §3.19.8.
}
],
"resources": { # See §3.11.16.
"rules": { # See §3.35.3
"CA2010": { # A rule object (§3.36).
"messageStrings": { # See §3.30.7.
"default": "Variable '{0}' is uninitialized."
}
}