Rename diagnostic so that it can be reused with scanf checking. No functionality change.

llvm-svn: 108896
This commit is contained in:
Ted Kremenek 2010-07-20 20:03:43 +00:00
parent 4e8e93f142
commit b65a9d5a1a
2 changed files with 2 additions and 2 deletions

View File

@ -2980,7 +2980,7 @@ def warn_printf_nonsensical_optional_amount: Warning<
def warn_printf_nonsensical_flag: Warning<
"flag '%0' results in undefined behavior with '%1' conversion specifier">,
InGroup<Format>;
def warn_printf_nonsensical_length: Warning<
def warn_format_nonsensical_length: Warning<
"length modifier '%0' results in undefined behavior or no effect with '%1' conversion specifier">,
InGroup<Format>;
def warn_printf_ignored_flag: Warning<

View File

@ -1518,7 +1518,7 @@ CheckPrintfHandler::HandlePrintfSpecifier(const analyze_printf::PrintfSpecifier
const LengthModifier &LM = FS.getLengthModifier();
if (!FS.hasValidLengthModifier())
S.Diag(getLocationOfByte(LM.getStart()),
diag::warn_printf_nonsensical_length)
diag::warn_format_nonsensical_length)
<< LM.toString() << CS.toString()
<< getSpecifierRange(startSpecifier, specifierLen)
<< FixItHint::CreateRemoval(getSpecifierRange(LM.getStart(),