Kaydet (Commit) 5a58e809 authored tarafından Noel Grandin's avatar Noel Grandin

loplugin:cstylecast

and improve the error message in the plugin

Change-Id: I8719832a48e14c132f463340fbbc537845f82b0b
üst fb2ad7ce
...@@ -198,7 +198,7 @@ bool CStyleCast::VisitCStyleCastExpr(const CStyleCastExpr * expr) { ...@@ -198,7 +198,7 @@ bool CStyleCast::VisitCStyleCastExpr(const CStyleCastExpr * expr) {
report( report(
DiagnosticsEngine::Warning, "%0 C-style cast from %1%2 to %3%4%5", DiagnosticsEngine::Warning, "%0 C-style cast from %1%2 to %3%4%5",
expr->getSourceRange().getBegin()) expr->getSourceRange().getBegin())
<< expr->getCastKindName() << incompFrom << incompFrom
<< expr->getSubExprAsWritten()->getType() << incompTo << expr->getType() << expr->getSubExprAsWritten()->getType() << incompTo << expr->getType()
<< performs << expr->getSourceRange(); << performs << expr->getSourceRange();
return true; return true;
......
...@@ -497,7 +497,7 @@ void PrintFontManager::countFontconfigFonts( std::unordered_map<OString, int, OS ...@@ -497,7 +497,7 @@ void PrintFontManager::countFontconfigFonts( std::unordered_map<OString, int, OS
FcResult eFileRes = FcPatternGetString(pFSet->fonts[i], FC_FILE, 0, &file); FcResult eFileRes = FcPatternGetString(pFSet->fonts[i], FC_FILE, 0, &file);
FcResult eFamilyRes = rWrapper.LocalizedElementFromPattern( pFSet->fonts[i], &family, FC_FAMILY, FC_FAMILYLANG ); FcResult eFamilyRes = rWrapper.LocalizedElementFromPattern( pFSet->fonts[i], &family, FC_FAMILY, FC_FAMILYLANG );
if (bMinimalFontset && strncmp((char*)family, "Liberation", strlen("Liberation"))) if (bMinimalFontset && strncmp(reinterpret_cast<char*>(family), "Liberation", strlen("Liberation")))
continue; continue;
FcResult eStyleRes = rWrapper.LocalizedElementFromPattern( pFSet->fonts[i], &style, FC_STYLE, FC_STYLELANG ); FcResult eStyleRes = rWrapper.LocalizedElementFromPattern( pFSet->fonts[i], &style, FC_STYLE, FC_STYLELANG );
FcResult eSlantRes = FcPatternGetInteger(pFSet->fonts[i], FC_SLANT, 0, &slant); FcResult eSlantRes = FcPatternGetInteger(pFSet->fonts[i], FC_SLANT, 0, &slant);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment