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

Unified Diff: webrtc/base/basictypes_unittest.cc

Issue 1186093004: Define uint64 and int64 using long long. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Created 5 years, 6 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 | « webrtc/base/basictypes.h ('k') | webrtc/base/helpers.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webrtc/base/basictypes_unittest.cc
diff --git a/webrtc/base/basictypes_unittest.cc b/webrtc/base/basictypes_unittest.cc
index 20515ecf969c6d854d224b8769980ce0aebc5e9b..3ac4337bc2e9fe340fa79daf16dab41294ac9c83 100644
--- a/webrtc/base/basictypes_unittest.cc
+++ b/webrtc/base/basictypes_unittest.cc
@@ -14,6 +14,15 @@
namespace rtc {
+static_assert(sizeof(int8) == 1, "Unexpected size");
+static_assert(sizeof(uint8) == 1, "Unexpected size");
+static_assert(sizeof(int16) == 2, "Unexpected size");
+static_assert(sizeof(uint16) == 2, "Unexpected size");
+static_assert(sizeof(int32) == 4, "Unexpected size");
+static_assert(sizeof(uint32) == 4, "Unexpected size");
+static_assert(sizeof(int64) == 8, "Unexpected size");
+static_assert(sizeof(uint64) == 8, "Unexpected size");
+
TEST(BasicTypesTest, Endian) {
uint16 v16 = 0x1234u;
uint8 first_byte = *reinterpret_cast<uint8*>(&v16);
« no previous file with comments | « webrtc/base/basictypes.h ('k') | webrtc/base/helpers.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698