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

Unified Diff: util/numeric/safe_assignment.h

Issue 809303003: win: Add static_cast to AssignIfInRange (Closed) Base URL: https://chromium.googlesource.com/crashpad/crashpad@file-writer-3
Patch Set: Created 6 years 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: util/numeric/safe_assignment.h
diff --git a/util/numeric/safe_assignment.h b/util/numeric/safe_assignment.h
index 05e0b2d9cfd2e2bf8476b8a5996a84284e9296c5..358d983701585b654c69c0b6d5851bc7bf15ed2c 100644
--- a/util/numeric/safe_assignment.h
+++ b/util/numeric/safe_assignment.h
@@ -35,7 +35,7 @@ bool AssignIfInRange(Destination* destination, Source source) {
return false;
}
- *destination = source;
+ *destination = static_cast<Destination>(source);
return true;
}
« 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