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

Unified Diff: sync/syncable/entry_kernel.h

Issue 1545553003: Switch to standard integer types in sync/. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 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 | « sync/syncable/entry.cc ('k') | sync/syncable/entry_kernel.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sync/syncable/entry_kernel.h
diff --git a/sync/syncable/entry_kernel.h b/sync/syncable/entry_kernel.h
index be606d1f93d1477256a13bde6822a087d2600d55..96a657f3a528a2e3c5803978e52b724dccd827be 100644
--- a/sync/syncable/entry_kernel.h
+++ b/sync/syncable/entry_kernel.h
@@ -5,6 +5,8 @@
#ifndef SYNC_SYNCABLE_ENTRY_KERNEL_H_
#define SYNC_SYNCABLE_ENTRY_KERNEL_H_
+#include <stdint.h>
+
#include <algorithm>
#include <map>
#include <set>
@@ -40,7 +42,7 @@ namespace syncable {
// directory_backing_store.cc
// - TestSimpleFieldsPreservedDuringSaveChanges in syncable_unittest.cc
-static const int64 kInvalidMetaHandle = 0;
+static const int64_t kInvalidMetaHandle = 0;
enum {
BEGIN_FIELDS = 0,
@@ -204,7 +206,7 @@ struct SYNC_EXPORT EntryKernel {
std::string string_fields[STRING_FIELDS_COUNT];
EntitySpecificsPtr specifics_fields[PROTO_FIELDS_COUNT];
- int64 int64_fields[INT64_FIELDS_COUNT];
+ int64_t int64_fields[INT64_FIELDS_COUNT];
base::Time time_fields[TIME_FIELDS_COUNT];
Id id_fields[ID_FIELDS_COUNT];
UniquePosition unique_position_fields[UNIQUE_POSITION_FIELDS_COUNT];
@@ -246,10 +248,10 @@ struct SYNC_EXPORT EntryKernel {
}
// Setters.
- inline void put(MetahandleField field, int64 value) {
+ inline void put(MetahandleField field, int64_t value) {
int64_fields[field - INT64_FIELDS_BEGIN] = value;
}
- inline void put(Int64Field field, int64 value) {
+ inline void put(Int64Field field, int64_t value) {
int64_fields[field - INT64_FIELDS_BEGIN] = value;
}
inline void put(TimeField field, const base::Time& value) {
@@ -261,7 +263,7 @@ struct SYNC_EXPORT EntryKernel {
inline void put(IdField field, const Id& value) {
id_fields[field - ID_FIELDS_BEGIN] = value;
}
- inline void put(BaseVersion field, int64 value) {
+ inline void put(BaseVersion field, int64_t value) {
int64_fields[field - INT64_FIELDS_BEGIN] = value;
}
inline void put(IndexedBitField field, bool value) {
@@ -292,10 +294,10 @@ struct SYNC_EXPORT EntryKernel {
}
// Const ref getters.
- inline int64 ref(MetahandleField field) const {
+ inline int64_t ref(MetahandleField field) const {
return int64_fields[field - INT64_FIELDS_BEGIN];
}
- inline int64 ref(Int64Field field) const {
+ inline int64_t ref(Int64Field field) const {
return int64_fields[field - INT64_FIELDS_BEGIN];
}
inline const base::Time& ref(TimeField field) const {
@@ -304,7 +306,7 @@ struct SYNC_EXPORT EntryKernel {
inline const Id& ref(IdField field) const {
return id_fields[field - ID_FIELDS_BEGIN];
}
- inline int64 ref(BaseVersion field) const {
+ inline int64_t ref(BaseVersion field) const {
return int64_fields[field - INT64_FIELDS_BEGIN];
}
inline bool ref(IndexedBitField field) const {
@@ -402,7 +404,7 @@ struct EntryKernelMutation {
EntryKernel original, mutated;
};
-typedef std::map<int64, EntryKernelMutation> EntryKernelMutationMap;
+typedef std::map<int64_t, EntryKernelMutation> EntryKernelMutationMap;
typedef Immutable<EntryKernelMutationMap> ImmutableEntryKernelMutationMap;
« no previous file with comments | « sync/syncable/entry.cc ('k') | sync/syncable/entry_kernel.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698