Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(5)

Unified Diff: include/core/SkMath.h

Issue 872673007: Disable the noisiest /analyze warning in Chrome. ~3,700/12,000 (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Remove _PREFAST_ check. Created 5 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: include/core/SkMath.h
diff --git a/include/core/SkMath.h b/include/core/SkMath.h
index 014f014debb771575af495aad5469498bebbf6cd..d9517dd6a228f4bdce4a581385a34633dc05c5e5 100644
--- a/include/core/SkMath.h
+++ b/include/core/SkMath.h
@@ -79,6 +79,9 @@ int SkCLZ_portable(uint32_t);
if (mask) {
DWORD index;
_BitScanReverse(&index, mask);
+ // Suppress this bogus /analyze warning. The check for non-zero
+ // guarantees that _BitScanReverse will succeed.
+#pragma warning(suppress : 6102) // Using 'index' from failed function call
return index ^ 0x1F;
} else {
return 32;
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698