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

Unified Diff: runtime/platform/utils.h

Issue 14299008: Add utilities for converting from Host endianity to big endian and little endian formats for the va… (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 7 years, 8 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 | runtime/platform/utils_android.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/platform/utils.h
===================================================================
--- runtime/platform/utils.h (revision 21569)
+++ runtime/platform/utils.h (working copy)
@@ -170,6 +170,15 @@
length >= 0 &&
count <= (length - offset);
}
+
+ // Utility functions for converting values from host endianess to
+ // big or little endian values.
+ static uint16_t HostToBigEndian16(uint16_t host_value);
+ static uint32_t HostToBigEndian32(uint32_t host_value);
+ static uint64_t HostToBigEndian64(uint64_t host_value);
+ static uint16_t HostToLittleEndian16(uint16_t host_value);
+ static uint32_t HostToLittleEndian32(uint32_t host_value);
+ static uint64_t HostToLittleEndian64(uint64_t host_value);
};
} // namespace dart
« no previous file with comments | « no previous file | runtime/platform/utils_android.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698