summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--components/startup_metric_utils/browser/startup_metric_utils.cc7
-rw-r--r--components/storage_monitor/media_storage_util.cc1
-rw-r--r--components/storage_monitor/media_storage_util.h2
-rw-r--r--components/storage_monitor/media_transfer_protocol_device_observer_linux.h1
-rw-r--r--components/storage_monitor/media_transfer_protocol_device_observer_linux_unittest.cc1
-rw-r--r--components/storage_monitor/mtab_watcher_linux.cc2
-rw-r--r--components/storage_monitor/mtab_watcher_linux.h3
-rw-r--r--components/storage_monitor/portable_device_watcher_win.h1
-rw-r--r--components/storage_monitor/removable_device_constants.cc1
-rw-r--r--components/storage_monitor/storage_info.cc9
-rw-r--r--components/storage_monitor/storage_info.h8
-rw-r--r--components/storage_monitor/storage_monitor.h1
-rw-r--r--components/storage_monitor/storage_monitor_chromeos.h3
-rw-r--r--components/storage_monitor/storage_monitor_chromeos_unittest.cc17
-rw-r--r--components/storage_monitor/storage_monitor_linux.cc1
-rw-r--r--components/storage_monitor/storage_monitor_linux.h1
-rw-r--r--components/storage_monitor/storage_monitor_linux_unittest.cc9
-rw-r--r--components/storage_monitor/storage_monitor_mac.h1
-rw-r--r--components/storage_monitor/storage_monitor_mac.mm4
-rw-r--r--components/storage_monitor/storage_monitor_mac_unittest.mm13
-rw-r--r--components/storage_monitor/storage_monitor_win.cc1
-rw-r--r--components/storage_monitor/storage_monitor_win.h2
-rw-r--r--components/storage_monitor/storage_monitor_win_unittest.cc2
-rw-r--r--components/storage_monitor/test_media_transfer_protocol_manager_linux.h2
-rw-r--r--components/storage_monitor/test_portable_device_watcher_win.h1
-rw-r--r--components/storage_monitor/test_storage_monitor.cc1
-rw-r--r--components/storage_monitor/test_storage_monitor.h1
-rw-r--r--components/storage_monitor/test_storage_monitor_win.h1
-rw-r--r--components/storage_monitor/test_volume_mount_watcher_win.cc2
-rw-r--r--components/storage_monitor/test_volume_mount_watcher_win.h5
-rw-r--r--components/storage_monitor/transient_device_ids.h2
-rw-r--r--components/storage_monitor/volume_mount_watcher_win.cc8
-rw-r--r--components/storage_monitor/volume_mount_watcher_win.h2
-rw-r--r--components/suggestions/blacklist_store.cc2
-rw-r--r--components/suggestions/blacklist_store_unittest.cc1
-rw-r--r--components/suggestions/image_encoder_ios.mm1
-rw-r--r--components/suggestions/image_fetcher.h1
-rw-r--r--components/suggestions/image_fetcher_delegate.h2
-rw-r--r--components/suggestions/image_manager.h2
-rw-r--r--components/suggestions/suggestions_service.cc11
-rw-r--r--components/suggestions/suggestions_service.h6
-rw-r--r--components/suggestions/suggestions_service_unittest.cc7
-rw-r--r--components/suggestions/suggestions_store.cc4
-rw-r--r--components/suggestions/suggestions_store_unittest.cc13
-rw-r--r--components/sync_bookmarks/bookmark_change_processor.cc48
-rw-r--r--components/sync_bookmarks/bookmark_change_processor.h33
-rw-r--r--components/sync_bookmarks/bookmark_data_type_controller.h1
-rw-r--r--components/sync_bookmarks/bookmark_model_associator.cc70
-rw-r--r--components/sync_bookmarks/bookmark_model_associator.h38
-rw-r--r--components/sync_driver/backend_migrator.h1
-rw-r--r--components/sync_driver/backup_rollback_controller.h1
-rw-r--r--components/sync_driver/change_processor.h5
-rw-r--r--components/sync_driver/change_processor_mock.h5
-rw-r--r--components/sync_driver/data_type_encryption_handler.h1
-rw-r--r--components/sync_driver/data_type_manager_impl.h2
-rw-r--r--components/sync_driver/device_info.h2
-rw-r--r--components/sync_driver/device_info_data_type_controller.h1
-rw-r--r--components/sync_driver/device_info_service.h8
-rw-r--r--components/sync_driver/device_info_sync_service.cc4
-rw-r--r--components/sync_driver/device_info_sync_service.h9
-rw-r--r--components/sync_driver/device_info_sync_service_unittest.cc5
-rw-r--r--components/sync_driver/fake_generic_change_processor.h1
-rw-r--r--components/sync_driver/fake_sync_client.h1
-rw-r--r--components/sync_driver/frontend_data_type_controller.h2
-rw-r--r--components/sync_driver/generic_change_processor.cc10
-rw-r--r--components/sync_driver/generic_change_processor.h5
-rw-r--r--components/sync_driver/generic_change_processor_factory.h1
-rw-r--r--components/sync_driver/generic_change_processor_unittest.cc2
-rw-r--r--components/sync_driver/glue/browser_thread_model_worker.h2
-rw-r--r--components/sync_driver/glue/sync_backend_host.h2
-rw-r--r--components/sync_driver/glue/sync_backend_host_core.cc2
-rw-r--r--components/sync_driver/glue/sync_backend_host_core.h8
-rw-r--r--components/sync_driver/glue/sync_backend_host_impl.cc4
-rw-r--r--components/sync_driver/glue/sync_backend_host_impl.h6
-rw-r--r--components/sync_driver/glue/sync_backend_host_impl_unittest.cc6
-rw-r--r--components/sync_driver/glue/sync_backend_registrar.cc2
-rw-r--r--components/sync_driver/glue/sync_backend_registrar.h6
-rw-r--r--components/sync_driver/glue/ui_model_worker.h1
-rw-r--r--components/sync_driver/glue/ui_model_worker_unittest.cc1
-rw-r--r--components/sync_driver/invalidation_adapter.cc2
-rw-r--r--components/sync_driver/invalidation_adapter.h4
-rw-r--r--components/sync_driver/local_device_info_provider_impl.cc1
-rw-r--r--components/sync_driver/model_association_manager.cc6
-rw-r--r--components/sync_driver/model_association_manager.h1
-rw-r--r--components/sync_driver/model_associator.h9
-rw-r--r--components/sync_driver/non_blocking_data_type_controller.h1
-rw-r--r--components/sync_driver/non_ui_data_type_controller.h1
-rw-r--r--components/sync_driver/non_ui_data_type_controller_unittest.cc1
-rw-r--r--components/sync_driver/pref_names.cc1
-rw-r--r--components/sync_driver/profile_sync_auth_provider.cc1
-rw-r--r--components/sync_driver/profile_sync_auth_provider.h1
-rw-r--r--components/sync_driver/proxy_data_type_controller.h2
-rw-r--r--components/sync_driver/shared_change_processor.h1
-rw-r--r--components/sync_driver/signin_manager_wrapper.h3
-rw-r--r--components/sync_driver/sync_error_controller.h2
-rw-r--r--components/sync_driver/sync_frontend.h1
-rw-r--r--components/sync_driver/sync_policy_handler.h1
-rw-r--r--components/sync_driver/sync_prefs.cc6
-rw-r--r--components/sync_driver/sync_prefs.h9
-rw-r--r--components/sync_driver/sync_prefs_unittest.cc6
-rw-r--r--components/sync_driver/sync_stopped_reporter.h1
-rw-r--r--components/sync_driver/sync_stopped_reporter_unittest.cc1
-rw-r--r--components/sync_driver/sync_util.cc1
-rw-r--r--components/sync_driver/system_encryptor_unittest.cc1
-rw-r--r--components/sync_driver/ui_data_type_controller.h2
-rw-r--r--components/sync_sessions/favicon_cache.cc10
-rw-r--r--components/sync_sessions/favicon_cache.h9
-rw-r--r--components/sync_sessions/favicon_cache_unittest.cc10
-rw-r--r--components/sync_sessions/local_session_event_router.h1
-rw-r--r--components/sync_sessions/open_tabs_ui_delegate.h1
-rw-r--r--components/sync_sessions/revisit/current_tab_matcher.h1
-rw-r--r--components/sync_sessions/revisit/offset_tab_matcher.cc2
-rw-r--r--components/sync_sessions/revisit/offset_tab_matcher.h1
-rw-r--r--components/sync_sessions/revisit/page_revisit_broadcaster.cc1
-rw-r--r--components/sync_sessions/revisit/page_revisit_broadcaster_unittest.cc4
-rw-r--r--components/sync_sessions/revisit/sessions_page_revisit_observer.h1
-rw-r--r--components/sync_sessions/revisit/typed_url_page_revisit_observer.h1
-rw-r--r--components/sync_sessions/revisit/typed_url_page_revisit_task.h1
-rw-r--r--components/sync_sessions/sessions_sync_manager.cc1
-rw-r--r--components/sync_sessions/sessions_sync_manager.h4
-rw-r--r--components/sync_sessions/synced_session_tracker.h4
-rw-r--r--components/sync_sessions/tab_node_pool.h4
-rw-r--r--components/sync_sessions/tab_node_pool_unittest.cc2
-rw-r--r--components/syncable_prefs/pref_model_associator.h2
-rw-r--r--components/syncable_prefs/pref_service_mock_factory.h1
-rw-r--r--components/syncable_prefs/pref_service_syncable.cc2
-rw-r--r--components/syncable_prefs/pref_service_syncable.h5
-rw-r--r--components/syncable_prefs/pref_service_syncable_factory.h1
-rw-r--r--components/syncable_prefs/pref_service_syncable_unittest.cc12
-rw-r--r--components/syncable_prefs/synced_pref_change_registrar.h1
-rw-r--r--components/syncable_prefs/testing_pref_service_syncable.h2
-rw-r--r--components/test/run_all_unittests.cc2
-rw-r--r--components/test_runner/accessibility_controller.cc1
-rw-r--r--components/test_runner/accessibility_controller.h1
-rw-r--r--components/test_runner/app_banner_client.h1
-rw-r--r--components/test_runner/blink_test_platform_support_linux.cc3
-rw-r--r--components/test_runner/blink_test_platform_support_mac.mm1
-rw-r--r--components/test_runner/blink_test_platform_support_win.cc2
-rw-r--r--components/test_runner/event_sender.cc5
-rw-r--r--components/test_runner/event_sender.h4
-rw-r--r--components/test_runner/gamepad_controller.cc3
-rw-r--r--components/test_runner/gamepad_controller.h1
-rw-r--r--components/test_runner/gc_controller.h2
-rw-r--r--components/test_runner/mock_color_chooser.h2
-rw-r--r--components/test_runner/mock_constraints.cc2
-rw-r--r--components/test_runner/mock_credential_manager_client.h1
-rw-r--r--components/test_runner/mock_grammar_check.cc3
-rw-r--r--components/test_runner/mock_spell_check.cc3
-rw-r--r--components/test_runner/mock_spell_check.h2
-rw-r--r--components/test_runner/mock_web_media_stream_center.cc3
-rw-r--r--components/test_runner/mock_web_media_stream_center.h2
-rw-r--r--components/test_runner/mock_web_midi_accessor.cc1
-rw-r--r--components/test_runner/mock_web_midi_accessor.h4
-rw-r--r--components/test_runner/mock_web_speech_recognizer.cc3
-rw-r--r--components/test_runner/mock_web_speech_recognizer.h2
-rw-r--r--components/test_runner/mock_web_theme_engine.cc1
-rw-r--r--components/test_runner/mock_web_theme_engine.h1
-rw-r--r--components/test_runner/mock_web_user_media_client.cc2
-rw-r--r--components/test_runner/mock_web_user_media_client.h1
-rw-r--r--components/test_runner/mock_webrtc_data_channel_handler.h4
-rw-r--r--components/test_runner/mock_webrtc_dtmf_sender_handler.h2
-rw-r--r--components/test_runner/mock_webrtc_peer_connection_handler.cc2
-rw-r--r--components/test_runner/mock_webrtc_peer_connection_handler.h2
-rw-r--r--components/test_runner/spell_check_client.cc3
-rw-r--r--components/test_runner/spell_check_client.h4
-rw-r--r--components/test_runner/test_common.cc2
-rw-r--r--components/test_runner/test_info_extractor.cc1
-rw-r--r--components/test_runner/test_info_extractor.h3
-rw-r--r--components/test_runner/test_interfaces.cc2
-rw-r--r--components/test_runner/test_interfaces.h2
-rw-r--r--components/test_runner/test_plugin.cc20
-rw-r--r--components/test_runner/test_plugin.h2
-rw-r--r--components/test_runner/test_runner.cc3
-rw-r--r--components/test_runner/test_runner.h5
-rw-r--r--components/test_runner/text_input_controller.cc1
-rw-r--r--components/test_runner/web_ax_object_proxy.cc3
-rw-r--r--components/test_runner/web_ax_object_proxy.h4
-rw-r--r--components/test_runner/web_frame_test_proxy.h2
-rw-r--r--components/test_runner/web_test_interfaces.h1
-rw-r--r--components/test_runner/web_test_proxy.cc3
-rw-r--r--components/test_runner/web_test_proxy.h3
-rw-r--r--components/timers/alarm_timer_chromeos.cc1
-rw-r--r--components/toolbar/toolbar_model.h4
-rw-r--r--components/tracing/child_memory_dump_manager_delegate_impl.cc2
-rw-r--r--components/tracing/child_memory_dump_manager_delegate_impl.h9
-rw-r--r--components/tracing/child_trace_message_filter.cc6
-rw-r--r--components/tracing/child_trace_message_filter.h11
-rw-r--r--components/tracing/child_trace_message_filter_browsertest.cc20
-rw-r--r--components/tracing/graphics_memory_dump_provider_android.cc3
-rw-r--r--components/tracing/graphics_memory_dump_provider_android.h3
-rw-r--r--components/tracing/trace_config_file.cc3
-rw-r--r--components/tracing/trace_config_file.h1
-rw-r--r--components/tracing/tracing_messages.h10
-rw-r--r--components/translate/content/browser/content_translate_driver.h2
-rw-r--r--components/translate/content/browser/data_file_browser_cld_data_provider.cc21
-rw-r--r--components/translate/content/browser/data_file_browser_cld_data_provider.h6
-rw-r--r--components/translate/content/common/data_file_cld_data_provider_messages.h6
-rw-r--r--components/translate/content/renderer/data_file_renderer_cld_data_provider.cc13
-rw-r--r--components/translate/content/renderer/data_file_renderer_cld_data_provider.h10
-rw-r--r--components/translate/content/renderer/translate_helper.h1
-rw-r--r--components/translate/core/browser/language_state.h2
-rw-r--r--components/translate/core/browser/language_state_unittest.cc1
-rw-r--r--components/translate/core/browser/options_menu_model.cc1
-rw-r--r--components/translate/core/browser/options_menu_model.h1
-rw-r--r--components/translate/core/browser/translate_accept_languages.cc2
-rw-r--r--components/translate/core/browser/translate_accept_languages.h2
-rw-r--r--components/translate/core/browser/translate_browser_metrics.cc4
-rw-r--r--components/translate/core/browser/translate_browser_metrics_unittest.cc2
-rw-r--r--components/translate/core/browser/translate_infobar_delegate.cc1
-rw-r--r--components/translate/core/browser/translate_infobar_delegate.h4
-rw-r--r--components/translate/core/browser/translate_language_list.cc3
-rw-r--r--components/translate/core/browser/translate_language_list.h1
-rw-r--r--components/translate/core/browser/translate_manager.h1
-rw-r--r--components/translate/core/browser/translate_manager_unittest.cc1
-rw-r--r--components/translate/core/browser/translate_prefs.cc1
-rw-r--r--components/translate/core/browser/translate_prefs.h4
-rw-r--r--components/translate/core/browser/translate_prefs_unittest.cc1
-rw-r--r--components/translate/core/browser/translate_script.cc1
-rw-r--r--components/translate/core/browser/translate_script.h1
-rw-r--r--components/translate/core/browser/translate_script_unittest.cc2
-rw-r--r--components/translate/core/browser/translate_step.h2
-rw-r--r--components/translate/core/browser/translate_ui_delegate.h3
-rw-r--r--components/translate/core/browser/translate_url_fetcher.h1
-rw-r--r--components/translate/core/common/translate_errors.h2
-rw-r--r--components/translate/core/common/translate_metrics.cc26
-rw-r--r--components/translate/core/common/translate_metrics_unittest.cc2
-rw-r--r--components/translate/core/common/translate_util.cc4
-rw-r--r--components/translate/core/language_detection/language_detection_util.cc3
-rw-r--r--components/translate/ios/browser/ios_translate_driver.h2
-rw-r--r--components/translate/ios/browser/js_language_detection_manager.h1
-rw-r--r--components/ui/zoom/page_zoom.cc2
-rw-r--r--components/ui/zoom/page_zoom_constants.h2
-rw-r--r--components/ui/zoom/zoom_controller.h2
-rw-r--r--components/ui/zoom/zoom_event_manager.h1
-rw-r--r--components/undo/bookmark_undo_service.cc16
-rw-r--r--components/undo/bookmark_undo_service.h1
-rw-r--r--components/undo/bookmark_undo_service_test.cc3
-rw-r--r--components/undo/bookmark_undo_utils.h2
-rw-r--r--components/undo/undo_manager.h4
-rw-r--r--components/undo/undo_manager_test.cc1
-rw-r--r--components/update_client/action.h2
-rw-r--r--components/update_client/action_update_check.cc2
-rw-r--r--components/update_client/background_downloader_win.cc1
-rw-r--r--components/update_client/component_unpacker.cc1
-rw-r--r--components/update_client/crx_downloader.cc1
-rw-r--r--components/update_client/crx_downloader_unittest.cc1
-rw-r--r--components/update_client/ping_manager.cc2
-rw-r--r--components/update_client/test_configurator.h2
-rw-r--r--components/update_client/update_checker.cc2
-rw-r--r--components/update_client/update_client_unittest.cc1
-rw-r--r--components/update_client/update_query_params.cc1
-rw-r--r--components/update_client/update_query_params.h2
-rw-r--r--components/update_client/update_query_params_delegate.h2
-rw-r--r--components/update_client/update_response.cc2
-rw-r--r--components/update_client/utils.cc2
-rw-r--r--components/upload_list/upload_list.cc2
-rw-r--r--components/upload_list/upload_list.h1
-rw-r--r--components/upload_list/upload_list_unittest.cc2
-rw-r--r--components/url_formatter/elide_url.cc3
-rw-r--r--components/url_formatter/elide_url.h1
-rw-r--r--components/url_formatter/elide_url_unittest.cc4
-rw-r--r--components/url_formatter/url_fixer.cc10
-rw-r--r--components/url_formatter/url_fixer_unittest.cc4
-rw-r--r--components/url_formatter/url_formatter.h1
-rw-r--r--components/url_formatter/url_formatter_unittest.cc1
-rw-r--r--components/url_matcher/regex_set_matcher.cc2
-rw-r--r--components/url_matcher/string_pattern.h2
-rw-r--r--components/url_matcher/substring_set_matcher.cc41
-rw-r--r--components/url_matcher/substring_set_matcher.h18
-rw-r--r--components/url_matcher/substring_set_matcher_unittest.cc2
-rw-r--r--components/url_matcher/url_matcher.h3
-rw-r--r--components/url_matcher/url_matcher_factory.cc1
-rw-r--r--components/url_matcher/url_matcher_factory.h2
-rw-r--r--components/url_matcher/url_matcher_factory_unittest.cc4
-rw-r--r--components/url_matcher/url_matcher_helpers.cc2
-rw-r--r--components/url_matcher/url_matcher_unittest.cc3
-rw-r--r--components/user_manager/empty_user_info.h1
-rw-r--r--components/user_manager/fake_user_manager.h1
-rw-r--r--components/user_manager/known_user.cc2
-rw-r--r--components/user_manager/user.cc3
-rw-r--r--components/user_manager/user.h2
-rw-r--r--components/user_manager/user_image/default_user_images.cc2
-rw-r--r--components/user_manager/user_image/default_user_images.h3
-rw-r--r--components/user_manager/user_info_impl.h1
-rw-r--r--components/user_manager/user_manager.h1
-rw-r--r--components/user_manager/user_manager_base.cc3
-rw-r--r--components/user_manager/user_manager_base.h2
-rw-r--r--components/user_prefs/tracked/dictionary_hash_store_contents.cc1
-rw-r--r--components/user_prefs/tracked/mock_validation_delegate.h2
-rw-r--r--components/user_prefs/tracked/pref_hash_calculator.cc6
-rw-r--r--components/user_prefs/tracked/pref_hash_calculator.h2
-rw-r--r--components/user_prefs/tracked/pref_hash_calculator_unittest.cc1
-rw-r--r--components/user_prefs/tracked/pref_hash_filter.cc7
-rw-r--r--components/user_prefs/tracked/pref_hash_filter.h4
-rw-r--r--components/user_prefs/tracked/pref_hash_filter_unittest.cc4
-rw-r--r--components/user_prefs/tracked/pref_hash_store_impl.cc3
-rw-r--r--components/user_prefs/tracked/segregated_pref_store.cc8
-rw-r--r--components/user_prefs/tracked/segregated_pref_store.h10
-rw-r--r--components/user_prefs/tracked/tracked_atomic_preference.h2
-rw-r--r--components/user_prefs/tracked/tracked_preference_helper.h2
-rw-r--r--components/user_prefs/tracked/tracked_preferences_migration_unittest.cc1
-rw-r--r--components/user_prefs/tracked/tracked_split_preference.h2
-rw-r--r--components/user_prefs/user_prefs.h2
-rw-r--r--components/variations/active_field_trials.cc2
-rw-r--r--components/variations/active_field_trials.h7
-rw-r--r--components/variations/active_field_trials_unittest.cc2
-rw-r--r--components/variations/android/component_jni_registrar.cc2
-rw-r--r--components/variations/android/variations_seed_bridge.cc5
-rw-r--r--components/variations/caching_permuted_entropy_provider.cc16
-rw-r--r--components/variations/caching_permuted_entropy_provider.h13
-rw-r--r--components/variations/caching_permuted_entropy_provider_unittest.cc4
-rw-r--r--components/variations/entropy_provider.cc35
-rw-r--r--components/variations/entropy_provider.h25
-rw-r--r--components/variations/entropy_provider_unittest.cc28
-rw-r--r--components/variations/experiment_labels_unittest.cc4
-rw-r--r--components/variations/metrics_util.cc4
-rw-r--r--components/variations/metrics_util.h9
-rw-r--r--components/variations/metrics_util_unittest.cc6
-rw-r--r--components/variations/net/variations_http_headers.cc3
-rw-r--r--components/variations/net/variations_http_headers_unittest.cc2
-rw-r--r--components/variations/service/ui_string_overrider.h4
-rw-r--r--components/variations/service/ui_string_overrider_unittest.cc4
-rw-r--r--components/variations/service/variations_service.cc10
-rw-r--r--components/variations/service/variations_service.h1
-rw-r--r--components/variations/service/variations_service_unittest.cc3
-rw-r--r--components/variations/study_filtering.cc6
-rw-r--r--components/variations/study_filtering_unittest.cc7
-rw-r--r--components/variations/synthetic_trials.h2
-rw-r--r--components/variations/variations_associated_data.cc1
-rw-r--r--components/variations/variations_associated_data_unittest.cc1
-rw-r--r--components/variations/variations_http_header_provider.cc2
-rw-r--r--components/variations/variations_http_header_provider.h2
-rw-r--r--components/variations/variations_request_scheduler.cc3
-rw-r--r--components/variations/variations_request_scheduler.h1
-rw-r--r--components/variations/variations_request_scheduler_mobile.h1
-rw-r--r--components/variations/variations_seed_processor.cc4
-rw-r--r--components/variations/variations_seed_processor.h3
-rw-r--r--components/variations/variations_seed_processor_unittest.cc6
-rw-r--r--components/variations/variations_seed_simulator.cc2
-rw-r--r--components/variations/variations_seed_simulator.h1
-rw-r--r--components/variations/variations_seed_simulator_unittest.cc5
-rw-r--r--components/variations/variations_seed_store.cc29
-rw-r--r--components/variations/variations_seed_store.h2
-rw-r--r--components/variations/variations_seed_store_unittest.cc2
-rw-r--r--components/visitedlink/browser/visitedlink_event_listener.h1
-rw-r--r--components/visitedlink/browser/visitedlink_master.cc109
-rw-r--r--components/visitedlink/browser/visitedlink_master.h64
-rw-r--r--components/visitedlink/common/visitedlink_common.cc6
-rw-r--r--components/visitedlink/common/visitedlink_common.h30
-rw-r--r--components/visitedlink/common/visitedlink_messages.h6
-rw-r--r--components/visitedlink/renderer/visitedlink_slave.cc5
-rw-r--r--components/visitedlink/renderer/visitedlink_slave.h1
-rw-r--r--components/visitedlink/test/visitedlink_unittest.cc22
-rw-r--r--components/wallpaper/wallpaper_manager_base.h3
-rw-r--r--components/wallpaper/wallpaper_resizer.h3
-rw-r--r--components/wallpaper/wallpaper_resizer_unittest.cc3
-rw-r--r--components/web_cache/browser/web_cache_manager.cc2
-rw-r--r--components/web_cache/browser/web_cache_manager.h4
-rw-r--r--components/web_cache/browser/web_cache_manager_unittest.cc2
-rw-r--r--components/web_cache/common/web_cache_messages.h3
-rw-r--r--components/web_cache/renderer/web_cache_render_process_observer.h2
-rw-r--r--components/web_contents_delegate_android/color_chooser_android.cc2
-rw-r--r--components/web_contents_delegate_android/color_chooser_android.h3
-rw-r--r--components/web_contents_delegate_android/component_jni_registrar.cc1
-rw-r--r--components/web_contents_delegate_android/web_contents_delegate_android.cc7
-rw-r--r--components/web_contents_delegate_android/web_contents_delegate_android.h6
-rw-r--r--components/web_modal/single_web_contents_dialog_manager.h1
-rw-r--r--components/web_modal/test_web_contents_modal_dialog_host.h2
-rw-r--r--components/web_modal/test_web_contents_modal_dialog_manager_delegate.h2
-rw-r--r--components/web_modal/web_contents_modal_dialog_manager.h1
-rw-r--r--components/web_modal/web_contents_modal_dialog_manager_unittest.cc1
-rw-r--r--components/web_resource/eula_accepted_notifier.cc1
-rw-r--r--components/web_resource/eula_accepted_notifier.h2
-rw-r--r--components/web_resource/eula_accepted_notifier_unittest.cc1
-rw-r--r--components/web_resource/notification_promo.cc4
-rw-r--r--components/web_resource/notification_promo.h2
-rw-r--r--components/web_resource/notification_promo_mobile_ntp.h2
-rw-r--r--components/web_resource/promo_resource_service.cc10
-rw-r--r--components/web_resource/promo_resource_service.h5
-rw-r--r--components/web_resource/promo_resource_service_mobile_ntp_unittest.cc2
-rw-r--r--components/web_resource/promo_resource_service_unittest.cc2
-rw-r--r--components/web_resource/resource_request_allowed_notifier.h1
-rw-r--r--components/web_resource/resource_request_allowed_notifier_test_util.h1
-rw-r--r--components/web_resource/resource_request_allowed_notifier_unittest.cc1
-rw-r--r--components/web_resource/web_resource_service.cc8
-rw-r--r--components/web_resource/web_resource_service.h5
-rw-r--r--components/web_view/client_initiated_frame_connection.h2
-rw-r--r--components/web_view/find_controller.h4
-rw-r--r--components/web_view/frame.cc6
-rw-r--r--components/web_view/frame.h8
-rw-r--r--components/web_view/frame_apptest.cc4
-rw-r--r--components/web_view/frame_connection.cc1
-rw-r--r--components/web_view/frame_connection.h4
-rw-r--r--components/web_view/frame_devtools_agent.cc1
-rw-r--r--components/web_view/frame_devtools_agent.h2
-rw-r--r--components/web_view/frame_tree.h3
-rw-r--r--components/web_view/frame_tree_delegate.h2
-rw-r--r--components/web_view/navigation_controller.h1
-rw-r--r--components/web_view/navigation_entry.h1
-rw-r--r--components/web_view/pending_web_view_load.h1
-rw-r--r--components/web_view/public/cpp/web_view.cc4
-rw-r--r--components/web_view/test_frame_tree_delegate.h2
-rw-r--r--components/web_view/test_runner/test_runner_application_delegate.cc1
-rw-r--r--components/web_view/test_runner/test_runner_application_delegate.h3
-rw-r--r--components/web_view/url_request_cloneable.cc2
-rw-r--r--components/web_view/url_request_cloneable.h4
-rw-r--r--components/web_view/web_view_apptest.cc3
-rw-r--r--components/web_view/web_view_impl.h2
-rw-r--r--components/webcrypto/algorithms/aes.cc2
-rw-r--r--components/webcrypto/algorithms/aes.h2
-rw-r--r--components/webcrypto/algorithms/aes_cbc.cc2
-rw-r--r--components/webcrypto/algorithms/aes_cbc_unittest.cc4
-rw-r--r--components/webcrypto/algorithms/aes_ctr.cc3
-rw-r--r--components/webcrypto/algorithms/aes_ctr_unittest.cc10
-rw-r--r--components/webcrypto/algorithms/aes_gcm.cc2
-rw-r--r--components/webcrypto/algorithms/aes_gcm_unittest.cc4
-rw-r--r--components/webcrypto/algorithms/aes_kw.cc2
-rw-r--r--components/webcrypto/algorithms/aes_kw_unittest.cc4
-rw-r--r--components/webcrypto/algorithms/asymmetric_key_util.cc1
-rw-r--r--components/webcrypto/algorithms/ec.cc2
-rw-r--r--components/webcrypto/algorithms/ec.h2
-rw-r--r--components/webcrypto/algorithms/ecdh.cc2
-rw-r--r--components/webcrypto/algorithms/ecdh_unittest.cc3
-rw-r--r--components/webcrypto/algorithms/ecdsa.cc2
-rw-r--r--components/webcrypto/algorithms/ecdsa_unittest.cc3
-rw-r--r--components/webcrypto/algorithms/hkdf.cc1
-rw-r--r--components/webcrypto/algorithms/hmac.cc2
-rw-r--r--components/webcrypto/algorithms/hmac_unittest.cc3
-rw-r--r--components/webcrypto/algorithms/pbkdf2.cc2
-rw-r--r--components/webcrypto/algorithms/rsa.h2
-rw-r--r--components/webcrypto/algorithms/rsa_oaep.cc2
-rw-r--r--components/webcrypto/algorithms/rsa_oaep_unittest.cc4
-rw-r--r--components/webcrypto/algorithms/rsa_pss.cc2
-rw-r--r--components/webcrypto/algorithms/rsa_pss_unittest.cc3
-rw-r--r--components/webcrypto/algorithms/rsa_sign.cc2
-rw-r--r--components/webcrypto/algorithms/rsa_ssa.cc2
-rw-r--r--components/webcrypto/algorithms/rsa_ssa_unittest.cc4
-rw-r--r--components/webcrypto/algorithms/secret_key_util.h2
-rw-r--r--components/webcrypto/algorithms/sha.cc1
-rw-r--r--components/webcrypto/algorithms/sha_unittest.cc3
-rw-r--r--components/webcrypto/algorithms/test_helpers.cc3
-rw-r--r--components/webcrypto/algorithms/test_helpers.h2
-rw-r--r--components/webcrypto/algorithms/util.h2
-rw-r--r--components/webcrypto/crypto_data.h1
-rw-r--r--components/webcrypto/jwk.cc3
-rw-r--r--components/webcrypto/status.h2
-rw-r--r--components/webcrypto/webcrypto_impl.cc2
-rw-r--r--components/webcrypto/webcrypto_impl.h2
-rw-r--r--components/webdata/common/web_data_request_manager.h3
-rw-r--r--components/webdata/common/web_data_results.h29
-rw-r--r--components/webdata/common/web_data_service_base.h1
-rw-r--r--components/webdata/common/web_database.h1
-rw-r--r--components/webdata/common/web_database_backend.h2
-rw-r--r--components/webdata/common/web_database_migration_unittest.cc1
-rw-r--r--components/webdata/common/web_database_service.cc2
-rw-r--r--components/webdata/common/web_database_service.h2
-rw-r--r--components/webdata/common/web_database_table.h1
-rw-r--r--components/webdata_services/web_data_service_test_util.h2
-rw-r--r--components/webdata_services/web_data_service_wrapper.cc1
-rw-r--r--components/webdata_services/web_data_service_wrapper.h1
-rw-r--r--components/webp_transcode/webp_decoder.h1
-rw-r--r--components/webp_transcode/webp_decoder.mm1
-rw-r--r--components/webp_transcode/webp_decoder_unittest.mm4
-rw-r--r--components/webp_transcode/webp_network_client.mm2
-rw-r--r--components/webp_transcode/webp_network_client_unittest.mm3
-rw-r--r--components/webusb/webusb_detector.h1
-rw-r--r--components/wifi/network_properties.cc2
-rw-r--r--components/wifi/network_properties.h8
-rw-r--r--components/wifi/wifi_service.h1
-rw-r--r--components/wifi/wifi_service_mac.mm1
-rw-r--r--components/wifi/wifi_service_win.cc5
-rw-r--r--components/wifi/wifi_test.cc1
-rw-r--r--components/wifi_sync/wifi_config_delegate_chromeos_unittest.cc2
-rw-r--r--components/wifi_sync/wifi_credential_syncable_service_factory.cc1
-rw-r--r--components/wifi_sync/wifi_credential_syncable_service_factory.h1
-rw-r--r--components/wifi_sync/wifi_credential_syncable_service_unittest.cc2
-rw-r--r--components/wifi_sync/wifi_security_class.h1
477 files changed, 1406 insertions, 652 deletions
diff --git a/components/startup_metric_utils/browser/startup_metric_utils.cc b/components/startup_metric_utils/browser/startup_metric_utils.cc
index 76491ff..914c960 100644
--- a/components/startup_metric_utils/browser/startup_metric_utils.cc
+++ b/components/startup_metric_utils/browser/startup_metric_utils.cc
@@ -4,6 +4,8 @@
#include "components/startup_metric_utils/browser/startup_metric_utils.h"
+#include <stddef.h>
+
#include "base/containers/hash_tables.h"
#include "base/environment.h"
#include "base/lazy_instance.h"
@@ -13,6 +15,7 @@
#include "base/sys_info.h"
#include "base/threading/platform_thread.h"
#include "base/trace_event/trace_event.h"
+#include "build/build_config.h"
#if defined(OS_WIN)
#include <winternl.h>
@@ -227,7 +230,7 @@ void RecordMainEntryTimeHistogram() {
const base::TimeDelta browser_main_entry_time_absolute =
g_browser_main_entry_point_time.Get() - base::Time::UnixEpoch();
- const uint64 browser_main_entry_time_raw_ms =
+ const uint64_t browser_main_entry_time_raw_ms =
browser_main_entry_time_absolute.InMilliseconds();
const base::TimeDelta browser_main_entry_time_raw_ms_high_word =
@@ -271,7 +274,7 @@ const char kChromeMainTicksEnvVar[] = "CHROME_MAIN_TICKS";
base::TimeTicks ExeMainEntryPointTicks() {
scoped_ptr<base::Environment> env(base::Environment::Create());
std::string ticks_string;
- int64 time_int = 0;
+ int64_t time_int = 0;
if (env->GetVar(kChromeMainTicksEnvVar, &ticks_string) &&
base::StringToInt64(ticks_string, &time_int)) {
return base::TimeTicks::FromInternalValue(time_int);
diff --git a/components/storage_monitor/media_storage_util.cc b/components/storage_monitor/media_storage_util.cc
index b9f321a..7b3b2c1 100644
--- a/components/storage_monitor/media_storage_util.cc
+++ b/components/storage_monitor/media_storage_util.cc
@@ -12,6 +12,7 @@
#include "base/metrics/histogram_macros.h"
#include "base/strings/string_util.h"
#include "base/strings/utf_string_conversions.h"
+#include "build/build_config.h"
#include "components/storage_monitor/removable_device_constants.h"
#include "components/storage_monitor/storage_monitor.h"
#include "content/public/browser/browser_thread.h"
diff --git a/components/storage_monitor/media_storage_util.h b/components/storage_monitor/media_storage_util.h
index 12dcd46..99c14d6 100644
--- a/components/storage_monitor/media_storage_util.h
+++ b/components/storage_monitor/media_storage_util.h
@@ -11,9 +11,9 @@
#include <set>
#include <string>
-#include "base/basictypes.h"
#include "base/callback_forward.h"
#include "base/files/file_path.h"
+#include "base/macros.h"
namespace storage_monitor {
diff --git a/components/storage_monitor/media_transfer_protocol_device_observer_linux.h b/components/storage_monitor/media_transfer_protocol_device_observer_linux.h
index 50467ad..611d0da 100644
--- a/components/storage_monitor/media_transfer_protocol_device_observer_linux.h
+++ b/components/storage_monitor/media_transfer_protocol_device_observer_linux.h
@@ -8,6 +8,7 @@
#include <map>
#include <string>
+#include "base/macros.h"
#include "base/strings/string16.h"
#include "components/storage_monitor/storage_monitor.h"
#include "device/media_transfer_protocol/media_transfer_protocol_manager.h"
diff --git a/components/storage_monitor/media_transfer_protocol_device_observer_linux_unittest.cc b/components/storage_monitor/media_transfer_protocol_device_observer_linux_unittest.cc
index 10f6e9a..413f811 100644
--- a/components/storage_monitor/media_transfer_protocol_device_observer_linux_unittest.cc
+++ b/components/storage_monitor/media_transfer_protocol_device_observer_linux_unittest.cc
@@ -8,6 +8,7 @@
#include <string>
+#include "base/macros.h"
#include "base/memory/scoped_ptr.h"
#include "base/run_loop.h"
#include "base/strings/utf_string_conversions.h"
diff --git a/components/storage_monitor/mtab_watcher_linux.cc b/components/storage_monitor/mtab_watcher_linux.cc
index 31dda98..2de7369 100644
--- a/components/storage_monitor/mtab_watcher_linux.cc
+++ b/components/storage_monitor/mtab_watcher_linux.cc
@@ -7,9 +7,11 @@
#include "components/storage_monitor/mtab_watcher_linux.h"
#include <mntent.h>
+#include <stddef.h>
#include <stdio.h>
#include "base/bind.h"
+#include "base/macros.h"
#include "content/public/browser/browser_thread.h"
namespace {
diff --git a/components/storage_monitor/mtab_watcher_linux.h b/components/storage_monitor/mtab_watcher_linux.h
index 206ed53..0a39fe3 100644
--- a/components/storage_monitor/mtab_watcher_linux.h
+++ b/components/storage_monitor/mtab_watcher_linux.h
@@ -15,10 +15,11 @@
#include <map>
-#include "base/basictypes.h"
#include "base/files/file_path.h"
#include "base/files/file_path_watcher.h"
+#include "base/macros.h"
#include "base/memory/weak_ptr.h"
+#include "build/build_config.h"
namespace storage_monitor {
diff --git a/components/storage_monitor/portable_device_watcher_win.h b/components/storage_monitor/portable_device_watcher_win.h
index 4708c81..becb7ea 100644
--- a/components/storage_monitor/portable_device_watcher_win.h
+++ b/components/storage_monitor/portable_device_watcher_win.h
@@ -11,6 +11,7 @@
#include <string>
#include <vector>
+#include "base/macros.h"
#include "base/memory/ref_counted.h"
#include "base/memory/weak_ptr.h"
#include "base/strings/string16.h"
diff --git a/components/storage_monitor/removable_device_constants.cc b/components/storage_monitor/removable_device_constants.cc
index ce76b23..0bc46cd 100644
--- a/components/storage_monitor/removable_device_constants.cc
+++ b/components/storage_monitor/removable_device_constants.cc
@@ -2,6 +2,7 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
+#include "build/build_config.h"
#include "components/storage_monitor/removable_device_constants.h"
namespace storage_monitor {
diff --git a/components/storage_monitor/storage_info.cc b/components/storage_monitor/storage_info.cc
index 19d59b6..98bc7ce 100644
--- a/components/storage_monitor/storage_info.cc
+++ b/components/storage_monitor/storage_info.cc
@@ -4,6 +4,8 @@
#include "components/storage_monitor/storage_info.h"
+#include <stddef.h>
+
#include "base/logging.h"
#include "base/strings/utf_string_conversions.h"
#include "components/storage_monitor/media_storage_util.h"
@@ -22,7 +24,7 @@ const char kITunesPrefix[] = "itunes:";
const char kPicasaPrefix[] = "picasa:";
const char kIPhotoPrefix[] = "iphoto:";
-base::string16 GetDisplayNameForDevice(uint64 storage_size_in_bytes,
+base::string16 GetDisplayNameForDevice(uint64_t storage_size_in_bytes,
const base::string16& name) {
DCHECK(!name.empty());
return (storage_size_in_bytes == 0) ?
@@ -58,14 +60,13 @@ StorageInfo::StorageInfo(const std::string& device_id_in,
const base::string16& label,
const base::string16& vendor,
const base::string16& model,
- uint64 size_in_bytes)
+ uint64_t size_in_bytes)
: device_id_(device_id_in),
location_(device_location),
storage_label_(label),
vendor_name_(vendor),
model_name_(model),
- total_size_in_bytes_(size_in_bytes) {
-}
+ total_size_in_bytes_(size_in_bytes) {}
StorageInfo::~StorageInfo() {
}
diff --git a/components/storage_monitor/storage_info.h b/components/storage_monitor/storage_info.h
index caebe1c..d10e445 100644
--- a/components/storage_monitor/storage_info.h
+++ b/components/storage_monitor/storage_info.h
@@ -5,6 +5,8 @@
#ifndef COMPONENTS_STORAGE_MONITOR_STORAGE_INFO_H_
#define COMPONENTS_STORAGE_MONITOR_STORAGE_INFO_H_
+#include <stdint.h>
+
#include "base/files/file_path.h"
#include "base/strings/string16.h"
@@ -38,7 +40,7 @@ class StorageInfo {
const base::string16& label,
const base::string16& vendor,
const base::string16& model,
- uint64 size_in_bytes);
+ uint64_t size_in_bytes);
~StorageInfo();
// Returns a device id given properties of the device. A prefix dependent on
@@ -84,7 +86,7 @@ class StorageInfo {
const base::string16& storage_label() const { return storage_label_; }
const base::string16& vendor_name() const { return vendor_name_; }
const base::string16& model_name() const { return model_name_; }
- uint64 total_size_in_bytes() const { return total_size_in_bytes_; }
+ uint64_t total_size_in_bytes() const { return total_size_in_bytes_; }
void set_device_id(const std::string& device_id) { device_id_ = device_id; }
void set_location(const base::FilePath::StringType& location) {
@@ -115,7 +117,7 @@ class StorageInfo {
// Size of the removable device in bytes.
// Zero if not collected or unknown.
- uint64 total_size_in_bytes_;
+ uint64_t total_size_in_bytes_;
};
} // namespace storage_monitor
diff --git a/components/storage_monitor/storage_monitor.h b/components/storage_monitor/storage_monitor.h
index 5ddfe89..c3a2d9a 100644
--- a/components/storage_monitor/storage_monitor.h
+++ b/components/storage_monitor/storage_monitor.h
@@ -16,6 +16,7 @@
#include "base/strings/string16.h"
#include "base/synchronization/lock.h"
#include "base/threading/thread_checker.h"
+#include "build/build_config.h"
#include "components/storage_monitor/storage_info.h"
class MediaFileSystemRegistryTest;
diff --git a/components/storage_monitor/storage_monitor_chromeos.h b/components/storage_monitor/storage_monitor_chromeos.h
index bfbeed6..84af559 100644
--- a/components/storage_monitor/storage_monitor_chromeos.h
+++ b/components/storage_monitor/storage_monitor_chromeos.h
@@ -16,10 +16,11 @@
#include <map>
#include <string>
-#include "base/basictypes.h"
#include "base/compiler_specific.h"
+#include "base/macros.h"
#include "base/memory/scoped_ptr.h"
#include "base/memory/weak_ptr.h"
+#include "build/build_config.h"
#include "chromeos/disks/disk_mount_manager.h"
#include "components/storage_monitor/storage_monitor.h"
diff --git a/components/storage_monitor/storage_monitor_chromeos_unittest.cc b/components/storage_monitor/storage_monitor_chromeos_unittest.cc
index e2d3df3..053ef14 100644
--- a/components/storage_monitor/storage_monitor_chromeos_unittest.cc
+++ b/components/storage_monitor/storage_monitor_chromeos_unittest.cc
@@ -4,9 +4,12 @@
#include "components/storage_monitor/storage_monitor_chromeos.h"
+#include <stdint.h>
+
#include "base/files/file_util.h"
#include "base/files/scoped_temp_dir.h"
#include "base/logging.h"
+#include "base/macros.h"
#include "base/memory/scoped_ptr.h"
#include "base/run_loop.h"
#include "base/strings/utf_string_conversions.h"
@@ -44,9 +47,9 @@ const char kUniqueId1[] = "FFFF-FFFF";
const char kUniqueId2[] = "FFFF-FF0F";
const char kVendorName[] = "CompanyA";
-uint64 kDevice1SizeInBytes = 113048;
-uint64 kDevice2SizeInBytes = 212312;
-uint64 kSDCardSizeInBytes = 9000000;
+uint64_t kDevice1SizeInBytes = 113048;
+uint64_t kDevice2SizeInBytes = 212312;
+uint64_t kSDCardSizeInBytes = 9000000;
std::string GetDCIMDeviceId(const std::string& unique_id) {
return StorageInfo::MakeDeviceId(
@@ -107,12 +110,12 @@ class StorageMonitorCrosTest : public testing::Test {
const std::string& vendor_name,
const std::string& product_name,
chromeos::DeviceType device_type,
- uint64 device_size_in_bytes);
+ uint64_t device_size_in_bytes);
void UnmountDevice(chromeos::MountError error_code,
const DiskMountManager::MountPointInfo& mount_info);
- uint64 GetDeviceStorageSize(const std::string& device_location);
+ uint64_t GetDeviceStorageSize(const std::string& device_location);
// Create a directory named |dir| relative to the test directory.
// Set |with_dcim_dir| to true if the created directory will have a "DCIM"
@@ -193,7 +196,7 @@ void StorageMonitorCrosTest::MountDevice(
const std::string& vendor_name,
const std::string& product_name,
chromeos::DeviceType device_type,
- uint64 device_size_in_bytes) {
+ uint64_t device_size_in_bytes) {
if (error_code == chromeos::MOUNT_ERROR_NONE) {
disk_mount_manager_mock_->CreateDiskEntryForMountDevice(
mount_info,
@@ -221,7 +224,7 @@ void StorageMonitorCrosTest::UnmountDevice(
WaitForFileThread();
}
-uint64 StorageMonitorCrosTest::GetDeviceStorageSize(
+uint64_t StorageMonitorCrosTest::GetDeviceStorageSize(
const std::string& device_location) {
StorageInfo info;
if (!monitor_->GetStorageInfoForPath(base::FilePath(device_location), &info))
diff --git a/components/storage_monitor/storage_monitor_linux.cc b/components/storage_monitor/storage_monitor_linux.cc
index a97b92e..a6fefc4 100644
--- a/components/storage_monitor/storage_monitor_linux.cc
+++ b/components/storage_monitor/storage_monitor_linux.cc
@@ -14,6 +14,7 @@
#include <list>
#include "base/bind.h"
+#include "base/macros.h"
#include "base/metrics/histogram.h"
#include "base/process/kill.h"
#include "base/process/launch.h"
diff --git a/components/storage_monitor/storage_monitor_linux.h b/components/storage_monitor/storage_monitor_linux.h
index 5a01230..bbe6813 100644
--- a/components/storage_monitor/storage_monitor_linux.h
+++ b/components/storage_monitor/storage_monitor_linux.h
@@ -24,6 +24,7 @@
#include "base/macros.h"
#include "base/memory/scoped_ptr.h"
#include "base/memory/weak_ptr.h"
+#include "build/build_config.h"
#include "components/storage_monitor/mtab_watcher_linux.h"
#include "components/storage_monitor/storage_monitor.h"
#include "content/public/browser/browser_thread.h"
diff --git a/components/storage_monitor/storage_monitor_linux_unittest.cc b/components/storage_monitor/storage_monitor_linux_unittest.cc
index eee2bd3..295215e 100644
--- a/components/storage_monitor/storage_monitor_linux_unittest.cc
+++ b/components/storage_monitor/storage_monitor_linux_unittest.cc
@@ -7,6 +7,8 @@
#include "components/storage_monitor/storage_monitor_linux.h"
#include <mntent.h>
+#include <stddef.h>
+#include <stdint.h>
#include <stdio.h>
#include <string>
@@ -14,6 +16,7 @@
#include "base/files/file_util.h"
#include "base/files/scoped_temp_dir.h"
#include "base/logging.h"
+#include "base/macros.h"
#include "base/memory/scoped_ptr.h"
#include "base/run_loop.h"
#include "base/strings/utf_string_conversions.h"
@@ -52,7 +55,7 @@ struct TestDeviceData {
const char* device_path;
const char* unique_id;
StorageInfo::Type type;
- uint64 partition_size_in_bytes;
+ uint64_t partition_size_in_bytes;
};
const TestDeviceData kTestDeviceData[] = {
@@ -97,7 +100,7 @@ scoped_ptr<StorageInfo> GetDeviceInfo(const base::FilePath& device_path,
return storage_info.Pass();
}
-uint64 GetDevicePartitionSize(const std::string& device) {
+uint64_t GetDevicePartitionSize(const std::string& device) {
for (size_t i = 0; i < arraysize(kTestDeviceData); ++i) {
if (device == kTestDeviceData[i].device_path)
return kTestDeviceData[i].partition_size_in_bytes;
@@ -241,7 +244,7 @@ class StorageMonitorLinuxTest : public testing::Test {
return monitor_.get();
}
- uint64 GetStorageSize(const base::FilePath& path) {
+ uint64_t GetStorageSize(const base::FilePath& path) {
StorageInfo info;
if (!notifier()->GetStorageInfoForPath(path, &info))
return 0;
diff --git a/components/storage_monitor/storage_monitor_mac.h b/components/storage_monitor/storage_monitor_mac.h
index 9379f5e..46a8af4 100644
--- a/components/storage_monitor/storage_monitor_mac.h
+++ b/components/storage_monitor/storage_monitor_mac.h
@@ -9,6 +9,7 @@
#include <map>
#include "base/mac/scoped_cftyperef.h"
+#include "base/macros.h"
#include "base/memory/weak_ptr.h"
#include "components/storage_monitor/storage_monitor.h"
diff --git a/components/storage_monitor/storage_monitor_mac.mm b/components/storage_monitor/storage_monitor_mac.mm
index 22a884b..1ae2c83 100644
--- a/components/storage_monitor/storage_monitor_mac.mm
+++ b/components/storage_monitor/storage_monitor_mac.mm
@@ -4,6 +4,8 @@
#include "components/storage_monitor/storage_monitor_mac.h"
+#include <stdint.h>
+
#include "base/mac/foundation_util.h"
#include "base/mac/mac_util.h"
#include "base/strings/sys_string_conversions.h"
@@ -61,7 +63,7 @@ StorageInfo BuildStorageInfo(
CFNumberRef size_number =
base::mac::GetValueFromDictionary<CFNumberRef>(
dict, kDADiskDescriptionMediaSizeKey);
- uint64 size_in_bytes = 0;
+ uint64_t size_in_bytes = 0;
if (size_number)
CFNumberGetValue(size_number, kCFNumberLongLongType, &size_in_bytes);
diff --git a/components/storage_monitor/storage_monitor_mac_unittest.mm b/components/storage_monitor/storage_monitor_mac_unittest.mm
index 57ef88f..1b10d17 100644
--- a/components/storage_monitor/storage_monitor_mac_unittest.mm
+++ b/components/storage_monitor/storage_monitor_mac_unittest.mm
@@ -4,6 +4,8 @@
#include "components/storage_monitor/storage_monitor_mac.h"
+#include <stdint.h>
+
#include "base/bind_helpers.h"
#include "base/files/file_util.h"
#include "base/files/scoped_temp_dir.h"
@@ -19,17 +21,16 @@
#include "content/public/test/test_browser_thread_bundle.h"
#include "testing/gtest/include/gtest/gtest.h"
-uint64 kTestSize = 1000000ULL;
+uint64_t kTestSize = 1000000ULL;
namespace storage_monitor {
namespace {
-StorageInfo CreateStorageInfo(
- const std::string& device_id,
- const std::string& model_name,
- const base::FilePath& mount_point,
- uint64 size_bytes) {
+StorageInfo CreateStorageInfo(const std::string& device_id,
+ const std::string& model_name,
+ const base::FilePath& mount_point,
+ uint64_t size_bytes) {
return StorageInfo(
device_id, mount_point.value(), base::string16(), base::string16(),
base::UTF8ToUTF16(model_name), size_bytes);
diff --git a/components/storage_monitor/storage_monitor_win.cc b/components/storage_monitor/storage_monitor_win.cc
index 95a6911..c006b6f 100644
--- a/components/storage_monitor/storage_monitor_win.cc
+++ b/components/storage_monitor/storage_monitor_win.cc
@@ -8,6 +8,7 @@
#include <dbt.h>
#include <fileapi.h>
#include <shlobj.h>
+#include <stddef.h>
#include "base/win/wrapped_window_proc.h"
#include "components/storage_monitor/portable_device_watcher_win.h"
diff --git a/components/storage_monitor/storage_monitor_win.h b/components/storage_monitor/storage_monitor_win.h
index 2a99f12..a57133d 100644
--- a/components/storage_monitor/storage_monitor_win.h
+++ b/components/storage_monitor/storage_monitor_win.h
@@ -5,7 +5,7 @@
#ifndef COMPONENTS_STORAGE_MONITOR_STORAGE_MONITOR_WIN_H_
#define COMPONENTS_STORAGE_MONITOR_STORAGE_MONITOR_WIN_H_
-#include "base/basictypes.h"
+#include "base/macros.h"
#include "base/memory/ref_counted.h"
#include "base/memory/scoped_ptr.h"
#include "components/storage_monitor/storage_monitor.h"
diff --git a/components/storage_monitor/storage_monitor_win_unittest.cc b/components/storage_monitor/storage_monitor_win_unittest.cc
index f146cfc..b8f2487 100644
--- a/components/storage_monitor/storage_monitor_win_unittest.cc
+++ b/components/storage_monitor/storage_monitor_win_unittest.cc
@@ -4,10 +4,12 @@
#include <windows.h>
#include <dbt.h>
+#include <stddef.h>
#include <string>
#include <vector>
+#include "base/macros.h"
#include "base/memory/ref_counted.h"
#include "base/memory/scoped_ptr.h"
#include "base/run_loop.h"
diff --git a/components/storage_monitor/test_media_transfer_protocol_manager_linux.h b/components/storage_monitor/test_media_transfer_protocol_manager_linux.h
index a391639..c53b39c 100644
--- a/components/storage_monitor/test_media_transfer_protocol_manager_linux.h
+++ b/components/storage_monitor/test_media_transfer_protocol_manager_linux.h
@@ -5,8 +5,10 @@
#ifndef COMPONENTS_STORAGE_MONITOR_TEST_MEDIA_TRANSFER_PROTOCOL_MANAGER_LINUX_H_
#define COMPONENTS_STORAGE_MONITOR_TEST_MEDIA_TRANSFER_PROTOCOL_MANAGER_LINUX_H_
+#include <stddef.h>
#include <stdint.h>
+#include "base/macros.h"
#include "device/media_transfer_protocol/media_transfer_protocol_manager.h"
namespace storage_monitor {
diff --git a/components/storage_monitor/test_portable_device_watcher_win.h b/components/storage_monitor/test_portable_device_watcher_win.h
index 53275da..e0aabcb 100644
--- a/components/storage_monitor/test_portable_device_watcher_win.h
+++ b/components/storage_monitor/test_portable_device_watcher_win.h
@@ -10,6 +10,7 @@
#include <string>
+#include "base/macros.h"
#include "base/strings/string16.h"
#include "components/storage_monitor/portable_device_watcher_win.h"
diff --git a/components/storage_monitor/test_storage_monitor.cc b/components/storage_monitor/test_storage_monitor.cc
index 78f4df56..33e80a5 100644
--- a/components/storage_monitor/test_storage_monitor.cc
+++ b/components/storage_monitor/test_storage_monitor.cc
@@ -6,6 +6,7 @@
#include "base/run_loop.h"
#include "base/synchronization/waitable_event.h"
+#include "build/build_config.h"
#include "components/storage_monitor/storage_info.h"
#if defined(OS_LINUX)
diff --git a/components/storage_monitor/test_storage_monitor.h b/components/storage_monitor/test_storage_monitor.h
index da3809b..de80e013 100644
--- a/components/storage_monitor/test_storage_monitor.h
+++ b/components/storage_monitor/test_storage_monitor.h
@@ -7,6 +7,7 @@
#include <string>
+#include "build/build_config.h"
#include "components/storage_monitor/storage_monitor.h"
namespace storage_monitor {
diff --git a/components/storage_monitor/test_storage_monitor_win.h b/components/storage_monitor/test_storage_monitor_win.h
index 150b2459..12a34ba 100644
--- a/components/storage_monitor/test_storage_monitor_win.h
+++ b/components/storage_monitor/test_storage_monitor_win.h
@@ -10,6 +10,7 @@
#include <windows.h>
+#include "base/macros.h"
#include "base/memory/ref_counted.h"
#include "components/storage_monitor/storage_monitor_win.h"
diff --git a/components/storage_monitor/test_volume_mount_watcher_win.cc b/components/storage_monitor/test_volume_mount_watcher_win.cc
index 7464545..bc5f03e 100644
--- a/components/storage_monitor/test_volume_mount_watcher_win.cc
+++ b/components/storage_monitor/test_volume_mount_watcher_win.cc
@@ -99,7 +99,7 @@ void TestVolumeMountWatcherWin::AddDeviceForTesting(
const base::FilePath& device_path,
const std::string& device_id,
const base::string16& storage_label,
- uint64 total_size_in_bytes) {
+ uint64_t total_size_in_bytes) {
StorageInfo info(device_id, device_path.value(), storage_label,
base::string16(), base::string16(), total_size_in_bytes);
HandleDeviceAttachEventOnUIThread(device_path, info);
diff --git a/components/storage_monitor/test_volume_mount_watcher_win.h b/components/storage_monitor/test_volume_mount_watcher_win.h
index ca0a9b4..d6aa346 100644
--- a/components/storage_monitor/test_volume_mount_watcher_win.h
+++ b/components/storage_monitor/test_volume_mount_watcher_win.h
@@ -8,9 +8,12 @@
#ifndef COMPONENTS_STORAGE_MONITOR_TEST_VOLUME_MOUNT_WATCHER_WIN_H_
#define COMPONENTS_STORAGE_MONITOR_TEST_VOLUME_MOUNT_WATCHER_WIN_H_
+#include <stdint.h>
+
#include <string>
#include <vector>
+#include "base/macros.h"
#include "base/strings/string16.h"
#include "base/synchronization/waitable_event.h"
#include "components/storage_monitor/volume_mount_watcher_win.h"
@@ -32,7 +35,7 @@ class TestVolumeMountWatcherWin : public VolumeMountWatcherWin {
void AddDeviceForTesting(const base::FilePath& device_path,
const std::string& device_id,
const base::string16& device_name,
- uint64 total_size_in_bytes);
+ uint64_t total_size_in_bytes);
void SetAttachedDevicesFake();
diff --git a/components/storage_monitor/transient_device_ids.h b/components/storage_monitor/transient_device_ids.h
index 53227a9..5c8284e 100644
--- a/components/storage_monitor/transient_device_ids.h
+++ b/components/storage_monitor/transient_device_ids.h
@@ -13,7 +13,7 @@
#include <map>
#include <string>
-#include "base/basictypes.h"
+#include "base/macros.h"
#include "base/threading/thread_checker.h"
namespace storage_monitor {
diff --git a/components/storage_monitor/volume_mount_watcher_win.cc b/components/storage_monitor/volume_mount_watcher_win.cc
index 168d2eb..72ca3b2 100644
--- a/components/storage_monitor/volume_mount_watcher_win.cc
+++ b/components/storage_monitor/volume_mount_watcher_win.cc
@@ -5,6 +5,8 @@
#include "components/storage_monitor/volume_mount_watcher_win.h"
#include <windows.h>
+#include <stddef.h>
+#include <stdint.h>
#include <dbt.h>
#include <fileapi.h>
@@ -93,7 +95,7 @@ DeviceType GetDeviceType(const base::string16& mount_point) {
}
// Returns 0 if the devicetype is not volume.
-uint32 GetVolumeBitMaskFromBroadcastHeader(LPARAM data) {
+uint32_t GetVolumeBitMaskFromBroadcastHeader(LPARAM data) {
DEV_BROADCAST_VOLUME* dev_broadcast_volume =
reinterpret_cast<DEV_BROADCAST_VOLUME*>(data);
if (dev_broadcast_volume->dbcv_devicetype == DBT_DEVTYP_VOLUME)
@@ -110,7 +112,7 @@ bool IsLogicalVolumeStructure(LPARAM data) {
}
// Gets the total volume of the |mount_point| in bytes.
-uint64 GetVolumeSize(const base::string16& mount_point) {
+uint64_t GetVolumeSize(const base::string16& mount_point) {
ULARGE_INTEGER total;
if (!GetDiskFreeSpaceExW(mount_point.c_str(), NULL, &total, NULL))
return 0;
@@ -172,7 +174,7 @@ bool GetDeviceDetails(const base::FilePath& device_path, StorageInfo* info) {
base::WriteInto(&volume_label, kMaxPathBufLen),
kMaxPathBufLen, NULL, NULL, NULL, NULL, 0);
- uint64 total_size_in_bytes = GetVolumeSize(mount_point);
+ uint64_t total_size_in_bytes = GetVolumeSize(mount_point);
std::string device_id =
StorageInfo::MakeDeviceId(type, base::UTF16ToUTF8(guid));
diff --git a/components/storage_monitor/volume_mount_watcher_win.h b/components/storage_monitor/volume_mount_watcher_win.h
index bf351db..2d183d8 100644
--- a/components/storage_monitor/volume_mount_watcher_win.h
+++ b/components/storage_monitor/volume_mount_watcher_win.h
@@ -10,9 +10,9 @@
#include <string>
#include <vector>
-#include "base/basictypes.h"
#include "base/callback.h"
#include "base/files/file_path.h"
+#include "base/macros.h"
#include "base/memory/weak_ptr.h"
#include "base/sequenced_task_runner.h"
#include "base/strings/string16.h"
diff --git a/components/suggestions/blacklist_store.cc b/components/suggestions/blacklist_store.cc
index cc529ad..fff59fc 100644
--- a/components/suggestions/blacklist_store.cc
+++ b/components/suggestions/blacklist_store.cc
@@ -4,6 +4,8 @@
#include "components/suggestions/blacklist_store.h"
+#include <stddef.h>
+
#include <algorithm>
#include <set>
#include <string>
diff --git a/components/suggestions/blacklist_store_unittest.cc b/components/suggestions/blacklist_store_unittest.cc
index 9b2f8be..cd85078 100644
--- a/components/suggestions/blacklist_store_unittest.cc
+++ b/components/suggestions/blacklist_store_unittest.cc
@@ -7,6 +7,7 @@
#include <set>
#include <string>
+#include "base/macros.h"
#include "base/memory/scoped_ptr.h"
#include "base/test/histogram_tester.h"
diff --git a/components/suggestions/image_encoder_ios.mm b/components/suggestions/image_encoder_ios.mm
index 79d639c..9c27a3e 100644
--- a/components/suggestions/image_encoder_ios.mm
+++ b/components/suggestions/image_encoder_ios.mm
@@ -4,6 +4,7 @@
#include "components/suggestions/image_encoder.h"
+#include <stddef.h>
#import <UIKit/UIKit.h>
#include "base/mac/scoped_cftyperef.h"
diff --git a/components/suggestions/image_fetcher.h b/components/suggestions/image_fetcher.h
index 52fcff4..acb65d42 100644
--- a/components/suggestions/image_fetcher.h
+++ b/components/suggestions/image_fetcher.h
@@ -6,6 +6,7 @@
#define COMPONENTS_SUGGESTIONS_IMAGE_FETCHER_H_
#include "base/callback.h"
+#include "base/macros.h"
#include "components/suggestions/image_fetcher_delegate.h"
#include "url/gurl.h"
diff --git a/components/suggestions/image_fetcher_delegate.h b/components/suggestions/image_fetcher_delegate.h
index 69fbb86..d9ddec4 100644
--- a/components/suggestions/image_fetcher_delegate.h
+++ b/components/suggestions/image_fetcher_delegate.h
@@ -5,6 +5,8 @@
#ifndef COMPONENTS_SUGGESTIONS_IMAGE_FETCHER_DELEGATE_H_
#define COMPONENTS_SUGGESTIONS_IMAGE_FETCHER_DELEGATE_H_
+#include "base/macros.h"
+
class GURL;
class SkBitmap;
diff --git a/components/suggestions/image_manager.h b/components/suggestions/image_manager.h
index 3c01ba0..2466349 100644
--- a/components/suggestions/image_manager.h
+++ b/components/suggestions/image_manager.h
@@ -9,10 +9,10 @@
#include <string>
#include <vector>
-#include "base/basictypes.h"
#include "base/callback.h"
#include "base/containers/hash_tables.h"
#include "base/gtest_prod_util.h"
+#include "base/macros.h"
#include "base/memory/ref_counted_memory.h"
#include "base/memory/scoped_ptr.h"
#include "base/memory/weak_ptr.h"
diff --git a/components/suggestions/suggestions_service.cc b/components/suggestions/suggestions_service.cc
index c4b6761..7af3ddd 100644
--- a/components/suggestions/suggestions_service.cc
+++ b/components/suggestions/suggestions_service.cc
@@ -15,6 +15,7 @@
#include "base/strings/string_util.h"
#include "base/strings/stringprintf.h"
#include "base/thread_task_runner_handle.h"
+#include "build/build_config.h"
#include "components/data_use_measurement/core/data_use_user_data.h"
#include "components/pref_registry/pref_registry_syncable.h"
#include "components/signin/core/browser/signin_manager_base.h"
@@ -103,7 +104,7 @@ const char kPingURL[] =
"https://www.google.com/chromesuggestions/click?q=%lld&cd=%d";
// The default expiry timeout is 168 hours.
-const int64 kDefaultExpiryUsec = 168 * base::Time::kMicrosecondsPerHour;
+const int64_t kDefaultExpiryUsec = 168 * base::Time::kMicrosecondsPerHour;
const base::Feature kOAuth2AuthenticationFeature {
"SuggestionsServiceOAuth2", base::FEATURE_DISABLED_BY_DEFAULT
@@ -324,7 +325,8 @@ GURL SuggestionsService::BuildSuggestionsBlacklistClearURL() {
}
void SuggestionsService::SetDefaultExpiryTimestamp(
- SuggestionsProfile* suggestions, int64 default_timestamp_usec) {
+ SuggestionsProfile* suggestions,
+ int64_t default_timestamp_usec) {
for (int i = 0; i < suggestions->suggestions_size(); ++i) {
ChromeSuggestion* suggestion = suggestions->mutable_suggestions(i);
// Do not set expiry if the server has already provided a more specific
@@ -444,8 +446,9 @@ void SuggestionsService::OnURLFetchComplete(const net::URLFetcher* source) {
suggestions_store_->ClearSuggestions();
} else if (suggestions.ParseFromString(suggestions_data)) {
LogResponseState(RESPONSE_VALID);
- int64 now_usec = (base::Time::NowFromSystemTime() - base::Time::UnixEpoch())
- .ToInternalValue();
+ int64_t now_usec =
+ (base::Time::NowFromSystemTime() - base::Time::UnixEpoch())
+ .ToInternalValue();
SetDefaultExpiryTimestamp(&suggestions, now_usec + kDefaultExpiryUsec);
PopulateExtraData(&suggestions);
suggestions_store_->StoreSuggestions(suggestions);
diff --git a/components/suggestions/suggestions_service.h b/components/suggestions/suggestions_service.h
index 5a9b6d7..7f0dd21 100644
--- a/components/suggestions/suggestions_service.h
+++ b/components/suggestions/suggestions_service.h
@@ -5,13 +5,15 @@
#ifndef COMPONENTS_SUGGESTIONS_SUGGESTIONS_SERVICE_H_
#define COMPONENTS_SUGGESTIONS_SUGGESTIONS_SERVICE_H_
+#include <stdint.h>
+
#include <string>
#include <vector>
-#include "base/basictypes.h"
#include "base/callback.h"
#include "base/cancelable_callback.h"
#include "base/gtest_prod_util.h"
+#include "base/macros.h"
#include "base/memory/scoped_ptr.h"
#include "base/memory/weak_ptr.h"
#include "base/threading/thread_checker.h"
@@ -135,7 +137,7 @@ class SuggestionsService : public KeyedService, public net::URLFetcherDelegate {
// Sets default timestamp for suggestions which do not have expiry timestamp.
void SetDefaultExpiryTimestamp(SuggestionsProfile* suggestions,
- int64 timestamp_usec);
+ int64_t timestamp_usec);
// Issues a network request if there isn't already one happening.
void IssueRequestIfNoneOngoing(const GURL& url);
diff --git a/components/suggestions/suggestions_service_unittest.cc b/components/suggestions/suggestions_service_unittest.cc
index 81bcaaf..36d8cef 100644
--- a/components/suggestions/suggestions_service_unittest.cc
+++ b/components/suggestions/suggestions_service_unittest.cc
@@ -4,12 +4,15 @@
#include "components/suggestions/suggestions_service.h"
+#include <stdint.h>
+
#include <map>
#include <sstream>
#include <utility>
#include "base/bind.h"
#include "base/feature_list.h"
+#include "base/macros.h"
#include "base/memory/scoped_ptr.h"
#include "components/signin/core/browser/fake_profile_oauth2_token_service.h"
#include "components/suggestions/blacklist_store.h"
@@ -52,8 +55,8 @@ const char kTestClickUrl[] =
"https://www.google.com/chromesuggestions/click?q=123&cd=0";
const char kBlacklistedUrl[] = "http://blacklist.com";
const char kBlacklistedUrlAlt[] = "http://blacklist-atl.com";
-const int64 kTestDefaultExpiry = 1402200000000000;
-const int64 kTestSetExpiry = 1404792000000000;
+const int64_t kTestDefaultExpiry = 1402200000000000;
+const int64_t kTestSetExpiry = 1404792000000000;
scoped_ptr<net::FakeURLFetcher> CreateURLFetcher(
const GURL& url, net::URLFetcherDelegate* delegate,
diff --git a/components/suggestions/suggestions_store.cc b/components/suggestions/suggestions_store.cc
index 42d6dc5..dff3211 100644
--- a/components/suggestions/suggestions_store.cc
+++ b/components/suggestions/suggestions_store.cc
@@ -4,6 +4,8 @@
#include "components/suggestions/suggestions_store.h"
+#include <stdint.h>
+
#include <string>
#include "base/base64.h"
@@ -69,7 +71,7 @@ bool SuggestionsStore::LoadSuggestions(SuggestionsProfile* suggestions) {
void SuggestionsStore::FilterExpiredSuggestions(
SuggestionsProfile* suggestions) {
SuggestionsProfile filtered_suggestions;
- int64 now_usec =
+ int64_t now_usec =
(this->clock_->Now() - base::Time::UnixEpoch()).ToInternalValue();
for (int i = 0; i < suggestions->suggestions_size(); ++i) {
diff --git a/components/suggestions/suggestions_store_unittest.cc b/components/suggestions/suggestions_store_unittest.cc
index 99baedb..42a17c1 100644
--- a/components/suggestions/suggestions_store_unittest.cc
+++ b/components/suggestions/suggestions_store_unittest.cc
@@ -4,6 +4,9 @@
#include "components/suggestions/suggestions_store.h"
+#include <stdint.h>
+
+#include "base/macros.h"
#include "base/test/simple_test_clock.h"
#include "base/time/time.h"
#include "components/pref_registry/testing_pref_service_syncable.h"
@@ -19,8 +22,10 @@ namespace {
const char kTestTitle[] = "Foo site";
const char kTestUrl[] = "http://foo.com/";
-void AddSuggestion(SuggestionsProfile* suggestions, const char *title,
- const char *url, int64 expiry_ts) {
+void AddSuggestion(SuggestionsProfile* suggestions,
+ const char* title,
+ const char* url,
+ int64_t expiry_ts) {
ChromeSuggestion* suggestion = suggestions->add_suggestions();
suggestion->set_url(title);
suggestion->set_title(url);
@@ -39,9 +44,9 @@ SuggestionsProfile CreateTestSuggestionsProfileWithExpiry(
base::Time current_time,
int expired_count,
int valid_count) {
- int64 current_time_usec =
+ int64_t current_time_usec =
(current_time - base::Time::UnixEpoch()).ToInternalValue();
- int64 offset_usec = 5 * base::Time::kMicrosecondsPerMinute;
+ int64_t offset_usec = 5 * base::Time::kMicrosecondsPerMinute;
SuggestionsProfile suggestions;
for (int i = 1; i <= valid_count; i++)
diff --git a/components/sync_bookmarks/bookmark_change_processor.cc b/components/sync_bookmarks/bookmark_change_processor.cc
index df65f78..3644a03 100644
--- a/components/sync_bookmarks/bookmark_change_processor.cc
+++ b/components/sync_bookmarks/bookmark_change_processor.cc
@@ -4,6 +4,8 @@
#include "components/sync_bookmarks/bookmark_change_processor.h"
+#include <stddef.h>
+
#include <map>
#include <stack>
#include <vector>
@@ -123,7 +125,7 @@ int BookmarkChangeProcessor::RemoveSyncNodeHierarchy(
void BookmarkChangeProcessor::RemoveSyncNodeHierarchy(
const BookmarkNode* topmost) {
- int64 new_version = syncer::syncable::kInvalidTransactionVersion;
+ int64_t new_version = syncer::syncable::kInvalidTransactionVersion;
{
syncer::WriteTransaction trans(FROM_HERE, share_handle(), &new_version);
syncer::WriteNode topmost_sync_node(&trans);
@@ -145,22 +147,23 @@ void BookmarkChangeProcessor::RemoveSyncNodeHierarchy(
}
void BookmarkChangeProcessor::RemoveAllSyncNodes() {
- int64 new_version = syncer::syncable::kInvalidTransactionVersion;
+ int64_t new_version = syncer::syncable::kInvalidTransactionVersion;
{
syncer::WriteTransaction trans(FROM_HERE, share_handle(), &new_version);
- int64 bookmark_bar_node_sync_id = model_associator_->GetSyncIdFromChromeId(
- bookmark_model_->bookmark_bar_node()->id());
+ int64_t bookmark_bar_node_sync_id =
+ model_associator_->GetSyncIdFromChromeId(
+ bookmark_model_->bookmark_bar_node()->id());
DCHECK_NE(syncer::kInvalidId, bookmark_bar_node_sync_id);
RemoveAllChildNodes(&trans, bookmark_bar_node_sync_id, model_associator_);
- int64 other_node_sync_id = model_associator_->GetSyncIdFromChromeId(
+ int64_t other_node_sync_id = model_associator_->GetSyncIdFromChromeId(
bookmark_model_->other_node()->id());
DCHECK_NE(syncer::kInvalidId, other_node_sync_id);
RemoveAllChildNodes(&trans, other_node_sync_id, model_associator_);
// Remove mobile bookmarks node only if it is present.
- int64 mobile_node_sync_id = model_associator_->GetSyncIdFromChromeId(
+ int64_t mobile_node_sync_id = model_associator_->GetSyncIdFromChromeId(
bookmark_model_->mobile_node()->id());
if (mobile_node_sync_id != syncer::kInvalidId) {
RemoveAllChildNodes(&trans, mobile_node_sync_id, model_associator_);
@@ -178,7 +181,7 @@ void BookmarkChangeProcessor::RemoveAllSyncNodes() {
// static
int BookmarkChangeProcessor::RemoveAllChildNodes(
syncer::WriteTransaction* trans,
- int64 topmost_sync_id,
+ int64_t topmost_sync_id,
BookmarkModelAssociator* associator) {
// Do a DFS and delete all the child sync nodes, use sync id instead of
// bookmark node ids since the bookmark nodes may already be deleted.
@@ -191,11 +194,11 @@ int BookmarkChangeProcessor::RemoveAllChildNodes(
// delete node
int num_removed = 0;
- std::stack<int64> dfs_sync_id_stack;
+ std::stack<int64_t> dfs_sync_id_stack;
// Push the topmost node.
dfs_sync_id_stack.push(topmost_sync_id);
while (!dfs_sync_id_stack.empty()) {
- const int64 sync_node_id = dfs_sync_id_stack.top();
+ const int64_t sync_node_id = dfs_sync_id_stack.top();
syncer::WriteNode node(trans);
node.InitByIdLookup(sync_node_id);
if (!node.GetIsFolder() || node.GetFirstChildId() == syncer::kInvalidId) {
@@ -212,7 +215,7 @@ int BookmarkChangeProcessor::RemoveAllChildNodes(
DCHECK(dfs_sync_id_stack.empty());
}
} else {
- int64 child_id = node.GetFirstChildId();
+ int64_t child_id = node.GetFirstChildId();
if (child_id != syncer::kInvalidId) {
dfs_sync_id_stack.push(child_id);
}
@@ -241,8 +244,8 @@ void BookmarkChangeProcessor::CreateOrUpdateSyncNode(const BookmarkNode* node) {
const BookmarkNode* parent = node->parent();
int index = node->parent()->GetIndexOf(node);
- int64 new_version = syncer::syncable::kInvalidTransactionVersion;
- int64 sync_id = syncer::kInvalidId;
+ int64_t new_version = syncer::syncable::kInvalidTransactionVersion;
+ int64_t sync_id = syncer::kInvalidId;
{
// Acquire a scoped write lock via a transaction.
syncer::WriteTransaction trans(FROM_HERE, share_handle(), &new_version);
@@ -292,8 +295,11 @@ void BookmarkChangeProcessor::BookmarkNodeAdded(BookmarkModel* model,
}
// static
-int64 BookmarkChangeProcessor::CreateSyncNode(const BookmarkNode* parent,
- BookmarkModel* model, int index, syncer::WriteTransaction* trans,
+int64_t BookmarkChangeProcessor::CreateSyncNode(
+ const BookmarkNode* parent,
+ BookmarkModel* model,
+ int index,
+ syncer::WriteTransaction* trans,
BookmarkModelAssociator* associator,
sync_driver::DataTypeErrorHandler* error_handler) {
const BookmarkNode* child = parent->GetChild(index);
@@ -357,7 +363,7 @@ void BookmarkChangeProcessor::BookmarkNodeChanged(BookmarkModel* model,
}
// Static.
-int64 BookmarkChangeProcessor::UpdateSyncNode(
+int64_t BookmarkChangeProcessor::UpdateSyncNode(
const BookmarkNode* node,
BookmarkModel* model,
syncer::WriteTransaction* trans,
@@ -400,7 +406,7 @@ void BookmarkChangeProcessor::BookmarkNodeMoved(BookmarkModel* model,
return;
}
- int64 new_version = syncer::syncable::kInvalidTransactionVersion;
+ int64_t new_version = syncer::syncable::kInvalidTransactionVersion;
{
// Acquire a scoped write lock via a transaction.
syncer::WriteTransaction trans(FROM_HERE, share_handle(), &new_version);
@@ -458,7 +464,7 @@ void BookmarkChangeProcessor::BookmarkNodeChildrenReordered(
BookmarkModel* model, const BookmarkNode* node) {
if (!CanSyncNode(node))
return;
- int64 new_version = syncer::syncable::kInvalidTransactionVersion;
+ int64_t new_version = syncer::syncable::kInvalidTransactionVersion;
std::vector<const BookmarkNode*> children;
{
// Acquire a scoped write lock via a transaction.
@@ -545,7 +551,7 @@ bool BookmarkChangeProcessor::PlaceSyncNode(MoveOrCreate operation,
// model.
void BookmarkChangeProcessor::ApplyChangesFromSyncModel(
const syncer::BaseTransaction* trans,
- int64 model_version,
+ int64_t model_version,
const syncer::ImmutableChangeRecordList& changes) {
DCHECK(thread_checker_.CalledOnValidThread());
// A note about ordering. Sync backend is responsible for ordering the change
@@ -637,7 +643,7 @@ void BookmarkChangeProcessor::ApplyChangesFromSyncModel(
std::multimap<int, const BookmarkNode*> to_reposition;
syncer::ReadNode synced_bookmarks(trans);
- int64 synced_bookmarks_id = syncer::kInvalidId;
+ int64_t synced_bookmarks_id = syncer::kInvalidId;
if (synced_bookmarks.InitByTagLookupForBookmarks(kMobileBookmarksTag) ==
syncer::BaseNode::INIT_OK) {
synced_bookmarks_id = synced_bookmarks.GetId();
@@ -771,7 +777,7 @@ void BookmarkChangeProcessor::UpdateBookmarkWithSyncData(
// static
void BookmarkChangeProcessor::UpdateTransactionVersion(
- int64 new_version,
+ int64_t new_version,
BookmarkModel* model,
const std::vector<const BookmarkNode*>& nodes) {
if (new_version != syncer::syncable::kInvalidTransactionVersion) {
@@ -817,7 +823,7 @@ const BookmarkNode* BookmarkChangeProcessor::CreateBookmarkNode(
// 'creation_time_us' was added in m24. Assume a time of 0 means now.
const sync_pb::BookmarkSpecifics& specifics =
sync_node->GetBookmarkSpecifics();
- const int64 create_time_internal = specifics.creation_time_us();
+ const int64_t create_time_internal = specifics.creation_time_us();
base::Time create_time = (create_time_internal == 0) ?
base::Time::Now() : base::Time::FromInternalValue(create_time_internal);
node = model->AddURLWithCreationTimeAndMetaInfo(
diff --git a/components/sync_bookmarks/bookmark_change_processor.h b/components/sync_bookmarks/bookmark_change_processor.h
index b8d25fe..dff812b 100644
--- a/components/sync_bookmarks/bookmark_change_processor.h
+++ b/components/sync_bookmarks/bookmark_change_processor.h
@@ -5,9 +5,12 @@
#ifndef COMPONENTS_SYNC_BOOKMARKS_BOOKMARK_CHANGE_PROCESSOR_H_
#define COMPONENTS_SYNC_BOOKMARKS_BOOKMARK_CHANGE_PROCESSOR_H_
+#include <stdint.h>
+
#include <vector>
#include "base/compiler_specific.h"
+#include "base/macros.h"
#include "base/threading/thread_checker.h"
#include "components/bookmarks/browser/bookmark_model_observer.h"
#include "components/bookmarks/browser/bookmark_node.h"
@@ -82,7 +85,7 @@ class BookmarkChangeProcessor : public bookmarks::BookmarkModelObserver,
// the sync model to the bookmarks model.
void ApplyChangesFromSyncModel(
const syncer::BaseTransaction* trans,
- int64 model_version,
+ int64_t model_version,
const syncer::ImmutableChangeRecordList& changes) override;
// The following methods are static and hence may be invoked at any time, and
@@ -145,19 +148,21 @@ class BookmarkChangeProcessor : public bookmarks::BookmarkModelObserver,
// will be transferred to the new node. A node corresponding to |parent|
// must already exist and be associated for this call to succeed. Returns
// the ID of the just-created node, or if creation fails, kInvalidID.
- static int64 CreateSyncNode(const bookmarks::BookmarkNode* parent,
- bookmarks::BookmarkModel* model,
- int index,
- syncer::WriteTransaction* trans,
- BookmarkModelAssociator* associator,
- sync_driver::DataTypeErrorHandler* error_handler);
+ static int64_t CreateSyncNode(
+ const bookmarks::BookmarkNode* parent,
+ bookmarks::BookmarkModel* model,
+ int index,
+ syncer::WriteTransaction* trans,
+ BookmarkModelAssociator* associator,
+ sync_driver::DataTypeErrorHandler* error_handler);
// Update |bookmark_node|'s sync node.
- static int64 UpdateSyncNode(const bookmarks::BookmarkNode* bookmark_node,
- bookmarks::BookmarkModel* model,
- syncer::WriteTransaction* trans,
- BookmarkModelAssociator* associator,
- sync_driver::DataTypeErrorHandler* error_handler);
+ static int64_t UpdateSyncNode(
+ const bookmarks::BookmarkNode* bookmark_node,
+ bookmarks::BookmarkModel* model,
+ syncer::WriteTransaction* trans,
+ BookmarkModelAssociator* associator,
+ sync_driver::DataTypeErrorHandler* error_handler);
// Tombstone |topmost_sync_node| node and all its children in the sync domain
// using transaction |trans|. Returns the number of removed nodes.
@@ -168,7 +173,7 @@ class BookmarkChangeProcessor : public bookmarks::BookmarkModelObserver,
// Update transaction version of |model| and |nodes| to |new_version| if
// it's valid.
static void UpdateTransactionVersion(
- int64 new_version,
+ int64_t new_version,
bookmarks::BookmarkModel* model,
const std::vector<const bookmarks::BookmarkNode*>& nodes);
@@ -225,7 +230,7 @@ class BookmarkChangeProcessor : public bookmarks::BookmarkModelObserver,
// Remove all children of |sync_node|. Returns the number of removed
// children.
static int RemoveAllChildNodes(syncer::WriteTransaction* trans,
- int64 sync_id,
+ int64_t sync_id,
BookmarkModelAssociator* associator);
// Remove |sync_node|. It should not have any children.
diff --git a/components/sync_bookmarks/bookmark_data_type_controller.h b/components/sync_bookmarks/bookmark_data_type_controller.h
index b7cb7b3..578e2de 100644
--- a/components/sync_bookmarks/bookmark_data_type_controller.h
+++ b/components/sync_bookmarks/bookmark_data_type_controller.h
@@ -8,6 +8,7 @@
#include <string>
#include "base/compiler_specific.h"
+#include "base/macros.h"
#include "base/scoped_observer.h"
#include "components/bookmarks/browser/base_bookmark_model_observer.h"
#include "components/history/core/browser/history_service_observer.h"
diff --git a/components/sync_bookmarks/bookmark_model_associator.cc b/components/sync_bookmarks/bookmark_model_associator.cc
index 99dfb83..d5d445f 100644
--- a/components/sync_bookmarks/bookmark_model_associator.cc
+++ b/components/sync_bookmarks/bookmark_model_associator.cc
@@ -81,7 +81,7 @@ class BookmarkNodeFinder {
const BookmarkNode* FindBookmarkNode(const GURL& url,
const std::string& title,
bool is_folder,
- int64 preferred_id);
+ int64_t preferred_id);
// Returns true if |bookmark_node| matches the specified |url|,
// |title|, and |is_folder| flags.
@@ -143,7 +143,7 @@ const BookmarkNode* BookmarkNodeFinder::FindBookmarkNode(
const GURL& url,
const std::string& title,
bool is_folder,
- int64 preferred_id) {
+ int64_t preferred_id) {
const BookmarkNode* match = nullptr;
// First lookup a range of bookmarks with the same title.
@@ -214,11 +214,11 @@ BookmarkModelAssociator::Context::Context(
BookmarkModelAssociator::Context::~Context() {
}
-void BookmarkModelAssociator::Context::PushNode(int64 sync_id) {
+void BookmarkModelAssociator::Context::PushNode(int64_t sync_id) {
dfs_stack_.push(sync_id);
}
-bool BookmarkModelAssociator::Context::PopNode(int64* sync_id) {
+bool BookmarkModelAssociator::Context::PopNode(int64_t* sync_id) {
if (dfs_stack_.empty()) {
*sync_id = 0;
return false;
@@ -229,8 +229,8 @@ bool BookmarkModelAssociator::Context::PopNode(int64* sync_id) {
}
void BookmarkModelAssociator::Context::SetPreAssociationVersions(
- int64 native_version,
- int64 sync_version) {
+ int64_t native_version,
+ int64_t sync_version) {
local_merge_result_->set_pre_association_version(native_version);
syncer_merge_result_->set_pre_association_version(sync_version);
}
@@ -295,7 +295,7 @@ void BookmarkModelAssociator::Context::AddBookmarkRoot(
bookmark_roots_.push_back(root);
}
-int64 BookmarkModelAssociator::Context::GetSyncPreAssociationVersion() const {
+int64_t BookmarkModelAssociator::Context::GetSyncPreAssociationVersion() const {
return syncer_merge_result_->pre_association_version();
}
@@ -332,22 +332,22 @@ syncer::SyncError BookmarkModelAssociator::DisassociateModels() {
return syncer::SyncError();
}
-int64 BookmarkModelAssociator::GetSyncIdFromChromeId(const int64& node_id) {
+int64_t BookmarkModelAssociator::GetSyncIdFromChromeId(const int64_t& node_id) {
BookmarkIdToSyncIdMap::const_iterator iter = id_map_.find(node_id);
return iter == id_map_.end() ? syncer::kInvalidId : iter->second;
}
const BookmarkNode* BookmarkModelAssociator::GetChromeNodeFromSyncId(
- int64 sync_id) {
+ int64_t sync_id) {
SyncIdToBookmarkNodeMap::const_iterator iter = id_map_inverse_.find(sync_id);
return iter == id_map_inverse_.end() ? NULL : iter->second;
}
bool BookmarkModelAssociator::InitSyncNodeFromChromeId(
- const int64& node_id,
+ const int64_t& node_id,
syncer::BaseNode* sync_node) {
DCHECK(sync_node);
- int64 sync_id = GetSyncIdFromChromeId(node_id);
+ int64_t sync_id = GetSyncIdFromChromeId(node_id);
if (sync_id == syncer::kInvalidId)
return false;
if (sync_node->InitByIdLookup(sync_id) != syncer::BaseNode::INIT_OK)
@@ -357,9 +357,9 @@ bool BookmarkModelAssociator::InitSyncNodeFromChromeId(
}
void BookmarkModelAssociator::AddAssociation(const BookmarkNode* node,
- int64 sync_id) {
+ int64_t sync_id) {
DCHECK(thread_checker_.CalledOnValidThread());
- int64 node_id = node->id();
+ int64_t node_id = node->id();
DCHECK_NE(sync_id, syncer::kInvalidId);
DCHECK(id_map_.find(node_id) == id_map_.end());
DCHECK(id_map_inverse_.find(sync_id) == id_map_inverse_.end());
@@ -380,7 +380,7 @@ void BookmarkModelAssociator::Associate(const BookmarkNode* node,
}
}
-void BookmarkModelAssociator::Disassociate(int64 sync_id) {
+void BookmarkModelAssociator::Disassociate(int64_t sync_id) {
DCHECK(thread_checker_.CalledOnValidThread());
SyncIdToBookmarkNodeMap::iterator iter = id_map_inverse_.find(sync_id);
if (iter == id_map_inverse_.end())
@@ -428,7 +428,7 @@ bool BookmarkModelAssociator::AssociateTaggedPermanentNode(
const BookmarkNode* permanent_node,
const std::string& tag) {
// Do nothing if |permanent_node| is already initialized and associated.
- int64 sync_id = GetSyncIdFromChromeId(permanent_node->id());
+ int64_t sync_id = GetSyncIdFromChromeId(permanent_node->id());
if (sync_id != syncer::kInvalidId)
return true;
@@ -496,15 +496,15 @@ syncer::SyncError BookmarkModelAssociator::AssociatePermanentFolders(
// Note: the root node may have additional extra nodes. Currently none of
// them are meant to sync.
- int64 bookmark_bar_sync_id =
+ int64_t bookmark_bar_sync_id =
GetSyncIdFromChromeId(bookmark_model_->bookmark_bar_node()->id());
DCHECK_NE(bookmark_bar_sync_id, syncer::kInvalidId);
context->AddBookmarkRoot(bookmark_model_->bookmark_bar_node());
- int64 other_bookmarks_sync_id =
+ int64_t other_bookmarks_sync_id =
GetSyncIdFromChromeId(bookmark_model_->other_node()->id());
DCHECK_NE(other_bookmarks_sync_id, syncer::kInvalidId);
context->AddBookmarkRoot(bookmark_model_->other_node());
- int64 mobile_bookmarks_sync_id =
+ int64_t mobile_bookmarks_sync_id =
GetSyncIdFromChromeId(bookmark_model_->mobile_node()->id());
if (expect_mobile_bookmarks_folder_)
DCHECK_NE(syncer::kInvalidId, mobile_bookmarks_sync_id);
@@ -569,7 +569,7 @@ syncer::SyncError BookmarkModelAssociator::BuildAssociations(Context* context) {
DCHECK_NE(context->native_model_sync_state(), AHEAD);
int initial_duplicate_count = 0;
- int64 new_version = syncer::syncable::kInvalidTransactionVersion;
+ int64_t new_version = syncer::syncable::kInvalidTransactionVersion;
{
syncer::WriteTransaction trans(FROM_HERE, user_share_, &new_version);
@@ -601,7 +601,7 @@ syncer::SyncError BookmarkModelAssociator::BuildAssociations(Context* context) {
// perform the primary match. If there are multiple match candidates it
// selects the preferred one based on sync node external ID match to the
// bookmark folder ID.
- int64 sync_parent_id;
+ int64_t sync_parent_id;
while (context->PopNode(&sync_parent_id)) {
syncer::ReadNode sync_parent(&trans);
if (sync_parent.InitByIdLookup(sync_parent_id) !=
@@ -620,7 +620,7 @@ syncer::SyncError BookmarkModelAssociator::BuildAssociations(Context* context) {
}
DCHECK(parent_node->is_folder());
- std::vector<int64> children;
+ std::vector<int64_t> children;
sync_parent.GetChildIds(&children);
error = BuildAssociations(&trans, parent_node, children, context);
@@ -662,14 +662,14 @@ syncer::SyncError BookmarkModelAssociator::BuildAssociations(Context* context) {
syncer::SyncError BookmarkModelAssociator::BuildAssociations(
syncer::WriteTransaction* trans,
const BookmarkNode* parent_node,
- const std::vector<int64>& sync_ids,
+ const std::vector<int64_t>& sync_ids,
Context* context) {
BookmarkNodeFinder node_finder(parent_node);
int index = 0;
- for (std::vector<int64>::const_iterator it = sync_ids.begin();
+ for (std::vector<int64_t>::const_iterator it = sync_ids.begin();
it != sync_ids.end(); ++it) {
- int64 sync_child_id = *it;
+ int64_t sync_child_id = *it;
syncer::ReadNode sync_child_node(trans);
if (sync_child_node.InitByIdLookup(sync_child_id) !=
syncer::BaseNode::INIT_OK) {
@@ -677,7 +677,7 @@ syncer::SyncError BookmarkModelAssociator::BuildAssociations(
FROM_HERE, "Failed to lookup node.", model_type());
}
- int64 external_id = sync_child_node.GetExternalId();
+ int64_t external_id = sync_child_node.GetExternalId();
GURL url(sync_child_node.GetBookmarkSpecifics().url());
const BookmarkNode* child_node = node_finder.FindBookmarkNode(
url, sync_child_node.GetTitle(), sync_child_node.GetIsFolder(),
@@ -725,7 +725,7 @@ syncer::SyncError BookmarkModelAssociator::BuildAssociations(
// So the children starting from index in the parent bookmark node are the
// ones that are not present in the parent sync node. So create them.
for (int i = index; i < parent_node->child_count(); ++i) {
- int64 sync_child_id = BookmarkChangeProcessor::CreateSyncNode(
+ int64_t sync_child_id = BookmarkChangeProcessor::CreateSyncNode(
parent_node, bookmark_model_, i, trans, this,
unrecoverable_error_handler_);
if (syncer::kInvalidId == sync_child_id) {
@@ -783,7 +783,7 @@ const BookmarkNode* BookmarkModelAssociator::CreateBookmarkNode(
int BookmarkModelAssociator::RemoveSyncNodeHierarchy(
syncer::WriteTransaction* trans,
- int64 sync_id) {
+ int64_t sync_id) {
syncer::WriteNode sync_node(trans);
if (sync_node.InitByIdLookup(sync_id) != syncer::BaseNode::INIT_OK) {
syncer::SyncError error(FROM_HERE, syncer::SyncError::DATATYPE_ERROR,
@@ -798,11 +798,11 @@ int BookmarkModelAssociator::RemoveSyncNodeHierarchy(
}
struct FolderInfo {
- FolderInfo(const BookmarkNode* f, const BookmarkNode* p, int64 id)
+ FolderInfo(const BookmarkNode* f, const BookmarkNode* p, int64_t id)
: folder(f), parent(p), sync_id(id) {}
const BookmarkNode* folder;
const BookmarkNode* parent;
- int64 sync_id;
+ int64_t sync_id;
};
typedef std::vector<FolderInfo> FolderInfoList;
@@ -818,7 +818,7 @@ void BookmarkModelAssociator::ApplyDeletesFromSyncJournal(
// Make a set of all external IDs in the delete journal,
// ignore entries with unset external IDs.
- std::set<int64> journaled_external_ids;
+ std::set<int64_t> journaled_external_ids;
for (size_t i = 0; i < num_journals_unmatched; i++) {
if (bk_delete_journals[i].external_id != 0)
journaled_external_ids.insert(bk_delete_journals[i].external_id);
@@ -888,7 +888,7 @@ void BookmarkModelAssociator::ApplyDeletesFromSyncJournal(
// Ids of sync nodes not found in bookmark model, meaning the deletions are
// persisted and correponding delete journals can be dropped.
- std::set<int64> journals_to_purge;
+ std::set<int64_t> journals_to_purge;
// Remove empty folders from bottom to top.
for (FolderInfoList::reverse_iterator it = folders_matched.rbegin();
@@ -928,7 +928,7 @@ void BookmarkModelAssociator::PersistAssociations() {
return;
}
- int64 new_version = syncer::syncable::kInvalidTransactionVersion;
+ int64_t new_version = syncer::syncable::kInvalidTransactionVersion;
std::vector<const BookmarkNode*> bnodes;
{
syncer::WriteTransaction trans(FROM_HERE, user_share_, &new_version);
@@ -936,7 +936,7 @@ void BookmarkModelAssociator::PersistAssociations() {
for (iter = dirty_associations_sync_ids_.begin();
iter != dirty_associations_sync_ids_.end();
++iter) {
- int64 sync_id = *iter;
+ int64_t sync_id = *iter;
syncer::WriteNode sync_node(&trans);
if (sync_node.InitByIdLookup(sync_id) != syncer::BaseNode::INIT_OK) {
syncer::SyncError error(
@@ -972,11 +972,11 @@ bool BookmarkModelAssociator::CryptoReadyIfNecessary() {
syncer::SyncError BookmarkModelAssociator::CheckModelSyncState(
Context* context) const {
DCHECK_EQ(context->native_model_sync_state(), UNSET);
- int64 native_version =
+ int64_t native_version =
bookmark_model_->root_node()->sync_transaction_version();
syncer::ReadTransaction trans(FROM_HERE, user_share_);
- int64 sync_version = trans.GetModelVersion(syncer::BOOKMARKS);
+ int64_t sync_version = trans.GetModelVersion(syncer::BOOKMARKS);
context->SetPreAssociationVersions(native_version, sync_version);
if (native_version != syncer::syncable::kInvalidTransactionVersion) {
diff --git a/components/sync_bookmarks/bookmark_model_associator.h b/components/sync_bookmarks/bookmark_model_associator.h
index c7164fa..d5c777c 100644
--- a/components/sync_bookmarks/bookmark_model_associator.h
+++ b/components/sync_bookmarks/bookmark_model_associator.h
@@ -5,15 +5,18 @@
#ifndef COMPONENTS_SYNC_BOOKMARKS_BOOKMARK_MODEL_ASSOCIATOR_H_
#define COMPONENTS_SYNC_BOOKMARKS_BOOKMARK_MODEL_ASSOCIATOR_H_
+#include <stddef.h>
+#include <stdint.h>
+
#include <map>
#include <set>
#include <stack>
#include <string>
#include <vector>
-#include "base/basictypes.h"
#include "base/compiler_specific.h"
#include "base/hash.h"
+#include "base/macros.h"
#include "base/memory/weak_ptr.h"
#include "base/threading/thread_checker.h"
#include "components/sync_driver/data_type_error_handler.h"
@@ -46,7 +49,7 @@ namespace browser_sync {
// * Persisting model associations and loading them back.
class BookmarkModelAssociator
: public sync_driver::
- PerDataTypeAssociatorInterface<bookmarks::BookmarkNode, int64> {
+ PerDataTypeAssociatorInterface<bookmarks::BookmarkNode, int64_t> {
public:
static syncer::ModelType model_type() { return syncer::BOOKMARKS; }
// |expect_mobile_bookmarks_folder| controls whether or not we
@@ -82,24 +85,24 @@ class BookmarkModelAssociator
// Returns sync id for the given bookmark node id.
// Returns syncer::kInvalidId if the sync node is not found for the given
// bookmark node id.
- int64 GetSyncIdFromChromeId(const int64& node_id) override;
+ int64_t GetSyncIdFromChromeId(const int64_t& node_id) override;
// Returns the bookmark node for the given sync id.
// Returns NULL if no bookmark node is found for the given sync id.
const bookmarks::BookmarkNode* GetChromeNodeFromSyncId(
- int64 sync_id) override;
+ int64_t sync_id) override;
// Initializes the given sync node from the given bookmark node id.
// Returns false if no sync node was found for the given bookmark node id or
// if the initialization of sync node fails.
- bool InitSyncNodeFromChromeId(const int64& node_id,
+ bool InitSyncNodeFromChromeId(const int64_t& node_id,
syncer::BaseNode* sync_node) override;
// Associates the given bookmark node with the given sync node.
void Associate(const bookmarks::BookmarkNode* node,
const syncer::BaseNode& sync_node) override;
// Remove the association that corresponds to the given sync id.
- void Disassociate(int64 sync_id) override;
+ void Disassociate(int64_t sync_id) override;
void AbortAssociation() override {
// No implementation needed, this associator runs on the main
@@ -110,15 +113,15 @@ class BookmarkModelAssociator
bool CryptoReadyIfNecessary() override;
private:
- typedef std::map<int64, int64> BookmarkIdToSyncIdMap;
- typedef std::map<int64, const bookmarks::BookmarkNode*>
+ typedef std::map<int64_t, int64_t> BookmarkIdToSyncIdMap;
+ typedef std::map<int64_t, const bookmarks::BookmarkNode*>
SyncIdToBookmarkNodeMap;
- typedef std::set<int64> DirtyAssociationsSyncIds;
+ typedef std::set<int64_t> DirtyAssociationsSyncIds;
typedef std::vector<const bookmarks::BookmarkNode*> BookmarkList;
typedef std::stack<const bookmarks::BookmarkNode*> BookmarkStack;
// Add association between native node and sync node to the maps.
- void AddAssociation(const bookmarks::BookmarkNode* node, int64 sync_id);
+ void AddAssociation(const bookmarks::BookmarkNode* node, int64_t sync_id);
// Posts a task to persist dirty associations.
void PostPersistAssociationsTask();
@@ -154,14 +157,15 @@ class BookmarkModelAssociator
~Context();
// Push a sync node to the DFS stack.
- void PushNode(int64 sync_id);
+ void PushNode(int64_t sync_id);
// Pops a sync node from the DFS stack. Returns false if the stack
// is empty.
- bool PopNode(int64* sync_id);
+ bool PopNode(int64_t* sync_id);
// The following methods are used to update |local_merge_result_| and
// |syncer_merge_result_|.
- void SetPreAssociationVersions(int64 native_version, int64 sync_version);
+ void SetPreAssociationVersions(int64_t native_version,
+ int64_t sync_version);
void SetNumItemsBeforeAssociation(int local_num, int sync_num);
void SetNumItemsAfterAssociation(int local_num, int sync_num);
void IncrementLocalItemsDeleted();
@@ -186,7 +190,7 @@ class BookmarkModelAssociator
const BookmarkList& bookmark_roots() const { return bookmark_roots_; }
// Gets pre-association sync version for Bookmarks datatype.
- int64 GetSyncPreAssociationVersion() const;
+ int64_t GetSyncPreAssociationVersion() const;
void MarkForVersionUpdate(const bookmarks::BookmarkNode* node);
const BookmarkList& bookmarks_for_version_update() const {
@@ -195,7 +199,7 @@ class BookmarkModelAssociator
private:
// DFS stack of sync nodes traversed during association.
- std::stack<int64> dfs_stack_;
+ std::stack<int64_t> dfs_stack_;
// Local and merge results are not owned.
syncer::SyncMergeResult* local_merge_result_;
syncer::SyncMergeResult* syncer_merge_result_;
@@ -262,7 +266,7 @@ class BookmarkModelAssociator
syncer::SyncError BuildAssociations(
syncer::WriteTransaction* trans,
const bookmarks::BookmarkNode* parent_node,
- const std::vector<int64>& sync_ids,
+ const std::vector<int64_t>& sync_ids,
Context* context);
// Helper method for creating a new native bookmark node.
@@ -276,7 +280,7 @@ class BookmarkModelAssociator
// Helper method for deleting a sync node and all its children.
// Returns the number of sync nodes deleted.
- int RemoveSyncNodeHierarchy(syncer::WriteTransaction* trans, int64 sync_id);
+ int RemoveSyncNodeHierarchy(syncer::WriteTransaction* trans, int64_t sync_id);
// Check whether bookmark model and sync model are synced by comparing
// their transaction versions.
diff --git a/components/sync_driver/backend_migrator.h b/components/sync_driver/backend_migrator.h
index 89f5ec5..dfda73c 100644
--- a/components/sync_driver/backend_migrator.h
+++ b/components/sync_driver/backend_migrator.h
@@ -8,6 +8,7 @@
#include <string>
#include "base/compiler_specific.h"
+#include "base/macros.h"
#include "base/memory/weak_ptr.h"
#include "base/observer_list.h"
#include "components/sync_driver/data_type_manager.h"
diff --git a/components/sync_driver/backup_rollback_controller.h b/components/sync_driver/backup_rollback_controller.h
index cd9e331..f8b6b26 100644
--- a/components/sync_driver/backup_rollback_controller.h
+++ b/components/sync_driver/backup_rollback_controller.h
@@ -6,6 +6,7 @@
#define COMPONENTS_SYNC_DRIVER_BACKUP_ROLLBACK_CONTROLLER_H_
#include "base/callback.h"
+#include "base/macros.h"
#include "base/memory/weak_ptr.h"
class SigninManagerWrapper;
diff --git a/components/sync_driver/change_processor.h b/components/sync_driver/change_processor.h
index 30762be..e441548 100644
--- a/components/sync_driver/change_processor.h
+++ b/components/sync_driver/change_processor.h
@@ -5,6 +5,9 @@
#ifndef COMPONENTS_SYNC_DRIVER_CHANGE_PROCESSOR_H_
#define COMPONENTS_SYNC_DRIVER_CHANGE_PROCESSOR_H_
+#include <stdint.h>
+
+#include "base/macros.h"
#include "components/sync_driver/data_type_error_handler.h"
#include "sync/internal_api/public/base_transaction.h"
#include "sync/internal_api/public/change_record.h"
@@ -36,7 +39,7 @@ class ChangeProcessor {
// applied to the frontend model.
virtual void ApplyChangesFromSyncModel(
const syncer::BaseTransaction* trans,
- int64 model_version,
+ int64_t model_version,
const syncer::ImmutableChangeRecordList& changes) = 0;
// The changes found in ApplyChangesFromSyncModel may be too slow to be
diff --git a/components/sync_driver/change_processor_mock.h b/components/sync_driver/change_processor_mock.h
index 5bb43606..a2743cd 100644
--- a/components/sync_driver/change_processor_mock.h
+++ b/components/sync_driver/change_processor_mock.h
@@ -5,6 +5,8 @@
#ifndef COMPONENTS_SYNC_DRIVER_CHANGE_PROCESSOR_MOCK_H_
#define COMPONENTS_SYNC_DRIVER_CHANGE_PROCESSOR_MOCK_H_
+#include <stdint.h>
+
#include <string>
#include "components/sync_driver/change_processor.h"
@@ -20,7 +22,8 @@ class ChangeProcessorMock
ChangeProcessorMock();
virtual ~ChangeProcessorMock();
MOCK_METHOD3(ApplyChangesFromSyncModel,
- void(const syncer::BaseTransaction*, int64,
+ void(const syncer::BaseTransaction*,
+ int64_t,
const syncer::ImmutableChangeRecordList&));
MOCK_METHOD0(CommitChangesFromSyncModel, void());
MOCK_METHOD0(StartImpl, void());
diff --git a/components/sync_driver/data_type_encryption_handler.h b/components/sync_driver/data_type_encryption_handler.h
index 71e7018..65451bf 100644
--- a/components/sync_driver/data_type_encryption_handler.h
+++ b/components/sync_driver/data_type_encryption_handler.h
@@ -5,7 +5,6 @@
#ifndef COMPONENTS_SYNC_DRIVER_DATA_TYPE_ENCRYPTION_HANDLER_H_
#define COMPONENTS_SYNC_DRIVER_DATA_TYPE_ENCRYPTION_HANDLER_H_
-#include "base/basictypes.h"
#include "sync/internal_api/public/base/model_type.h"
namespace sync_driver {
diff --git a/components/sync_driver/data_type_manager_impl.h b/components/sync_driver/data_type_manager_impl.h
index 692d27f..3c198c3 100644
--- a/components/sync_driver/data_type_manager_impl.h
+++ b/components/sync_driver/data_type_manager_impl.h
@@ -11,9 +11,9 @@
#include <queue>
#include <vector>
-#include "base/basictypes.h"
#include "base/callback_forward.h"
#include "base/compiler_specific.h"
+#include "base/macros.h"
#include "base/memory/weak_ptr.h"
#include "base/time/time.h"
#include "components/sync_driver/backend_data_type_configurer.h"
diff --git a/components/sync_driver/device_info.h b/components/sync_driver/device_info.h
index a6c0955..2cfc418 100644
--- a/components/sync_driver/device_info.h
+++ b/components/sync_driver/device_info.h
@@ -7,8 +7,8 @@
#include <string>
-#include "base/basictypes.h"
#include "base/callback.h"
+#include "base/macros.h"
#include "sync/protocol/sync.pb.h"
namespace base {
diff --git a/components/sync_driver/device_info_data_type_controller.h b/components/sync_driver/device_info_data_type_controller.h
index dbf669c..217f47c 100644
--- a/components/sync_driver/device_info_data_type_controller.h
+++ b/components/sync_driver/device_info_data_type_controller.h
@@ -5,6 +5,7 @@
#ifndef COMPONENTS_SYNC_DRIVER_DEVICE_INFO_DATA_TYPE_CONTROLLER_H_
#define COMPONENTS_SYNC_DRIVER_DEVICE_INFO_DATA_TYPE_CONTROLLER_H_
+#include "base/macros.h"
#include "base/memory/scoped_ptr.h"
#include "base/single_thread_task_runner.h"
#include "components/sync_driver/local_device_info_provider.h"
diff --git a/components/sync_driver/device_info_service.h b/components/sync_driver/device_info_service.h
index 4c8ac29..fdd649b 100644
--- a/components/sync_driver/device_info_service.h
+++ b/components/sync_driver/device_info_service.h
@@ -5,6 +5,8 @@
#ifndef COMPONENTS_SYNC_DRIVER_DEVICE_INFO_SERVICE_H_
#define COMPONENTS_SYNC_DRIVER_DEVICE_INFO_SERVICE_H_
+#include <stdint.h>
+
#include <map>
#include <string>
#include <vector>
@@ -89,11 +91,11 @@ class DeviceInfoService : public syncer_v2::ModelTypeService,
void OnProviderInitialized();
// |local_device_backup_time_| accessors.
- int64 local_device_backup_time() const { return local_device_backup_time_; }
+ int64_t local_device_backup_time() const { return local_device_backup_time_; }
bool has_local_device_backup_time() const {
return local_device_backup_time_ >= 0;
}
- void set_local_device_backup_time(int64 value) {
+ void set_local_device_backup_time(int64_t value) {
local_device_backup_time_ = value;
}
void clear_local_device_backup_time() { local_device_backup_time_ = -1; }
@@ -101,7 +103,7 @@ class DeviceInfoService : public syncer_v2::ModelTypeService,
// TODO(skym): Remove once we remove local provider.
// Local device last set backup time (in proto format).
// -1 if the value hasn't been specified
- int64 local_device_backup_time_;
+ int64_t local_device_backup_time_;
// |local_device_info_provider_| isn't owned.
const sync_driver::LocalDeviceInfoProvider* const local_device_info_provider_;
diff --git a/components/sync_driver/device_info_sync_service.cc b/components/sync_driver/device_info_sync_service.cc
index 65b9418..8005e97 100644
--- a/components/sync_driver/device_info_sync_service.cc
+++ b/components/sync_driver/device_info_sync_service.cc
@@ -4,6 +4,8 @@
#include "components/sync_driver/device_info_sync_service.h"
+#include <stddef.h>
+
#include "base/metrics/histogram_macros.h"
#include "base/strings/stringprintf.h"
#include "components/sync_driver/local_device_info_provider.h"
@@ -108,7 +110,7 @@ SyncMergeResult DeviceInfoSyncService::MergeDataAndStartSyncing(
// Retrieve local device backup timestamp value from the sync data.
bool has_synced_backup_time =
iter->GetSpecifics().device_info().has_backup_timestamp();
- int64 synced_backup_time =
+ int64_t synced_backup_time =
has_synced_backup_time
? iter->GetSpecifics().device_info().backup_timestamp()
: -1;
diff --git a/components/sync_driver/device_info_sync_service.h b/components/sync_driver/device_info_sync_service.h
index 2f1e89a..7d529bb 100644
--- a/components/sync_driver/device_info_sync_service.h
+++ b/components/sync_driver/device_info_sync_service.h
@@ -5,9 +5,12 @@
#ifndef COMPONENTS_SYNC_DRIVER_DEVICE_INFO_SYNC_SERVICE_H_
#define COMPONENTS_SYNC_DRIVER_DEVICE_INFO_SYNC_SERVICE_H_
+#include <stdint.h>
+
#include <map>
#include <string>
+#include "base/macros.h"
#include "base/memory/scoped_ptr.h"
#include "base/memory/scoped_vector.h"
#include "base/observer_list.h"
@@ -77,18 +80,18 @@ class DeviceInfoSyncService : public syncer::SyncableService,
bool UpdateBackupTime(syncer::SyncData* sync_data);
// |local_device_backup_time_| accessors.
- int64 local_device_backup_time() const { return local_device_backup_time_; }
+ int64_t local_device_backup_time() const { return local_device_backup_time_; }
bool has_local_device_backup_time() const {
return local_device_backup_time_ >= 0;
}
- void set_local_device_backup_time(int64 value) {
+ void set_local_device_backup_time(int64_t value) {
local_device_backup_time_ = value;
}
void clear_local_device_backup_time() { local_device_backup_time_ = -1; }
// Local device last set backup time (in proto format).
// -1 if the value hasn't been specified
- int64 local_device_backup_time_;
+ int64_t local_device_backup_time_;
// |local_device_info_provider_| isn't owned.
const LocalDeviceInfoProvider* const local_device_info_provider_;
diff --git a/components/sync_driver/device_info_sync_service_unittest.cc b/components/sync_driver/device_info_sync_service_unittest.cc
index 559ca2a..9592b71 100644
--- a/components/sync_driver/device_info_sync_service_unittest.cc
+++ b/components/sync_driver/device_info_sync_service_unittest.cc
@@ -4,6 +4,9 @@
#include "components/sync_driver/device_info_sync_service.h"
+#include <stddef.h>
+#include <stdint.h>
+
#include <string>
#include "components/sync_driver/local_device_info_provider_mock.h"
@@ -110,7 +113,7 @@ class DeviceInfoSyncServiceTest : public testing::Test,
SyncData CreateRemoteData(const std::string& client_id,
const std::string& client_name,
- int64 backup_timestamp = 0) {
+ int64_t backup_timestamp = 0) {
sync_pb::EntitySpecifics entity;
sync_pb::DeviceInfoSpecifics& specifics = *entity.mutable_device_info();
diff --git a/components/sync_driver/fake_generic_change_processor.h b/components/sync_driver/fake_generic_change_processor.h
index f961839..4eb69d4 100644
--- a/components/sync_driver/fake_generic_change_processor.h
+++ b/components/sync_driver/fake_generic_change_processor.h
@@ -7,6 +7,7 @@
#include <string>
+#include "base/macros.h"
#include "components/sync_driver/generic_change_processor.h"
#include "components/sync_driver/generic_change_processor_factory.h"
#include "components/sync_driver/sync_api_component_factory.h"
diff --git a/components/sync_driver/fake_sync_client.h b/components/sync_driver/fake_sync_client.h
index de07659..81cfe68 100644
--- a/components/sync_driver/fake_sync_client.h
+++ b/components/sync_driver/fake_sync_client.h
@@ -5,6 +5,7 @@
#ifndef COMPONENTS_SYNC_DRIVER_FAKE_SYNC_CLIENT_H_
#define COMPONENTS_SYNC_DRIVER_FAKE_SYNC_CLIENT_H_
+#include "base/macros.h"
#include "components/sync_driver/sync_client.h"
namespace sync_driver {
diff --git a/components/sync_driver/frontend_data_type_controller.h b/components/sync_driver/frontend_data_type_controller.h
index 9a0bb8a..27776f0 100644
--- a/components/sync_driver/frontend_data_type_controller.h
+++ b/components/sync_driver/frontend_data_type_controller.h
@@ -7,8 +7,8 @@
#include <string>
-#include "base/basictypes.h"
#include "base/compiler_specific.h"
+#include "base/macros.h"
#include "base/memory/scoped_ptr.h"
#include "base/threading/thread_checker.h"
#include "components/sync_driver/data_type_error_handler.h"
diff --git a/components/sync_driver/generic_change_processor.cc b/components/sync_driver/generic_change_processor.cc
index b1ffb70..c64aa2f 100644
--- a/components/sync_driver/generic_change_processor.cc
+++ b/components/sync_driver/generic_change_processor.cc
@@ -4,6 +4,8 @@
#include "components/sync_driver/generic_change_processor.h"
+#include <stddef.h>
+
#include <algorithm>
#include <string>
@@ -64,7 +66,7 @@ void SetAttachmentMetadata(const syncer::AttachmentIdList& attachment_ids,
}
syncer::SyncData BuildRemoteSyncData(
- int64 sync_id,
+ int64_t sync_id,
const syncer::BaseNode& read_node,
const syncer::AttachmentServiceProxy& attachment_service_proxy) {
const syncer::AttachmentIdList& attachment_ids = read_node.GetAttachmentIds();
@@ -137,7 +139,7 @@ GenericChangeProcessor::~GenericChangeProcessor() {
void GenericChangeProcessor::ApplyChangesFromSyncModel(
const syncer::BaseTransaction* trans,
- int64 model_version,
+ int64_t model_version,
const syncer::ImmutableChangeRecordList& changes) {
DCHECK(CalledOnValidThread());
DCHECK(syncer_changes_.empty());
@@ -257,10 +259,10 @@ syncer::SyncError GenericChangeProcessor::GetAllSyncDataReturnError(
// TODO(akalin): We'll have to do a tree traversal for bookmarks.
DCHECK_NE(type_, syncer::BOOKMARKS);
- std::vector<int64> child_ids;
+ std::vector<int64_t> child_ids;
root.GetChildIds(&child_ids);
- for (std::vector<int64>::iterator it = child_ids.begin();
+ for (std::vector<int64_t>::iterator it = child_ids.begin();
it != child_ids.end(); ++it) {
syncer::ReadNode sync_child_node(&trans);
if (sync_child_node.InitByIdLookup(*it) !=
diff --git a/components/sync_driver/generic_change_processor.h b/components/sync_driver/generic_change_processor.h
index 7aeaf4a..7586d32 100644
--- a/components/sync_driver/generic_change_processor.h
+++ b/components/sync_driver/generic_change_processor.h
@@ -5,10 +5,13 @@
#ifndef COMPONENTS_SYNC_DRIVER_GENERIC_CHANGE_PROCESSOR_H_
#define COMPONENTS_SYNC_DRIVER_GENERIC_CHANGE_PROCESSOR_H_
+#include <stdint.h>
+
#include <string>
#include <vector>
#include "base/compiler_specific.h"
+#include "base/macros.h"
#include "base/memory/weak_ptr.h"
#include "base/threading/non_thread_safe.h"
#include "components/sync_driver/change_processor.h"
@@ -63,7 +66,7 @@ class GenericChangeProcessor : public ChangeProcessor,
// Build and store a list of all changes into |syncer_changes_|.
void ApplyChangesFromSyncModel(
const syncer::BaseTransaction* trans,
- int64 version,
+ int64_t version,
const syncer::ImmutableChangeRecordList& changes) override;
// Passes |syncer_changes_|, built in ApplyChangesFromSyncModel, onto
// |local_service_| by way of its ProcessSyncChanges method.
diff --git a/components/sync_driver/generic_change_processor_factory.h b/components/sync_driver/generic_change_processor_factory.h
index aef2373..6b18079 100644
--- a/components/sync_driver/generic_change_processor_factory.h
+++ b/components/sync_driver/generic_change_processor_factory.h
@@ -5,6 +5,7 @@
#ifndef COMPONENTS_SYNC_DRIVER_GENERIC_CHANGE_PROCESSOR_FACTORY_H_
#define COMPONENTS_SYNC_DRIVER_GENERIC_CHANGE_PROCESSOR_FACTORY_H_
+#include "base/macros.h"
#include "base/memory/weak_ptr.h"
#include "sync/internal_api/public/base/model_type.h"
diff --git a/components/sync_driver/generic_change_processor_unittest.cc b/components/sync_driver/generic_change_processor_unittest.cc
index 3d75db1..17fd06d 100644
--- a/components/sync_driver/generic_change_processor_unittest.cc
+++ b/components/sync_driver/generic_change_processor_unittest.cc
@@ -4,6 +4,8 @@
#include "components/sync_driver/generic_change_processor.h"
+#include <stddef.h>
+
#include <string>
#include "base/memory/scoped_ptr.h"
diff --git a/components/sync_driver/glue/browser_thread_model_worker.h b/components/sync_driver/glue/browser_thread_model_worker.h
index a3d15be..cee50a0 100644
--- a/components/sync_driver/glue/browser_thread_model_worker.h
+++ b/components/sync_driver/glue/browser_thread_model_worker.h
@@ -5,9 +5,9 @@
#ifndef COMPONENTS_SYNC_DRIVER_GLUE_BROWSER_THREAD_MODEL_WORKER_H_
#define COMPONENTS_SYNC_DRIVER_GLUE_BROWSER_THREAD_MODEL_WORKER_H_
-#include "base/basictypes.h"
#include "base/callback_forward.h"
#include "base/compiler_specific.h"
+#include "base/macros.h"
#include "sync/internal_api/public/engine/model_safe_worker.h"
#include "sync/internal_api/public/util/syncer_error.h"
diff --git a/components/sync_driver/glue/sync_backend_host.h b/components/sync_driver/glue/sync_backend_host.h
index 7dfe96e..081c315 100644
--- a/components/sync_driver/glue/sync_backend_host.h
+++ b/components/sync_driver/glue/sync_backend_host.h
@@ -7,9 +7,9 @@
#include <string>
-#include "base/basictypes.h"
#include "base/callback.h"
#include "base/compiler_specific.h"
+#include "base/macros.h"
#include "base/memory/scoped_ptr.h"
#include "base/threading/thread.h"
#include "components/sync_driver/backend_data_type_configurer.h"
diff --git a/components/sync_driver/glue/sync_backend_host_core.cc b/components/sync_driver/glue/sync_backend_host_core.cc
index 31181ebc..28e77e0 100644
--- a/components/sync_driver/glue/sync_backend_host_core.cc
+++ b/components/sync_driver/glue/sync_backend_host_core.cc
@@ -86,7 +86,7 @@ DoInitializeOptions::DoInitializeOptions(
const base::Closure& report_unrecoverable_error_function,
scoped_ptr<syncer::SyncEncryptionHandler::NigoriState> saved_nigori_state,
syncer::PassphraseTransitionClearDataOption clear_data_option,
- const std::map<syncer::ModelType, int64>& invalidation_versions)
+ const std::map<syncer::ModelType, int64_t>& invalidation_versions)
: sync_loop(sync_loop),
registrar(registrar),
routing_info(routing_info),
diff --git a/components/sync_driver/glue/sync_backend_host_core.h b/components/sync_driver/glue/sync_backend_host_core.h
index 9fcd0fa..404732c 100644
--- a/components/sync_driver/glue/sync_backend_host_core.h
+++ b/components/sync_driver/glue/sync_backend_host_core.h
@@ -5,6 +5,8 @@
#ifndef COMPONENTS_SYNC_DRIVER_GLUE_SYNC_BACKEND_HOST_CORE_H_
#define COMPONENTS_SYNC_DRIVER_GLUE_SYNC_BACKEND_HOST_CORE_H_
+#include <stdint.h>
+
#include "base/macros.h"
#include "base/memory/ref_counted.h"
#include "base/timer/timer.h"
@@ -45,7 +47,7 @@ struct DoInitializeOptions {
const base::Closure& report_unrecoverable_error_function,
scoped_ptr<syncer::SyncEncryptionHandler::NigoriState> saved_nigori_state,
syncer::PassphraseTransitionClearDataOption clear_data_option,
- const std::map<syncer::ModelType, int64>& invalidation_versions);
+ const std::map<syncer::ModelType, int64_t>& invalidation_versions);
~DoInitializeOptions();
base::MessageLoop* sync_loop;
@@ -71,7 +73,7 @@ struct DoInitializeOptions {
base::Closure report_unrecoverable_error_function;
scoped_ptr<syncer::SyncEncryptionHandler::NigoriState> saved_nigori_state;
const syncer::PassphraseTransitionClearDataOption clear_data_option;
- const std::map<syncer::ModelType, int64> invalidation_versions;
+ const std::map<syncer::ModelType, int64_t> invalidation_versions;
};
// Helper struct to handle currying params to
@@ -320,7 +322,7 @@ class SyncBackendHostCore
// received invalidation version for each type.
// This allows dropping any invalidations with versions older than those
// most recently received for that data type.
- std::map<syncer::ModelType, int64> last_invalidation_versions_;
+ std::map<syncer::ModelType, int64_t> last_invalidation_versions_;
base::WeakPtrFactory<SyncBackendHostCore> weak_ptr_factory_;
diff --git a/components/sync_driver/glue/sync_backend_host_impl.cc b/components/sync_driver/glue/sync_backend_host_impl.cc
index eeb4712..a5e90ff 100644
--- a/components/sync_driver/glue/sync_backend_host_impl.cc
+++ b/components/sync_driver/glue/sync_backend_host_impl.cc
@@ -116,7 +116,7 @@ void SyncBackendHostImpl::Initialize(
if (cl->HasSwitch(switches::kSyncEnableClearDataOnPassphraseEncryption))
clear_data_option = syncer::PASSPHRASE_TRANSITION_CLEAR_DATA;
- std::map<syncer::ModelType, int64> invalidation_versions;
+ std::map<syncer::ModelType, int64_t> invalidation_versions;
sync_prefs_->GetInvalidationVersions(&invalidation_versions);
scoped_ptr<DoInitializeOptions> init_opts(new DoInitializeOptions(
@@ -828,7 +828,7 @@ void SyncBackendHostImpl::HandleDirectoryStatusCountersUpdatedOnFrontendLoop(
}
void SyncBackendHostImpl::UpdateInvalidationVersions(
- const std::map<syncer::ModelType, int64>& invalidation_versions) {
+ const std::map<syncer::ModelType, int64_t>& invalidation_versions) {
sync_prefs_->UpdateInvalidationVersions(invalidation_versions);
}
diff --git a/components/sync_driver/glue/sync_backend_host_impl.h b/components/sync_driver/glue/sync_backend_host_impl.h
index c8d5968..ed11743 100644
--- a/components/sync_driver/glue/sync_backend_host_impl.h
+++ b/components/sync_driver/glue/sync_backend_host_impl.h
@@ -5,11 +5,13 @@
#ifndef COMPONENTS_SYNC_DRIVER_GLUE_SYNC_BACKEND_HOST_IMPL_H_
#define COMPONENTS_SYNC_DRIVER_GLUE_SYNC_BACKEND_HOST_IMPL_H_
+#include <stdint.h>
+
#include <string>
-#include "base/basictypes.h"
#include "base/callback.h"
#include "base/compiler_specific.h"
+#include "base/macros.h"
#include "base/memory/scoped_ptr.h"
#include "base/memory/weak_ptr.h"
#include "base/threading/thread.h"
@@ -220,7 +222,7 @@ class SyncBackendHostImpl
// Overwrites the kSyncInvalidationVersions preference with the most recent
// set of invalidation versions for each type.
void UpdateInvalidationVersions(
- const std::map<syncer::ModelType, int64>& invalidation_versions);
+ const std::map<syncer::ModelType, int64_t>& invalidation_versions);
sync_driver::SyncFrontend* frontend() {
return frontend_;
diff --git a/components/sync_driver/glue/sync_backend_host_impl_unittest.cc b/components/sync_driver/glue/sync_backend_host_impl_unittest.cc
index f34cf97..d90ff59 100644
--- a/components/sync_driver/glue/sync_backend_host_impl_unittest.cc
+++ b/components/sync_driver/glue/sync_backend_host_impl_unittest.cc
@@ -4,6 +4,8 @@
#include "components/sync_driver/glue/sync_backend_host_impl.h"
+#include <stdint.h>
+
#include <cstddef>
#include <map>
@@ -795,7 +797,7 @@ TEST_F(SyncBackendHostTest, ClearServerDataCallsAreForwarded) {
// set of invalidation version is persisted across restarts.
TEST_F(SyncBackendHostTest, IgnoreOldInvalidations) {
// Set up some old persisted invalidations.
- std::map<syncer::ModelType, int64> invalidation_versions;
+ std::map<syncer::ModelType, int64_t> invalidation_versions;
invalidation_versions[syncer::BOOKMARKS] = 20;
sync_prefs_->UpdateInvalidationVersions(invalidation_versions);
InitializeBackend(true);
@@ -843,7 +845,7 @@ TEST_F(SyncBackendHostTest, IgnoreOldInvalidations) {
// Verify that the invalidation versions were updated in the prefs.
invalidation_versions[syncer::BOOKMARKS] = 30;
invalidation_versions[syncer::SESSIONS] = 10;
- std::map<syncer::ModelType, int64> persisted_invalidation_versions;
+ std::map<syncer::ModelType, int64_t> persisted_invalidation_versions;
sync_prefs_->GetInvalidationVersions(&persisted_invalidation_versions);
EXPECT_EQ(invalidation_versions.size(),
persisted_invalidation_versions.size());
diff --git a/components/sync_driver/glue/sync_backend_registrar.cc b/components/sync_driver/glue/sync_backend_registrar.cc
index 3b67b97..263224e 100644
--- a/components/sync_driver/glue/sync_backend_registrar.cc
+++ b/components/sync_driver/glue/sync_backend_registrar.cc
@@ -185,7 +185,7 @@ bool SyncBackendRegistrar::IsTypeActivatedForTest(
void SyncBackendRegistrar::OnChangesApplied(
syncer::ModelType model_type,
- int64 model_version,
+ int64_t model_version,
const syncer::BaseTransaction* trans,
const syncer::ImmutableChangeRecordList& changes) {
sync_driver::ChangeProcessor* processor = GetProcessor(model_type);
diff --git a/components/sync_driver/glue/sync_backend_registrar.h b/components/sync_driver/glue/sync_backend_registrar.h
index 5c4fb59..8e3674f 100644
--- a/components/sync_driver/glue/sync_backend_registrar.h
+++ b/components/sync_driver/glue/sync_backend_registrar.h
@@ -5,11 +5,13 @@
#ifndef COMPONENTS_SYNC_DRIVER_GLUE_SYNC_BACKEND_REGISTRAR_H_
#define COMPONENTS_SYNC_DRIVER_GLUE_SYNC_BACKEND_REGISTRAR_H_
+#include <stdint.h>
+
#include <map>
#include <vector>
-#include "base/basictypes.h"
#include "base/compiler_specific.h"
+#include "base/macros.h"
#include "base/memory/ref_counted.h"
#include "base/synchronization/lock.h"
#include "base/threading/thread.h"
@@ -111,7 +113,7 @@ class SyncBackendRegistrar : public syncer::SyncManager::ChangeDelegate,
// any thread.
void OnChangesApplied(
syncer::ModelType model_type,
- int64 model_version,
+ int64_t model_version,
const syncer::BaseTransaction* trans,
const syncer::ImmutableChangeRecordList& changes) override;
void OnChangesComplete(syncer::ModelType model_type) override;
diff --git a/components/sync_driver/glue/ui_model_worker.h b/components/sync_driver/glue/ui_model_worker.h
index 1a2269c..4c4cdbbd 100644
--- a/components/sync_driver/glue/ui_model_worker.h
+++ b/components/sync_driver/glue/ui_model_worker.h
@@ -7,6 +7,7 @@
#include "base/callback.h"
#include "base/compiler_specific.h"
+#include "base/macros.h"
#include "base/single_thread_task_runner.h"
#include "base/synchronization/condition_variable.h"
#include "base/synchronization/lock.h"
diff --git a/components/sync_driver/glue/ui_model_worker_unittest.cc b/components/sync_driver/glue/ui_model_worker_unittest.cc
index ec7bc88..3fde232 100644
--- a/components/sync_driver/glue/ui_model_worker_unittest.cc
+++ b/components/sync_driver/glue/ui_model_worker_unittest.cc
@@ -8,6 +8,7 @@
#include "base/bind_helpers.h"
#include "base/callback.h"
#include "base/location.h"
+#include "base/macros.h"
#include "base/memory/ref_counted.h"
#include "base/memory/scoped_ptr.h"
#include "base/single_thread_task_runner.h"
diff --git a/components/sync_driver/invalidation_adapter.cc b/components/sync_driver/invalidation_adapter.cc
index a7cc8d5..dcc14d6 100644
--- a/components/sync_driver/invalidation_adapter.cc
+++ b/components/sync_driver/invalidation_adapter.cc
@@ -24,7 +24,7 @@ const std::string& InvalidationAdapter::GetPayload() const {
return invalidation_.payload();
}
-int64 InvalidationAdapter::GetVersion() const {
+int64_t InvalidationAdapter::GetVersion() const {
return invalidation_.version();
}
diff --git a/components/sync_driver/invalidation_adapter.h b/components/sync_driver/invalidation_adapter.h
index 3377f54..45a30f6 100644
--- a/components/sync_driver/invalidation_adapter.h
+++ b/components/sync_driver/invalidation_adapter.h
@@ -5,6 +5,8 @@
#ifndef COMPONENTS_SYNC_DRIVER_INVALIDATION_ADAPTER_H_
#define COMPONENTS_SYNC_DRIVER_INVALIDATION_ADAPTER_H_
+#include <stdint.h>
+
#include <string>
#include "components/invalidation/public/invalidation.h"
@@ -21,7 +23,7 @@ class InvalidationAdapter : public syncer::InvalidationInterface {
// Implementation of InvalidationInterface.
bool IsUnknownVersion() const override;
const std::string& GetPayload() const override;
- int64 GetVersion() const override;
+ int64_t GetVersion() const override;
void Acknowledge() override;
void Drop() override;
diff --git a/components/sync_driver/local_device_info_provider_impl.cc b/components/sync_driver/local_device_info_provider_impl.cc
index 6c2f993..79e737c 100644
--- a/components/sync_driver/local_device_info_provider_impl.cc
+++ b/components/sync_driver/local_device_info_provider_impl.cc
@@ -6,6 +6,7 @@
#include "base/bind.h"
#include "base/task_runner.h"
+#include "build/build_config.h"
#include "components/sync_driver/sync_util.h"
#include "sync/util/get_session_name.h"
diff --git a/components/sync_driver/model_association_manager.cc b/components/sync_driver/model_association_manager.cc
index b732006..b31f4ab 100644
--- a/components/sync_driver/model_association_manager.cc
+++ b/components/sync_driver/model_association_manager.cc
@@ -4,10 +4,14 @@
#include "components/sync_driver/model_association_manager.h"
+#include <stddef.h>
+#include <stdint.h>
+
#include <algorithm>
#include <functional>
#include "base/logging.h"
+#include "base/macros.h"
#include "base/message_loop/message_loop.h"
#include "base/metrics/histogram_macros.h"
#include "base/trace_event/trace_event.h"
@@ -72,7 +76,7 @@ static_assert(arraysize(kStartOrder) ==
// The amount of time we wait for association to finish. If some types haven't
// finished association by the time, DataTypeManager is notified of the
// unfinished types.
-const int64 kAssociationTimeOutInSeconds = 600;
+const int64_t kAssociationTimeOutInSeconds = 600;
syncer::DataTypeAssociationStats BuildAssociationStatsFromMergeResults(
const syncer::SyncMergeResult& local_merge_result,
diff --git a/components/sync_driver/model_association_manager.h b/components/sync_driver/model_association_manager.h
index 6126280..d5f4c58 100644
--- a/components/sync_driver/model_association_manager.h
+++ b/components/sync_driver/model_association_manager.h
@@ -7,6 +7,7 @@
#include <map>
+#include "base/macros.h"
#include "base/memory/weak_ptr.h"
#include "base/timer/timer.h"
diff --git a/components/sync_driver/model_associator.h b/components/sync_driver/model_associator.h
index 4d6e327..0b8f4ab 100644
--- a/components/sync_driver/model_associator.h
+++ b/components/sync_driver/model_associator.h
@@ -5,7 +5,8 @@
#ifndef COMPONENTS_SYNC_DRIVER_MODEL_ASSOCIATOR_H_
#define COMPONENTS_SYNC_DRIVER_MODEL_ASSOCIATOR_H_
-#include "base/basictypes.h"
+#include <stdint.h>
+
#include "base/synchronization/lock.h"
#include "sync/api/sync_error.h"
#include "sync/internal_api/public/base/model_type.h"
@@ -70,11 +71,11 @@ class PerDataTypeAssociatorInterface : public AssociatorInterface {
// Returns sync id for the given chrome model id.
// Returns syncer::kInvalidId if the sync node is not found for the given
// chrome id.
- virtual int64 GetSyncIdFromChromeId(const IDType& id) = 0;
+ virtual int64_t GetSyncIdFromChromeId(const IDType& id) = 0;
// Returns the chrome node for the given sync id.
// Returns NULL if no node is found for the given sync id.
- virtual const Node* GetChromeNodeFromSyncId(int64 sync_id) = 0;
+ virtual const Node* GetChromeNodeFromSyncId(int64_t sync_id) = 0;
// Initializes the given sync node from the given chrome node id.
// Returns false if no sync node was found for the given chrome node id or
@@ -88,7 +89,7 @@ class PerDataTypeAssociatorInterface : public AssociatorInterface {
const syncer::BaseNode& sync_node) = 0;
// Remove the association that corresponds to the given sync id.
- virtual void Disassociate(int64 sync_id) = 0;
+ virtual void Disassociate(int64_t sync_id) = 0;
};
} // namespace sync_driver
diff --git a/components/sync_driver/non_blocking_data_type_controller.h b/components/sync_driver/non_blocking_data_type_controller.h
index eb472e4..b1a3490 100644
--- a/components/sync_driver/non_blocking_data_type_controller.h
+++ b/components/sync_driver/non_blocking_data_type_controller.h
@@ -5,6 +5,7 @@
#ifndef COMPONENTS_SYNC_DRIVER_NON_BLOCKING_DATA_TYPE_CONTROLLER_H_
#define COMPONENTS_SYNC_DRIVER_NON_BLOCKING_DATA_TYPE_CONTROLLER_H_
+#include "base/macros.h"
#include "base/memory/weak_ptr.h"
#include "components/sync_driver/data_type_controller.h"
#include "sync/internal_api/public/base/model_type.h"
diff --git a/components/sync_driver/non_ui_data_type_controller.h b/components/sync_driver/non_ui_data_type_controller.h
index 0b859d4..d3c850b 100644
--- a/components/sync_driver/non_ui_data_type_controller.h
+++ b/components/sync_driver/non_ui_data_type_controller.h
@@ -7,7 +7,6 @@
#include <string>
-#include "base/basictypes.h"
#include "base/compiler_specific.h"
#include "base/memory/ref_counted.h"
#include "base/memory/weak_ptr.h"
diff --git a/components/sync_driver/non_ui_data_type_controller_unittest.cc b/components/sync_driver/non_ui_data_type_controller_unittest.cc
index 61b5e23..db773ba 100644
--- a/components/sync_driver/non_ui_data_type_controller_unittest.cc
+++ b/components/sync_driver/non_ui_data_type_controller_unittest.cc
@@ -11,6 +11,7 @@
#include "base/callback.h"
#include "base/compiler_specific.h"
#include "base/location.h"
+#include "base/macros.h"
#include "base/memory/scoped_ptr.h"
#include "base/single_thread_task_runner.h"
#include "base/synchronization/waitable_event.h"
diff --git a/components/sync_driver/pref_names.cc b/components/sync_driver/pref_names.cc
index 86fa867..8b7afd9 100644
--- a/components/sync_driver/pref_names.cc
+++ b/components/sync_driver/pref_names.cc
@@ -2,6 +2,7 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
+#include "build/build_config.h"
#include "components/sync_driver/pref_names.h"
namespace sync_driver {
diff --git a/components/sync_driver/profile_sync_auth_provider.cc b/components/sync_driver/profile_sync_auth_provider.cc
index 4f269ed..a342871 100644
--- a/components/sync_driver/profile_sync_auth_provider.cc
+++ b/components/sync_driver/profile_sync_auth_provider.cc
@@ -6,6 +6,7 @@
#include "base/bind.h"
#include "base/location.h"
+#include "base/macros.h"
#include "base/single_thread_task_runner.h"
#include "base/thread_task_runner_handle.h"
#include "components/signin/core/browser/profile_oauth2_token_service.h"
diff --git a/components/sync_driver/profile_sync_auth_provider.h b/components/sync_driver/profile_sync_auth_provider.h
index 6b4b4aa..e9dffb9 100644
--- a/components/sync_driver/profile_sync_auth_provider.h
+++ b/components/sync_driver/profile_sync_auth_provider.h
@@ -7,6 +7,7 @@
#include <string>
+#include "base/macros.h"
#include "base/memory/scoped_ptr.h"
#include "base/memory/weak_ptr.h"
#include "google_apis/gaia/oauth2_token_service.h"
diff --git a/components/sync_driver/proxy_data_type_controller.h b/components/sync_driver/proxy_data_type_controller.h
index 2f3127e5..6860a27 100644
--- a/components/sync_driver/proxy_data_type_controller.h
+++ b/components/sync_driver/proxy_data_type_controller.h
@@ -7,8 +7,8 @@
#include <string>
-#include "base/basictypes.h"
#include "base/compiler_specific.h"
+#include "base/macros.h"
#include "base/single_thread_task_runner.h"
#include "components/sync_driver/data_type_controller.h"
diff --git a/components/sync_driver/shared_change_processor.h b/components/sync_driver/shared_change_processor.h
index e8683a5..0695ff2 100644
--- a/components/sync_driver/shared_change_processor.h
+++ b/components/sync_driver/shared_change_processor.h
@@ -8,6 +8,7 @@
#include <string>
#include "base/location.h"
+#include "base/macros.h"
#include "base/memory/ref_counted.h"
#include "base/memory/weak_ptr.h"
#include "base/single_thread_task_runner.h"
diff --git a/components/sync_driver/signin_manager_wrapper.h b/components/sync_driver/signin_manager_wrapper.h
index 51eaed3..cb1398d 100644
--- a/components/sync_driver/signin_manager_wrapper.h
+++ b/components/sync_driver/signin_manager_wrapper.h
@@ -7,7 +7,7 @@
#include <string>
-#include "base/basictypes.h"
+#include "base/macros.h"
class SigninManagerBase;
@@ -34,6 +34,7 @@ class SigninManagerWrapper {
private:
SigninManagerBase* original_;
+
DISALLOW_COPY_AND_ASSIGN(SigninManagerWrapper);
};
diff --git a/components/sync_driver/sync_error_controller.h b/components/sync_driver/sync_error_controller.h
index 1cb77d7..ce623c6 100644
--- a/components/sync_driver/sync_error_controller.h
+++ b/components/sync_driver/sync_error_controller.h
@@ -5,8 +5,8 @@
#ifndef COMPONENTS_SYNC_DRIVER_SYNC_ERROR_CONTROLLER_H_
#define COMPONENTS_SYNC_DRIVER_SYNC_ERROR_CONTROLLER_H_
-#include "base/basictypes.h"
#include "base/compiler_specific.h"
+#include "base/macros.h"
#include "base/observer_list.h"
#include "components/sync_driver/sync_service_observer.h"
diff --git a/components/sync_driver/sync_frontend.h b/components/sync_driver/sync_frontend.h
index 155f1c1..f4ed96d 100644
--- a/components/sync_driver/sync_frontend.h
+++ b/components/sync_driver/sync_frontend.h
@@ -7,7 +7,6 @@
#include <string>
-#include "base/basictypes.h"
#include "sync/internal_api/public/base/model_type.h"
#include "sync/internal_api/public/sync_encryption_handler.h"
#include "sync/internal_api/public/sync_manager.h"
diff --git a/components/sync_driver/sync_policy_handler.h b/components/sync_driver/sync_policy_handler.h
index 4b0be81..7dd6efe 100644
--- a/components/sync_driver/sync_policy_handler.h
+++ b/components/sync_driver/sync_policy_handler.h
@@ -6,6 +6,7 @@
#define COMPONENTS_SYNC_DRIVER_SYNC_POLICY_HANDLER_H_
#include "base/compiler_specific.h"
+#include "base/macros.h"
#include "components/policy/core/browser/configuration_policy_handler.h"
class PrefValueMap;
diff --git a/components/sync_driver/sync_prefs.cc b/components/sync_driver/sync_prefs.cc
index a000fc4..6f005ec 100644
--- a/components/sync_driver/sync_prefs.cc
+++ b/components/sync_driver/sync_prefs.cc
@@ -490,7 +490,7 @@ void SyncPrefs::SetCleanShutdown(bool value) {
}
void SyncPrefs::GetInvalidationVersions(
- std::map<syncer::ModelType, int64>* invalidation_versions) const {
+ std::map<syncer::ModelType, int64_t>* invalidation_versions) const {
const base::DictionaryValue* invalidation_dictionary =
pref_service_->GetDictionary(prefs::kSyncInvalidationVersions);
syncer::ModelTypeSet protocol_types = syncer::ProtocolTypes();
@@ -499,7 +499,7 @@ void SyncPrefs::GetInvalidationVersions(
std::string version_str;
if (!invalidation_dictionary->GetString(key, &version_str))
continue;
- int64 version = 0;
+ int64_t version = 0;
if (!base::StringToInt64(version_str, &version))
continue;
(*invalidation_versions)[iter.Get()] = version;
@@ -507,7 +507,7 @@ void SyncPrefs::GetInvalidationVersions(
}
void SyncPrefs::UpdateInvalidationVersions(
- const std::map<syncer::ModelType, int64>& invalidation_versions) {
+ const std::map<syncer::ModelType, int64_t>& invalidation_versions) {
scoped_ptr<base::DictionaryValue> invalidation_dictionary(
new base::DictionaryValue());
for (const auto& map_iter : invalidation_versions) {
diff --git a/components/sync_driver/sync_prefs.h b/components/sync_driver/sync_prefs.h
index c66564c..7c71f21 100644
--- a/components/sync_driver/sync_prefs.h
+++ b/components/sync_driver/sync_prefs.h
@@ -5,16 +5,19 @@
#ifndef COMPONENTS_SYNC_DRIVER_SYNC_PREFS_H_
#define COMPONENTS_SYNC_DRIVER_SYNC_PREFS_H_
+#include <stdint.h>
+
#include <map>
#include <string>
-#include "base/basictypes.h"
#include "base/compiler_specific.h"
+#include "base/macros.h"
#include "base/memory/weak_ptr.h"
#include "base/observer_list.h"
#include "base/prefs/pref_member.h"
#include "base/threading/non_thread_safe.h"
#include "base/time/time.h"
+#include "build/build_config.h"
#include "sync/internal_api/public/base/model_type.h"
#include "sync/internal_api/public/sync_encryption_handler.h"
@@ -159,9 +162,9 @@ class SyncPrefs : NON_EXPORTED_BASE(public base::NonThreadSafe),
// Get/set for the last known sync invalidation versions.
void GetInvalidationVersions(
- std::map<syncer::ModelType, int64>* invalidation_versions) const;
+ std::map<syncer::ModelType, int64_t>* invalidation_versions) const;
void UpdateInvalidationVersions(
- const std::map<syncer::ModelType, int64>& invalidation_versions);
+ const std::map<syncer::ModelType, int64_t>& invalidation_versions);
// Will return the contents of the LastRunVersion preference. This may be an
// empty string if no version info was present, and is only valid at
diff --git a/components/sync_driver/sync_prefs_unittest.cc b/components/sync_driver/sync_prefs_unittest.cc
index 4ad8b5f..f171266 100644
--- a/components/sync_driver/sync_prefs_unittest.cc
+++ b/components/sync_driver/sync_prefs_unittest.cc
@@ -4,6 +4,8 @@
#include "components/sync_driver/sync_prefs.h"
+#include <stdint.h>
+
#include <map>
#include "base/command_line.h"
@@ -241,7 +243,7 @@ TEST_F(SyncPrefsTest, DeviceInfo) {
// Verify that invalidation versions are persisted and loaded correctly.
TEST_F(SyncPrefsTest, InvalidationVersions) {
- std::map<syncer::ModelType, int64> versions;
+ std::map<syncer::ModelType, int64_t> versions;
versions[syncer::BOOKMARKS] = 10;
versions[syncer::SESSIONS] = 20;
versions[syncer::PREFERENCES] = 30;
@@ -249,7 +251,7 @@ TEST_F(SyncPrefsTest, InvalidationVersions) {
SyncPrefs sync_prefs(&pref_service_);
sync_prefs.UpdateInvalidationVersions(versions);
- std::map<syncer::ModelType, int64> versions2;
+ std::map<syncer::ModelType, int64_t> versions2;
sync_prefs.GetInvalidationVersions(&versions2);
EXPECT_EQ(versions.size(), versions2.size());
diff --git a/components/sync_driver/sync_stopped_reporter.h b/components/sync_driver/sync_stopped_reporter.h
index 8d7cd5c..251ef33 100644
--- a/components/sync_driver/sync_stopped_reporter.h
+++ b/components/sync_driver/sync_stopped_reporter.h
@@ -8,6 +8,7 @@
#include <string>
#include "base/callback.h"
+#include "base/macros.h"
#include "base/timer/timer.h"
#include "net/url_request/url_fetcher.h"
#include "net/url_request/url_fetcher_delegate.h"
diff --git a/components/sync_driver/sync_stopped_reporter_unittest.cc b/components/sync_driver/sync_stopped_reporter_unittest.cc
index d218c8ec..2ae5d20 100644
--- a/components/sync_driver/sync_stopped_reporter_unittest.cc
+++ b/components/sync_driver/sync_stopped_reporter_unittest.cc
@@ -6,6 +6,7 @@
#include <string>
+#include "base/macros.h"
#include "base/message_loop/message_loop.h"
#include "base/run_loop.h"
#include "base/test/test_simple_task_runner.h"
diff --git a/components/sync_driver/sync_util.cc b/components/sync_driver/sync_util.cc
index e0b0c8d..c56b152 100644
--- a/components/sync_driver/sync_util.cc
+++ b/components/sync_driver/sync_util.cc
@@ -6,6 +6,7 @@
#include "base/command_line.h"
#include "base/logging.h"
+#include "build/build_config.h"
#include "components/sync_driver/sync_driver_switches.h"
#include "url/gurl.h"
diff --git a/components/sync_driver/system_encryptor_unittest.cc b/components/sync_driver/system_encryptor_unittest.cc
index f0a6e93..2922834 100644
--- a/components/sync_driver/system_encryptor_unittest.cc
+++ b/components/sync_driver/system_encryptor_unittest.cc
@@ -6,6 +6,7 @@
#include <string>
+#include "build/build_config.h"
#include "components/os_crypt/os_crypt.h"
#include "testing/gtest/include/gtest/gtest.h"
diff --git a/components/sync_driver/ui_data_type_controller.h b/components/sync_driver/ui_data_type_controller.h
index 55641a6..1ce32e1 100644
--- a/components/sync_driver/ui_data_type_controller.h
+++ b/components/sync_driver/ui_data_type_controller.h
@@ -7,8 +7,8 @@
#include <string>
-#include "base/basictypes.h"
#include "base/compiler_specific.h"
+#include "base/macros.h"
#include "base/memory/ref_counted.h"
#include "base/memory/weak_ptr.h"
#include "components/sync_driver/directory_data_type_controller.h"
diff --git a/components/sync_sessions/favicon_cache.cc b/components/sync_sessions/favicon_cache.cc
index 1b7bce5..3055a24 100644
--- a/components/sync_sessions/favicon_cache.cc
+++ b/components/sync_sessions/favicon_cache.cc
@@ -5,6 +5,7 @@
#include "components/sync_sessions/favicon_cache.h"
#include "base/location.h"
+#include "base/macros.h"
#include "base/metrics/histogram.h"
#include "base/single_thread_task_runner.h"
#include "base/thread_task_runner_handle.h"
@@ -508,7 +509,7 @@ bool FaviconCache::GetSyncedFaviconForPageURL(
void FaviconCache::OnReceivedSyncFavicon(const GURL& page_url,
const GURL& icon_url,
const std::string& icon_bytes,
- int64 visit_time_ms) {
+ int64_t visit_time_ms) {
if (!icon_url.is_valid() || !page_url.is_valid() || icon_url.SchemeIs("data"))
return;
DVLOG(1) << "Associating " << page_url.spec() << " with favicon at "
@@ -529,10 +530,9 @@ void FaviconCache::OnReceivedSyncFavicon(const GURL& page_url,
icon_bytes, visit_time_ms));
}
-void FaviconCache::OnReceivedSyncFaviconImpl(
- const GURL& icon_url,
- const std::string& icon_bytes,
- int64 visit_time_ms) {
+void FaviconCache::OnReceivedSyncFaviconImpl(const GURL& icon_url,
+ const std::string& icon_bytes,
+ int64_t visit_time_ms) {
// If this favicon is already synced, do nothing else.
if (synced_favicons_.find(icon_url) != synced_favicons_.end())
return;
diff --git a/components/sync_sessions/favicon_cache.h b/components/sync_sessions/favicon_cache.h
index 1361792..19202ea 100644
--- a/components/sync_sessions/favicon_cache.h
+++ b/components/sync_sessions/favicon_cache.h
@@ -5,14 +5,17 @@
#ifndef COMPONENTS_SYNC_SESSIONS_FAVICON_CACHE_H_
#define COMPONENTS_SYNC_SESSIONS_FAVICON_CACHE_H_
+#include <stddef.h>
+#include <stdint.h>
+
#include <map>
#include <set>
#include <string>
#include <vector>
-#include "base/basictypes.h"
#include "base/compiler_specific.h"
#include "base/gtest_prod_util.h"
+#include "base/macros.h"
#include "base/memory/linked_ptr.h"
#include "base/memory/ref_counted.h"
#include "base/memory/ref_counted_memory.h"
@@ -105,7 +108,7 @@ class FaviconCache : public syncer::SyncableService,
void OnReceivedSyncFavicon(const GURL& page_url,
const GURL& icon_url,
const std::string& icon_bytes,
- int64 visit_time_ms);
+ int64_t visit_time_ms);
private:
friend class SyncFaviconCacheTest;
@@ -132,7 +135,7 @@ class FaviconCache : public syncer::SyncableService,
// whether caller holds a sync transaction.
void OnReceivedSyncFaviconImpl(const GURL& icon_url,
const std::string& icon_bytes,
- int64 visit_time_ms);
+ int64_t visit_time_ms);
// Callback method to store a tab's favicon into its sync node once it becomes
// available. Does nothing if no favicon data was available.
diff --git a/components/sync_sessions/favicon_cache_unittest.cc b/components/sync_sessions/favicon_cache_unittest.cc
index 84a7945..f42b813 100644
--- a/components/sync_sessions/favicon_cache_unittest.cc
+++ b/components/sync_sessions/favicon_cache_unittest.cc
@@ -4,6 +4,10 @@
#include "components/sync_sessions/favicon_cache.h"
+#include <stddef.h>
+#include <stdint.h>
+
+#include "base/macros.h"
#include "base/message_loop/message_loop.h"
#include "base/strings/string_number_conversions.h"
#include "base/strings/stringprintf.h"
@@ -109,7 +113,7 @@ struct TestFaviconData {
std::string image_16;
std::string image_32;
std::string image_64;
- int64 last_visit_time;
+ int64_t last_visit_time;
bool is_bookmarked;
};
@@ -286,7 +290,7 @@ class SyncFaviconCacheTest : public testing::Test {
void TriggerSyncFaviconReceived(const GURL& page_url,
const GURL& icon_url,
const std::string& icon_bytes,
- int64 last_visit_time_ms);
+ int64_t last_visit_time_ms);
private:
base::MessageLoopForUI message_loop_;
@@ -445,7 +449,7 @@ void SyncFaviconCacheTest::TriggerSyncFaviconReceived(
const GURL& page_url,
const GURL& icon_url,
const std::string& icon_bytes,
- int64 last_visit_time_ms) {
+ int64_t last_visit_time_ms) {
cache()->OnReceivedSyncFavicon(page_url,
icon_url,
icon_bytes,
diff --git a/components/sync_sessions/local_session_event_router.h b/components/sync_sessions/local_session_event_router.h
index 67f23b0..8cf9e95 100644
--- a/components/sync_sessions/local_session_event_router.h
+++ b/components/sync_sessions/local_session_event_router.h
@@ -7,7 +7,6 @@
#include <set>
-#include "base/basictypes.h"
#include "base/macros.h"
#include "url/gurl.h"
diff --git a/components/sync_sessions/open_tabs_ui_delegate.h b/components/sync_sessions/open_tabs_ui_delegate.h
index 4b887c0..911b83e9 100644
--- a/components/sync_sessions/open_tabs_ui_delegate.h
+++ b/components/sync_sessions/open_tabs_ui_delegate.h
@@ -8,7 +8,6 @@
#include <string>
#include <vector>
-#include "base/basictypes.h"
#include "base/memory/ref_counted.h"
#include "base/memory/ref_counted_memory.h"
#include "components/sessions/core/session_id.h"
diff --git a/components/sync_sessions/revisit/current_tab_matcher.h b/components/sync_sessions/revisit/current_tab_matcher.h
index a1a9080..2aa037c 100644
--- a/components/sync_sessions/revisit/current_tab_matcher.h
+++ b/components/sync_sessions/revisit/current_tab_matcher.h
@@ -6,6 +6,7 @@
#define COMPONENTS_SYNC_SESSIONS_REVISIT_CURRENT_TAB_MATCHER_H_
#include "base/gtest_prod_util.h"
+#include "base/macros.h"
#include "components/sync_sessions/revisit/page_equality.h"
#include "components/sync_sessions/revisit/page_visit_observer.h"
diff --git a/components/sync_sessions/revisit/offset_tab_matcher.cc b/components/sync_sessions/revisit/offset_tab_matcher.cc
index 7cbb7ec..5ca1434 100644
--- a/components/sync_sessions/revisit/offset_tab_matcher.cc
+++ b/components/sync_sessions/revisit/offset_tab_matcher.cc
@@ -4,6 +4,8 @@
#include "components/sync_sessions/revisit/offset_tab_matcher.h"
+#include <stddef.h>
+
#include <algorithm>
#include "base/metrics/histogram_macros.h"
diff --git a/components/sync_sessions/revisit/offset_tab_matcher.h b/components/sync_sessions/revisit/offset_tab_matcher.h
index ff68f8f..725b05b 100644
--- a/components/sync_sessions/revisit/offset_tab_matcher.h
+++ b/components/sync_sessions/revisit/offset_tab_matcher.h
@@ -5,6 +5,7 @@
#ifndef COMPONENTS_SYNC_SESSIONS_REVISIT_OFFSET_TAB_MATCHER_H_
#define COMPONENTS_SYNC_SESSIONS_REVISIT_OFFSET_TAB_MATCHER_H_
+#include "base/macros.h"
#include "components/sync_sessions/revisit/page_equality.h"
#include "components/sync_sessions/revisit/page_visit_observer.h"
diff --git a/components/sync_sessions/revisit/page_revisit_broadcaster.cc b/components/sync_sessions/revisit/page_revisit_broadcaster.cc
index 094e666..6b5767c 100644
--- a/components/sync_sessions/revisit/page_revisit_broadcaster.cc
+++ b/components/sync_sessions/revisit/page_revisit_broadcaster.cc
@@ -7,6 +7,7 @@
#include <string>
#include <vector>
+#include "base/macros.h"
#include "base/memory/scoped_ptr.h"
#include "base/metrics/field_trial.h"
#include "components/bookmarks/browser/bookmark_model.h"
diff --git a/components/sync_sessions/revisit/page_revisit_broadcaster_unittest.cc b/components/sync_sessions/revisit/page_revisit_broadcaster_unittest.cc
index 9518547..8a7e950 100644
--- a/components/sync_sessions/revisit/page_revisit_broadcaster_unittest.cc
+++ b/components/sync_sessions/revisit/page_revisit_broadcaster_unittest.cc
@@ -4,6 +4,8 @@
#include "components/sync_sessions/revisit/page_revisit_broadcaster.h"
+#include <stdint.h>
+
#include "components/sync_sessions/revisit/page_visit_observer.h"
#include "testing/gtest/include/gtest/gtest.h"
#include "ui/base/page_transition_types.h"
@@ -25,7 +27,7 @@ class SyncPageRevisitBroadcasterTest : public ::testing::Test {
}
void Check(const PageVisitObserver::TransitionType expected,
- const int32 conversionInput) {
+ const int32_t conversionInput) {
Check(expected, ui::PageTransitionFromInt(conversionInput));
}
};
diff --git a/components/sync_sessions/revisit/sessions_page_revisit_observer.h b/components/sync_sessions/revisit/sessions_page_revisit_observer.h
index 74b21ef..defe7343 100644
--- a/components/sync_sessions/revisit/sessions_page_revisit_observer.h
+++ b/components/sync_sessions/revisit/sessions_page_revisit_observer.h
@@ -7,6 +7,7 @@
#include <vector>
+#include "base/macros.h"
#include "base/memory/scoped_ptr.h"
#include "base/memory/weak_ptr.h"
#include "components/sync_sessions/revisit/page_visit_observer.h"
diff --git a/components/sync_sessions/revisit/typed_url_page_revisit_observer.h b/components/sync_sessions/revisit/typed_url_page_revisit_observer.h
index 972a670..fc69d1d 100644
--- a/components/sync_sessions/revisit/typed_url_page_revisit_observer.h
+++ b/components/sync_sessions/revisit/typed_url_page_revisit_observer.h
@@ -5,6 +5,7 @@
#ifndef COMPONENTS_SYNC_SESSIONS_REVISIT_TYPED_URL_PAGE_REVISIT_OBSERVER_H_
#define COMPONENTS_SYNC_SESSIONS_REVISIT_TYPED_URL_PAGE_REVISIT_OBSERVER_H_
+#include "base/macros.h"
#include "base/memory/weak_ptr.h"
#include "base/task/cancelable_task_tracker.h"
#include "components/sync_sessions/revisit/page_visit_observer.h"
diff --git a/components/sync_sessions/revisit/typed_url_page_revisit_task.h b/components/sync_sessions/revisit/typed_url_page_revisit_task.h
index 2851109..49b4398 100644
--- a/components/sync_sessions/revisit/typed_url_page_revisit_task.h
+++ b/components/sync_sessions/revisit/typed_url_page_revisit_task.h
@@ -6,6 +6,7 @@
#define COMPONENTS_SYNC_SESSIONS_REVISIT_TYPED_URL_PAGE_REVISIT_TASK_H_
#include "base/gtest_prod_util.h"
+#include "base/macros.h"
#include "components/history/core/browser/history_db_task.h"
#include "components/history/core/browser/history_types.h"
#include "components/sync_sessions/revisit/page_visit_observer.h"
diff --git a/components/sync_sessions/sessions_sync_manager.cc b/components/sync_sessions/sessions_sync_manager.cc
index f3902b4..48ab5ed 100644
--- a/components/sync_sessions/sessions_sync_manager.cc
+++ b/components/sync_sessions/sessions_sync_manager.cc
@@ -7,6 +7,7 @@
#include <algorithm>
#include "base/metrics/field_trial.h"
+#include "build/build_config.h"
#include "components/sync_driver/local_device_info_provider.h"
#include "components/sync_sessions/sync_sessions_client.h"
#include "components/sync_sessions/synced_tab_delegate.h"
diff --git a/components/sync_sessions/sessions_sync_manager.h b/components/sync_sessions/sessions_sync_manager.h
index c0e2aad..2c990e0 100644
--- a/components/sync_sessions/sessions_sync_manager.h
+++ b/components/sync_sessions/sessions_sync_manager.h
@@ -5,14 +5,16 @@
#ifndef COMPONENTS_SYNC_SESSIONS_SESSIONS_SYNC_MANAGER_H_
#define COMPONENTS_SYNC_SESSIONS_SESSIONS_SYNC_MANAGER_H_
+#include <stddef.h>
+
#include <map>
#include <set>
#include <string>
#include <vector>
-#include "base/basictypes.h"
#include "base/callback_forward.h"
#include "base/gtest_prod_util.h"
+#include "base/macros.h"
#include "base/memory/weak_ptr.h"
#include "base/time/time.h"
#include "components/sessions/core/session_id.h"
diff --git a/components/sync_sessions/synced_session_tracker.h b/components/sync_sessions/synced_session_tracker.h
index a1a058b..a45a80e 100644
--- a/components/sync_sessions/synced_session_tracker.h
+++ b/components/sync_sessions/synced_session_tracker.h
@@ -5,12 +5,14 @@
#ifndef COMPONENTS_SYNC_SESSIONS_SYNCED_SESSION_TRACKER_H_
#define COMPONENTS_SYNC_SESSIONS_SYNCED_SESSION_TRACKER_H_
+#include <stddef.h>
+
#include <map>
#include <set>
#include <string>
#include <vector>
-#include "base/basictypes.h"
+#include "base/macros.h"
#include "components/sessions/core/session_id.h"
#include "components/sessions/core/session_types.h"
#include "components/sync_sessions/synced_session.h"
diff --git a/components/sync_sessions/tab_node_pool.h b/components/sync_sessions/tab_node_pool.h
index d2539c0..77021a1 100644
--- a/components/sync_sessions/tab_node_pool.h
+++ b/components/sync_sessions/tab_node_pool.h
@@ -5,11 +5,13 @@
#ifndef COMPONENTS_SYNC_SESSIONS_TAB_NODE_POOL_H_
#define COMPONENTS_SYNC_SESSIONS_TAB_NODE_POOL_H_
+#include <stddef.h>
+
#include <map>
#include <set>
#include <string>
-#include "base/basictypes.h"
+#include "base/macros.h"
#include "components/sessions/core/session_id.h"
#include "sync/api/sync_change_processor.h"
diff --git a/components/sync_sessions/tab_node_pool_unittest.cc b/components/sync_sessions/tab_node_pool_unittest.cc
index b87e84c..5c0a4d7 100644
--- a/components/sync_sessions/tab_node_pool_unittest.cc
+++ b/components/sync_sessions/tab_node_pool_unittest.cc
@@ -4,6 +4,8 @@
#include "components/sync_sessions/tab_node_pool.h"
+#include <stddef.h>
+
#include <vector>
#include "sync/api/sync_change.h"
diff --git a/components/syncable_prefs/pref_model_associator.h b/components/syncable_prefs/pref_model_associator.h
index aa33c67..302924d 100644
--- a/components/syncable_prefs/pref_model_associator.h
+++ b/components/syncable_prefs/pref_model_associator.h
@@ -9,9 +9,9 @@
#include <set>
#include <string>
-#include "base/basictypes.h"
#include "base/compiler_specific.h"
#include "base/containers/hash_tables.h"
+#include "base/macros.h"
#include "base/observer_list.h"
#include "base/threading/non_thread_safe.h"
#include "components/syncable_prefs/synced_pref_observer.h"
diff --git a/components/syncable_prefs/pref_service_mock_factory.h b/components/syncable_prefs/pref_service_mock_factory.h
index f5b5d32..9ff937f 100644
--- a/components/syncable_prefs/pref_service_mock_factory.h
+++ b/components/syncable_prefs/pref_service_mock_factory.h
@@ -5,6 +5,7 @@
#ifndef COMPONENTS_SYNCABLE_PREFS_PREF_SERVICE_MOCK_FACTORY_H_
#define COMPONENTS_SYNCABLE_PREFS_PREF_SERVICE_MOCK_FACTORY_H_
+#include "base/macros.h"
#include "components/syncable_prefs/pref_service_syncable_factory.h"
namespace syncable_prefs {
diff --git a/components/syncable_prefs/pref_service_syncable.cc b/components/syncable_prefs/pref_service_syncable.cc
index b538a1d..3384fb9 100644
--- a/components/syncable_prefs/pref_service_syncable.cc
+++ b/components/syncable_prefs/pref_service_syncable.cc
@@ -164,7 +164,7 @@ void PrefServiceSyncable::SetPrefModelAssociatorClientForTesting(
void PrefServiceSyncable::AddRegisteredSyncablePreference(
const std::string& path,
- uint32 flags) {
+ uint32_t flags) {
DCHECK(FindPreference(path));
if (flags & user_prefs::PrefRegistrySyncable::SYNCABLE_PREF) {
pref_sync_associator_.RegisterPref(path.c_str());
diff --git a/components/syncable_prefs/pref_service_syncable.h b/components/syncable_prefs/pref_service_syncable.h
index 81224ac..be719aa 100644
--- a/components/syncable_prefs/pref_service_syncable.h
+++ b/components/syncable_prefs/pref_service_syncable.h
@@ -5,9 +5,12 @@
#ifndef COMPONENTS_SYNCABLE_PREFS_PREF_SERVICE_SYNCABLE_H_
#define COMPONENTS_SYNCABLE_PREFS_PREF_SERVICE_SYNCABLE_H_
+#include <stdint.h>
+
#include <vector>
#include "base/callback_forward.h"
+#include "base/macros.h"
#include "base/prefs/pref_service.h"
#include "components/pref_registry/pref_registry_syncable.h"
#include "components/syncable_prefs/pref_model_associator.h"
@@ -90,7 +93,7 @@ class PrefServiceSyncable : public PrefService {
private:
friend class PrefModelAssociator;
- void AddRegisteredSyncablePreference(const std::string& path, uint32 flags);
+ void AddRegisteredSyncablePreference(const std::string& path, uint32_t flags);
// Invoked internally when the IsSyncing() state changes.
void OnIsSyncingChanged();
diff --git a/components/syncable_prefs/pref_service_syncable_factory.h b/components/syncable_prefs/pref_service_syncable_factory.h
index 5b28e3c..184ef09 100644
--- a/components/syncable_prefs/pref_service_syncable_factory.h
+++ b/components/syncable_prefs/pref_service_syncable_factory.h
@@ -5,6 +5,7 @@
#ifndef COMPONENTS_SYNCABLE_PREFS_PREF_SERVICE_SYNCABLE_FACTORY_H_
#define COMPONENTS_SYNCABLE_PREFS_PREF_SERVICE_SYNCABLE_FACTORY_H_
+#include "base/macros.h"
#include "base/prefs/pref_service_factory.h"
namespace base {
diff --git a/components/syncable_prefs/pref_service_syncable_unittest.cc b/components/syncable_prefs/pref_service_syncable_unittest.cc
index 2c90f9c..cc173d1 100644
--- a/components/syncable_prefs/pref_service_syncable_unittest.cc
+++ b/components/syncable_prefs/pref_service_syncable_unittest.cc
@@ -4,9 +4,12 @@
#include "components/syncable_prefs/pref_service_syncable.h"
+#include <stdint.h>
+
#include "base/json/json_reader.h"
#include "base/json/json_string_value_serializer.h"
#include "base/json/json_writer.h"
+#include "base/macros.h"
#include "base/message_loop/message_loop.h"
#include "base/prefs/scoped_user_pref_update.h"
#include "base/strings/utf_string_conversions.h"
@@ -120,11 +123,10 @@ class PrefServiceSyncableTest : public testing::Test {
next_pref_remote_sync_node_id_ = 0;
}
- syncer::SyncChange MakeRemoteChange(
- int64 id,
- const std::string& name,
- const base::Value& value,
- SyncChange::SyncChangeType type) {
+ syncer::SyncChange MakeRemoteChange(int64_t id,
+ const std::string& name,
+ const base::Value& value,
+ SyncChange::SyncChangeType type) {
std::string serialized;
JSONStringValueSerializer json(&serialized);
if (!json.Serialize(value))
diff --git a/components/syncable_prefs/synced_pref_change_registrar.h b/components/syncable_prefs/synced_pref_change_registrar.h
index 7c4a541..8c18ab3 100644
--- a/components/syncable_prefs/synced_pref_change_registrar.h
+++ b/components/syncable_prefs/synced_pref_change_registrar.h
@@ -9,6 +9,7 @@
#include <string>
#include "base/callback.h"
+#include "base/macros.h"
#include "components/syncable_prefs/pref_service_syncable.h"
#include "components/syncable_prefs/synced_pref_observer.h"
diff --git a/components/syncable_prefs/testing_pref_service_syncable.h b/components/syncable_prefs/testing_pref_service_syncable.h
index 8235c6e..e55ce55 100644
--- a/components/syncable_prefs/testing_pref_service_syncable.h
+++ b/components/syncable_prefs/testing_pref_service_syncable.h
@@ -5,7 +5,7 @@
#ifndef COMPONENTS_SYNCABLE_PREFS_TESTING_PREF_SERVICE_SYNCABLE_H_
#define COMPONENTS_SYNCABLE_PREFS_TESTING_PREF_SERVICE_SYNCABLE_H_
-#include "base/basictypes.h"
+#include "base/macros.h"
#include "base/prefs/testing_pref_service.h"
#include "components/syncable_prefs/pref_service_syncable.h"
diff --git a/components/test/run_all_unittests.cc b/components/test/run_all_unittests.cc
index fc5a018..77c8559 100644
--- a/components/test/run_all_unittests.cc
+++ b/components/test/run_all_unittests.cc
@@ -4,11 +4,13 @@
#include "base/bind.h"
#include "base/files/file_path.h"
+#include "base/macros.h"
#include "base/memory/scoped_ptr.h"
#include "base/metrics/statistics_recorder.h"
#include "base/path_service.h"
#include "base/test/launcher/unit_test_launcher.h"
#include "base/test/test_suite.h"
+#include "build/build_config.h"
#include "components/content_settings/core/common/content_settings_pattern.h"
#include "testing/gtest/include/gtest/gtest.h"
#include "ui/base/resource/resource_bundle.h"
diff --git a/components/test_runner/accessibility_controller.cc b/components/test_runner/accessibility_controller.cc
index 4bd84b6..f6fd849 100644
--- a/components/test_runner/accessibility_controller.cc
+++ b/components/test_runner/accessibility_controller.cc
@@ -4,6 +4,7 @@
#include "components/test_runner/accessibility_controller.h"
+#include "base/macros.h"
#include "gin/handle.h"
#include "gin/object_template_builder.h"
#include "gin/wrappable.h"
diff --git a/components/test_runner/accessibility_controller.h b/components/test_runner/accessibility_controller.h
index 8617b10..7bc62aa 100644
--- a/components/test_runner/accessibility_controller.h
+++ b/components/test_runner/accessibility_controller.h
@@ -7,6 +7,7 @@
#include <vector>
+#include "base/macros.h"
#include "base/memory/weak_ptr.h"
#include "components/test_runner/web_ax_object_proxy.h"
#include "third_party/WebKit/public/web/WebAXObject.h"
diff --git a/components/test_runner/app_banner_client.h b/components/test_runner/app_banner_client.h
index b268c9f..0439baf 100644
--- a/components/test_runner/app_banner_client.h
+++ b/components/test_runner/app_banner_client.h
@@ -7,6 +7,7 @@
#include "base/compiler_specific.h"
#include "base/id_map.h"
+#include "base/macros.h"
#include "components/test_runner/test_runner_export.h"
#include "third_party/WebKit/public/platform/modules/app_banner/WebAppBannerClient.h"
diff --git a/components/test_runner/blink_test_platform_support_linux.cc b/components/test_runner/blink_test_platform_support_linux.cc
index 402fd68..8afe107 100644
--- a/components/test_runner/blink_test_platform_support_linux.cc
+++ b/components/test_runner/blink_test_platform_support_linux.cc
@@ -4,9 +4,12 @@
#include "components/test_runner/blink_test_platform_support.h"
+#include <stddef.h>
+
#include "base/files/file_path.h"
#include "base/files/file_util.h"
#include "base/logging.h"
+#include "base/macros.h"
#include "base/path_service.h"
#include "ui/gfx/test/fontconfig_util_linux.h"
diff --git a/components/test_runner/blink_test_platform_support_mac.mm b/components/test_runner/blink_test_platform_support_mac.mm
index e0150d6..0406326 100644
--- a/components/test_runner/blink_test_platform_support_mac.mm
+++ b/components/test_runner/blink_test_platform_support_mac.mm
@@ -5,6 +5,7 @@
#include "base/command_line.h"
#include "base/logging.h"
#include "base/mac/bundle_locations.h"
+#include "base/macros.h"
#include "base/path_service.h"
#include "components/test_runner/blink_test_platform_support.h"
diff --git a/components/test_runner/blink_test_platform_support_win.cc b/components/test_runner/blink_test_platform_support_win.cc
index f76500b..8ac4be3 100644
--- a/components/test_runner/blink_test_platform_support_win.cc
+++ b/components/test_runner/blink_test_platform_support_win.cc
@@ -5,6 +5,7 @@
#include "components/test_runner/blink_test_platform_support.h"
#include <windows.h>
+#include <stddef.h>
#include <iostream>
#include <list>
#include <string>
@@ -13,6 +14,7 @@
#include "base/files/file_path.h"
#include "base/files/file_util.h"
#include "base/logging.h"
+#include "base/macros.h"
#include "base/path_service.h"
#include "base/strings/utf_string_conversions.h"
#include "ui/gfx/win/direct_write.h"
diff --git a/components/test_runner/event_sender.cc b/components/test_runner/event_sender.cc
index 18f5292..df15076 100644
--- a/components/test_runner/event_sender.cc
+++ b/components/test_runner/event_sender.cc
@@ -4,12 +4,15 @@
#include "components/test_runner/event_sender.h"
-#include "base/basictypes.h"
+#include <stddef.h>
+
#include "base/logging.h"
+#include "base/macros.h"
#include "base/strings/string16.h"
#include "base/strings/string_util.h"
#include "base/strings/stringprintf.h"
#include "base/strings/utf_string_conversions.h"
+#include "build/build_config.h"
#include "components/test_runner/mock_spell_check.h"
#include "components/test_runner/test_interfaces.h"
#include "components/test_runner/web_test_delegate.h"
diff --git a/components/test_runner/event_sender.h b/components/test_runner/event_sender.h
index d408b1e..54986aa 100644
--- a/components/test_runner/event_sender.h
+++ b/components/test_runner/event_sender.h
@@ -5,6 +5,8 @@
#ifndef COMPONENTS_TEST_RUNNER_EVENT_SENDER_H_
#define COMPONENTS_TEST_RUNNER_EVENT_SENDER_H_
+#include <stdint.h>
+
#include <queue>
#include <string>
#include <vector>
@@ -288,7 +290,7 @@ class EventSender : public base::SupportsWeakPtr<EventSender> {
blink::WebDragOperation current_drag_effect_;
- uint32 time_offset_ms_;
+ uint32_t time_offset_ms_;
int click_count_;
// Timestamp (in seconds) of the last event that was dispatched
double last_event_timestamp_;
diff --git a/components/test_runner/gamepad_controller.cc b/components/test_runner/gamepad_controller.cc
index 58c58a2..18c2fa4 100644
--- a/components/test_runner/gamepad_controller.cc
+++ b/components/test_runner/gamepad_controller.cc
@@ -4,6 +4,9 @@
#include "components/test_runner/gamepad_controller.h"
+#include <string.h>
+
+#include "base/macros.h"
#include "components/test_runner/web_test_delegate.h"
#include "gin/arguments.h"
#include "gin/handle.h"
diff --git a/components/test_runner/gamepad_controller.h b/components/test_runner/gamepad_controller.h
index fe32cb3..eab4f01 100644
--- a/components/test_runner/gamepad_controller.h
+++ b/components/test_runner/gamepad_controller.h
@@ -7,6 +7,7 @@
#include <map>
+#include "base/macros.h"
#include "base/memory/weak_ptr.h"
#include "components/test_runner/test_runner_export.h"
#include "third_party/WebKit/public/platform/WebGamepads.h"
diff --git a/components/test_runner/gc_controller.h b/components/test_runner/gc_controller.h
index 2fce5bc..182fe8b 100644
--- a/components/test_runner/gc_controller.h
+++ b/components/test_runner/gc_controller.h
@@ -5,7 +5,7 @@
#ifndef COMPONENTS_TEST_RUNNER_GC_CONTROLLER_H_
#define COMPONENTS_TEST_RUNNER_GC_CONTROLLER_H_
-#include "base/basictypes.h"
+#include "base/macros.h"
#include "gin/wrappable.h"
namespace blink {
diff --git a/components/test_runner/mock_color_chooser.h b/components/test_runner/mock_color_chooser.h
index 74af942..0948aae 100644
--- a/components/test_runner/mock_color_chooser.h
+++ b/components/test_runner/mock_color_chooser.h
@@ -5,7 +5,7 @@
#ifndef COMPONENTS_TEST_RUNNER_MOCK_COLOR_CHOOSER_H_
#define COMPONENTS_TEST_RUNNER_MOCK_COLOR_CHOOSER_H_
-#include "base/basictypes.h"
+#include "base/macros.h"
#include "components/test_runner/web_task.h"
#include "third_party/WebKit/public/web/WebColorChooser.h"
#include "third_party/WebKit/public/web/WebColorChooserClient.h"
diff --git a/components/test_runner/mock_constraints.cc b/components/test_runner/mock_constraints.cc
index 9058619..7e18e55 100644
--- a/components/test_runner/mock_constraints.cc
+++ b/components/test_runner/mock_constraints.cc
@@ -4,6 +4,8 @@
#include "components/test_runner/mock_constraints.h"
+#include <stddef.h>
+
#include "third_party/WebKit/public/platform/WebMediaConstraints.h"
#include "third_party/WebKit/public/platform/WebString.h"
diff --git a/components/test_runner/mock_credential_manager_client.h b/components/test_runner/mock_credential_manager_client.h
index 78c1b18..2ac7034 100644
--- a/components/test_runner/mock_credential_manager_client.h
+++ b/components/test_runner/mock_credential_manager_client.h
@@ -5,6 +5,7 @@
#ifndef COMPONENTS_TEST_RUNNER_MOCK_CREDENTIAL_MANAGER_CLIENT_H_
#define COMPONENTS_TEST_RUNNER_MOCK_CREDENTIAL_MANAGER_CLIENT_H_
+#include "base/macros.h"
#include "base/memory/scoped_ptr.h"
#include "third_party/WebKit/public/platform/WebCredentialManagerClient.h"
#include "third_party/WebKit/public/platform/WebVector.h"
diff --git a/components/test_runner/mock_grammar_check.cc b/components/test_runner/mock_grammar_check.cc
index 26f318f..b172dfa 100644
--- a/components/test_runner/mock_grammar_check.cc
+++ b/components/test_runner/mock_grammar_check.cc
@@ -4,9 +4,12 @@
#include "components/test_runner/mock_grammar_check.h"
+#include <stddef.h>
+
#include <algorithm>
#include "base/logging.h"
+#include "base/macros.h"
#include "components/test_runner/test_common.h"
#include "third_party/WebKit/public/platform/WebCString.h"
#include "third_party/WebKit/public/platform/WebString.h"
diff --git a/components/test_runner/mock_spell_check.cc b/components/test_runner/mock_spell_check.cc
index adb2b53..3f427f6 100644
--- a/components/test_runner/mock_spell_check.cc
+++ b/components/test_runner/mock_spell_check.cc
@@ -4,9 +4,12 @@
#include "components/test_runner/mock_spell_check.h"
+#include <stddef.h>
+
#include <algorithm>
#include "base/logging.h"
+#include "base/macros.h"
#include "components/test_runner/test_common.h"
#include "third_party/WebKit/public/platform/WebCString.h"
diff --git a/components/test_runner/mock_spell_check.h b/components/test_runner/mock_spell_check.h
index 8325535..f6bf715 100644
--- a/components/test_runner/mock_spell_check.h
+++ b/components/test_runner/mock_spell_check.h
@@ -7,7 +7,7 @@
#include <vector>
-#include "base/basictypes.h"
+#include "base/macros.h"
#include "third_party/WebKit/public/platform/WebString.h"
#include "third_party/WebKit/public/platform/WebVector.h"
#include "third_party/WebKit/public/web/WebTextCheckingResult.h"
diff --git a/components/test_runner/mock_web_media_stream_center.cc b/components/test_runner/mock_web_media_stream_center.cc
index 3c92061..6c9983e 100644
--- a/components/test_runner/mock_web_media_stream_center.cc
+++ b/components/test_runner/mock_web_media_stream_center.cc
@@ -4,7 +4,10 @@
#include "components/test_runner/mock_web_media_stream_center.h"
+#include <stddef.h>
+
#include "base/logging.h"
+#include "base/macros.h"
#include "components/test_runner/test_interfaces.h"
#include "components/test_runner/web_test_delegate.h"
#include "third_party/WebKit/public/platform/WebAudioDestinationConsumer.h"
diff --git a/components/test_runner/mock_web_media_stream_center.h b/components/test_runner/mock_web_media_stream_center.h
index 874a827..cc2fc65 100644
--- a/components/test_runner/mock_web_media_stream_center.h
+++ b/components/test_runner/mock_web_media_stream_center.h
@@ -5,7 +5,7 @@
#ifndef COMPONENTS_TEST_RUNNER_MOCK_WEB_MEDIA_STREAM_CENTER_H_
#define COMPONENTS_TEST_RUNNER_MOCK_WEB_MEDIA_STREAM_CENTER_H_
-#include "base/basictypes.h"
+#include "base/macros.h"
#include "components/test_runner/web_task.h"
#include "third_party/WebKit/public/platform/WebMediaStreamCenter.h"
diff --git a/components/test_runner/mock_web_midi_accessor.cc b/components/test_runner/mock_web_midi_accessor.cc
index f4cbbf5..1a4bc57 100644
--- a/components/test_runner/mock_web_midi_accessor.cc
+++ b/components/test_runner/mock_web_midi_accessor.cc
@@ -4,6 +4,7 @@
#include "components/test_runner/mock_web_midi_accessor.h"
+#include "base/macros.h"
#include "components/test_runner/test_interfaces.h"
#include "components/test_runner/test_runner.h"
#include "components/test_runner/web_test_delegate.h"
diff --git a/components/test_runner/mock_web_midi_accessor.h b/components/test_runner/mock_web_midi_accessor.h
index e67211c5..0f68ed2 100644
--- a/components/test_runner/mock_web_midi_accessor.h
+++ b/components/test_runner/mock_web_midi_accessor.h
@@ -5,7 +5,9 @@
#ifndef COMPONENTS_TEST_RUNNER_MOCK_WEB_MIDI_ACCESSOR_H_
#define COMPONENTS_TEST_RUNNER_MOCK_WEB_MIDI_ACCESSOR_H_
-#include "base/basictypes.h"
+#include <stddef.h>
+
+#include "base/macros.h"
#include "components/test_runner/web_task.h"
#include "third_party/WebKit/public/platform/WebMIDIAccessor.h"
diff --git a/components/test_runner/mock_web_speech_recognizer.cc b/components/test_runner/mock_web_speech_recognizer.cc
index 17b430d..880152a 100644
--- a/components/test_runner/mock_web_speech_recognizer.cc
+++ b/components/test_runner/mock_web_speech_recognizer.cc
@@ -4,7 +4,10 @@
#include "components/test_runner/mock_web_speech_recognizer.h"
+#include <stddef.h>
+
#include "base/logging.h"
+#include "base/macros.h"
#include "components/test_runner/web_test_delegate.h"
#include "third_party/WebKit/public/web/WebSpeechRecognitionResult.h"
#include "third_party/WebKit/public/web/WebSpeechRecognizerClient.h"
diff --git a/components/test_runner/mock_web_speech_recognizer.h b/components/test_runner/mock_web_speech_recognizer.h
index 85ca109..b3950de 100644
--- a/components/test_runner/mock_web_speech_recognizer.h
+++ b/components/test_runner/mock_web_speech_recognizer.h
@@ -8,7 +8,7 @@
#include <deque>
#include <vector>
-#include "base/basictypes.h"
+#include "base/macros.h"
#include "components/test_runner/web_task.h"
#include "third_party/WebKit/public/web/WebSpeechRecognizer.h"
diff --git a/components/test_runner/mock_web_theme_engine.cc b/components/test_runner/mock_web_theme_engine.cc
index af31ed6..fed1934 100644
--- a/components/test_runner/mock_web_theme_engine.cc
+++ b/components/test_runner/mock_web_theme_engine.cc
@@ -7,6 +7,7 @@
#if !defined(OS_MACOSX)
#include "base/logging.h"
+#include "build/build_config.h"
#include "skia/ext/platform_canvas.h"
#include "third_party/WebKit/public/platform/WebRect.h"
#include "third_party/WebKit/public/platform/WebSize.h"
diff --git a/components/test_runner/mock_web_theme_engine.h b/components/test_runner/mock_web_theme_engine.h
index fc6d0ac..e8b7ddf 100644
--- a/components/test_runner/mock_web_theme_engine.h
+++ b/components/test_runner/mock_web_theme_engine.h
@@ -5,6 +5,7 @@
#ifndef COMPONENTS_TEST_RUNNER_MOCK_WEB_THEME_ENGINE_H_
#define COMPONENTS_TEST_RUNNER_MOCK_WEB_THEME_ENGINE_H_
+#include "build/build_config.h"
#include "third_party/WebKit/public/platform/WebThemeEngine.h"
namespace test_runner {
diff --git a/components/test_runner/mock_web_user_media_client.cc b/components/test_runner/mock_web_user_media_client.cc
index 3bd55e5f..4197a26 100644
--- a/components/test_runner/mock_web_user_media_client.cc
+++ b/components/test_runner/mock_web_user_media_client.cc
@@ -4,6 +4,8 @@
#include "components/test_runner/mock_web_user_media_client.h"
+#include <stddef.h>
+
#include "base/logging.h"
#include "base/macros.h"
#include "components/test_runner/mock_constraints.h"
diff --git a/components/test_runner/mock_web_user_media_client.h b/components/test_runner/mock_web_user_media_client.h
index 33b55d5..dda0d4df 100644
--- a/components/test_runner/mock_web_user_media_client.h
+++ b/components/test_runner/mock_web_user_media_client.h
@@ -5,6 +5,7 @@
#ifndef COMPONENTS_TEST_RUNNER_MOCK_WEB_USER_MEDIA_CLIENT_H_
#define COMPONENTS_TEST_RUNNER_MOCK_WEB_USER_MEDIA_CLIENT_H_
+#include "base/macros.h"
#include "components/test_runner/web_task.h"
#include "third_party/WebKit/public/web/WebUserMediaClient.h"
diff --git a/components/test_runner/mock_webrtc_data_channel_handler.h b/components/test_runner/mock_webrtc_data_channel_handler.h
index 780fc7f..403a219 100644
--- a/components/test_runner/mock_webrtc_data_channel_handler.h
+++ b/components/test_runner/mock_webrtc_data_channel_handler.h
@@ -5,7 +5,9 @@
#ifndef COMPONENTS_TEST_RUNNER_MOCK_WEBRTC_DATA_CHANNEL_HANDLER_H_
#define COMPONENTS_TEST_RUNNER_MOCK_WEBRTC_DATA_CHANNEL_HANDLER_H_
-#include "base/basictypes.h"
+#include <stddef.h>
+
+#include "base/macros.h"
#include "components/test_runner/web_task.h"
#include "third_party/WebKit/public/platform/WebRTCDataChannelHandler.h"
#include "third_party/WebKit/public/platform/WebRTCDataChannelHandlerClient.h"
diff --git a/components/test_runner/mock_webrtc_dtmf_sender_handler.h b/components/test_runner/mock_webrtc_dtmf_sender_handler.h
index 955ef85..4e6487a 100644
--- a/components/test_runner/mock_webrtc_dtmf_sender_handler.h
+++ b/components/test_runner/mock_webrtc_dtmf_sender_handler.h
@@ -5,7 +5,7 @@
#ifndef COMPONENTS_TEST_RUNNER_MOCK_WEBRTC_DTMF_SENDER_HANDLER_H_
#define COMPONENTS_TEST_RUNNER_MOCK_WEBRTC_DTMF_SENDER_HANDLER_H_
-#include "base/basictypes.h"
+#include "base/macros.h"
#include "components/test_runner/web_task.h"
#include "third_party/WebKit/public/platform/WebMediaStreamTrack.h"
#include "third_party/WebKit/public/platform/WebRTCDTMFSenderHandler.h"
diff --git a/components/test_runner/mock_webrtc_peer_connection_handler.cc b/components/test_runner/mock_webrtc_peer_connection_handler.cc
index 1fb0bc9..4e43815 100644
--- a/components/test_runner/mock_webrtc_peer_connection_handler.cc
+++ b/components/test_runner/mock_webrtc_peer_connection_handler.cc
@@ -4,6 +4,8 @@
#include "components/test_runner/mock_webrtc_peer_connection_handler.h"
+#include <stddef.h>
+
#include "components/test_runner/mock_constraints.h"
#include "components/test_runner/mock_webrtc_data_channel_handler.h"
#include "components/test_runner/mock_webrtc_dtmf_sender_handler.h"
diff --git a/components/test_runner/mock_webrtc_peer_connection_handler.h b/components/test_runner/mock_webrtc_peer_connection_handler.h
index c828f42..4173840 100644
--- a/components/test_runner/mock_webrtc_peer_connection_handler.h
+++ b/components/test_runner/mock_webrtc_peer_connection_handler.h
@@ -7,7 +7,7 @@
#include <map>
-#include "base/basictypes.h"
+#include "base/macros.h"
#include "components/test_runner/web_task.h"
#include "third_party/WebKit/public/platform/WebRTCPeerConnectionHandler.h"
#include "third_party/WebKit/public/platform/WebRTCSessionDescription.h"
diff --git a/components/test_runner/spell_check_client.cc b/components/test_runner/spell_check_client.cc
index 9ef7caf..304cfed 100644
--- a/components/test_runner/spell_check_client.cc
+++ b/components/test_runner/spell_check_client.cc
@@ -4,6 +4,9 @@
#include "components/test_runner/spell_check_client.h"
+#include <stddef.h>
+
+#include "base/macros.h"
#include "components/test_runner/mock_grammar_check.h"
#include "components/test_runner/web_test_delegate.h"
#include "components/test_runner/web_test_proxy.h"
diff --git a/components/test_runner/spell_check_client.h b/components/test_runner/spell_check_client.h
index f1436cf..40af2d2 100644
--- a/components/test_runner/spell_check_client.h
+++ b/components/test_runner/spell_check_client.h
@@ -5,7 +5,9 @@
#ifndef COMPONENTS_TEST_RUNNER_SPELL_CHECK_CLIENT_H_
#define COMPONENTS_TEST_RUNNER_SPELL_CHECK_CLIENT_H_
-#include "base/basictypes.h"
+#include <stdint.h>
+
+#include "base/macros.h"
#include "components/test_runner/mock_spell_check.h"
#include "components/test_runner/web_task.h"
#include "third_party/WebKit/public/web/WebSpellCheckClient.h"
diff --git a/components/test_runner/test_common.cc b/components/test_runner/test_common.cc
index 8a096d6..eff2dad 100644
--- a/components/test_runner/test_common.cc
+++ b/components/test_runner/test_common.cc
@@ -4,6 +4,8 @@
#include "components/test_runner/test_common.h"
+#include <stddef.h>
+
#include "base/lazy_instance.h"
#include "base/macros.h"
#include "base/rand_util.h"
diff --git a/components/test_runner/test_info_extractor.cc b/components/test_runner/test_info_extractor.cc
index 2c7ecbc..42e0e48 100644
--- a/components/test_runner/test_info_extractor.cc
+++ b/components/test_runner/test_info_extractor.cc
@@ -12,6 +12,7 @@
#include "base/strings/sys_string_conversions.h"
#include "base/strings/utf_string_conversions.h"
#include "base/threading/thread_restrictions.h"
+#include "build/build_config.h"
#include "net/base/filename_util.h"
namespace test_runner {
diff --git a/components/test_runner/test_info_extractor.h b/components/test_runner/test_info_extractor.h
index a34a37d..4f4a11c 100644
--- a/components/test_runner/test_info_extractor.h
+++ b/components/test_runner/test_info_extractor.h
@@ -5,10 +5,13 @@
#ifndef COMPONENTS_TEST_RUNNER_TEST_INFO_EXTRACTOR_H_
#define COMPONENTS_TEST_RUNNER_TEST_INFO_EXTRACTOR_H_
+#include <stddef.h>
+
#include <string>
#include "base/command_line.h"
#include "base/files/file_path.h"
+#include "base/macros.h"
#include "components/test_runner/test_runner_export.h"
#include "url/gurl.h"
diff --git a/components/test_runner/test_interfaces.cc b/components/test_runner/test_interfaces.cc
index 0339ad1..ee0d34f 100644
--- a/components/test_runner/test_interfaces.cc
+++ b/components/test_runner/test_interfaces.cc
@@ -4,6 +4,8 @@
#include "components/test_runner/test_interfaces.h"
+#include <stddef.h>
+
#include <string>
#include "base/json/json_writer.h"
diff --git a/components/test_runner/test_interfaces.h b/components/test_runner/test_interfaces.h
index 3585b35..1834f5a 100644
--- a/components/test_runner/test_interfaces.h
+++ b/components/test_runner/test_interfaces.h
@@ -7,7 +7,7 @@
#include <vector>
-#include "base/basictypes.h"
+#include "base/macros.h"
#include "base/memory/scoped_ptr.h"
#include "base/memory/weak_ptr.h"
#include "components/test_runner/mock_web_theme_engine.h"
diff --git a/components/test_runner/test_plugin.cc b/components/test_runner/test_plugin.cc
index b8d5a691..f26ebe2 100644
--- a/components/test_runner/test_plugin.cc
+++ b/components/test_runner/test_plugin.cc
@@ -4,7 +4,9 @@
#include "components/test_runner/test_plugin.h"
-#include "base/basictypes.h"
+#include <stddef.h>
+#include <stdint.h>
+
#include "base/bind.h"
#include "base/logging.h"
#include "base/memory/shared_memory.h"
@@ -418,11 +420,9 @@ void TestPlugin::DrawSceneGL() {
}
void TestPlugin::DrawSceneSoftware(void* memory) {
- SkColor background_color =
- SkColorSetARGB(static_cast<uint8>(scene_.opacity * 255),
- scene_.background_color[0],
- scene_.background_color[1],
- scene_.background_color[2]);
+ SkColor background_color = SkColorSetARGB(
+ static_cast<uint8_t>(scene_.opacity * 255), scene_.background_color[0],
+ scene_.background_color[1], scene_.background_color[2]);
const SkImageInfo info =
SkImageInfo::MakeN32Premul(rect_.width, rect_.height);
@@ -433,11 +433,9 @@ void TestPlugin::DrawSceneSoftware(void* memory) {
if (scene_.primitive != PrimitiveNone) {
DCHECK_EQ(PrimitiveTriangle, scene_.primitive);
- SkColor foreground_color =
- SkColorSetARGB(static_cast<uint8>(scene_.opacity * 255),
- scene_.primitive_color[0],
- scene_.primitive_color[1],
- scene_.primitive_color[2]);
+ SkColor foreground_color = SkColorSetARGB(
+ static_cast<uint8_t>(scene_.opacity * 255), scene_.primitive_color[0],
+ scene_.primitive_color[1], scene_.primitive_color[2]);
SkPath triangle_path;
triangle_path.moveTo(0.5f * rect_.width, 0.9f * rect_.height);
triangle_path.lineTo(0.1f * rect_.width, 0.1f * rect_.height);
diff --git a/components/test_runner/test_plugin.h b/components/test_runner/test_plugin.h
index 6c52dfe..55c2832 100644
--- a/components/test_runner/test_plugin.h
+++ b/components/test_runner/test_plugin.h
@@ -7,7 +7,7 @@
#include <string>
-#include "base/basictypes.h"
+#include "base/macros.h"
#include "base/memory/scoped_ptr.h"
#include "cc/layers/texture_layer.h"
#include "cc/layers/texture_layer_client.h"
diff --git a/components/test_runner/test_runner.cc b/components/test_runner/test_runner.cc
index 79224b1..e7743fd 100644
--- a/components/test_runner/test_runner.cc
+++ b/components/test_runner/test_runner.cc
@@ -4,9 +4,12 @@
#include "components/test_runner/test_runner.h"
+#include <stddef.h>
+
#include <limits>
#include "base/logging.h"
+#include "base/macros.h"
#include "base/strings/stringprintf.h"
#include "build/build_config.h"
#include "components/test_runner/mock_credential_manager_client.h"
diff --git a/components/test_runner/test_runner.h b/components/test_runner/test_runner.h
index be23d1b..372aff9 100644
--- a/components/test_runner/test_runner.h
+++ b/components/test_runner/test_runner.h
@@ -5,11 +5,14 @@
#ifndef COMPONENTS_TEST_RUNNER_TEST_RUNNER_H_
#define COMPONENTS_TEST_RUNNER_TEST_RUNNER_H_
+#include <stdint.h>
+
#include <deque>
#include <set>
#include <string>
#include <vector>
+#include "base/macros.h"
#include "base/memory/scoped_ptr.h"
#include "base/memory/weak_ptr.h"
#include "components/test_runner/test_runner_export.h"
@@ -609,7 +612,7 @@ class TestRunner : public WebTestRunner,
// Similar to LayoutAndPaintAsyncThen(), but pass parameters of the captured
// snapshot (width, height, snapshot) to the callback. The snapshot is in
- // uint8 RGBA format.
+ // uint8_t RGBA format.
void CapturePixelsAsyncThen(v8::Local<v8::Function> callback);
// Similar to CapturePixelsAsyncThen(). Copies to the clipboard the image
// located at a particular point in the WebView (if there is such an image),
diff --git a/components/test_runner/text_input_controller.cc b/components/test_runner/text_input_controller.cc
index 5539153..49678ab 100644
--- a/components/test_runner/text_input_controller.cc
+++ b/components/test_runner/text_input_controller.cc
@@ -4,6 +4,7 @@
#include "components/test_runner/text_input_controller.h"
+#include "base/macros.h"
#include "gin/arguments.h"
#include "gin/handle.h"
#include "gin/object_template_builder.h"
diff --git a/components/test_runner/web_ax_object_proxy.cc b/components/test_runner/web_ax_object_proxy.cc
index 3160dea..8c71884 100644
--- a/components/test_runner/web_ax_object_proxy.cc
+++ b/components/test_runner/web_ax_object_proxy.cc
@@ -4,6 +4,9 @@
#include "components/test_runner/web_ax_object_proxy.h"
+#include <stddef.h>
+
+#include "base/macros.h"
#include "base/strings/stringprintf.h"
#include "gin/handle.h"
#include "third_party/WebKit/public/platform/WebPoint.h"
diff --git a/components/test_runner/web_ax_object_proxy.h b/components/test_runner/web_ax_object_proxy.h
index d25fac6..cc7853a 100644
--- a/components/test_runner/web_ax_object_proxy.h
+++ b/components/test_runner/web_ax_object_proxy.h
@@ -5,9 +5,11 @@
#ifndef COMPONENTS_TEST_RUNNER_WEB_AX_OBJECT_PROXY_H_
#define COMPONENTS_TEST_RUNNER_WEB_AX_OBJECT_PROXY_H_
+#include <stdint.h>
+
#include <string>
-#include "base/basictypes.h"
+#include "base/macros.h"
#include "gin/object_template_builder.h"
#include "gin/wrappable.h"
#include "third_party/WebKit/public/web/WebAXObject.h"
diff --git a/components/test_runner/web_frame_test_proxy.h b/components/test_runner/web_frame_test_proxy.h
index 31ec31c..e2ff634 100644
--- a/components/test_runner/web_frame_test_proxy.h
+++ b/components/test_runner/web_frame_test_proxy.h
@@ -5,7 +5,7 @@
#ifndef COMPONENTS_TEST_RUNNER_WEB_FRAME_TEST_PROXY_H_
#define COMPONENTS_TEST_RUNNER_WEB_FRAME_TEST_PROXY_H_
-#include "base/basictypes.h"
+#include "base/macros.h"
#include "components/test_runner/mock_screen_orientation_client.h"
#include "components/test_runner/web_test_delegate.h"
#include "components/test_runner/web_test_interfaces.h"
diff --git a/components/test_runner/web_test_interfaces.h b/components/test_runner/web_test_interfaces.h
index 4056268..816b7e8 100644
--- a/components/test_runner/web_test_interfaces.h
+++ b/components/test_runner/web_test_interfaces.h
@@ -5,6 +5,7 @@
#ifndef COMPONENTS_TEST_RUNNER_WEB_TEST_INTERFACES_H_
#define COMPONENTS_TEST_RUNNER_WEB_TEST_INTERFACES_H_
+#include "base/macros.h"
#include "base/memory/scoped_ptr.h"
#include "components/test_runner/test_runner_export.h"
diff --git a/components/test_runner/web_test_proxy.cc b/components/test_runner/web_test_proxy.cc
index 1293ad3..9cd2372 100644
--- a/components/test_runner/web_test_proxy.cc
+++ b/components/test_runner/web_test_proxy.cc
@@ -4,6 +4,9 @@
#include "components/test_runner/web_test_proxy.h"
+#include <stddef.h>
+#include <stdint.h>
+
#include <cctype>
#include "base/callback_helpers.h"
diff --git a/components/test_runner/web_test_proxy.h b/components/test_runner/web_test_proxy.h
index 146ae1a..d304f64 100644
--- a/components/test_runner/web_test_proxy.h
+++ b/components/test_runner/web_test_proxy.h
@@ -9,9 +9,10 @@
#include <map>
#include <string>
-#include "base/basictypes.h"
#include "base/callback.h"
+#include "base/macros.h"
#include "base/memory/scoped_ptr.h"
+#include "build/build_config.h"
#include "components/test_runner/test_runner_export.h"
#include "components/test_runner/web_task.h"
#include "third_party/WebKit/public/platform/WebImage.h"
diff --git a/components/timers/alarm_timer_chromeos.cc b/components/timers/alarm_timer_chromeos.cc
index 8797345..57b1c0c 100644
--- a/components/timers/alarm_timer_chromeos.cc
+++ b/components/timers/alarm_timer_chromeos.cc
@@ -4,6 +4,7 @@
#include "components/timers/alarm_timer_chromeos.h"
+#include <stdint.h>
#include <sys/timerfd.h>
#include "base/bind.h"
diff --git a/components/toolbar/toolbar_model.h b/components/toolbar/toolbar_model.h
index dc67fc7..0a12208 100644
--- a/components/toolbar/toolbar_model.h
+++ b/components/toolbar/toolbar_model.h
@@ -5,9 +5,11 @@
#ifndef COMPONENTS_TOOLBAR_TOOLBAR_MODEL_H_
#define COMPONENTS_TOOLBAR_TOOLBAR_MODEL_H_
+#include <stddef.h>
+
#include <string>
-#include "base/basictypes.h"
+#include "base/macros.h"
#include "base/strings/string16.h"
#include "url/gurl.h"
diff --git a/components/tracing/child_memory_dump_manager_delegate_impl.cc b/components/tracing/child_memory_dump_manager_delegate_impl.cc
index fe5c952..05c2662 100644
--- a/components/tracing/child_memory_dump_manager_delegate_impl.cc
+++ b/components/tracing/child_memory_dump_manager_delegate_impl.cc
@@ -90,7 +90,7 @@ void ChildMemoryDumpManagerDelegateImpl::RequestGlobalMemoryDump(
ctmf_->SendGlobalMemoryDumpRequest(args, callback);
}
-uint64 ChildMemoryDumpManagerDelegateImpl::GetTracingProcessId() const {
+uint64_t ChildMemoryDumpManagerDelegateImpl::GetTracingProcessId() const {
return tracing_process_id_;
}
diff --git a/components/tracing/child_memory_dump_manager_delegate_impl.h b/components/tracing/child_memory_dump_manager_delegate_impl.h
index 8150a07..9a4dc6b 100644
--- a/components/tracing/child_memory_dump_manager_delegate_impl.h
+++ b/components/tracing/child_memory_dump_manager_delegate_impl.h
@@ -7,6 +7,9 @@
#include "base/trace_event/memory_dump_manager.h"
+#include <stdint.h>
+
+#include "base/macros.h"
#include "base/memory/ref_counted.h"
#include "base/memory/singleton.h"
#include "base/synchronization/lock.h"
@@ -35,12 +38,12 @@ class TRACING_EXPORT ChildMemoryDumpManagerDelegateImpl
void RequestGlobalMemoryDump(
const base::trace_event::MemoryDumpRequestArgs& args,
const base::trace_event::MemoryDumpCallback& callback) override;
- uint64 GetTracingProcessId() const override;
+ uint64_t GetTracingProcessId() const override;
void SetChildTraceMessageFilter(ChildTraceMessageFilter* ctmf);
// Pass kInvalidTracingProcessId to invalidate the id.
- void set_tracing_process_id(uint64 id) {
+ void set_tracing_process_id(uint64_t id) {
DCHECK(tracing_process_id_ ==
base::trace_event::MemoryDumpManager::kInvalidTracingProcessId ||
id ==
@@ -72,7 +75,7 @@ class TRACING_EXPORT ChildMemoryDumpManagerDelegateImpl
// The unique id of the child process, created for tracing and is expected to
// be valid only when tracing is enabled.
- uint64 tracing_process_id_;
+ uint64_t tracing_process_id_;
DISALLOW_COPY_AND_ASSIGN(ChildMemoryDumpManagerDelegateImpl);
};
diff --git a/components/tracing/child_trace_message_filter.cc b/components/tracing/child_trace_message_filter.cc
index 0694a17..f0d76ed 100644
--- a/components/tracing/child_trace_message_filter.cc
+++ b/components/tracing/child_trace_message_filter.cc
@@ -73,7 +73,7 @@ ChildTraceMessageFilter::~ChildTraceMessageFilter() {}
void ChildTraceMessageFilter::OnBeginTracing(
const std::string& trace_config_str,
base::TimeTicks browser_time,
- uint64 tracing_process_id) {
+ uint64_t tracing_process_id) {
#if defined(__native_client__)
// NaCl and system times are offset by a bit, so subtract some time from
// the captured timestamps. The value might be off by a bit due to messaging
@@ -200,7 +200,7 @@ void ChildTraceMessageFilter::OnProcessMemoryDumpRequest(
base::Bind(&ChildTraceMessageFilter::OnProcessMemoryDumpDone, this));
}
-void ChildTraceMessageFilter::OnProcessMemoryDumpDone(uint64 dump_guid,
+void ChildTraceMessageFilter::OnProcessMemoryDumpDone(uint64_t dump_guid,
bool success) {
sender_->Send(
new TracingHostMsg_ProcessMemoryDumpResponse(dump_guid, success));
@@ -229,7 +229,7 @@ void ChildTraceMessageFilter::SendGlobalMemoryDumpRequest(
// Sent by the Browser's MemoryDumpManager in response of a dump request
// initiated by this child process.
-void ChildTraceMessageFilter::OnGlobalMemoryDumpResponse(uint64 dump_guid,
+void ChildTraceMessageFilter::OnGlobalMemoryDumpResponse(uint64_t dump_guid,
bool success) {
DCHECK_NE(0U, pending_memory_dump_guid_);
pending_memory_dump_guid_ = 0;
diff --git a/components/tracing/child_trace_message_filter.h b/components/tracing/child_trace_message_filter.h
index 4799976..4a9cfc5 100644
--- a/components/tracing/child_trace_message_filter.h
+++ b/components/tracing/child_trace_message_filter.h
@@ -5,7 +5,10 @@
#ifndef COMPONENTS_TRACING_CHILD_TRACE_MESSAGE_FILTER_H_
#define COMPONENTS_TRACING_CHILD_TRACE_MESSAGE_FILTER_H_
+#include <stdint.h>
+
#include "base/bind.h"
+#include "base/macros.h"
#include "base/memory/ref_counted_memory.h"
#include "base/metrics/histogram.h"
#include "base/time/time.h"
@@ -47,7 +50,7 @@ class TRACING_EXPORT ChildTraceMessageFilter : public IPC::MessageFilter {
// Message handlers.
void OnBeginTracing(const std::string& trace_config_str,
base::TimeTicks browser_time,
- uint64 tracing_process_id);
+ uint64_t tracing_process_id);
void OnEndTracing();
void OnCancelTracing();
void OnStartMonitoring(const std::string& trace_config_str,
@@ -61,7 +64,7 @@ class TRACING_EXPORT ChildTraceMessageFilter : public IPC::MessageFilter {
void OnWatchEventMatched();
void OnProcessMemoryDumpRequest(
const base::trace_event::MemoryDumpRequestArgs& args);
- void OnGlobalMemoryDumpResponse(uint64 dump_guid, bool success);
+ void OnGlobalMemoryDumpResponse(uint64_t dump_guid, bool success);
void OnSetUMACallback(const std::string& histogram_name,
int histogram_lower_value,
int histogram_upper_value,
@@ -84,7 +87,7 @@ class TRACING_EXPORT ChildTraceMessageFilter : public IPC::MessageFilter {
const scoped_refptr<base::RefCountedString>& events_str_ptr,
bool has_more_events);
- void OnProcessMemoryDumpDone(uint64 dump_guid, bool success);
+ void OnProcessMemoryDumpDone(uint64_t dump_guid, bool success);
void SetSenderForTesting(IPC::Sender* sender);
@@ -93,7 +96,7 @@ class TRACING_EXPORT ChildTraceMessageFilter : public IPC::MessageFilter {
// guid of the outstanding request (to the Browser's MemoryDumpManager), if
// any. 0 if there is no request pending.
- uint64 pending_memory_dump_guid_;
+ uint64_t pending_memory_dump_guid_;
// callback of the outstanding memory dump request, if any.
base::trace_event::MemoryDumpCallback pending_memory_dump_callback_;
diff --git a/components/tracing/child_trace_message_filter_browsertest.cc b/components/tracing/child_trace_message_filter_browsertest.cc
index 7041104..011b556 100644
--- a/components/tracing/child_trace_message_filter_browsertest.cc
+++ b/components/tracing/child_trace_message_filter_browsertest.cc
@@ -2,6 +2,8 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
+#include <stdint.h>
+
#include "base/callback.h"
#include "base/run_loop.h"
#include "base/thread_task_runner_handle.h"
@@ -36,7 +38,7 @@ class MockDumpProvider : public base::trace_event::MemoryDumpProvider {
class ChildTracingTest : public content::RenderViewTest, public IPC::Listener {
public:
// Used as callback argument for MemoryDumpManager::RequestGlobalDump():
- void OnMemoryDumpCallback(uint64 dump_guid, bool status) {
+ void OnMemoryDumpCallback(uint64_t dump_guid, bool status) {
last_callback_dump_guid_ = dump_guid;
last_callback_status_ = status;
++callback_call_count_;
@@ -124,7 +126,7 @@ class ChildTracingTest : public content::RenderViewTest, public IPC::Listener {
// Simulates a synthetic browser -> child process memory dump request and
// checks that the child actually sends a response to that.
- void RequestProcessMemoryDumpAndCheckResponse(uint64 dump_guid) {
+ void RequestProcessMemoryDumpAndCheckResponse(uint64_t dump_guid) {
SimulateSyntheticMessageFromBrowser(TracingMsg_ProcessMemoryDumpRequest(
{dump_guid, MemoryDumpType::EXPLICITLY_TRIGGERED}));
@@ -136,7 +138,7 @@ class ChildTracingTest : public content::RenderViewTest, public IPC::Listener {
// Check that the |dump_guid| and the |success| fields are properly set.
TracingHostMsg_ProcessMemoryDumpResponse::Param params;
TracingHostMsg_ProcessMemoryDumpResponse::Read(msg, &params);
- const uint64 resp_guid = base::get<0>(params);
+ const uint64_t resp_guid = base::get<0>(params);
const bool resp_success = base::get<1>(params);
EXPECT_EQ(dump_guid, resp_guid);
EXPECT_TRUE(resp_success);
@@ -162,21 +164,21 @@ class ChildTracingTest : public content::RenderViewTest, public IPC::Listener {
base::trace_event::MemoryDumpCallback callback_;
uint32_t wait_for_ipc_message_type_;
base::Closure wait_for_ipc_closure_;
- uint32 callback_call_count_;
- uint64 last_callback_dump_guid_;
+ uint32_t callback_call_count_;
+ uint64_t last_callback_dump_guid_;
bool last_callback_status_;
};
// Covers the case of some browser-initiated memory dumps.
TEST_F(ChildTracingTest, BrowserInitiatedMemoryDumps) {
- const uint32 kNumDumps = 3;
+ const uint32_t kNumDumps = 3;
EnableTracingWithMemoryDumps();
EXPECT_CALL(*mock_dump_provider_, OnMemoryDump(_, _))
.Times(kNumDumps)
.WillRepeatedly(Return(true));
- for (uint32 i = 0; i < kNumDumps; ++i) {
+ for (uint32_t i = 0; i < kNumDumps; ++i) {
render_thread_->sink().ClearMessages();
RequestProcessMemoryDumpAndCheckResponse(i + 1);
}
@@ -274,7 +276,7 @@ TEST_F(ChildTracingTest, OverlappingChildInitiatedMemoryDumps) {
// Covers the case of five child-initiated global memory dumps. Each global dump
// request has a callback, which is expected to fail for 3 out of 5 cases.
TEST_F(ChildTracingTest, MultipleChildInitiatedMemoryDumpWithFailures) {
- const uint32 kNumRequests = 5;
+ const uint32_t kNumRequests = 5;
MemoryDumpType kDumpType = MemoryDumpType::EXPLICITLY_TRIGGERED;
EnableTracingWithMemoryDumps();
@@ -282,7 +284,7 @@ TEST_F(ChildTracingTest, MultipleChildInitiatedMemoryDumpWithFailures) {
.Times(kNumRequests)
.WillRepeatedly(Return(true));
- for (uint32 i = 0; i < kNumRequests; ++i) {
+ for (uint32_t i = 0; i < kNumRequests; ++i) {
render_thread_->sink().ClearMessages();
MemoryDumpManager::GetInstance()->RequestGlobalDump(
kDumpType, MemoryDumpLevelOfDetail::DETAILED, callback_);
diff --git a/components/tracing/graphics_memory_dump_provider_android.cc b/components/tracing/graphics_memory_dump_provider_android.cc
index dcafe40..da21617 100644
--- a/components/tracing/graphics_memory_dump_provider_android.cc
+++ b/components/tracing/graphics_memory_dump_provider_android.cc
@@ -5,12 +5,15 @@
#include "components/tracing/graphics_memory_dump_provider_android.h"
#include <fcntl.h>
+#include <stdint.h>
+#include <string.h>
#include <sys/socket.h>
#include <sys/time.h>
#include <sys/types.h>
#include <sys/un.h>
#include "base/files/scoped_file.h"
+#include "base/macros.h"
#include "base/posix/eintr_wrapper.h"
#include "base/strings/string_number_conversions.h"
#include "base/strings/string_piece.h"
diff --git a/components/tracing/graphics_memory_dump_provider_android.h b/components/tracing/graphics_memory_dump_provider_android.h
index c9dfd21..748810c 100644
--- a/components/tracing/graphics_memory_dump_provider_android.h
+++ b/components/tracing/graphics_memory_dump_provider_android.h
@@ -5,10 +5,13 @@
#ifndef COMPONENTS_TRACING_GRAPHICS_MEMORY_DUMP_PROVIDER_ANDROID_H_
#define COMPONENTS_TRACING_GRAPHICS_MEMORY_DUMP_PROVIDER_ANDROID_H_
+#include <stddef.h>
+
#include <string>
#include "base/containers/hash_tables.h"
#include "base/gtest_prod_util.h"
+#include "base/macros.h"
#include "base/memory/singleton.h"
#include "base/trace_event/memory_dump_provider.h"
#include "components/tracing/tracing_export.h"
diff --git a/components/tracing/trace_config_file.cc b/components/tracing/trace_config_file.cc
index f3b908e7..fb84d49 100644
--- a/components/tracing/trace_config_file.cc
+++ b/components/tracing/trace_config_file.cc
@@ -4,6 +4,8 @@
#include "components/tracing/trace_config_file.h"
+#include <stddef.h>
+
#include <string>
#include "base/command_line.h"
@@ -13,6 +15,7 @@
#include "base/logging.h"
#include "base/memory/singleton.h"
#include "base/values.h"
+#include "build/build_config.h"
#include "components/tracing/tracing_switches.h"
namespace tracing {
diff --git a/components/tracing/trace_config_file.h b/components/tracing/trace_config_file.h
index 0834fc2..c53c108 100644
--- a/components/tracing/trace_config_file.h
+++ b/components/tracing/trace_config_file.h
@@ -8,6 +8,7 @@
#include "base/files/file_path.h"
#include "base/macros.h"
#include "base/trace_event/trace_config.h"
+#include "build/build_config.h"
#include "components/tracing/tracing_export.h"
namespace base {
diff --git a/components/tracing/tracing_messages.h b/components/tracing/tracing_messages.h
index 26dd9d1..47592be 100644
--- a/components/tracing/tracing_messages.h
+++ b/components/tracing/tracing_messages.h
@@ -3,10 +3,12 @@
// found in the LICENSE file.
// Multiply-included message header, no traditional include guard.
+
+#include <stdint.h>
+
#include <string>
#include <vector>
-#include "base/basictypes.h"
#include "base/metrics/histogram.h"
#include "base/sync_socket.h"
#include "base/trace_event/memory_dump_request_args.h"
@@ -47,7 +49,7 @@ IPC_ENUM_TRAITS_MAX_VALUE(
IPC_MESSAGE_CONTROL3(TracingMsg_BeginTracing,
std::string /* trace_config_str */,
base::TimeTicks /* browser_time */,
- uint64 /* Tracing process id (hash of child id) */)
+ uint64_t /* Tracing process id (hash of child id) */)
// Sent to all child processes to disable trace event recording.
IPC_MESSAGE_CONTROL0(TracingMsg_EndTracing)
@@ -84,7 +86,7 @@ IPC_MESSAGE_CONTROL1(TracingMsg_ProcessMemoryDumpRequest,
// Reply to TracingHostMsg_GlobalMemoryDumpRequest, sent by the browser process.
// This is to get the result of a global dump initiated by a child process.
IPC_MESSAGE_CONTROL2(TracingMsg_GlobalMemoryDumpResponse,
- uint64 /* dump_guid */,
+ uint64_t /* dump_guid */,
bool /* success */)
IPC_MESSAGE_CONTROL4(TracingMsg_SetUMACallback,
@@ -129,7 +131,7 @@ IPC_MESSAGE_CONTROL1(TracingHostMsg_GlobalMemoryDumpRequest,
// Reply to TracingMsg_ProcessMemoryDumpRequest.
IPC_MESSAGE_CONTROL2(TracingHostMsg_ProcessMemoryDumpResponse,
- uint64 /* dump_guid */,
+ uint64_t /* dump_guid */,
bool /* success */)
IPC_MESSAGE_CONTROL1(TracingHostMsg_TriggerBackgroundTrace,
diff --git a/components/translate/content/browser/content_translate_driver.h b/components/translate/content/browser/content_translate_driver.h
index ee352ff..92d5d64 100644
--- a/components/translate/content/browser/content_translate_driver.h
+++ b/components/translate/content/browser/content_translate_driver.h
@@ -5,7 +5,7 @@
#ifndef COMPONENTS_TRANSLATE_CONTENT_BROWSER_CONTENT_TRANSLATE_DRIVER_H_
#define COMPONENTS_TRANSLATE_CONTENT_BROWSER_CONTENT_TRANSLATE_DRIVER_H_
-#include "base/basictypes.h"
+#include "base/macros.h"
#include "base/memory/weak_ptr.h"
#include "base/observer_list.h"
#include "components/translate/core/browser/translate_driver.h"
diff --git a/components/translate/content/browser/data_file_browser_cld_data_provider.cc b/components/translate/content/browser/data_file_browser_cld_data_provider.cc
index 05fd8a9..dcfe4ce 100644
--- a/components/translate/content/browser/data_file_browser_cld_data_provider.cc
+++ b/components/translate/content/browser/data_file_browser_cld_data_provider.cc
@@ -8,7 +8,6 @@
#include "components/translate/content/browser/data_file_browser_cld_data_provider.h"
-#include "base/basictypes.h"
#include "base/files/file.h"
#include "base/files/file_path.h"
#include "base/files/file_util.h"
@@ -32,8 +31,8 @@ namespace {
// We also track the offset at which the data starts, and its length.
base::LazyInstance<base::FilePath> g_cached_filepath; // guarded by g_file_lock
base::File* g_cached_file = NULL; // guarded by g_file_lock_
-uint64 g_cached_data_offset = 0; // guarded by g_file_lock_
-uint64 g_cached_data_length = 0; // guarded by g_file_lock_
+uint64_t g_cached_data_offset = 0; // guarded by g_file_lock_
+uint64_t g_cached_data_length = 0; // guarded by g_file_lock_
// Guards g_cached_filepath
base::LazyInstance<base::Lock> g_file_lock_;
@@ -87,8 +86,8 @@ void DataFileBrowserCldDataProvider::OnCldDataRequest() {
// blocking pool.
VLOG(1) << "Received request for CLD data file.";
base::File* handle = NULL;
- uint64 data_offset = 0;
- uint64 data_length = 0;
+ uint64_t data_offset = 0;
+ uint64_t data_length = 0;
{
base::AutoLock lock(g_file_lock_.Get());
handle = g_cached_file;
@@ -125,8 +124,8 @@ void DataFileBrowserCldDataProvider::OnCldDataRequest() {
void DataFileBrowserCldDataProvider::SendCldDataResponse() {
base::File* handle = NULL;
- uint64 data_offset = 0;
- uint64 data_length = 0;
+ uint64_t data_offset = 0;
+ uint64_t data_length = 0;
{
base::AutoLock lock(g_file_lock_.Get());
handle = g_cached_file;
@@ -140,8 +139,8 @@ void DataFileBrowserCldDataProvider::SendCldDataResponse() {
void DataFileBrowserCldDataProvider::SendCldDataResponseInternal(
const base::File* handle,
- const uint64 data_offset,
- const uint64 data_length) {
+ const uint64_t data_offset,
+ const uint64_t data_length) {
VLOG(1) << "Sending CLD data file response.";
content::RenderFrameHost* render_frame_host =
@@ -224,8 +223,8 @@ void DataFileBrowserCldDataProvider::OnCldDataRequestInternal() {
// For now, our offset and length are simply 0 and the length of the file,
// respectively. If we later decide to include the CLD2 data file inside of
// a larger binary context, these params can be twiddled appropriately.
- const uint64 data_offset = 0;
- const uint64 data_length = file_info.size;
+ const uint64_t data_offset = 0;
+ const uint64_t data_length = file_info.size;
{
base::AutoLock lock(g_file_lock_.Get());
diff --git a/components/translate/content/browser/data_file_browser_cld_data_provider.h b/components/translate/content/browser/data_file_browser_cld_data_provider.h
index 0114017..05dbd18 100644
--- a/components/translate/content/browser/data_file_browser_cld_data_provider.h
+++ b/components/translate/content/browser/data_file_browser_cld_data_provider.h
@@ -9,6 +9,8 @@
#ifndef COMPONENTS_TRANSLATE_CONTENT_BROWSER_DATA_FILE_BROWSER_CLD_DATA_PROVIDER_H_
#define COMPONENTS_TRANSLATE_CONTENT_BROWSER_DATA_FILE_BROWSER_CLD_DATA_PROVIDER_H_
+#include <stdint.h>
+
#include "base/files/file.h"
#include "base/files/file_path.h"
#include "base/macros.h"
@@ -34,8 +36,8 @@ class DataFileBrowserCldDataProvider : public BrowserCldDataProvider {
private:
void SendCldDataResponseInternal(const base::File*,
- const uint64,
- const uint64);
+ const uint64_t,
+ const uint64_t);
static void OnCldDataRequestInternal();
content::WebContents* web_contents_;
diff --git a/components/translate/content/common/data_file_cld_data_provider_messages.h b/components/translate/content/common/data_file_cld_data_provider_messages.h
index 04a1e33..1faa3b6 100644
--- a/components/translate/content/common/data_file_cld_data_provider_messages.h
+++ b/components/translate/content/common/data_file_cld_data_provider_messages.h
@@ -8,6 +8,8 @@
// Multiply-included message file, hence no include guard.
+#include <stdint.h>
+
#include "ipc/ipc_message_macros.h"
#include "ipc/ipc_message_utils.h"
#include "ipc/ipc_platform_file.h"
@@ -32,5 +34,5 @@ IPC_MESSAGE_ROUTED0(ChromeFrameHostMsg_NeedCldDataFile)
// DataFileRendererCldDataProvider.
IPC_MESSAGE_ROUTED3(ChromeFrameMsg_CldDataFileAvailable,
IPC::PlatformFileForTransit /* ipc_file_handle */,
- uint64 /* data_offset */,
- uint64 /* data_length */)
+ uint64_t /* data_offset */,
+ uint64_t /* data_length */)
diff --git a/components/translate/content/renderer/data_file_renderer_cld_data_provider.cc b/components/translate/content/renderer/data_file_renderer_cld_data_provider.cc
index 792a3bc..6bfb46e 100644
--- a/components/translate/content/renderer/data_file_renderer_cld_data_provider.cc
+++ b/components/translate/content/renderer/data_file_renderer_cld_data_provider.cc
@@ -8,7 +8,6 @@
#include "data_file_renderer_cld_data_provider.h"
-#include "base/basictypes.h"
#include "base/files/file.h"
#include "base/files/memory_mapped_file.h"
#include "base/lazy_instance.h"
@@ -72,16 +71,16 @@ void DataFileRendererCldDataProvider::SetCldAvailableCallback(
void DataFileRendererCldDataProvider::OnCldDataAvailable(
const IPC::PlatformFileForTransit ipc_file_handle,
- const uint64 data_offset,
- const uint64 data_length) {
+ const uint64_t data_offset,
+ const uint64_t data_length) {
LoadCldData(IPC::PlatformFileForTransitToFile(ipc_file_handle),
data_offset,
data_length);
}
void DataFileRendererCldDataProvider::LoadCldData(base::File file,
- const uint64 data_offset,
- const uint64 data_length) {
+ const uint64_t data_offset,
+ const uint64_t data_length) {
// Terminate immediately if data is already loaded.
if (IsCldDataAvailable())
return;
@@ -102,7 +101,7 @@ void DataFileRendererCldDataProvider::LoadCldData(base::File file,
}
// Sanity checks
- uint64 max_int32 = std::numeric_limits<int32>::max();
+ uint64_t max_int32 = std::numeric_limits<int32_t>::max();
if (data_length + data_offset > g_cld_mmap.Get().value->length() ||
data_length > max_int32) { // max signed 32 bit integer
LOG(ERROR) << "Illegal mmap config: data_offset=" << data_offset
@@ -114,7 +113,7 @@ void DataFileRendererCldDataProvider::LoadCldData(base::File file,
}
// Initialize the CLD subsystem... and it's all done!
- const uint8* data_ptr = g_cld_mmap.Get().value->data() + data_offset;
+ const uint8_t* data_ptr = g_cld_mmap.Get().value->data() + data_offset;
CLD2::loadDataFromRawAddress(data_ptr, data_length);
DCHECK(CLD2::isDataLoaded()) << "Failed to load CLD data from mmap";
if (!cld_available_callback_.is_null()) {
diff --git a/components/translate/content/renderer/data_file_renderer_cld_data_provider.h b/components/translate/content/renderer/data_file_renderer_cld_data_provider.h
index 53764c4..8b64475 100644
--- a/components/translate/content/renderer/data_file_renderer_cld_data_provider.h
+++ b/components/translate/content/renderer/data_file_renderer_cld_data_provider.h
@@ -9,6 +9,8 @@
#ifndef COMPONENTS_TRANSLATE_CONTENT_RENDERER_DATA_FILE_RENDERER_CLD_DATA_PROVIDER_H_
#define COMPONENTS_TRANSLATE_CONTENT_RENDERER_DATA_FILE_RENDERER_CLD_DATA_PROVIDER_H_
+#include <stdint.h>
+
#include "base/files/file.h"
#include "base/macros.h"
#include "components/translate/content/renderer/renderer_cld_data_provider.h"
@@ -32,8 +34,8 @@ class DataFileRendererCldDataProvider : public RendererCldDataProvider {
// third_party/cld_2/src/internal/compact_lang_det.h for more information on
// the dynamic data loading process.
void LoadCldData(base::File file,
- const uint64 data_offset,
- const uint64 data_length);
+ const uint64_t data_offset,
+ const uint64_t data_length);
// RendererCldDataProvider implementations:
bool OnMessageReceived(const IPC::Message&) override;
@@ -43,8 +45,8 @@ class DataFileRendererCldDataProvider : public RendererCldDataProvider {
private:
void OnCldDataAvailable(const IPC::PlatformFileForTransit ipc_file_handle,
- const uint64 data_offset,
- const uint64 data_length);
+ const uint64_t data_offset,
+ const uint64_t data_length);
content::RenderFrameObserver* render_frame_observer_;
base::Callback<void(void)> cld_available_callback_;
diff --git a/components/translate/content/renderer/translate_helper.h b/components/translate/content/renderer/translate_helper.h
index ad3a5d8..e3eab89 100644
--- a/components/translate/content/renderer/translate_helper.h
+++ b/components/translate/content/renderer/translate_helper.h
@@ -7,6 +7,7 @@
#include <string>
+#include "base/macros.h"
#include "base/memory/scoped_ptr.h"
#include "base/memory/weak_ptr.h"
#include "base/strings/string16.h"
diff --git a/components/translate/core/browser/language_state.h b/components/translate/core/browser/language_state.h
index 4bd7f4b..08e670f 100644
--- a/components/translate/core/browser/language_state.h
+++ b/components/translate/core/browser/language_state.h
@@ -7,7 +7,7 @@
#include <string>
-#include "base/basictypes.h"
+#include "base/macros.h"
namespace translate {
diff --git a/components/translate/core/browser/language_state_unittest.cc b/components/translate/core/browser/language_state_unittest.cc
index c028a28..2116e96 100644
--- a/components/translate/core/browser/language_state_unittest.cc
+++ b/components/translate/core/browser/language_state_unittest.cc
@@ -4,6 +4,7 @@
#include "components/translate/core/browser/language_state.h"
+#include "base/macros.h"
#include "base/memory/scoped_ptr.h"
#include "components/translate/core/browser/language_state.h"
#include "components/translate/core/browser/translate_driver.h"
diff --git a/components/translate/core/browser/options_menu_model.cc b/components/translate/core/browser/options_menu_model.cc
index f5eeb1b..d369f63 100644
--- a/components/translate/core/browser/options_menu_model.cc
+++ b/components/translate/core/browser/options_menu_model.cc
@@ -5,6 +5,7 @@
#include "components/translate/core/browser/options_menu_model.h"
#include "base/metrics/histogram.h"
+#include "build/build_config.h"
#include "components/translate/core/browser/translate_driver.h"
#include "components/translate/core/browser/translate_infobar_delegate.h"
#include "grit/components_strings.h"
diff --git a/components/translate/core/browser/options_menu_model.h b/components/translate/core/browser/options_menu_model.h
index 5beae3b..44fc5b2 100644
--- a/components/translate/core/browser/options_menu_model.h
+++ b/components/translate/core/browser/options_menu_model.h
@@ -5,6 +5,7 @@
#ifndef COMPONENTS_TRANSLATE_CORE_BROWSER_OPTIONS_MENU_MODEL_H_
#define COMPONENTS_TRANSLATE_CORE_BROWSER_OPTIONS_MENU_MODEL_H_
+#include "base/macros.h"
#include "ui/base/models/simple_menu_model.h"
namespace translate {
diff --git a/components/translate/core/browser/translate_accept_languages.cc b/components/translate/core/browser/translate_accept_languages.cc
index e65d92f..b95a63f 100644
--- a/components/translate/core/browser/translate_accept_languages.cc
+++ b/components/translate/core/browser/translate_accept_languages.cc
@@ -4,6 +4,8 @@
#include "components/translate/core/browser/translate_accept_languages.h"
+#include <stddef.h>
+
#include "base/bind.h"
#include "base/prefs/pref_service.h"
#include "base/strings/string_split.h"
diff --git a/components/translate/core/browser/translate_accept_languages.h b/components/translate/core/browser/translate_accept_languages.h
index 33b8884..e429648 100644
--- a/components/translate/core/browser/translate_accept_languages.h
+++ b/components/translate/core/browser/translate_accept_languages.h
@@ -8,7 +8,7 @@
#include <set>
#include <string>
-#include "base/basictypes.h"
+#include "base/macros.h"
#include "base/prefs/pref_change_registrar.h"
class PrefService;
diff --git a/components/translate/core/browser/translate_browser_metrics.cc b/components/translate/core/browser/translate_browser_metrics.cc
index d2791050..75b9177 100644
--- a/components/translate/core/browser/translate_browser_metrics.cc
+++ b/components/translate/core/browser/translate_browser_metrics.cc
@@ -4,9 +4,11 @@
#include "components/translate/core/browser/translate_browser_metrics.h"
+#include <stddef.h>
+
#include <string>
-#include "base/basictypes.h"
+#include "base/macros.h"
#include "base/metrics/histogram_macros.h"
#include "base/metrics/sparse_histogram.h"
#include "components/language_usage_metrics/language_usage_metrics.h"
diff --git a/components/translate/core/browser/translate_browser_metrics_unittest.cc b/components/translate/core/browser/translate_browser_metrics_unittest.cc
index c9a24c2..c384a31 100644
--- a/components/translate/core/browser/translate_browser_metrics_unittest.cc
+++ b/components/translate/core/browser/translate_browser_metrics_unittest.cc
@@ -4,7 +4,7 @@
#include "components/translate/core/browser/translate_browser_metrics.h"
-#include "base/basictypes.h"
+#include "base/macros.h"
#include "base/memory/scoped_ptr.h"
#include "base/metrics/histogram.h"
#include "base/metrics/histogram_samples.h"
diff --git a/components/translate/core/browser/translate_infobar_delegate.cc b/components/translate/core/browser/translate_infobar_delegate.cc
index 605bf49..d038466 100644
--- a/components/translate/core/browser/translate_infobar_delegate.cc
+++ b/components/translate/core/browser/translate_infobar_delegate.cc
@@ -8,6 +8,7 @@
#include "base/i18n/string_compare.h"
#include "base/metrics/histogram_macros.h"
+#include "build/build_config.h"
#include "components/infobars/core/infobar.h"
#include "components/infobars/core/infobar_manager.h"
#include "components/translate/core/browser/language_state.h"
diff --git a/components/translate/core/browser/translate_infobar_delegate.h b/components/translate/core/browser/translate_infobar_delegate.h
index 671ed5c..7843183 100644
--- a/components/translate/core/browser/translate_infobar_delegate.h
+++ b/components/translate/core/browser/translate_infobar_delegate.h
@@ -5,13 +5,17 @@
#ifndef COMPONENTS_TRANSLATE_CORE_BROWSER_TRANSLATE_INFOBAR_DELEGATE_H_
#define COMPONENTS_TRANSLATE_CORE_BROWSER_TRANSLATE_INFOBAR_DELEGATE_H_
+#include <stddef.h>
+
#include <string>
#include <utility>
#include <vector>
#include "base/logging.h"
+#include "base/macros.h"
#include "base/memory/scoped_ptr.h"
#include "base/memory/weak_ptr.h"
+#include "build/build_config.h"
#include "components/infobars/core/infobar_delegate.h"
#include "components/translate/core/browser/translate_prefs.h"
#include "components/translate/core/browser/translate_step.h"
diff --git a/components/translate/core/browser/translate_language_list.cc b/components/translate/core/browser/translate_language_list.cc
index a9ce331..881406b 100644
--- a/components/translate/core/browser/translate_language_list.cc
+++ b/components/translate/core/browser/translate_language_list.cc
@@ -4,12 +4,15 @@
#include "components/translate/core/browser/translate_language_list.h"
+#include <stddef.h>
+
#include <set>
#include "base/bind.h"
#include "base/json/json_reader.h"
#include "base/lazy_instance.h"
#include "base/logging.h"
+#include "base/macros.h"
#include "base/strings/string_util.h"
#include "base/strings/stringprintf.h"
#include "base/values.h"
diff --git a/components/translate/core/browser/translate_language_list.h b/components/translate/core/browser/translate_language_list.h
index c9a3316..a6ba955 100644
--- a/components/translate/core/browser/translate_language_list.h
+++ b/components/translate/core/browser/translate_language_list.h
@@ -11,6 +11,7 @@
#include "base/callback_list.h"
#include "base/gtest_prod_util.h"
+#include "base/macros.h"
#include "base/memory/scoped_ptr.h"
#include "base/time/time.h"
diff --git a/components/translate/core/browser/translate_manager.h b/components/translate/core/browser/translate_manager.h
index c099002..3cf2af1 100644
--- a/components/translate/core/browser/translate_manager.h
+++ b/components/translate/core/browser/translate_manager.h
@@ -10,6 +10,7 @@
#include <vector>
#include "base/callback_list.h"
+#include "base/macros.h"
#include "base/memory/scoped_ptr.h"
#include "base/memory/weak_ptr.h"
#include "components/translate/core/browser/language_state.h"
diff --git a/components/translate/core/browser/translate_manager_unittest.cc b/components/translate/core/browser/translate_manager_unittest.cc
index 77c5d03..b416f36f 100644
--- a/components/translate/core/browser/translate_manager_unittest.cc
+++ b/components/translate/core/browser/translate_manager_unittest.cc
@@ -4,6 +4,7 @@
#include "components/translate/core/browser/translate_manager.h"
+#include "build/build_config.h"
#include "components/pref_registry/pref_registry_syncable.h"
#include "components/pref_registry/testing_pref_service_syncable.h"
#include "components/translate/core/browser/translate_download_manager.h"
diff --git a/components/translate/core/browser/translate_prefs.cc b/components/translate/core/browser/translate_prefs.cc
index 78105ba..b265f96 100644
--- a/components/translate/core/browser/translate_prefs.cc
+++ b/components/translate/core/browser/translate_prefs.cc
@@ -10,6 +10,7 @@
#include "base/prefs/scoped_user_pref_update.h"
#include "base/strings/string_split.h"
#include "base/strings/string_util.h"
+#include "build/build_config.h"
#include "components/pref_registry/pref_registry_syncable.h"
#include "components/translate/core/browser/translate_accept_languages.h"
#include "components/translate/core/browser/translate_download_manager.h"
diff --git a/components/translate/core/browser/translate_prefs.h b/components/translate/core/browser/translate_prefs.h
index 5e9be62..10b39ca 100644
--- a/components/translate/core/browser/translate_prefs.h
+++ b/components/translate/core/browser/translate_prefs.h
@@ -5,12 +5,16 @@
#ifndef COMPONENTS_TRANSLATE_CORE_BROWSER_TRANSLATE_PREFS_H_
#define COMPONENTS_TRANSLATE_CORE_BROWSER_TRANSLATE_PREFS_H_
+#include <stddef.h>
+
#include <string>
#include <vector>
#include "base/gtest_prod_util.h"
+#include "base/macros.h"
#include "base/prefs/scoped_user_pref_update.h"
#include "base/time/time.h"
+#include "build/build_config.h"
#include "url/gurl.h"
class PrefService;
diff --git a/components/translate/core/browser/translate_prefs_unittest.cc b/components/translate/core/browser/translate_prefs_unittest.cc
index 7773dc3..9c61c5d 100644
--- a/components/translate/core/browser/translate_prefs_unittest.cc
+++ b/components/translate/core/browser/translate_prefs_unittest.cc
@@ -9,6 +9,7 @@
#include <vector>
#include "base/prefs/scoped_user_pref_update.h"
+#include "build/build_config.h"
#include "components/pref_registry/testing_pref_service_syncable.h"
#include "components/translate/core/browser/translate_download_manager.h"
#include "testing/gtest/include/gtest/gtest.h"
diff --git a/components/translate/core/browser/translate_script.cc b/components/translate/core/browser/translate_script.cc
index 379b55b..5dad793 100644
--- a/components/translate/core/browser/translate_script.cc
+++ b/components/translate/core/browser/translate_script.cc
@@ -14,6 +14,7 @@
#include "base/strings/string_util.h"
#include "base/strings/stringprintf.h"
#include "base/thread_task_runner_handle.h"
+#include "build/build_config.h"
#include "components/translate/core/browser/translate_url_fetcher.h"
#include "components/translate/core/browser/translate_url_util.h"
#include "components/translate/core/common/translate_switches.h"
diff --git a/components/translate/core/browser/translate_script.h b/components/translate/core/browser/translate_script.h
index 065ccc7..1a39d8f 100644
--- a/components/translate/core/browser/translate_script.h
+++ b/components/translate/core/browser/translate_script.h
@@ -10,6 +10,7 @@
#include "base/callback_forward.h"
#include "base/gtest_prod_util.h"
+#include "base/macros.h"
#include "base/memory/scoped_ptr.h"
#include "base/memory/weak_ptr.h"
#include "base/time/time.h"
diff --git a/components/translate/core/browser/translate_script_unittest.cc b/components/translate/core/browser/translate_script_unittest.cc
index 288b59b..cc99eb9 100644
--- a/components/translate/core/browser/translate_script_unittest.cc
+++ b/components/translate/core/browser/translate_script_unittest.cc
@@ -6,7 +6,9 @@
#include "base/bind.h"
#include "base/command_line.h"
+#include "base/macros.h"
#include "base/strings/stringprintf.h"
+#include "build/build_config.h"
#include "components/translate/core/browser/translate_download_manager.h"
#include "components/translate/core/common/translate_switches.h"
#include "net/base/load_flags.h"
diff --git a/components/translate/core/browser/translate_step.h b/components/translate/core/browser/translate_step.h
index 6a9c18c..73b7ffc 100644
--- a/components/translate/core/browser/translate_step.h
+++ b/components/translate/core/browser/translate_step.h
@@ -5,7 +5,7 @@
#ifndef COMPONENTS_TRANSLATE_CORE_BROWSER_TRANSLATE_STEP_H_
#define COMPONENTS_TRANSLATE_CORE_BROWSER_TRANSLATE_STEP_H_
-#include "base/basictypes.h"
+#include "build/build_config.h"
namespace translate {
diff --git a/components/translate/core/browser/translate_ui_delegate.h b/components/translate/core/browser/translate_ui_delegate.h
index 04f457c..82a4bc9 100644
--- a/components/translate/core/browser/translate_ui_delegate.h
+++ b/components/translate/core/browser/translate_ui_delegate.h
@@ -5,10 +5,13 @@
#ifndef COMPONENTS_TRANSLATE_CORE_BROWSER_TRANSLATE_UI_DELEGATE_H_
#define COMPONENTS_TRANSLATE_CORE_BROWSER_TRANSLATE_UI_DELEGATE_H_
+#include <stddef.h>
+
#include <string>
#include <vector>
#include "base/logging.h"
+#include "base/macros.h"
#include "base/memory/scoped_ptr.h"
#include "base/memory/weak_ptr.h"
#include "base/strings/string16.h"
diff --git a/components/translate/core/browser/translate_url_fetcher.h b/components/translate/core/browser/translate_url_fetcher.h
index 90ed6bc..290750e 100644
--- a/components/translate/core/browser/translate_url_fetcher.h
+++ b/components/translate/core/browser/translate_url_fetcher.h
@@ -6,6 +6,7 @@
#define COMPONENTS_TRANSLATE_CORE_BROWSER_TRANSLATE_URL_FETCHER_H_
#include "base/callback.h"
+#include "base/macros.h"
#include "base/memory/scoped_ptr.h"
#include "net/url_request/url_fetcher_delegate.h"
#include "url/gurl.h"
diff --git a/components/translate/core/common/translate_errors.h b/components/translate/core/common/translate_errors.h
index 5016ef9..268fe45 100644
--- a/components/translate/core/common/translate_errors.h
+++ b/components/translate/core/common/translate_errors.h
@@ -5,7 +5,7 @@
#ifndef COMPONENTS_TRANSLATE_CORE_COMMON_TRANSLATE_ERRORS_H_
#define COMPONENTS_TRANSLATE_CORE_COMMON_TRANSLATE_ERRORS_H_
-#include "base/basictypes.h"
+#include "base/macros.h"
namespace translate {
diff --git a/components/translate/core/common/translate_metrics.cc b/components/translate/core/common/translate_metrics.cc
index 84dcf34ef..ae31a23 100644
--- a/components/translate/core/common/translate_metrics.cc
+++ b/components/translate/core/common/translate_metrics.cc
@@ -4,7 +4,10 @@
#include "components/translate/core/common/translate_metrics.h"
-#include "base/basictypes.h"
+#include <stddef.h>
+#include <stdint.h>
+
+#include "base/macros.h"
#include "base/metrics/histogram_macros.h"
#include "url/url_constants.h"
@@ -78,24 +81,21 @@ void ReportLanguageVerification(LanguageVerificationType type) {
}
void ReportTimeToBeReady(double time_in_msec) {
- UMA_HISTOGRAM_MEDIUM_TIMES(
- kTranslateTimeToBeReady,
- base::TimeDelta::FromMicroseconds(
- static_cast<int64>(time_in_msec * 1000.0)));
+ UMA_HISTOGRAM_MEDIUM_TIMES(kTranslateTimeToBeReady,
+ base::TimeDelta::FromMicroseconds(
+ static_cast<int64_t>(time_in_msec * 1000.0)));
}
void ReportTimeToLoad(double time_in_msec) {
- UMA_HISTOGRAM_MEDIUM_TIMES(
- kTranslateTimeToLoad,
- base::TimeDelta::FromMicroseconds(
- static_cast<int64>(time_in_msec * 1000.0)));
+ UMA_HISTOGRAM_MEDIUM_TIMES(kTranslateTimeToLoad,
+ base::TimeDelta::FromMicroseconds(
+ static_cast<int64_t>(time_in_msec * 1000.0)));
}
void ReportTimeToTranslate(double time_in_msec) {
- UMA_HISTOGRAM_MEDIUM_TIMES(
- kTranslateTimeToTranslate,
- base::TimeDelta::FromMicroseconds(
- static_cast<int64>(time_in_msec * 1000.0)));
+ UMA_HISTOGRAM_MEDIUM_TIMES(kTranslateTimeToTranslate,
+ base::TimeDelta::FromMicroseconds(
+ static_cast<int64_t>(time_in_msec * 1000.0)));
}
void ReportUserActionDuration(base::TimeTicks begin, base::TimeTicks end) {
diff --git a/components/translate/core/common/translate_metrics_unittest.cc b/components/translate/core/common/translate_metrics_unittest.cc
index 04eac9f..2867d70 100644
--- a/components/translate/core/common/translate_metrics_unittest.cc
+++ b/components/translate/core/common/translate_metrics_unittest.cc
@@ -4,7 +4,7 @@
#include "components/translate/core/common/translate_metrics.h"
-#include "base/basictypes.h"
+#include "base/macros.h"
#include "base/memory/scoped_ptr.h"
#include "base/metrics/histogram.h"
#include "base/metrics/histogram_samples.h"
diff --git a/components/translate/core/common/translate_util.cc b/components/translate/core/common/translate_util.cc
index 6cb6d14..7eef452 100644
--- a/components/translate/core/common/translate_util.cc
+++ b/components/translate/core/common/translate_util.cc
@@ -4,9 +4,11 @@
#include "components/translate/core/common/translate_util.h"
-#include "base/basictypes.h"
+#include <stddef.h>
+
#include "base/command_line.h"
#include "base/logging.h"
+#include "base/macros.h"
#include "base/strings/string_split.h"
#include "components/translate/core/common/translate_switches.h"
#include "url/gurl.h"
diff --git a/components/translate/core/language_detection/language_detection_util.cc b/components/translate/core/language_detection/language_detection_util.cc
index c4699d4d..3b8bda7 100644
--- a/components/translate/core/language_detection/language_detection_util.cc
+++ b/components/translate/core/language_detection/language_detection_util.cc
@@ -4,7 +4,10 @@
#include "components/translate/core/language_detection/language_detection_util.h"
+#include <stddef.h>
+
#include "base/logging.h"
+#include "base/macros.h"
#include "base/strings/string_split.h"
#include "base/strings/string_util.h"
#include "base/strings/utf_string_conversions.h"
diff --git a/components/translate/ios/browser/ios_translate_driver.h b/components/translate/ios/browser/ios_translate_driver.h
index e54bd6a..20103ad 100644
--- a/components/translate/ios/browser/ios_translate_driver.h
+++ b/components/translate/ios/browser/ios_translate_driver.h
@@ -7,7 +7,7 @@
#include <string>
-#include "base/basictypes.h"
+#include "base/macros.h"
#include "base/memory/weak_ptr.h"
#include "components/translate/core/browser/translate_driver.h"
#include "components/translate/ios/browser/language_detection_controller.h"
diff --git a/components/translate/ios/browser/js_language_detection_manager.h b/components/translate/ios/browser/js_language_detection_manager.h
index b7ca492..83a6065 100644
--- a/components/translate/ios/browser/js_language_detection_manager.h
+++ b/components/translate/ios/browser/js_language_detection_manager.h
@@ -6,6 +6,7 @@
#define COMPONENTS_TRANSLATE_IOS_BROWSER_JS_LANGUAGE_DETECTION_MANAGER_H_
#import <Foundation/Foundation.h>
+#include <stddef.h>
#include "base/callback_forward.h"
#include "base/strings/string16.h"
diff --git a/components/ui/zoom/page_zoom.cc b/components/ui/zoom/page_zoom.cc
index 3f4470f..6d65d78 100644
--- a/components/ui/zoom/page_zoom.cc
+++ b/components/ui/zoom/page_zoom.cc
@@ -4,6 +4,8 @@
#include "components/ui/zoom/page_zoom.h"
+#include <stddef.h>
+
#include <algorithm>
#include <cmath>
diff --git a/components/ui/zoom/page_zoom_constants.h b/components/ui/zoom/page_zoom_constants.h
index 50d9b4c..bb2111e 100644
--- a/components/ui/zoom/page_zoom_constants.h
+++ b/components/ui/zoom/page_zoom_constants.h
@@ -5,6 +5,8 @@
#ifndef COMPONENTS_UI_ZOOM_PAGE_ZOOM_CONSTANTS_H_
#define COMPONENTS_UI_ZOOM_PAGE_ZOOM_CONSTANTS_H_
+#include <stddef.h>
+
#include <vector>
namespace ui_zoom {
diff --git a/components/ui/zoom/zoom_controller.h b/components/ui/zoom/zoom_controller.h
index 8eae938..ce6cc83 100644
--- a/components/ui/zoom/zoom_controller.h
+++ b/components/ui/zoom/zoom_controller.h
@@ -5,8 +5,8 @@
#ifndef COMPONENTS_UI_ZOOM_ZOOM_CONTROLLER_H_
#define COMPONENTS_UI_ZOOM_ZOOM_CONTROLLER_H_
-#include "base/basictypes.h"
#include "base/compiler_specific.h"
+#include "base/macros.h"
#include "base/memory/ref_counted.h"
#include "base/memory/scoped_ptr.h"
#include "base/observer_list.h"
diff --git a/components/ui/zoom/zoom_event_manager.h b/components/ui/zoom/zoom_event_manager.h
index b18c3a4..4d9f7e0 100644
--- a/components/ui/zoom/zoom_event_manager.h
+++ b/components/ui/zoom/zoom_event_manager.h
@@ -6,6 +6,7 @@
#define COMPONENTS_UI_ZOOM_ZOOM_EVENT_MANAGER_H_
#include "base/callback_list.h"
+#include "base/macros.h"
#include "base/memory/weak_ptr.h"
#include "base/observer_list.h"
#include "base/supports_user_data.h"
diff --git a/components/undo/bookmark_undo_service.cc b/components/undo/bookmark_undo_service.cc
index 0a348b5..b6bbeac 100644
--- a/components/undo/bookmark_undo_service.cc
+++ b/components/undo/bookmark_undo_service.cc
@@ -4,6 +4,10 @@
#include "components/undo/bookmark_undo_service.h"
+#include <stddef.h>
+#include <stdint.h>
+
+#include "base/macros.h"
#include "components/bookmarks/browser/bookmark_model.h"
#include "components/bookmarks/browser/bookmark_node_data.h"
#include "components/bookmarks/browser/bookmark_undo_provider.h"
@@ -51,7 +55,7 @@ class BookmarkAddOperation : public BookmarkUndoOperation {
int GetRedoLabelId() const override;
private:
- int64 parent_id_;
+ int64_t parent_id_;
const int index_;
DISALLOW_COPY_AND_ASSIGN(BookmarkAddOperation);
@@ -161,7 +165,7 @@ class BookmarkEditOperation : public BookmarkUndoOperation {
int GetRedoLabelId() const override;
private:
- int64 node_id_;
+ int64_t node_id_;
BookmarkNodeData original_bookmark_;
DISALLOW_COPY_AND_ASSIGN(BookmarkEditOperation);
@@ -212,8 +216,8 @@ class BookmarkMoveOperation : public BookmarkUndoOperation {
void Undo() override;
private:
- int64 old_parent_id_;
- int64 new_parent_id_;
+ int64_t old_parent_id_;
+ int64_t new_parent_id_;
int old_index_;
int new_index_;
@@ -280,8 +284,8 @@ class BookmarkReorderOperation : public BookmarkUndoOperation {
int GetRedoLabelId() const override;
private:
- int64 parent_id_;
- std::vector<int64> ordered_bookmarks_;
+ int64_t parent_id_;
+ std::vector<int64_t> ordered_bookmarks_;
DISALLOW_COPY_AND_ASSIGN(BookmarkReorderOperation);
};
diff --git a/components/undo/bookmark_undo_service.h b/components/undo/bookmark_undo_service.h
index 00df063..954362a 100644
--- a/components/undo/bookmark_undo_service.h
+++ b/components/undo/bookmark_undo_service.h
@@ -7,6 +7,7 @@
#include <map>
+#include "base/macros.h"
#include "base/scoped_observer.h"
#include "components/bookmarks/browser/base_bookmark_model_observer.h"
#include "components/bookmarks/browser/bookmark_node_data.h"
diff --git a/components/undo/bookmark_undo_service_test.cc b/components/undo/bookmark_undo_service_test.cc
index c8de6b0..ea3752e 100644
--- a/components/undo/bookmark_undo_service_test.cc
+++ b/components/undo/bookmark_undo_service_test.cc
@@ -4,6 +4,9 @@
#include "components/undo/bookmark_undo_service.h"
+#include <stddef.h>
+
+#include "base/macros.h"
#include "base/strings/utf_string_conversions.h"
#include "components/bookmarks/browser/bookmark_model.h"
#include "components/bookmarks/test/bookmark_test_helpers.h"
diff --git a/components/undo/bookmark_undo_utils.h b/components/undo/bookmark_undo_utils.h
index 987e2728..e0eeead 100644
--- a/components/undo/bookmark_undo_utils.h
+++ b/components/undo/bookmark_undo_utils.h
@@ -5,7 +5,7 @@
#ifndef COMPONENTS_UNDO_BOOKMARK_UNDO_UTILS_H_
#define COMPONENTS_UNDO_BOOKMARK_UNDO_UTILS_H_
-#include "base/basictypes.h"
+#include "base/macros.h"
class BookmarkUndoService;
class UndoManager;
diff --git a/components/undo/undo_manager.h b/components/undo/undo_manager.h
index 0c0af8b..ef12995 100644
--- a/components/undo/undo_manager.h
+++ b/components/undo/undo_manager.h
@@ -5,7 +5,9 @@
#ifndef COMPONENTS_UNDO_UNDO_MANAGER_H_
#define COMPONENTS_UNDO_UNDO_MANAGER_H_
-#include "base/basictypes.h"
+#include <stddef.h>
+
+#include "base/macros.h"
#include "base/memory/scoped_ptr.h"
#include "base/memory/scoped_vector.h"
#include "base/observer_list.h"
diff --git a/components/undo/undo_manager_test.cc b/components/undo/undo_manager_test.cc
index 5053572..21efdb7 100644
--- a/components/undo/undo_manager_test.cc
+++ b/components/undo/undo_manager_test.cc
@@ -3,6 +3,7 @@
// found in the LICENSE file.
#include "base/auto_reset.h"
+#include "base/macros.h"
#include "components/undo/undo_manager.h"
#include "components/undo/undo_manager_observer.h"
#include "components/undo/undo_operation.h"
diff --git a/components/update_client/action.h b/components/update_client/action.h
index d85e868..5b67134 100644
--- a/components/update_client/action.h
+++ b/components/update_client/action.h
@@ -5,6 +5,8 @@
#ifndef COMPONENTS_UPDATE_CLIENT_ACTION_H_
#define COMPONENTS_UPDATE_CLIENT_ACTION_H_
+#include <stddef.h>
+
#include <string>
#include "base/callback.h"
diff --git a/components/update_client/action_update_check.cc b/components/update_client/action_update_check.cc
index cfff7677..1f14229 100644
--- a/components/update_client/action_update_check.cc
+++ b/components/update_client/action_update_check.cc
@@ -4,6 +4,8 @@
#include "components/update_client/action_update_check.h"
+#include <stddef.h>
+
#include "base/bind.h"
#include "base/bind_helpers.h"
#include "base/callback.h"
diff --git a/components/update_client/background_downloader_win.cc b/components/update_client/background_downloader_win.cc
index 0b9814e..12b863a 100644
--- a/components/update_client/background_downloader_win.cc
+++ b/components/update_client/background_downloader_win.cc
@@ -6,6 +6,7 @@
#include <atlbase.h>
#include <atlcom.h>
+#include <stddef.h>
#include <stdint.h>
#include <functional>
diff --git a/components/update_client/component_unpacker.cc b/components/update_client/component_unpacker.cc
index b0fc94a..78d678e 100644
--- a/components/update_client/component_unpacker.cc
+++ b/components/update_client/component_unpacker.cc
@@ -16,6 +16,7 @@
#include "base/json/json_file_value_serializer.h"
#include "base/location.h"
#include "base/logging.h"
+#include "base/macros.h"
#include "base/numerics/safe_conversions.h"
#include "base/strings/string_number_conversions.h"
#include "base/strings/stringprintf.h"
diff --git a/components/update_client/crx_downloader.cc b/components/update_client/crx_downloader.cc
index a3419fd..6a0b142 100644
--- a/components/update_client/crx_downloader.cc
+++ b/components/update_client/crx_downloader.cc
@@ -9,6 +9,7 @@
#include "base/logging.h"
#include "base/sequenced_task_runner.h"
#include "base/thread_task_runner_handle.h"
+#include "build/build_config.h"
#include "components/update_client/url_fetcher_downloader.h"
#if defined(OS_WIN)
diff --git a/components/update_client/crx_downloader_unittest.cc b/components/update_client/crx_downloader_unittest.cc
index 3acccb0..4a58a86 100644
--- a/components/update_client/crx_downloader_unittest.cc
+++ b/components/update_client/crx_downloader_unittest.cc
@@ -11,6 +11,7 @@
#include "base/path_service.h"
#include "base/run_loop.h"
#include "base/thread_task_runner_handle.h"
+#include "build/build_config.h"
#include "components/update_client/crx_downloader.h"
#include "net/base/net_errors.h"
#include "net/url_request/test_url_request_interceptor.h"
diff --git a/components/update_client/ping_manager.cc b/components/update_client/ping_manager.cc
index 24afde6..23019f5 100644
--- a/components/update_client/ping_manager.cc
+++ b/components/update_client/ping_manager.cc
@@ -4,6 +4,8 @@
#include "components/update_client/ping_manager.h"
+#include <stddef.h>
+
#include <string>
#include <vector>
diff --git a/components/update_client/test_configurator.h b/components/update_client/test_configurator.h
index 237c944..b1e64e9 100644
--- a/components/update_client/test_configurator.h
+++ b/components/update_client/test_configurator.h
@@ -5,6 +5,8 @@
#ifndef COMPONENTS_UPDATE_CLIENT_TEST_CONFIGURATOR_H_
#define COMPONENTS_UPDATE_CLIENT_TEST_CONFIGURATOR_H_
+#include <stdint.h>
+
#include <string>
#include <utility>
#include <vector>
diff --git a/components/update_client/update_checker.cc b/components/update_client/update_checker.cc
index be686ef..09a716d 100644
--- a/components/update_client/update_checker.cc
+++ b/components/update_client/update_checker.cc
@@ -4,6 +4,8 @@
#include "components/update_client/update_checker.h"
+#include <stddef.h>
+
#include <string>
#include <vector>
diff --git a/components/update_client/update_client_unittest.cc b/components/update_client/update_client_unittest.cc
index d8ad6df..d2194c4 100644
--- a/components/update_client/update_client_unittest.cc
+++ b/components/update_client/update_client_unittest.cc
@@ -7,6 +7,7 @@
#include "base/files/file_path.h"
#include "base/files/file_util.h"
#include "base/location.h"
+#include "base/macros.h"
#include "base/memory/ref_counted.h"
#include "base/memory/scoped_ptr.h"
#include "base/message_loop/message_loop.h"
diff --git a/components/update_client/update_query_params.cc b/components/update_client/update_query_params.cc
index 33bd00e..f2d298d 100644
--- a/components/update_client/update_query_params.cc
+++ b/components/update_client/update_query_params.cc
@@ -8,6 +8,7 @@
#include "base/logging.h"
#include "base/strings/stringprintf.h"
#include "base/win/windows_version.h"
+#include "build/build_config.h"
#include "components/update_client/update_query_params_delegate.h"
namespace update_client {
diff --git a/components/update_client/update_query_params.h b/components/update_client/update_query_params.h
index 48f7acf..f625b42 100644
--- a/components/update_client/update_query_params.h
+++ b/components/update_client/update_query_params.h
@@ -7,7 +7,7 @@
#include <string>
-#include "base/basictypes.h"
+#include "base/macros.h"
namespace update_client {
diff --git a/components/update_client/update_query_params_delegate.h b/components/update_client/update_query_params_delegate.h
index 0dd97ff..6230e2e 100644
--- a/components/update_client/update_query_params_delegate.h
+++ b/components/update_client/update_query_params_delegate.h
@@ -7,7 +7,7 @@
#include <string>
-#include "base/basictypes.h"
+#include "base/macros.h"
namespace update_client {
diff --git a/components/update_client/update_response.cc b/components/update_client/update_response.cc
index c0996fc..cbdaee8 100644
--- a/components/update_client/update_response.cc
+++ b/components/update_client/update_response.cc
@@ -4,6 +4,8 @@
#include "components/update_client/update_response.h"
+#include <stddef.h>
+
#include <algorithm>
#include "base/memory/scoped_ptr.h"
diff --git a/components/update_client/utils.cc b/components/update_client/utils.cc
index 2b66050..ca1cf3b 100644
--- a/components/update_client/utils.cc
+++ b/components/update_client/utils.cc
@@ -4,6 +4,7 @@
#include "components/update_client/utils.h"
+#include <stddef.h>
#include <stdint.h>
#include <cmath>
@@ -16,6 +17,7 @@
#include "base/strings/stringprintf.h"
#include "base/sys_info.h"
#include "base/win/windows_version.h"
+#include "build/build_config.h"
#include "components/crx_file/id_util.h"
#include "components/update_client/configurator.h"
#include "components/update_client/crx_update_item.h"
diff --git a/components/upload_list/upload_list.cc b/components/upload_list/upload_list.cc
index 893a7de..0b4a551 100644
--- a/components/upload_list/upload_list.cc
+++ b/components/upload_list/upload_list.cc
@@ -4,6 +4,8 @@
#include "components/upload_list/upload_list.h"
+#include <stddef.h>
+
#include <algorithm>
#include <iterator>
diff --git a/components/upload_list/upload_list.h b/components/upload_list/upload_list.h
index f384f3e..0a237a4 100644
--- a/components/upload_list/upload_list.h
+++ b/components/upload_list/upload_list.h
@@ -10,6 +10,7 @@
#include "base/files/file_path.h"
#include "base/gtest_prod_util.h"
+#include "base/macros.h"
#include "base/memory/ref_counted.h"
#include "base/threading/thread_checker.h"
#include "base/time/time.h"
diff --git a/components/upload_list/upload_list_unittest.cc b/components/upload_list/upload_list_unittest.cc
index 83152aa..1e3e5c4 100644
--- a/components/upload_list/upload_list_unittest.cc
+++ b/components/upload_list/upload_list_unittest.cc
@@ -4,6 +4,8 @@
#include "components/upload_list/upload_list.h"
+#include <stddef.h>
+
#include <string>
#include "base/files/file_path.h"
diff --git a/components/url_formatter/elide_url.cc b/components/url_formatter/elide_url.cc
index 646f9b5..7f5538a 100644
--- a/components/url_formatter/elide_url.cc
+++ b/components/url_formatter/elide_url.cc
@@ -4,9 +4,12 @@
#include "components/url_formatter/elide_url.h"
+#include <stddef.h>
+
#include "base/logging.h"
#include "base/strings/string_split.h"
#include "base/strings/utf_string_conversions.h"
+#include "build/build_config.h"
#include "components/url_formatter/url_formatter.h"
#include "net/base/escape.h"
#include "net/base/registry_controlled_domains/registry_controlled_domain.h"
diff --git a/components/url_formatter/elide_url.h b/components/url_formatter/elide_url.h
index 73c0baa..ca9274a 100644
--- a/components/url_formatter/elide_url.h
+++ b/components/url_formatter/elide_url.h
@@ -10,6 +10,7 @@
#include <string>
#include "base/strings/string16.h"
+#include "build/build_config.h"
class GURL;
diff --git a/components/url_formatter/elide_url_unittest.cc b/components/url_formatter/elide_url_unittest.cc
index f0f4fbb..ede2bf6 100644
--- a/components/url_formatter/elide_url_unittest.cc
+++ b/components/url_formatter/elide_url_unittest.cc
@@ -4,8 +4,12 @@
#include "components/url_formatter/elide_url.h"
+#include <stddef.h>
+
#include "base/ios/ios_util.h"
+#include "base/macros.h"
#include "base/strings/utf_string_conversions.h"
+#include "build/build_config.h"
#include "testing/gtest/include/gtest/gtest.h"
#include "url/gurl.h"
diff --git a/components/url_formatter/url_fixer.cc b/components/url_formatter/url_fixer.cc
index c49a902..919a38d 100644
--- a/components/url_formatter/url_fixer.cc
+++ b/components/url_formatter/url_fixer.cc
@@ -4,16 +4,16 @@
#include "components/url_formatter/url_fixer.h"
+#include <stddef.h>
+
#include <algorithm>
#include "base/files/file_path.h"
#include "base/files/file_util.h"
#include "base/logging.h"
-#if defined(OS_POSIX)
-#include "base/path_service.h"
-#endif
#include "base/strings/string_util.h"
#include "base/strings/utf_string_conversions.h"
+#include "build/build_config.h"
#include "components/url_formatter/url_formatter.h"
#include "net/base/escape.h"
#include "net/base/filename_util.h"
@@ -22,6 +22,10 @@
#include "url/url_file.h"
#include "url/url_util.h"
+#if defined(OS_POSIX)
+#include "base/path_service.h"
+#endif
+
namespace url_formatter {
const char* home_directory_override = nullptr;
diff --git a/components/url_formatter/url_fixer_unittest.cc b/components/url_formatter/url_fixer_unittest.cc
index 900b553..01b1c3c 100644
--- a/components/url_formatter/url_fixer_unittest.cc
+++ b/components/url_formatter/url_fixer_unittest.cc
@@ -2,15 +2,17 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
+#include <stddef.h>
#include <stdlib.h>
#include "base/base_paths.h"
-#include "base/basictypes.h"
#include "base/files/file_path.h"
#include "base/files/file_util.h"
#include "base/files/scoped_temp_dir.h"
+#include "base/macros.h"
#include "base/strings/string_util.h"
#include "base/strings/utf_string_conversions.h"
+#include "build/build_config.h"
#include "components/url_formatter/url_fixer.h"
#include "net/base/filename_util.h"
#include "testing/gtest/include/gtest/gtest.h"
diff --git a/components/url_formatter/url_formatter.h b/components/url_formatter/url_formatter.h
index 11bf0c9..ddf4098 100644
--- a/components/url_formatter/url_formatter.h
+++ b/components/url_formatter/url_formatter.h
@@ -15,6 +15,7 @@
#ifndef COMPONENTS_URL_FORMATTER_URL_FORMATTER_H_
#define COMPONENTS_URL_FORMATTER_URL_FORMATTER_H_
+#include <stddef.h>
#include <stdint.h>
#include <string>
diff --git a/components/url_formatter/url_formatter_unittest.cc b/components/url_formatter/url_formatter_unittest.cc
index 0dd635a..7f6285a 100644
--- a/components/url_formatter/url_formatter_unittest.cc
+++ b/components/url_formatter/url_formatter_unittest.cc
@@ -4,6 +4,7 @@
#include "components/url_formatter/url_formatter.h"
+#include <stddef.h>
#include <string.h>
#include <vector>
diff --git a/components/url_matcher/regex_set_matcher.cc b/components/url_matcher/regex_set_matcher.cc
index 15bd8b3..d597f00 100644
--- a/components/url_matcher/regex_set_matcher.cc
+++ b/components/url_matcher/regex_set_matcher.cc
@@ -4,6 +4,8 @@
#include "components/url_matcher/regex_set_matcher.h"
+#include <stddef.h>
+
#include "base/logging.h"
#include "base/stl_util.h"
#include "base/strings/string_util.h"
diff --git a/components/url_matcher/string_pattern.h b/components/url_matcher/string_pattern.h
index ca5f223..34ad213 100644
--- a/components/url_matcher/string_pattern.h
+++ b/components/url_matcher/string_pattern.h
@@ -8,7 +8,7 @@
#include <string>
#include <vector>
-#include "base/basictypes.h"
+#include "base/macros.h"
#include "components/url_matcher/url_matcher_export.h"
namespace url_matcher {
diff --git a/components/url_matcher/substring_set_matcher.cc b/components/url_matcher/substring_set_matcher.cc
index 848c863..dff9aa7 100644
--- a/components/url_matcher/substring_set_matcher.cc
+++ b/components/url_matcher/substring_set_matcher.cc
@@ -4,6 +4,8 @@
#include "components/url_matcher/substring_set_matcher.h"
+#include <stddef.h>
+
#include <algorithm>
#include <queue>
@@ -21,8 +23,8 @@ bool ComparePatterns(const StringPattern* a, const StringPattern* b) {
// Given the set of patterns, compute how many nodes will the corresponding
// Aho-Corasick tree have. Note that |patterns| need to be sorted.
-uint32 TreeSize(const std::vector<const StringPattern*>& patterns) {
- uint32 result = 1u; // 1 for the root node.
+uint32_t TreeSize(const std::vector<const StringPattern*>& patterns) {
+ uint32_t result = 1u; // 1 for the root node.
if (patterns.empty())
return result;
@@ -37,10 +39,10 @@ uint32 TreeSize(const std::vector<const StringPattern*>& patterns) {
for (; current != patterns.end(); ++last, ++current) {
const std::string& last_pattern = (*last)->pattern();
const std::string& current_pattern = (*current)->pattern();
- const uint32 prefix_bound =
+ const uint32_t prefix_bound =
std::min(last_pattern.size(), current_pattern.size());
- uint32 common_prefix = 0;
+ uint32_t common_prefix = 0;
while (common_prefix < prefix_bound &&
last_pattern[common_prefix] == current_pattern[common_prefix])
++common_prefix;
@@ -113,9 +115,9 @@ bool SubstringSetMatcher::Match(const std::string& text,
// Handle patterns matching the empty string.
matches->insert(tree_[0].matches().begin(), tree_[0].matches().end());
- uint32 current_node = 0;
+ uint32_t current_node = 0;
for (std::string::const_iterator i = text.begin(); i != text.end(); ++i) {
- uint32 edge_from_current = tree_[current_node].GetEdge(*i);
+ uint32_t edge_from_current = tree_[current_node].GetEdge(*i);
while (edge_from_current == AhoCorasickNode::kNoSuchEdge &&
current_node != 0) {
current_node = tree_[current_node].failure();
@@ -163,12 +165,12 @@ void SubstringSetMatcher::InsertPatternIntoAhoCorasickTree(
const std::string::const_iterator text_end = text.end();
// Iterators on the tree and the text.
- uint32 current_node = 0;
+ uint32_t current_node = 0;
std::string::const_iterator i = text.begin();
// Follow existing paths for as long as possible.
while (i != text_end) {
- uint32 edge_from_current = tree_[current_node].GetEdge(*i);
+ uint32_t edge_from_current = tree_[current_node].GetEdge(*i);
if (edge_from_current == AhoCorasickNode::kNoSuchEdge)
break;
current_node = edge_from_current;
@@ -190,14 +192,14 @@ void SubstringSetMatcher::InsertPatternIntoAhoCorasickTree(
void SubstringSetMatcher::CreateFailureEdges() {
typedef AhoCorasickNode::Edges Edges;
- std::queue<uint32> queue;
+ std::queue<uint32_t> queue;
AhoCorasickNode& root = tree_[0];
root.set_failure(0);
const Edges& root_edges = root.edges();
for (Edges::const_iterator e = root_edges.begin(); e != root_edges.end();
++e) {
- const uint32& leads_to = e->second;
+ const uint32_t& leads_to = e->second;
tree_[leads_to].set_failure(0);
queue.push(leads_to);
}
@@ -208,28 +210,27 @@ void SubstringSetMatcher::CreateFailureEdges() {
for (Edges::const_iterator e = current_node.edges().begin();
e != current_node.edges().end(); ++e) {
const char& edge_label = e->first;
- const uint32& leads_to = e->second;
+ const uint32_t& leads_to = e->second;
queue.push(leads_to);
- uint32 failure = current_node.failure();
- uint32 edge_from_failure = tree_[failure].GetEdge(edge_label);
+ uint32_t failure = current_node.failure();
+ uint32_t edge_from_failure = tree_[failure].GetEdge(edge_label);
while (edge_from_failure == AhoCorasickNode::kNoSuchEdge &&
failure != 0) {
failure = tree_[failure].failure();
edge_from_failure = tree_[failure].GetEdge(edge_label);
}
- const uint32 follow_in_case_of_failure =
- edge_from_failure != AhoCorasickNode::kNoSuchEdge
- ? edge_from_failure
- : 0;
+ const uint32_t follow_in_case_of_failure =
+ edge_from_failure != AhoCorasickNode::kNoSuchEdge ? edge_from_failure
+ : 0;
tree_[leads_to].set_failure(follow_in_case_of_failure);
tree_[leads_to].AddMatches(tree_[follow_in_case_of_failure].matches());
}
}
}
-const uint32 SubstringSetMatcher::AhoCorasickNode::kNoSuchEdge = 0xFFFFFFFF;
+const uint32_t SubstringSetMatcher::AhoCorasickNode::kNoSuchEdge = 0xFFFFFFFF;
SubstringSetMatcher::AhoCorasickNode::AhoCorasickNode()
: failure_(kNoSuchEdge) {}
@@ -251,12 +252,12 @@ SubstringSetMatcher::AhoCorasickNode::operator=(
return *this;
}
-uint32 SubstringSetMatcher::AhoCorasickNode::GetEdge(char c) const {
+uint32_t SubstringSetMatcher::AhoCorasickNode::GetEdge(char c) const {
Edges::const_iterator i = edges_.find(c);
return i == edges_.end() ? kNoSuchEdge : i->second;
}
-void SubstringSetMatcher::AhoCorasickNode::SetEdge(char c, uint32 node) {
+void SubstringSetMatcher::AhoCorasickNode::SetEdge(char c, uint32_t node) {
edges_[c] = node;
}
diff --git a/components/url_matcher/substring_set_matcher.h b/components/url_matcher/substring_set_matcher.h
index 8a05ef3..22a7b73 100644
--- a/components/url_matcher/substring_set_matcher.h
+++ b/components/url_matcher/substring_set_matcher.h
@@ -5,13 +5,15 @@
#ifndef COMPONENTS_URL_MATCHER_SUBSTRING_SET_MATCHER_H_
#define COMPONENTS_URL_MATCHER_SUBSTRING_SET_MATCHER_H_
+#include <stdint.h>
+
#include <limits>
#include <map>
#include <set>
#include <string>
#include <vector>
-#include "base/basictypes.h"
+#include "base/macros.h"
#include "components/url_matcher/string_pattern.h"
#include "components/url_matcher/url_matcher_export.h"
@@ -82,22 +84,22 @@ class URL_MATCHER_EXPORT SubstringSetMatcher {
class AhoCorasickNode {
public:
// Key: label of the edge, value: node index in |tree_| of parent class.
- typedef std::map<char, uint32> Edges;
+ typedef std::map<char, uint32_t> Edges;
typedef std::set<StringPattern::ID> Matches;
- static const uint32 kNoSuchEdge; // Represents an invalid node index.
+ static const uint32_t kNoSuchEdge; // Represents an invalid node index.
AhoCorasickNode();
~AhoCorasickNode();
AhoCorasickNode(const AhoCorasickNode& other);
AhoCorasickNode& operator=(const AhoCorasickNode& other);
- uint32 GetEdge(char c) const;
- void SetEdge(char c, uint32 node);
+ uint32_t GetEdge(char c) const;
+ void SetEdge(char c, uint32_t node);
const Edges& edges() const { return edges_; }
- uint32 failure() const { return failure_; }
- void set_failure(uint32 failure) { failure_ = failure; }
+ uint32_t failure() const { return failure_; }
+ void set_failure(uint32_t failure) { failure_ = failure; }
void AddMatch(StringPattern::ID id);
void AddMatches(const Matches& matches);
@@ -108,7 +110,7 @@ class URL_MATCHER_EXPORT SubstringSetMatcher {
Edges edges_;
// Node index that failure edge leads to.
- uint32 failure_;
+ uint32_t failure_;
// Identifiers of matches.
Matches matches_;
diff --git a/components/url_matcher/substring_set_matcher_unittest.cc b/components/url_matcher/substring_set_matcher_unittest.cc
index f5f2be0..48db478 100644
--- a/components/url_matcher/substring_set_matcher_unittest.cc
+++ b/components/url_matcher/substring_set_matcher_unittest.cc
@@ -4,6 +4,8 @@
#include "components/url_matcher/substring_set_matcher.h"
+#include <stddef.h>
+
#include <set>
#include <string>
#include <vector>
diff --git a/components/url_matcher/url_matcher.h b/components/url_matcher/url_matcher.h
index 11dc658..712cb8a 100644
--- a/components/url_matcher/url_matcher.h
+++ b/components/url_matcher/url_matcher.h
@@ -5,9 +5,12 @@
#ifndef COMPONENTS_URL_MATCHER_URL_MATCHER_H_
#define COMPONENTS_URL_MATCHER_URL_MATCHER_H_
+#include <stddef.h>
+
#include <set>
#include <vector>
+#include "base/macros.h"
#include "base/memory/ref_counted.h"
#include "base/memory/scoped_ptr.h"
#include "components/url_matcher/regex_set_matcher.h"
diff --git a/components/url_matcher/url_matcher_factory.cc b/components/url_matcher/url_matcher_factory.cc
index e55102d..31d0167 100644
--- a/components/url_matcher/url_matcher_factory.cc
+++ b/components/url_matcher/url_matcher_factory.cc
@@ -9,6 +9,7 @@
#include "base/lazy_instance.h"
#include "base/logging.h"
+#include "base/macros.h"
#include "base/strings/stringprintf.h"
#include "base/values.h"
#include "components/url_matcher/url_matcher_constants.h"
diff --git a/components/url_matcher/url_matcher_factory.h b/components/url_matcher/url_matcher_factory.h
index 93ff202..e65edec 100644
--- a/components/url_matcher/url_matcher_factory.h
+++ b/components/url_matcher/url_matcher_factory.h
@@ -7,7 +7,7 @@
#include <string>
-#include "base/basictypes.h"
+#include "base/macros.h"
#include "components/url_matcher/url_matcher.h"
#include "components/url_matcher/url_matcher_export.h"
diff --git a/components/url_matcher/url_matcher_factory_unittest.cc b/components/url_matcher/url_matcher_factory_unittest.cc
index c2fc71b..4718ca9 100644
--- a/components/url_matcher/url_matcher_factory_unittest.cc
+++ b/components/url_matcher/url_matcher_factory_unittest.cc
@@ -4,8 +4,10 @@
#include "components/url_matcher/url_matcher_factory.h"
-#include "base/basictypes.h"
+#include <stddef.h>
+
#include "base/format_macros.h"
+#include "base/macros.h"
#include "base/strings/stringprintf.h"
#include "base/values.h"
#include "components/url_matcher/url_matcher_constants.h"
diff --git a/components/url_matcher/url_matcher_helpers.cc b/components/url_matcher/url_matcher_helpers.cc
index 6eab51d..de69d7e 100644
--- a/components/url_matcher/url_matcher_helpers.cc
+++ b/components/url_matcher/url_matcher_helpers.cc
@@ -4,6 +4,8 @@
#include "components/url_matcher/url_matcher_helpers.h"
+#include <stddef.h>
+
#include "base/values.h"
namespace url_matcher {
diff --git a/components/url_matcher/url_matcher_unittest.cc b/components/url_matcher/url_matcher_unittest.cc
index 3d6d6c5..7219d60 100644
--- a/components/url_matcher/url_matcher_unittest.cc
+++ b/components/url_matcher/url_matcher_unittest.cc
@@ -4,6 +4,9 @@
#include "components/url_matcher/url_matcher.h"
+#include <stddef.h>
+
+#include "base/macros.h"
#include "base/strings/string_util.h"
#include "testing/gtest/include/gtest/gtest.h"
#include "url/gurl.h"
diff --git a/components/user_manager/empty_user_info.h b/components/user_manager/empty_user_info.h
index 5fb41c9..b99e4bb 100644
--- a/components/user_manager/empty_user_info.h
+++ b/components/user_manager/empty_user_info.h
@@ -7,6 +7,7 @@
#include <string>
+#include "base/macros.h"
#include "base/strings/string16.h"
#include "components/user_manager/user_info.h"
#include "components/user_manager/user_manager_export.h"
diff --git a/components/user_manager/fake_user_manager.h b/components/user_manager/fake_user_manager.h
index 77f1649..c85bcde 100644
--- a/components/user_manager/fake_user_manager.h
+++ b/components/user_manager/fake_user_manager.h
@@ -8,6 +8,7 @@
#include <map>
#include <string>
+#include "base/macros.h"
#include "base/memory/scoped_ptr.h"
#include "components/signin/core/account_id/account_id.h"
#include "components/user_manager/user.h"
diff --git a/components/user_manager/known_user.cc b/components/user_manager/known_user.cc
index d78dff7..aa28fa7 100644
--- a/components/user_manager/known_user.cc
+++ b/components/user_manager/known_user.cc
@@ -4,6 +4,8 @@
#include "components/user_manager/known_user.h"
+#include <stddef.h>
+
#include "base/logging.h"
#include "base/memory/scoped_ptr.h"
#include "base/prefs/pref_registry_simple.h"
diff --git a/components/user_manager/user.cc b/components/user_manager/user.cc
index 3ead416..a76546c 100644
--- a/components/user_manager/user.cc
+++ b/components/user_manager/user.cc
@@ -4,7 +4,10 @@
#include "components/user_manager/user.h"
+#include <stddef.h>
+
#include "base/logging.h"
+#include "base/macros.h"
#include "base/strings/stringprintf.h"
#include "base/strings/utf_string_conversions.h"
#include "base/threading/thread_restrictions.h"
diff --git a/components/user_manager/user.h b/components/user_manager/user.h
index 71d7016..b4e1198 100644
--- a/components/user_manager/user.h
+++ b/components/user_manager/user.h
@@ -8,7 +8,7 @@
#include <string>
#include <vector>
-#include "base/basictypes.h"
+#include "base/macros.h"
#include "base/strings/string16.h"
#include "components/signin/core/account_id/account_id.h"
#include "components/user_manager/user_image/user_image.h"
diff --git a/components/user_manager/user_image/default_user_images.cc b/components/user_manager/user_image/default_user_images.cc
index 58ceacb..fd4118b 100644
--- a/components/user_manager/user_image/default_user_images.cc
+++ b/components/user_manager/user_image/default_user_images.cc
@@ -4,8 +4,8 @@
#include "components/user_manager/user_image/default_user_images.h"
-#include "base/basictypes.h"
#include "base/logging.h"
+#include "base/macros.h"
#include "base/strings/string_number_conversions.h"
#include "base/strings/string_piece.h"
#include "base/strings/string_util.h"
diff --git a/components/user_manager/user_image/default_user_images.h b/components/user_manager/user_image/default_user_images.h
index 34bc8bc..6a1cc4c 100644
--- a/components/user_manager/user_image/default_user_images.h
+++ b/components/user_manager/user_image/default_user_images.h
@@ -5,7 +5,8 @@
#ifndef COMPONENTS_USER_MANAGER_USER_IMAGE_DEFAULT_USER_IMAGES_H_
#define COMPONENTS_USER_MANAGER_USER_IMAGE_DEFAULT_USER_IMAGES_H_
-#include <cstddef> // for size_t
+#include <stddef.h>
+
#include <string>
#include "base/strings/string16.h"
diff --git a/components/user_manager/user_info_impl.h b/components/user_manager/user_info_impl.h
index d2733eb..a22c576 100644
--- a/components/user_manager/user_info_impl.h
+++ b/components/user_manager/user_info_impl.h
@@ -7,6 +7,7 @@
#include <string>
+#include "base/macros.h"
#include "base/strings/string16.h"
#include "components/signin/core/account_id/account_id.h"
#include "components/user_manager/user_info.h"
diff --git a/components/user_manager/user_manager.h b/components/user_manager/user_manager.h
index d614086..55245ad 100644
--- a/components/user_manager/user_manager.h
+++ b/components/user_manager/user_manager.h
@@ -7,6 +7,7 @@
#include <string>
+#include "base/macros.h"
#include "components/user_manager/user.h"
#include "components/user_manager/user_manager_export.h"
#include "components/user_manager/user_type.h"
diff --git a/components/user_manager/user_manager_base.cc b/components/user_manager/user_manager_base.cc
index 7c8e865..312aca1 100644
--- a/components/user_manager/user_manager_base.cc
+++ b/components/user_manager/user_manager_base.cc
@@ -4,7 +4,8 @@
#include "components/user_manager/user_manager_base.h"
-#include <cstddef>
+#include <stddef.h>
+
#include <set>
#include "base/bind.h"
diff --git a/components/user_manager/user_manager_base.h b/components/user_manager/user_manager_base.h
index 83dc076..d97d5cb 100644
--- a/components/user_manager/user_manager_base.h
+++ b/components/user_manager/user_manager_base.h
@@ -10,7 +10,7 @@
#include <string>
#include <vector>
-#include "base/basictypes.h"
+#include "base/macros.h"
#include "base/memory/weak_ptr.h"
#include "base/observer_list.h"
#include "base/synchronization/lock.h"
diff --git a/components/user_prefs/tracked/dictionary_hash_store_contents.cc b/components/user_prefs/tracked/dictionary_hash_store_contents.cc
index ba79127..40494af 100644
--- a/components/user_prefs/tracked/dictionary_hash_store_contents.cc
+++ b/components/user_prefs/tracked/dictionary_hash_store_contents.cc
@@ -6,6 +6,7 @@
#include "base/callback.h"
#include "base/logging.h"
+#include "base/macros.h"
#include "base/prefs/persistent_pref_store.h"
#include "base/values.h"
#include "components/pref_registry/pref_registry_syncable.h"
diff --git a/components/user_prefs/tracked/mock_validation_delegate.h b/components/user_prefs/tracked/mock_validation_delegate.h
index be2051e..0b8cb12 100644
--- a/components/user_prefs/tracked/mock_validation_delegate.h
+++ b/components/user_prefs/tracked/mock_validation_delegate.h
@@ -5,6 +5,8 @@
#ifndef COMPONENTS_USER_PREFS_TRACKED_MOCK_VALIDATION_DELEGATE_H_
#define COMPONENTS_USER_PREFS_TRACKED_MOCK_VALIDATION_DELEGATE_H_
+#include <stddef.h>
+
#include <string>
#include <vector>
diff --git a/components/user_prefs/tracked/pref_hash_calculator.cc b/components/user_prefs/tracked/pref_hash_calculator.cc
index 3d5b7fa..9e7a0d0 100644
--- a/components/user_prefs/tracked/pref_hash_calculator.cc
+++ b/components/user_prefs/tracked/pref_hash_calculator.cc
@@ -4,6 +4,8 @@
#include "components/user_prefs/tracked/pref_hash_calculator.h"
+#include <stdint.h>
+
#include <vector>
#include "base/bind.h"
@@ -20,7 +22,7 @@ namespace {
std::string GetDigestString(const std::string& key,
const std::string& message) {
crypto::HMAC hmac(crypto::HMAC::SHA256);
- std::vector<uint8> digest(hmac.DigestLength());
+ std::vector<uint8_t> digest(hmac.DigestLength());
if (!hmac.Init(key) || !hmac.Sign(message, &digest[0], digest.size())) {
NOTREACHED();
return std::string();
@@ -34,7 +36,7 @@ bool VerifyDigestString(const std::string& key,
const std::string& message,
const std::string& digest_string) {
crypto::HMAC hmac(crypto::HMAC::SHA256);
- std::vector<uint8> digest;
+ std::vector<uint8_t> digest;
return base::HexStringToBytes(digest_string, &digest) && hmac.Init(key) &&
hmac.Verify(message,
base::StringPiece(reinterpret_cast<char*>(&digest[0]),
diff --git a/components/user_prefs/tracked/pref_hash_calculator.h b/components/user_prefs/tracked/pref_hash_calculator.h
index 593828e..1f9b74f 100644
--- a/components/user_prefs/tracked/pref_hash_calculator.h
+++ b/components/user_prefs/tracked/pref_hash_calculator.h
@@ -7,7 +7,7 @@
#include <string>
-#include "base/basictypes.h"
+#include "base/macros.h"
namespace base {
class Value;
diff --git a/components/user_prefs/tracked/pref_hash_calculator_unittest.cc b/components/user_prefs/tracked/pref_hash_calculator_unittest.cc
index 4fc1ff6..2385b6c 100644
--- a/components/user_prefs/tracked/pref_hash_calculator_unittest.cc
+++ b/components/user_prefs/tracked/pref_hash_calculator_unittest.cc
@@ -6,6 +6,7 @@
#include <string>
+#include "base/macros.h"
#include "base/memory/scoped_ptr.h"
#include "base/strings/string_util.h"
#include "base/values.h"
diff --git a/components/user_prefs/tracked/pref_hash_filter.cc b/components/user_prefs/tracked/pref_hash_filter.cc
index d3cd61d..ac27892 100644
--- a/components/user_prefs/tracked/pref_hash_filter.cc
+++ b/components/user_prefs/tracked/pref_hash_filter.cc
@@ -4,9 +4,12 @@
#include "components/user_prefs/tracked/pref_hash_filter.h"
+#include <stdint.h>
+
#include <algorithm>
#include "base/logging.h"
+#include "base/macros.h"
#include "base/metrics/histogram.h"
#include "base/prefs/pref_service.h"
#include "base/prefs/pref_store.h"
@@ -110,11 +113,11 @@ base::Time PrefHashFilter::GetResetTime(PrefService* user_prefs) {
// order to ensure it remains consistent with the way we store this value
// (which we do via a PrefStore, preventing us from reusing
// PrefService::SetInt64).
- int64 internal_value = base::Time().ToInternalValue();
+ int64_t internal_value = base::Time().ToInternalValue();
if (!base::StringToInt64(
user_prefs->GetString(user_prefs::kPreferenceResetTime),
&internal_value)) {
- // Somehow the value stored on disk is not a valid int64.
+ // Somehow the value stored on disk is not a valid int64_t.
NOTREACHED();
return base::Time();
}
diff --git a/components/user_prefs/tracked/pref_hash_filter.h b/components/user_prefs/tracked/pref_hash_filter.h
index 5499569..109f4ce 100644
--- a/components/user_prefs/tracked/pref_hash_filter.h
+++ b/components/user_prefs/tracked/pref_hash_filter.h
@@ -5,14 +5,16 @@
#ifndef COMPONENTS_USER_PREFS_TRACKED_PREF_HASH_FILTER_H_
#define COMPONENTS_USER_PREFS_TRACKED_PREF_HASH_FILTER_H_
+#include <stddef.h>
+
#include <map>
#include <set>
#include <vector>
-#include "base/basictypes.h"
#include "base/callback.h"
#include "base/compiler_specific.h"
#include "base/containers/scoped_ptr_hash_map.h"
+#include "base/macros.h"
#include "base/memory/scoped_ptr.h"
#include "components/user_prefs/tracked/interceptable_pref_filter.h"
#include "components/user_prefs/tracked/tracked_preference.h"
diff --git a/components/user_prefs/tracked/pref_hash_filter_unittest.cc b/components/user_prefs/tracked/pref_hash_filter_unittest.cc
index 2d1f4d3..dfd3324 100644
--- a/components/user_prefs/tracked/pref_hash_filter_unittest.cc
+++ b/components/user_prefs/tracked/pref_hash_filter_unittest.cc
@@ -4,17 +4,19 @@
#include "components/user_prefs/tracked/pref_hash_filter.h"
+#include <stddef.h>
+
#include <map>
#include <set>
#include <string>
#include <utility>
#include <vector>
-#include "base/basictypes.h"
#include "base/bind.h"
#include "base/callback_forward.h"
#include "base/compiler_specific.h"
#include "base/logging.h"
+#include "base/macros.h"
#include "base/memory/ref_counted.h"
#include "base/memory/scoped_ptr.h"
#include "base/metrics/histogram_base.h"
diff --git a/components/user_prefs/tracked/pref_hash_store_impl.cc b/components/user_prefs/tracked/pref_hash_store_impl.cc
index dd86222..820c098 100644
--- a/components/user_prefs/tracked/pref_hash_store_impl.cc
+++ b/components/user_prefs/tracked/pref_hash_store_impl.cc
@@ -4,7 +4,10 @@
#include "components/user_prefs/tracked/pref_hash_store_impl.h"
+#include <stddef.h>
+
#include "base/logging.h"
+#include "base/macros.h"
#include "base/metrics/histogram.h"
#include "base/values.h"
#include "components/user_prefs/tracked/hash_store_contents.h"
diff --git a/components/user_prefs/tracked/segregated_pref_store.cc b/components/user_prefs/tracked/segregated_pref_store.cc
index 99031a2..0d2ef94 100644
--- a/components/user_prefs/tracked/segregated_pref_store.cc
+++ b/components/user_prefs/tracked/segregated_pref_store.cc
@@ -84,11 +84,11 @@ bool SegregatedPrefStore::GetValue(const std::string& key,
void SegregatedPrefStore::SetValue(const std::string& key,
scoped_ptr<base::Value> value,
- uint32 flags) {
+ uint32_t flags) {
StoreForKey(key)->SetValue(key, value.Pass(), flags);
}
-void SegregatedPrefStore::RemoveValue(const std::string& key, uint32 flags) {
+void SegregatedPrefStore::RemoveValue(const std::string& key, uint32_t flags) {
StoreForKey(key)->RemoveValue(key, flags);
}
@@ -98,13 +98,13 @@ bool SegregatedPrefStore::GetMutableValue(const std::string& key,
}
void SegregatedPrefStore::ReportValueChanged(const std::string& key,
- uint32 flags) {
+ uint32_t flags) {
StoreForKey(key)->ReportValueChanged(key, flags);
}
void SegregatedPrefStore::SetValueSilently(const std::string& key,
scoped_ptr<base::Value> value,
- uint32 flags) {
+ uint32_t flags) {
StoreForKey(key)->SetValueSilently(key, value.Pass(), flags);
}
diff --git a/components/user_prefs/tracked/segregated_pref_store.h b/components/user_prefs/tracked/segregated_pref_store.h
index d2bf013..c1960c0 100644
--- a/components/user_prefs/tracked/segregated_pref_store.h
+++ b/components/user_prefs/tracked/segregated_pref_store.h
@@ -5,6 +5,8 @@
#ifndef COMPONENTS_USER_PREFS_TRACKED_SEGREGATED_PREF_STORE_H_
#define COMPONENTS_USER_PREFS_TRACKED_SEGREGATED_PREF_STORE_H_
+#include <stdint.h>
+
#include <set>
#include <string>
@@ -54,15 +56,15 @@ class SegregatedPrefStore : public PersistentPrefStore {
// WriteablePrefStore implementation
void SetValue(const std::string& key,
scoped_ptr<base::Value> value,
- uint32 flags) override;
- void RemoveValue(const std::string& key, uint32 flags) override;
+ uint32_t flags) override;
+ void RemoveValue(const std::string& key, uint32_t flags) override;
// PersistentPrefStore implementation
bool GetMutableValue(const std::string& key, base::Value** result) override;
- void ReportValueChanged(const std::string& key, uint32 flags) override;
+ void ReportValueChanged(const std::string& key, uint32_t flags) override;
void SetValueSilently(const std::string& key,
scoped_ptr<base::Value> value,
- uint32 flags) override;
+ uint32_t flags) override;
bool ReadOnly() const override;
PrefReadError GetReadError() const override;
PrefReadError ReadPrefs() override;
diff --git a/components/user_prefs/tracked/tracked_atomic_preference.h b/components/user_prefs/tracked/tracked_atomic_preference.h
index 3e183cf..04bd0ea 100644
--- a/components/user_prefs/tracked/tracked_atomic_preference.h
+++ b/components/user_prefs/tracked/tracked_atomic_preference.h
@@ -5,6 +5,8 @@
#ifndef COMPONENTS_USER_PREFS_TRACKED_ATOMIC_PREFERENCE_H_
#define COMPONENTS_USER_PREFS_TRACKED_ATOMIC_PREFERENCE_H_
+#include <stddef.h>
+
#include <string>
#include "base/compiler_specific.h"
diff --git a/components/user_prefs/tracked/tracked_preference_helper.h b/components/user_prefs/tracked/tracked_preference_helper.h
index f2fe338..883e3e8 100644
--- a/components/user_prefs/tracked/tracked_preference_helper.h
+++ b/components/user_prefs/tracked/tracked_preference_helper.h
@@ -5,6 +5,8 @@
#ifndef COMPONENTS_USER_PREFS_TRACKED_TRACKED_PREFERENCE_HELPER_H_
#define COMPONENTS_USER_PREFS_TRACKED_TRACKED_PREFERENCE_HELPER_H_
+#include <stddef.h>
+
#include <string>
#include "base/macros.h"
diff --git a/components/user_prefs/tracked/tracked_preferences_migration_unittest.cc b/components/user_prefs/tracked/tracked_preferences_migration_unittest.cc
index ed44bba..fc134aa 100644
--- a/components/user_prefs/tracked/tracked_preferences_migration_unittest.cc
+++ b/components/user_prefs/tracked/tracked_preferences_migration_unittest.cc
@@ -10,6 +10,7 @@
#include "base/bind.h"
#include "base/callback.h"
+#include "base/macros.h"
#include "base/memory/scoped_ptr.h"
#include "base/prefs/testing_pref_service.h"
#include "base/strings/string_split.h"
diff --git a/components/user_prefs/tracked/tracked_split_preference.h b/components/user_prefs/tracked/tracked_split_preference.h
index 04c2128..f2700a4 100644
--- a/components/user_prefs/tracked/tracked_split_preference.h
+++ b/components/user_prefs/tracked/tracked_split_preference.h
@@ -5,6 +5,8 @@
#ifndef COMPONENTS_USER_PREFS_TRACKED_TRACKED_SPLIT_PREFERENCE_H_
#define COMPONENTS_USER_PREFS_TRACKED_TRACKED_SPLIT_PREFERENCE_H_
+#include <stddef.h>
+
#include <string>
#include "base/compiler_specific.h"
diff --git a/components/user_prefs/user_prefs.h b/components/user_prefs/user_prefs.h
index ceea4f0..55e81c9 100644
--- a/components/user_prefs/user_prefs.h
+++ b/components/user_prefs/user_prefs.h
@@ -5,7 +5,7 @@
#ifndef COMPONENTS_USER_PREFS_USER_PREFS_H_
#define COMPONENTS_USER_PREFS_USER_PREFS_H_
-#include "base/basictypes.h"
+#include "base/macros.h"
#include "base/supports_user_data.h"
#include "components/user_prefs/user_prefs_export.h"
diff --git a/components/variations/active_field_trials.cc b/components/variations/active_field_trials.cc
index 7199a91..07c8b6b 100644
--- a/components/variations/active_field_trials.cc
+++ b/components/variations/active_field_trials.cc
@@ -4,6 +4,8 @@
#include "components/variations/active_field_trials.h"
+#include <stddef.h>
+
#include <vector>
#include "base/strings/stringprintf.h"
diff --git a/components/variations/active_field_trials.h b/components/variations/active_field_trials.h
index 882ab8c..b742551 100644
--- a/components/variations/active_field_trials.h
+++ b/components/variations/active_field_trials.h
@@ -5,9 +5,10 @@
#ifndef COMPONENTS_VARIATIONS_ACTIVE_FIELD_TRIALS_H_
#define COMPONENTS_VARIATIONS_ACTIVE_FIELD_TRIALS_H_
+#include <stdint.h>
+
#include <string>
-#include "base/basictypes.h"
#include "base/metrics/field_trial.h"
namespace variations {
@@ -15,8 +16,8 @@ namespace variations {
// The Unique ID of a trial and its active group, where the name and group
// identifiers are hashes of the trial and group name strings.
struct ActiveGroupId {
- uint32 name;
- uint32 group;
+ uint32_t name;
+ uint32_t group;
};
// Returns an ActiveGroupId struct for the given trial and group names.
diff --git a/components/variations/active_field_trials_unittest.cc b/components/variations/active_field_trials_unittest.cc
index c8d621e..548b09c 100644
--- a/components/variations/active_field_trials_unittest.cc
+++ b/components/variations/active_field_trials_unittest.cc
@@ -4,6 +4,8 @@
#include "components/variations/active_field_trials.h"
+#include <stddef.h>
+
#include "components/variations/metrics_util.h"
#include "testing/gtest/include/gtest/gtest.h"
diff --git a/components/variations/android/component_jni_registrar.cc b/components/variations/android/component_jni_registrar.cc
index 1af1fd2..9691d2c 100644
--- a/components/variations/android/component_jni_registrar.cc
+++ b/components/variations/android/component_jni_registrar.cc
@@ -6,7 +6,7 @@
#include "base/android/jni_android.h"
#include "base/android/jni_registrar.h"
-#include "base/basictypes.h"
+#include "base/macros.h"
#include "components/variations/android/variations_associated_data_android.h"
namespace variations {
diff --git a/components/variations/android/variations_seed_bridge.cc b/components/variations/android/variations_seed_bridge.cc
index bb90050..5c2788b 100644
--- a/components/variations/android/variations_seed_bridge.cc
+++ b/components/variations/android/variations_seed_bridge.cc
@@ -5,6 +5,7 @@
#include "components/variations/android/variations_seed_bridge.h"
#include <jni.h>
+#include <stdint.h>
#include <vector>
#include "base/android/context_utils.h"
@@ -25,7 +26,7 @@ namespace {
std::string JavaByteArrayToString(JNIEnv* env, jbyteArray byte_array) {
if (!byte_array)
return std::string();
- std::vector<uint8> array_data;
+ std::vector<uint8_t> array_data;
base::android::JavaByteArrayToByteVector(env, byte_array, &array_data);
return std::string(array_data.begin(), array_data.end());
}
@@ -33,7 +34,7 @@ std::string JavaByteArrayToString(JNIEnv* env, jbyteArray byte_array) {
ScopedJavaLocalRef<jbyteArray> StringToJavaByteArray(
JNIEnv* env,
const std::string& str_data) {
- std::vector<uint8> array_data(str_data.begin(), str_data.end());
+ std::vector<uint8_t> array_data(str_data.begin(), str_data.end());
return base::android::ToJavaByteArray(env, array_data);
}
diff --git a/components/variations/caching_permuted_entropy_provider.cc b/components/variations/caching_permuted_entropy_provider.cc
index 5d919d0..f1ae8af 100644
--- a/components/variations/caching_permuted_entropy_provider.cc
+++ b/components/variations/caching_permuted_entropy_provider.cc
@@ -16,7 +16,7 @@ namespace metrics {
CachingPermutedEntropyProvider::CachingPermutedEntropyProvider(
PrefService* local_state,
- uint16 low_entropy_source,
+ uint16_t low_entropy_source,
size_t low_entropy_source_max)
: PermutedEntropyProvider(low_entropy_source, low_entropy_source_max),
local_state_(local_state) {
@@ -38,11 +38,11 @@ void CachingPermutedEntropyProvider::ClearCache(PrefService* local_state) {
local_state->ClearPref(variations::prefs::kVariationsPermutedEntropyCache);
}
-uint16 CachingPermutedEntropyProvider::GetPermutedValue(
- uint32 randomization_seed) const {
+uint16_t CachingPermutedEntropyProvider::GetPermutedValue(
+ uint32_t randomization_seed) const {
DCHECK(thread_checker_.CalledOnValidThread());
- uint16 value = 0;
+ uint16_t value = 0;
if (!FindValue(randomization_seed, &value)) {
value = PermutedEntropyProvider::GetPermutedValue(randomization_seed);
AddToCache(randomization_seed, value);
@@ -71,8 +71,8 @@ void CachingPermutedEntropyProvider::UpdateLocalState() const {
base64_encoded);
}
-void CachingPermutedEntropyProvider::AddToCache(uint32 randomization_seed,
- uint16 value) const {
+void CachingPermutedEntropyProvider::AddToCache(uint32_t randomization_seed,
+ uint16_t value) const {
PermutedEntropyCache::Entry* entry;
const int kMaxSize = 25;
if (cache_.entry_size() >= kMaxSize) {
@@ -94,8 +94,8 @@ void CachingPermutedEntropyProvider::AddToCache(uint32 randomization_seed,
UpdateLocalState();
}
-bool CachingPermutedEntropyProvider::FindValue(uint32 randomization_seed,
- uint16* value) const {
+bool CachingPermutedEntropyProvider::FindValue(uint32_t randomization_seed,
+ uint16_t* value) const {
for (int i = 0; i < cache_.entry_size(); ++i) {
if (cache_.entry(i).randomization_seed() == randomization_seed) {
*value = cache_.entry(i).value();
diff --git a/components/variations/caching_permuted_entropy_provider.h b/components/variations/caching_permuted_entropy_provider.h
index 0ec859f..ce76449 100644
--- a/components/variations/caching_permuted_entropy_provider.h
+++ b/components/variations/caching_permuted_entropy_provider.h
@@ -5,8 +5,11 @@
#ifndef COMPONENTS_VARIATIONS_CACHING_PERMUTED_ENTROPY_PROVIDER_H_
#define COMPONENTS_VARIATIONS_CACHING_PERMUTED_ENTROPY_PROVIDER_H_
-#include "base/basictypes.h"
+#include <stddef.h>
+#include <stdint.h>
+
#include "base/compiler_specific.h"
+#include "base/macros.h"
#include "base/threading/thread_checker.h"
#include "components/variations/entropy_provider.h"
#include "components/variations/proto/permuted_entropy_cache.pb.h"
@@ -25,7 +28,7 @@ class CachingPermutedEntropyProvider : public PermutedEntropyProvider {
// prefs service with the specified |low_entropy_source|, which should have a
// value in the range of [0, low_entropy_source_max).
CachingPermutedEntropyProvider(PrefService* local_state,
- uint16 low_entropy_source,
+ uint16_t low_entropy_source,
size_t low_entropy_source_max);
~CachingPermutedEntropyProvider() override;
@@ -38,7 +41,7 @@ class CachingPermutedEntropyProvider : public PermutedEntropyProvider {
private:
// PermutedEntropyProvider overrides:
- uint16 GetPermutedValue(uint32 randomization_seed) const override;
+ uint16_t GetPermutedValue(uint32_t randomization_seed) const override;
// Reads the cache from local state.
void ReadFromLocalState() const;
@@ -47,11 +50,11 @@ class CachingPermutedEntropyProvider : public PermutedEntropyProvider {
void UpdateLocalState() const;
// Adds |randomization_seed| -> |value| to the cache.
- void AddToCache(uint32 randomization_seed, uint16 value) const;
+ void AddToCache(uint32_t randomization_seed, uint16_t value) const;
// Finds the value corresponding to |randomization_seed|, setting |value| and
// returning true if found.
- bool FindValue(uint32 randomization_seed, uint16* value) const;
+ bool FindValue(uint32_t randomization_seed, uint16_t* value) const;
base::ThreadChecker thread_checker_;
PrefService* local_state_;
diff --git a/components/variations/caching_permuted_entropy_provider_unittest.cc b/components/variations/caching_permuted_entropy_provider_unittest.cc
index 269feab..1b1095b 100644
--- a/components/variations/caching_permuted_entropy_provider_unittest.cc
+++ b/components/variations/caching_permuted_entropy_provider_unittest.cc
@@ -4,9 +4,11 @@
#include "components/variations/caching_permuted_entropy_provider.h"
+#include <stddef.h>
+
#include <string>
-#include "base/basictypes.h"
+#include "base/macros.h"
#include "base/prefs/testing_pref_service.h"
#include "testing/gtest/include/gtest/gtest.h"
diff --git a/components/variations/entropy_provider.cc b/components/variations/entropy_provider.cc
index 7358340..d07277f 100644
--- a/components/variations/entropy_provider.cc
+++ b/components/variations/entropy_provider.cc
@@ -18,14 +18,14 @@ namespace metrics {
namespace internal {
-SeededRandGenerator::SeededRandGenerator(uint32 seed) {
+SeededRandGenerator::SeededRandGenerator(uint32_t seed) {
mersenne_twister_.init_genrand(seed);
}
SeededRandGenerator::~SeededRandGenerator() {
}
-uint32 SeededRandGenerator::operator()(uint32 range) {
+uint32_t SeededRandGenerator::operator()(uint32_t range) {
// Based on base::RandGenerator().
DCHECK_GT(range, 0u);
@@ -33,10 +33,10 @@ uint32 SeededRandGenerator::operator()(uint32 range) {
// make the random generator non-uniform (consider e.g. if
// MAX_UINT64 was 7 and |range| was 5, then a result of 1 would be twice
// as likely as a result of 3 or 4).
- uint32 max_acceptable_value =
- (std::numeric_limits<uint32>::max() / range) * range - 1;
+ uint32_t max_acceptable_value =
+ (std::numeric_limits<uint32_t>::max() / range) * range - 1;
- uint32 value;
+ uint32_t value;
do {
value = mersenne_twister_.genrand_int32();
} while (value > max_acceptable_value);
@@ -44,10 +44,10 @@ uint32 SeededRandGenerator::operator()(uint32 range) {
return value % range;
}
-void PermuteMappingUsingRandomizationSeed(uint32 randomization_seed,
- std::vector<uint16>* mapping) {
+void PermuteMappingUsingRandomizationSeed(uint32_t randomization_seed,
+ std::vector<uint16_t>* mapping) {
for (size_t i = 0; i < mapping->size(); ++i)
- (*mapping)[i] = static_cast<uint16>(i);
+ (*mapping)[i] = static_cast<uint16_t>(i);
SeededRandGenerator generator(randomization_seed);
@@ -78,7 +78,7 @@ SHA1EntropyProvider::~SHA1EntropyProvider() {
double SHA1EntropyProvider::GetEntropyForTrial(
const std::string& trial_name,
- uint32 randomization_seed) const {
+ uint32_t randomization_seed) const {
// Given enough input entropy, SHA-1 will produce a uniformly random spread
// in its output space. In this case, the input entropy that is used is the
// combination of the original |entropy_source_| and the |trial_name|.
@@ -93,7 +93,7 @@ double SHA1EntropyProvider::GetEntropyForTrial(
input.size(),
sha1_hash);
- uint64 bits;
+ uint64_t bits;
static_assert(sizeof(bits) < sizeof(sha1_hash), "more data required");
memcpy(&bits, sha1_hash, sizeof(bits));
bits = base::ByteSwapToLE64(bits);
@@ -101,13 +101,12 @@ double SHA1EntropyProvider::GetEntropyForTrial(
return base::BitsToOpenEndedUnitInterval(bits);
}
-PermutedEntropyProvider::PermutedEntropyProvider(
- uint16 low_entropy_source,
- size_t low_entropy_source_max)
+PermutedEntropyProvider::PermutedEntropyProvider(uint16_t low_entropy_source,
+ size_t low_entropy_source_max)
: low_entropy_source_(low_entropy_source),
low_entropy_source_max_(low_entropy_source_max) {
DCHECK_LT(low_entropy_source, low_entropy_source_max);
- DCHECK_LE(low_entropy_source_max, std::numeric_limits<uint16>::max());
+ DCHECK_LE(low_entropy_source_max, std::numeric_limits<uint16_t>::max());
}
PermutedEntropyProvider::~PermutedEntropyProvider() {
@@ -115,7 +114,7 @@ PermutedEntropyProvider::~PermutedEntropyProvider() {
double PermutedEntropyProvider::GetEntropyForTrial(
const std::string& trial_name,
- uint32 randomization_seed) const {
+ uint32_t randomization_seed) const {
if (randomization_seed == 0)
randomization_seed = HashName(trial_name);
@@ -123,9 +122,9 @@ double PermutedEntropyProvider::GetEntropyForTrial(
static_cast<double>(low_entropy_source_max_);
}
-uint16 PermutedEntropyProvider::GetPermutedValue(
- uint32 randomization_seed) const {
- std::vector<uint16> mapping(low_entropy_source_max_);
+uint16_t PermutedEntropyProvider::GetPermutedValue(
+ uint32_t randomization_seed) const {
+ std::vector<uint16_t> mapping(low_entropy_source_max_);
internal::PermuteMappingUsingRandomizationSeed(randomization_seed, &mapping);
return mapping[low_entropy_source_];
}
diff --git a/components/variations/entropy_provider.h b/components/variations/entropy_provider.h
index 0fff0b0..fa7a1e2 100644
--- a/components/variations/entropy_provider.h
+++ b/components/variations/entropy_provider.h
@@ -5,12 +5,15 @@
#ifndef COMPONENTS_VARIATIONS_ENTROPY_PROVIDER_H_
#define COMPONENTS_VARIATIONS_ENTROPY_PROVIDER_H_
+#include <stddef.h>
+#include <stdint.h>
+
#include <functional>
#include <string>
#include <vector>
-#include "base/basictypes.h"
#include "base/compiler_specific.h"
+#include "base/macros.h"
#include "base/metrics/field_trial.h"
#include "third_party/mt19937ar/mt19937ar.h"
@@ -21,20 +24,20 @@ namespace internal {
// A functor that generates random numbers based on a seed, using the Mersenne
// Twister algorithm. Suitable for use with std::random_shuffle().
-struct SeededRandGenerator : std::unary_function<uint32, uint32> {
- explicit SeededRandGenerator(uint32 seed);
+struct SeededRandGenerator : std::unary_function<uint32_t, uint32_t> {
+ explicit SeededRandGenerator(uint32_t seed);
~SeededRandGenerator();
// Returns a random number in range [0, range).
- uint32 operator()(uint32 range);
+ uint32_t operator()(uint32_t range);
MersenneTwister mersenne_twister_;
};
// Fills |mapping| to create a bijection of values in the range of
// [0, |mapping.size()|), permuted based on |randomization_seed|.
-void PermuteMappingUsingRandomizationSeed(uint32 randomization_seed,
- std::vector<uint16>* mapping);
+void PermuteMappingUsingRandomizationSeed(uint32_t randomization_seed,
+ std::vector<uint16_t>* mapping);
} // namespace internal
@@ -52,7 +55,7 @@ class SHA1EntropyProvider : public base::FieldTrial::EntropyProvider {
// base::FieldTrial::EntropyProvider implementation:
double GetEntropyForTrial(const std::string& trial_name,
- uint32 randomization_seed) const override;
+ uint32_t randomization_seed) const override;
private:
std::string entropy_source_;
@@ -69,21 +72,21 @@ class PermutedEntropyProvider : public base::FieldTrial::EntropyProvider {
public:
// Creates a PermutedEntropyProvider with the given |low_entropy_source|,
// which should have a value in the range of [0, low_entropy_source_max).
- PermutedEntropyProvider(uint16 low_entropy_source,
+ PermutedEntropyProvider(uint16_t low_entropy_source,
size_t low_entropy_source_max);
~PermutedEntropyProvider() override;
// base::FieldTrial::EntropyProvider implementation:
double GetEntropyForTrial(const std::string& trial_name,
- uint32 randomization_seed) const override;
+ uint32_t randomization_seed) const override;
protected:
// Performs the permutation algorithm and returns the permuted value that
// corresponds to |low_entropy_source_|.
- virtual uint16 GetPermutedValue(uint32 randomization_seed) const;
+ virtual uint16_t GetPermutedValue(uint32_t randomization_seed) const;
private:
- uint16 low_entropy_source_;
+ uint16_t low_entropy_source_;
size_t low_entropy_source_max_;
DISALLOW_COPY_AND_ASSIGN(PermutedEntropyProvider);
diff --git a/components/variations/entropy_provider_unittest.cc b/components/variations/entropy_provider_unittest.cc
index 652ab44..64c2862 100644
--- a/components/variations/entropy_provider_unittest.cc
+++ b/components/variations/entropy_provider_unittest.cc
@@ -4,12 +4,15 @@
#include "components/variations/entropy_provider.h"
+#include <stddef.h>
+#include <stdint.h>
+
#include <cmath>
#include <limits>
#include <numeric>
-#include "base/basictypes.h"
#include "base/guid.h"
+#include "base/macros.h"
#include "base/memory/scoped_ptr.h"
#include "base/rand_util.h"
#include "base/strings/string_number_conversions.h"
@@ -53,7 +56,7 @@ double GenerateSHA1Entropy(const std::string& entropy_source,
// Generates permutation-based entropy for the given |trial_name| based on
// |entropy_source| which must be in the range [0, entropy_max).
-double GeneratePermutedEntropy(uint16 entropy_source,
+double GeneratePermutedEntropy(uint16_t entropy_source,
size_t entropy_max,
const std::string& trial_name) {
PermutedEntropyProvider permuted_provider(entropy_source, entropy_max);
@@ -86,7 +89,7 @@ class SHA1EntropyGenerator : public TrialEntropyGenerator {
// Use a random GUID + 13 additional bits of entropy to match how the
// SHA1EntropyProvider is used in metrics_service.cc.
const int low_entropy_source =
- static_cast<uint16>(base::RandInt(0, kMaxLowEntropySize - 1));
+ static_cast<uint16_t>(base::RandInt(0, kMaxLowEntropySize - 1));
const std::string high_entropy_source =
base::GenerateGUID() + base::IntToString(low_entropy_source);
return GenerateSHA1Entropy(high_entropy_source, trial_name_);
@@ -107,7 +110,7 @@ class PermutedEntropyGenerator : public TrialEntropyGenerator {
// Note: Given a trial name, the computed mapping will be the same.
// As a performance optimization, pre-compute the mapping once per trial
// name and index into it for each entropy value.
- const uint32 randomization_seed = HashName(trial_name);
+ const uint32_t randomization_seed = HashName(trial_name);
internal::PermuteMappingUsingRandomizationSeed(randomization_seed,
&mapping_);
}
@@ -116,13 +119,13 @@ class PermutedEntropyGenerator : public TrialEntropyGenerator {
double GenerateEntropyValue() const override {
const int low_entropy_source =
- static_cast<uint16>(base::RandInt(0, kMaxLowEntropySize - 1));
+ static_cast<uint16_t>(base::RandInt(0, kMaxLowEntropySize - 1));
return mapping_[low_entropy_source] /
static_cast<double>(kMaxLowEntropySize);
}
private:
- std::vector<uint16> mapping_;
+ std::vector<uint16_t> mapping_;
DISALLOW_COPY_AND_ASSIGN(PermutedEntropyGenerator);
};
@@ -245,7 +248,7 @@ TEST(EntropyProviderTest, UseOneTimeRandomizationWithCustomSeedPermuted) {
base::FieldTrialList field_trial_list(
new PermutedEntropyProvider(1234, kMaxLowEntropySize));
const int kNoExpirationYear = base::FieldTrialList::kNoExpirationYear;
- const uint32 kCustomSeed = 9001;
+ const uint32_t kCustomSeed = 9001;
scoped_refptr<base::FieldTrial> trials[] = {
base::FieldTrialList::FactoryGetFieldTrialWithRandomizationSeed(
"one", 100, "default", kNoExpirationYear, 1, 1,
@@ -331,20 +334,21 @@ TEST(EntropyProviderTest, SeededRandGeneratorIsUniform) {
//
// Mirrors RandUtilTest.RandGeneratorIsUniform in base/rand_util_unittest.cc.
- const uint32 kTopOfRange = (std::numeric_limits<uint32>::max() / 4ULL) * 3ULL;
- const uint32 kExpectedAverage = kTopOfRange / 2ULL;
- const uint32 kAllowedVariance = kExpectedAverage / 50ULL; // +/- 2%
+ const uint32_t kTopOfRange =
+ (std::numeric_limits<uint32_t>::max() / 4ULL) * 3ULL;
+ const uint32_t kExpectedAverage = kTopOfRange / 2ULL;
+ const uint32_t kAllowedVariance = kExpectedAverage / 50ULL; // +/- 2%
const int kMinAttempts = 1000;
const int kMaxAttempts = 1000000;
for (size_t i = 0; i < arraysize(kTestTrialNames); ++i) {
- const uint32 seed = HashName(kTestTrialNames[i]);
+ const uint32_t seed = HashName(kTestTrialNames[i]);
internal::SeededRandGenerator rand_generator(seed);
double cumulative_average = 0.0;
int count = 0;
while (count < kMaxAttempts) {
- uint32 value = rand_generator(kTopOfRange);
+ uint32_t value = rand_generator(kTopOfRange);
cumulative_average = (count * cumulative_average + value) / (count + 1);
// Don't quit too quickly for things to start converging, or we may have
diff --git a/components/variations/experiment_labels_unittest.cc b/components/variations/experiment_labels_unittest.cc
index 77ee928..8df2826 100644
--- a/components/variations/experiment_labels_unittest.cc
+++ b/components/variations/experiment_labels_unittest.cc
@@ -4,11 +4,13 @@
#include "components/variations/experiment_labels.h"
+#include <stddef.h>
+
#include <set>
#include <string>
#include <vector>
-#include "base/basictypes.h"
+#include "base/macros.h"
#include "base/metrics/field_trial.h"
#include "base/strings/string_split.h"
#include "base/strings/utf_string_conversions.h"
diff --git a/components/variations/metrics_util.cc b/components/variations/metrics_util.cc
index 41b2df3..e6e76e3 100644
--- a/components/variations/metrics_util.cc
+++ b/components/variations/metrics_util.cc
@@ -9,7 +9,7 @@
namespace metrics {
-uint32 HashName(const std::string& name) {
+uint32_t HashName(const std::string& name) {
// SHA-1 is designed to produce a uniformly random spread in its output space,
// even for nearly-identical inputs.
unsigned char sha1_hash[base::kSHA1Length];
@@ -17,7 +17,7 @@ uint32 HashName(const std::string& name) {
name.size(),
sha1_hash);
- uint32 bits;
+ uint32_t bits;
static_assert(sizeof(bits) < sizeof(sha1_hash), "more data required");
memcpy(&bits, sha1_hash, sizeof(bits));
diff --git a/components/variations/metrics_util.h b/components/variations/metrics_util.h
index b331d4e..823fcd7 100644
--- a/components/variations/metrics_util.h
+++ b/components/variations/metrics_util.h
@@ -5,15 +5,16 @@
#ifndef COMPONENTS_VARIATIONS_METRICS_UTIL_H_
#define COMPONENTS_VARIATIONS_METRICS_UTIL_H_
+#include <stdint.h>
+
#include <string>
-#include "base/basictypes.h"
namespace metrics {
-// Computes a uint32 hash of a given string based on its SHA1 hash. Suitable for
-// uniquely identifying field trial names and group names.
-uint32 HashName(const std::string& name);
+// Computes a uint32_t hash of a given string based on its SHA1 hash. Suitable
+// for uniquely identifying field trial names and group names.
+uint32_t HashName(const std::string& name);
} // namespace metrics
diff --git a/components/variations/metrics_util_unittest.cc b/components/variations/metrics_util_unittest.cc
index 46f50ca..953e139 100644
--- a/components/variations/metrics_util_unittest.cc
+++ b/components/variations/metrics_util_unittest.cc
@@ -4,6 +4,10 @@
#include "components/variations/metrics_util.h"
+#include <stddef.h>
+#include <stdint.h>
+
+#include "base/macros.h"
#include "testing/gtest/include/gtest/gtest.h"
namespace metrics {
@@ -12,7 +16,7 @@ TEST(MetricsUtilTest, HashName) {
// Checks that hashing is stable on all platforms.
struct {
const char* name;
- uint32 hash_value;
+ uint32_t hash_value;
} known_hashes[] = {
{"a", 937752454u},
{"1", 723085877u},
diff --git a/components/variations/net/variations_http_headers.cc b/components/variations/net/variations_http_headers.cc
index 632a0e0..2507cbb 100644
--- a/components/variations/net/variations_http_headers.cc
+++ b/components/variations/net/variations_http_headers.cc
@@ -4,6 +4,9 @@
#include "components/variations/net/variations_http_headers.h"
+#include <stddef.h>
+
+#include "base/macros.h"
#include "base/strings/string_util.h"
#include "components/google/core/browser/google_util.h"
#include "components/variations/variations_http_header_provider.h"
diff --git a/components/variations/net/variations_http_headers_unittest.cc b/components/variations/net/variations_http_headers_unittest.cc
index 0f04c44..6b06953 100644
--- a/components/variations/net/variations_http_headers_unittest.cc
+++ b/components/variations/net/variations_http_headers_unittest.cc
@@ -4,6 +4,8 @@
#include "components/variations/net/variations_http_headers.h"
+#include <stddef.h>
+
#include "base/macros.h"
#include "testing/gtest/include/gtest/gtest.h"
#include "url/gurl.h"
diff --git a/components/variations/service/ui_string_overrider.h b/components/variations/service/ui_string_overrider.h
index 8aa4784..c5baf8d 100644
--- a/components/variations/service/ui_string_overrider.h
+++ b/components/variations/service/ui_string_overrider.h
@@ -5,7 +5,9 @@
#ifndef COMPONENTS_VARIATIONS_SERVICE_UI_STRING_OVERRIDER_H_
#define COMPONENTS_VARIATIONS_SERVICE_UI_STRING_OVERRIDER_H_
-#include "base/basictypes.h"
+#include <stddef.h>
+#include <stdint.h>
+
#include "base/macros.h"
#include "base/strings/string16.h"
diff --git a/components/variations/service/ui_string_overrider_unittest.cc b/components/variations/service/ui_string_overrider_unittest.cc
index 640d51c..0f4ab52 100644
--- a/components/variations/service/ui_string_overrider_unittest.cc
+++ b/components/variations/service/ui_string_overrider_unittest.cc
@@ -4,6 +4,10 @@
#include "components/variations/service/ui_string_overrider.h"
+#include <stddef.h>
+#include <stdint.h>
+
+#include "base/macros.h"
#include "testing/gtest/include/gtest/gtest.h"
namespace chrome_variations {
diff --git a/components/variations/service/variations_service.cc b/components/variations/service/variations_service.cc
index 8d3ced5..a300747 100644
--- a/components/variations/service/variations_service.cc
+++ b/components/variations/service/variations_service.cc
@@ -4,6 +4,9 @@
#include "components/variations/service/variations_service.h"
+#include <stddef.h>
+#include <stdint.h>
+
#include "base/build_time.h"
#include "base/command_line.h"
#include "base/metrics/histogram.h"
@@ -16,6 +19,7 @@
#include "base/timer/elapsed_timer.h"
#include "base/values.h"
#include "base/version.h"
+#include "build/build_config.h"
#include "components/data_use_measurement/core/data_use_user_data.h"
#include "components/metrics/metrics_state_manager.h"
#include "components/network_time/network_time_tracker.h"
@@ -47,7 +51,7 @@ const int kMaxRetrySeedFetch = 5;
// TODO(mad): To be removed when we stop updating the NetworkTimeTracker.
// For the HTTP date headers, the resolution of the server time is 1 second.
-const int64 kServerTimeResolutionMs = 1000;
+const int64_t kServerTimeResolutionMs = 1000;
// Maximum age permitted for a variations seed, in days.
const int kMaxVariationsSeedAgeDays = 30;
@@ -195,7 +199,7 @@ std::string GetHardwareClass() {
// Returns the date that should be used by the VariationsSeedProcessor to do
// expiry and start date checks.
base::Time GetReferenceDateForExpiryChecks(PrefService* local_state) {
- const int64 date_value = local_state->GetInt64(prefs::kVariationsSeedDate);
+ const int64_t date_value = local_state->GetInt64(prefs::kVariationsSeedDate);
const base::Time seed_date = base::Time::FromInternalValue(date_value);
const base::Time build_time = base::GetBuildTime();
// Use the build time for date checks if either the seed date is invalid or
@@ -302,7 +306,7 @@ bool VariationsService::CreateTrialsFromSeed(base::FeatureList* feature_list) {
if (!LoadSeed(&seed))
return false;
- const int64 last_fetch_time_internal =
+ const int64_t last_fetch_time_internal =
local_state_->GetInt64(prefs::kVariationsLastFetchTime);
const base::Time last_fetch_time =
base::Time::FromInternalValue(last_fetch_time_internal);
diff --git a/components/variations/service/variations_service.h b/components/variations/service/variations_service.h
index 0f65da0..61c6173 100644
--- a/components/variations/service/variations_service.h
+++ b/components/variations/service/variations_service.h
@@ -9,6 +9,7 @@
#include "base/compiler_specific.h"
#include "base/gtest_prod_util.h"
+#include "base/macros.h"
#include "base/memory/scoped_ptr.h"
#include "base/memory/weak_ptr.h"
#include "base/metrics/field_trial.h"
diff --git a/components/variations/service/variations_service_unittest.cc b/components/variations/service/variations_service_unittest.cc
index fcc0ff5..a0a0220 100644
--- a/components/variations/service/variations_service_unittest.cc
+++ b/components/variations/service/variations_service_unittest.cc
@@ -4,11 +4,14 @@
#include "components/variations/service/variations_service.h"
+#include <stddef.h>
+
#include <vector>
#include "base/base64.h"
#include "base/feature_list.h"
#include "base/json/json_string_value_serializer.h"
+#include "base/macros.h"
#include "base/message_loop/message_loop.h"
#include "base/prefs/testing_pref_service.h"
#include "base/sha1.h"
diff --git a/components/variations/study_filtering.cc b/components/variations/study_filtering.cc
index 8045c1c..f5b3f26 100644
--- a/components/variations/study_filtering.cc
+++ b/components/variations/study_filtering.cc
@@ -4,9 +4,13 @@
#include "components/variations/study_filtering.h"
+#include <stddef.h>
+#include <stdint.h>
+
#include <set>
#include "base/stl_util.h"
+#include "build/build_config.h"
namespace variations {
@@ -33,7 +37,7 @@ Study_Platform GetCurrentPlatform() {
}
// Converts |date_time| in Study date format to base::Time.
-base::Time ConvertStudyDateToBaseTime(int64 date_time) {
+base::Time ConvertStudyDateToBaseTime(int64_t date_time) {
return base::Time::UnixEpoch() + base::TimeDelta::FromSeconds(date_time);
}
diff --git a/components/variations/study_filtering_unittest.cc b/components/variations/study_filtering_unittest.cc
index 29b7c93..6d4c18f 100644
--- a/components/variations/study_filtering_unittest.cc
+++ b/components/variations/study_filtering_unittest.cc
@@ -4,8 +4,13 @@
#include "components/variations/study_filtering.h"
+#include <stddef.h>
+#include <stdint.h>
+#include <string.h>
+
#include <vector>
+#include "base/macros.h"
#include "base/strings/string_split.h"
#include "components/variations/processed_study.h"
#include "testing/gtest/include/gtest/gtest.h"
@@ -15,7 +20,7 @@ namespace variations {
namespace {
// Converts |time| to Study proto format.
-int64 TimeToProtoTime(const base::Time& time) {
+int64_t TimeToProtoTime(const base::Time& time) {
return (time - base::Time::UnixEpoch()).InSeconds();
}
diff --git a/components/variations/synthetic_trials.h b/components/variations/synthetic_trials.h
index b5b4240..fa47e64 100644
--- a/components/variations/synthetic_trials.h
+++ b/components/variations/synthetic_trials.h
@@ -5,6 +5,8 @@
#ifndef COMPONENTS_VARIATIONS_SYNTHETIC_TRIALS_H_
#define COMPONENTS_VARIATIONS_SYNTHETIC_TRIALS_H_
+#include <stdint.h>
+
#include <vector>
#include "base/compiler_specific.h"
diff --git a/components/variations/variations_associated_data.cc b/components/variations/variations_associated_data.cc
index b4f9c00..4f0b471 100644
--- a/components/variations/variations_associated_data.cc
+++ b/components/variations/variations_associated_data.cc
@@ -8,6 +8,7 @@
#include <utility>
#include <vector>
+#include "base/macros.h"
#include "base/memory/singleton.h"
namespace variations {
diff --git a/components/variations/variations_associated_data_unittest.cc b/components/variations/variations_associated_data_unittest.cc
index 770267c..470490d 100644
--- a/components/variations/variations_associated_data_unittest.cc
+++ b/components/variations/variations_associated_data_unittest.cc
@@ -4,6 +4,7 @@
#include "components/variations/variations_associated_data.h"
+#include "base/macros.h"
#include "base/metrics/field_trial.h"
#include "testing/gtest/include/gtest/gtest.h"
diff --git a/components/variations/variations_http_header_provider.cc b/components/variations/variations_http_header_provider.cc
index 97f96b0..2739aef 100644
--- a/components/variations/variations_http_header_provider.cc
+++ b/components/variations/variations_http_header_provider.cc
@@ -4,6 +4,8 @@
#include "components/variations/variations_http_header_provider.h"
+#include <stddef.h>
+
#include <set>
#include <string>
#include <vector>
diff --git a/components/variations/variations_http_header_provider.h b/components/variations/variations_http_header_provider.h
index 3c6ce75..b92daca 100644
--- a/components/variations/variations_http_header_provider.h
+++ b/components/variations/variations_http_header_provider.h
@@ -9,8 +9,8 @@
#include <string>
#include <vector>
-#include "base/basictypes.h"
#include "base/gtest_prod_util.h"
+#include "base/macros.h"
#include "base/metrics/field_trial.h"
#include "base/synchronization/lock.h"
#include "components/variations/synthetic_trials.h"
diff --git a/components/variations/variations_request_scheduler.cc b/components/variations/variations_request_scheduler.cc
index 4834421..08d39d1 100644
--- a/components/variations/variations_request_scheduler.cc
+++ b/components/variations/variations_request_scheduler.cc
@@ -4,7 +4,10 @@
#include "components/variations/variations_request_scheduler.h"
+#include <stddef.h>
+
#include "base/strings/string_number_conversions.h"
+#include "build/build_config.h"
#include "components/variations/variations_associated_data.h"
namespace variations {
diff --git a/components/variations/variations_request_scheduler.h b/components/variations/variations_request_scheduler.h
index c364010..2b94501 100644
--- a/components/variations/variations_request_scheduler.h
+++ b/components/variations/variations_request_scheduler.h
@@ -7,6 +7,7 @@
#include "base/bind.h"
#include "base/gtest_prod_util.h"
+#include "base/macros.h"
#include "base/time/time.h"
#include "base/timer/timer.h"
diff --git a/components/variations/variations_request_scheduler_mobile.h b/components/variations/variations_request_scheduler_mobile.h
index 75bbf55..5b46f1f 100644
--- a/components/variations/variations_request_scheduler_mobile.h
+++ b/components/variations/variations_request_scheduler_mobile.h
@@ -7,6 +7,7 @@
#include "base/bind.h"
#include "base/gtest_prod_util.h"
+#include "base/macros.h"
#include "components/variations/variations_request_scheduler.h"
class PrefService;
diff --git a/components/variations/variations_seed_processor.cc b/components/variations/variations_seed_processor.cc
index 8acfa88..9f19c3f 100644
--- a/components/variations/variations_seed_processor.cc
+++ b/components/variations/variations_seed_processor.cc
@@ -4,6 +4,8 @@
#include "components/variations/variations_seed_processor.h"
+#include <stddef.h>
+
#include <map>
#include <vector>
@@ -211,7 +213,7 @@ void VariationsSeedProcessor::CreateTrialFromStudy(
}
}
- uint32 randomization_seed = 0;
+ uint32_t randomization_seed = 0;
base::FieldTrial::RandomizationType randomization_type =
base::FieldTrial::SESSION_RANDOMIZED;
if (study.has_consistency() &&
diff --git a/components/variations/variations_seed_processor.h b/components/variations/variations_seed_processor.h
index f7199be..a7ddd5c 100644
--- a/components/variations/variations_seed_processor.h
+++ b/components/variations/variations_seed_processor.h
@@ -5,12 +5,15 @@
#ifndef COMPONENTS_VARIATIONS_VARIATIONS_SEED_PROCESSOR_H_
#define COMPONENTS_VARIATIONS_VARIATIONS_SEED_PROCESSOR_H_
+#include <stdint.h>
+
#include <string>
#include <vector>
#include "base/callback_forward.h"
#include "base/compiler_specific.h"
#include "base/gtest_prod_util.h"
+#include "base/macros.h"
#include "base/metrics/field_trial.h"
#include "base/strings/string16.h"
#include "base/time/time.h"
diff --git a/components/variations/variations_seed_processor_unittest.cc b/components/variations/variations_seed_processor_unittest.cc
index 89cab1b..8bc5ce6 100644
--- a/components/variations/variations_seed_processor_unittest.cc
+++ b/components/variations/variations_seed_processor_unittest.cc
@@ -4,6 +4,9 @@
#include "components/variations/variations_seed_processor.h"
+#include <stddef.h>
+#include <stdint.h>
+
#include <map>
#include <vector>
@@ -11,6 +14,7 @@
#include "base/command_line.h"
#include "base/feature_list.h"
#include "base/format_macros.h"
+#include "base/macros.h"
#include "base/strings/string_split.h"
#include "base/strings/stringprintf.h"
#include "base/strings/utf_string_conversions.h"
@@ -23,7 +27,7 @@ namespace variations {
namespace {
// Converts |time| to Study proto format.
-int64 TimeToProtoTime(const base::Time& time) {
+int64_t TimeToProtoTime(const base::Time& time) {
return (time - base::Time::UnixEpoch()).InSeconds();
}
diff --git a/components/variations/variations_seed_simulator.cc b/components/variations/variations_seed_simulator.cc
index 3687517..a9a2f87 100644
--- a/components/variations/variations_seed_simulator.cc
+++ b/components/variations/variations_seed_simulator.cc
@@ -4,6 +4,8 @@
#include "components/variations/variations_seed_simulator.h"
+#include <stddef.h>
+
#include <map>
#include "base/metrics/field_trial.h"
diff --git a/components/variations/variations_seed_simulator.h b/components/variations/variations_seed_simulator.h
index 9d37a50..dafaf09 100644
--- a/components/variations/variations_seed_simulator.h
+++ b/components/variations/variations_seed_simulator.h
@@ -9,6 +9,7 @@
#include <vector>
#include "base/compiler_specific.h"
+#include "base/macros.h"
#include "base/metrics/field_trial.h"
#include "base/version.h"
#include "components/variations/proto/study.pb.h"
diff --git a/components/variations/variations_seed_simulator_unittest.cc b/components/variations/variations_seed_simulator_unittest.cc
index 965c6af..1b656b6 100644
--- a/components/variations/variations_seed_simulator_unittest.cc
+++ b/components/variations/variations_seed_simulator_unittest.cc
@@ -4,8 +4,11 @@
#include "components/variations/variations_seed_simulator.h"
+#include <stdint.h>
+
#include <map>
+#include "base/macros.h"
#include "base/strings/stringprintf.h"
#include "components/variations/processed_study.h"
#include "components/variations/proto/study.pb.h"
@@ -26,7 +29,7 @@ class TestEntropyProvider : public base::FieldTrial::EntropyProvider {
// base::FieldTrial::EntropyProvider implementation:
double GetEntropyForTrial(const std::string& trial_name,
- uint32 randomization_seed) const override {
+ uint32_t randomization_seed) const override {
return entropy_value_;
}
diff --git a/components/variations/variations_seed_store.cc b/components/variations/variations_seed_store.cc
index 9054eae..0c7e840 100644
--- a/components/variations/variations_seed_store.cc
+++ b/components/variations/variations_seed_store.cc
@@ -4,13 +4,17 @@
#include "components/variations/variations_seed_store.h"
+#include <stdint.h>
+
#include "base/base64.h"
+#include "base/macros.h"
#include "base/metrics/histogram_macros.h"
#include "base/numerics/safe_math.h"
#include "base/prefs/pref_registry_simple.h"
#include "base/prefs/pref_service.h"
#include "base/sha1.h"
#include "base/strings/string_number_conversions.h"
+#include "build/build_config.h"
#include "components/compression/compression_utils.h"
#include "components/variations/pref_names.h"
#include "components/variations/proto/variations_seed.pb.h"
@@ -47,10 +51,8 @@ bool SignatureVerificationEnabled() {
// component, the OID ecdsa-with-SHA224, ecdsa-with-SHA256, ecdsa-with-
// SHA384, or ecdsa-with-SHA512.
// See also RFC 5480, Appendix A.
-const uint8 kECDSAWithSHA256AlgorithmID[] = {
- 0x30, 0x0a,
- 0x06, 0x08,
- 0x2a, 0x86, 0x48, 0xce, 0x3d, 0x04, 0x03, 0x02,
+const uint8_t kECDSAWithSHA256AlgorithmID[] = {
+ 0x30, 0x0a, 0x06, 0x08, 0x2a, 0x86, 0x48, 0xce, 0x3d, 0x04, 0x03, 0x02,
};
// The ECDSA public key of the variations server for verifying variations seed
@@ -295,7 +297,7 @@ void VariationsSeedStore::UpdateSeedDateAndLogDayChange(
VariationsSeedDateChangeState date_change = SEED_DATE_NO_OLD_DATE;
if (local_state_->HasPrefPath(prefs::kVariationsSeedDate)) {
- const int64 stored_date_value =
+ const int64_t stored_date_value =
local_state_->GetInt64(prefs::kVariationsSeedDate);
const base::Time stored_date =
base::Time::FromInternalValue(stored_date_value);
@@ -341,12 +343,12 @@ VariationsSeedStore::VerifySeedSignature(
crypto::SignatureVerifier verifier;
if (!verifier.VerifyInit(
kECDSAWithSHA256AlgorithmID, sizeof(kECDSAWithSHA256AlgorithmID),
- reinterpret_cast<const uint8*>(signature.data()), signature.size(),
+ reinterpret_cast<const uint8_t*>(signature.data()), signature.size(),
kPublicKey, arraysize(kPublicKey))) {
return VARIATIONS_SEED_SIGNATURE_INVALID_SIGNATURE;
}
- verifier.VerifyUpdate(reinterpret_cast<const uint8*>(seed_bytes.data()),
+ verifier.VerifyUpdate(reinterpret_cast<const uint8_t*>(seed_bytes.data()),
seed_bytes.size());
if (verifier.VerifyFinal())
return VARIATIONS_SEED_SIGNATURE_VALID;
@@ -502,14 +504,15 @@ bool VariationsSeedStore::ApplyDeltaPatch(const std::string& existing_data,
output->clear();
google::protobuf::io::CodedInputStream in(
- reinterpret_cast<const uint8*>(patch.data()), patch.length());
+ reinterpret_cast<const uint8_t*>(patch.data()), patch.length());
// Temporary string declared outside the loop so it can be re-used between
// different iterations (rather than allocating new ones).
std::string temp;
- const uint32 existing_data_size = static_cast<uint32>(existing_data.size());
+ const uint32_t existing_data_size =
+ static_cast<uint32_t>(existing_data.size());
while (in.CurrentPosition() != static_cast<int>(patch.length())) {
- uint32 value;
+ uint32_t value;
if (!in.ReadVarint32(&value))
return false;
@@ -526,13 +529,13 @@ bool VariationsSeedStore::ApplyDeltaPatch(const std::string& existing_data,
// Otherwise, when it's zero, it indicates that it's followed by a pair of
// numbers - |offset| and |length| that specify a range of data to copy
// from |existing_data|.
- uint32 offset;
- uint32 length;
+ uint32_t offset;
+ uint32_t length;
if (!in.ReadVarint32(&offset) || !in.ReadVarint32(&length))
return false;
// Check for |offset + length| being out of range and for overflow.
- base::CheckedNumeric<uint32> end_offset(offset);
+ base::CheckedNumeric<uint32_t> end_offset(offset);
end_offset += length;
if (!end_offset.IsValid() || end_offset.ValueOrDie() > existing_data_size)
return false;
diff --git a/components/variations/variations_seed_store.h b/components/variations/variations_seed_store.h
index d079a51..2450e68 100644
--- a/components/variations/variations_seed_store.h
+++ b/components/variations/variations_seed_store.h
@@ -9,7 +9,9 @@
#include "base/compiler_specific.h"
#include "base/gtest_prod_util.h"
+#include "base/macros.h"
#include "base/time/time.h"
+#include "build/build_config.h"
class PrefService;
class PrefRegistrySimple;
diff --git a/components/variations/variations_seed_store_unittest.cc b/components/variations/variations_seed_store_unittest.cc
index 419784f..f4e2f35 100644
--- a/components/variations/variations_seed_store_unittest.cc
+++ b/components/variations/variations_seed_store_unittest.cc
@@ -5,7 +5,9 @@
#include "components/variations/variations_seed_store.h"
#include "base/base64.h"
+#include "base/macros.h"
#include "base/prefs/testing_pref_service.h"
+#include "build/build_config.h"
#include "components/compression/compression_utils.h"
#include "components/variations/pref_names.h"
#include "components/variations/proto/study.pb.h"
diff --git a/components/visitedlink/browser/visitedlink_event_listener.h b/components/visitedlink/browser/visitedlink_event_listener.h
index d74c8db..7439471 100644
--- a/components/visitedlink/browser/visitedlink_event_listener.h
+++ b/components/visitedlink/browser/visitedlink_event_listener.h
@@ -7,6 +7,7 @@
#include <map>
+#include "base/macros.h"
#include "base/memory/linked_ptr.h"
#include "base/timer/timer.h"
#include "components/visitedlink/browser/visitedlink_master.h"
diff --git a/components/visitedlink/browser/visitedlink_master.cc b/components/visitedlink/browser/visitedlink_master.cc
index 3d9b7f5..c5c6490 100644
--- a/components/visitedlink/browser/visitedlink_master.cc
+++ b/components/visitedlink/browser/visitedlink_master.cc
@@ -4,12 +4,8 @@
#include "components/visitedlink/browser/visitedlink_master.h"
-#if defined(OS_WIN)
-#include <windows.h>
-#include <io.h>
-#include <shlobj.h>
-#endif // defined(OS_WIN)
#include <stdio.h>
+#include <string.h>
#include <algorithm>
@@ -19,30 +15,38 @@
#include "base/files/file_util.h"
#include "base/files/scoped_file.h"
#include "base/logging.h"
+#include "base/macros.h"
#include "base/message_loop/message_loop.h"
#include "base/rand_util.h"
#include "base/strings/string_util.h"
#include "base/threading/thread_restrictions.h"
+#include "build/build_config.h"
#include "components/visitedlink/browser/visitedlink_delegate.h"
#include "components/visitedlink/browser/visitedlink_event_listener.h"
#include "content/public/browser/browser_context.h"
#include "content/public/browser/browser_thread.h"
#include "url/gurl.h"
+#if defined(OS_WIN)
+#include <windows.h>
+#include <io.h>
+#include <shlobj.h>
+#endif // defined(OS_WIN)
+
using content::BrowserThread;
namespace visitedlink {
-const int32 VisitedLinkMaster::kFileHeaderSignatureOffset = 0;
-const int32 VisitedLinkMaster::kFileHeaderVersionOffset = 4;
-const int32 VisitedLinkMaster::kFileHeaderLengthOffset = 8;
-const int32 VisitedLinkMaster::kFileHeaderUsedOffset = 12;
-const int32 VisitedLinkMaster::kFileHeaderSaltOffset = 16;
+const int32_t VisitedLinkMaster::kFileHeaderSignatureOffset = 0;
+const int32_t VisitedLinkMaster::kFileHeaderVersionOffset = 4;
+const int32_t VisitedLinkMaster::kFileHeaderLengthOffset = 8;
+const int32_t VisitedLinkMaster::kFileHeaderUsedOffset = 12;
+const int32_t VisitedLinkMaster::kFileHeaderSaltOffset = 16;
-const int32 VisitedLinkMaster::kFileCurrentVersion = 3;
+const int32_t VisitedLinkMaster::kFileCurrentVersion = 3;
// the signature at the beginning of the URL table = "VLnk" (visited links)
-const int32 VisitedLinkMaster::kFileSignature = 0x6b6e4c56;
+const int32_t VisitedLinkMaster::kFileSignature = 0x6b6e4c56;
const size_t VisitedLinkMaster::kFileHeaderSize =
kFileHeaderSaltOffset + LINK_SALT_LENGTH;
@@ -57,9 +61,9 @@ namespace {
// Fills the given salt structure with some quasi-random values
// It is not necessary to generate a cryptographically strong random string,
// only that it be reasonably different for different users.
-void GenerateSalt(uint8 salt[LINK_SALT_LENGTH]) {
+void GenerateSalt(uint8_t salt[LINK_SALT_LENGTH]) {
DCHECK_EQ(LINK_SALT_LENGTH, 8) << "This code assumes the length of the salt";
- uint64 randval = base::RandUint64();
+ uint64_t randval = base::RandUint64();
memcpy(salt, &randval, 8);
}
@@ -92,7 +96,7 @@ static bool WriteToFile(FILE* file,
// prevents us from blocking the UI thread doing I/O. Double pointer to FILE
// is used because file may still not be opened by the time of scheduling
// the task for execution.
-void AsyncWrite(FILE** file, int32 offset, const std::string& data) {
+void AsyncWrite(FILE** file, int32_t offset, const std::string& data) {
if (*file)
WriteToFile(*file, offset, data.data(), data.size());
}
@@ -121,16 +125,16 @@ struct VisitedLinkMaster::LoadFromFileResult
LoadFromFileResult(base::ScopedFILE file,
scoped_ptr<base::SharedMemory> shared_memory,
Fingerprint* hash_table,
- int32 num_entries,
- int32 used_count,
- uint8 salt[LINK_SALT_LENGTH]);
+ int32_t num_entries,
+ int32_t used_count,
+ uint8_t salt[LINK_SALT_LENGTH]);
base::ScopedFILE file;
scoped_ptr<base::SharedMemory> shared_memory;
Fingerprint* hash_table;
- int32 num_entries;
- int32 used_count;
- uint8 salt[LINK_SALT_LENGTH];
+ int32_t num_entries;
+ int32_t used_count;
+ uint8_t salt[LINK_SALT_LENGTH];
private:
friend class base::RefCountedThreadSafe<LoadFromFileResult>;
@@ -143,9 +147,9 @@ VisitedLinkMaster::LoadFromFileResult::LoadFromFileResult(
base::ScopedFILE file,
scoped_ptr<base::SharedMemory> shared_memory,
Fingerprint* hash_table,
- int32 num_entries,
- int32 used_count,
- uint8 salt[LINK_SALT_LENGTH])
+ int32_t num_entries,
+ int32_t used_count,
+ uint8_t salt[LINK_SALT_LENGTH])
: file(file.Pass()),
shared_memory(shared_memory.Pass()),
hash_table(hash_table),
@@ -179,8 +183,7 @@ VisitedLinkMaster::LoadFromFileResult::~LoadFromFileResult() {
class VisitedLinkMaster::TableBuilder
: public VisitedLinkDelegate::URLEnumerator {
public:
- TableBuilder(VisitedLinkMaster* master,
- const uint8 salt[LINK_SALT_LENGTH]);
+ TableBuilder(VisitedLinkMaster* master, const uint8_t salt[LINK_SALT_LENGTH]);
// Called on the main thread when the master is being destroyed. This will
// prevent a crash when the query completes and the master is no longer
@@ -206,7 +209,7 @@ class VisitedLinkMaster::TableBuilder
bool success_;
// Salt for this new table.
- uint8 salt_[LINK_SALT_LENGTH];
+ uint8_t salt_[LINK_SALT_LENGTH];
// Stores the fingerprints we computed on the background thread.
VisitedLinkCommon::Fingerprints fingerprints_;
@@ -233,7 +236,7 @@ VisitedLinkMaster::VisitedLinkMaster(Listener* listener,
bool persist_to_disk,
bool suppress_rebuild,
const base::FilePath& filename,
- int32 default_table_size)
+ int32_t default_table_size)
: browser_context_(NULL),
delegate_(delegate),
persist_to_disk_(persist_to_disk),
@@ -595,7 +598,7 @@ void VisitedLinkMaster::WriteFullTable() {
}
// Write the new header.
- int32 header[4];
+ int32_t header[4];
header[0] = kFileSignature;
header[1] = kFileCurrentVersion;
header[2] = table_length_;
@@ -653,8 +656,8 @@ bool VisitedLinkMaster::LoadApartFromFile(
if (!file_closer.get())
return false;
- int32 num_entries, used_count;
- uint8 salt[LINK_SALT_LENGTH];
+ int32_t num_entries, used_count;
+ uint8_t salt[LINK_SALT_LENGTH];
if (!ReadFileHeader(file_closer.get(), &num_entries, &used_count, salt))
return false; // Header isn't valid.
@@ -792,9 +795,9 @@ bool VisitedLinkMaster::InitFromScratch(bool suppress_rebuild) {
// static
bool VisitedLinkMaster::ReadFileHeader(FILE* file,
- int32* num_entries,
- int32* used_count,
- uint8 salt[LINK_SALT_LENGTH]) {
+ int32_t* num_entries,
+ int32_t* used_count,
+ uint8_t salt[LINK_SALT_LENGTH]) {
// Get file size.
// Note that there is no need to seek back to the original location in the
// file since ReadFromFile() [which is the next call accessing the file]
@@ -806,12 +809,12 @@ bool VisitedLinkMaster::ReadFileHeader(FILE* file,
if (file_size <= kFileHeaderSize)
return false;
- uint8 header[kFileHeaderSize];
+ uint8_t header[kFileHeaderSize];
if (!ReadFromFile(file, 0, &header, kFileHeaderSize))
return false;
// Verify the signature.
- int32 signature;
+ int32_t signature;
memcpy(&signature, &header[kFileHeaderSignatureOffset], sizeof(signature));
if (signature != kFileSignature)
return false;
@@ -819,7 +822,7 @@ bool VisitedLinkMaster::ReadFileHeader(FILE* file,
// Verify the version is up-to-date. As with other read errors, a version
// mistmatch will trigger a rebuild of the database from history, which will
// have the effect of migrating the database.
- int32 version;
+ int32_t version;
memcpy(&version, &header[kFileHeaderVersionOffset], sizeof(version));
if (version != kFileCurrentVersion)
return false; // Bad version.
@@ -858,7 +861,7 @@ bool VisitedLinkMaster::GetDatabaseFileName(base::FilePath* filename) {
// Initializes the shared memory structure. The salt should already be filled
// in so that it can be written to the shared memory
-bool VisitedLinkMaster::CreateURLTable(int32 num_entries) {
+bool VisitedLinkMaster::CreateURLTable(int32_t num_entries) {
scoped_ptr<base::SharedMemory> shared_memory;
VisitedLinkCommon::Fingerprint* hash_table;
if (CreateApartURLTable(num_entries, salt_, &shared_memory, &hash_table)) {
@@ -874,8 +877,8 @@ bool VisitedLinkMaster::CreateURLTable(int32 num_entries) {
// static
bool VisitedLinkMaster::CreateApartURLTable(
- int32 num_entries,
- const uint8 salt[LINK_SALT_LENGTH],
+ int32_t num_entries,
+ const uint8_t salt[LINK_SALT_LENGTH],
scoped_ptr<base::SharedMemory>* shared_memory,
VisitedLinkCommon::Fingerprint** hash_table) {
DCHECK(salt);
@@ -883,7 +886,8 @@ bool VisitedLinkMaster::CreateApartURLTable(
DCHECK(hash_table);
// The table is the size of the table followed by the entries.
- uint32 alloc_size = num_entries * sizeof(Fingerprint) + sizeof(SharedHeader);
+ uint32_t alloc_size =
+ num_entries * sizeof(Fingerprint) + sizeof(SharedHeader);
// Create the shared memory object.
scoped_ptr<base::SharedMemory> sh_mem(new base::SharedMemory());
@@ -913,10 +917,10 @@ bool VisitedLinkMaster::CreateApartURLTable(
return true;
}
-bool VisitedLinkMaster::BeginReplaceURLTable(int32 num_entries) {
+bool VisitedLinkMaster::BeginReplaceURLTable(int32_t num_entries) {
base::SharedMemory *old_shared_memory = shared_memory_;
Fingerprint* old_hash_table = hash_table_;
- int32 old_table_length = table_length_;
+ int32_t old_table_length = table_length_;
if (!CreateURLTable(num_entries)) {
// Try to put back the old state.
shared_memory_ = old_shared_memory;
@@ -968,7 +972,7 @@ bool VisitedLinkMaster::ResizeTableIfNecessary() {
return true;
}
-void VisitedLinkMaster::ResizeTable(int32 new_size) {
+void VisitedLinkMaster::ResizeTable(int32_t new_size) {
DCHECK(shared_memory_ && shared_memory_->memory() && hash_table_);
shared_memory_serial_++;
@@ -978,13 +982,13 @@ void VisitedLinkMaster::ResizeTable(int32 new_size) {
base::SharedMemory* old_shared_memory = shared_memory_;
Fingerprint* old_hash_table = hash_table_;
- int32 old_table_length = table_length_;
+ int32_t old_table_length = table_length_;
if (!BeginReplaceURLTable(new_size))
return;
// Now we have two tables, our local copy which is the old one, and the new
// one loaded into this object where we need to copy the data.
- for (int32 i = 0; i < old_table_length; i++) {
+ for (int32_t i = 0; i < old_table_length; i++) {
Fingerprint cur = old_hash_table[i];
if (cur)
AddFingerprint(cur, false);
@@ -1007,14 +1011,14 @@ void VisitedLinkMaster::ResizeTable(int32 new_size) {
WriteFullTable();
}
-uint32 VisitedLinkMaster::DefaultTableSize() const {
+uint32_t VisitedLinkMaster::DefaultTableSize() const {
if (table_size_override_)
return table_size_override_;
return kDefaultTableSize;
}
-uint32 VisitedLinkMaster::NewTableSizeForCount(int32 item_count) const {
+uint32_t VisitedLinkMaster::NewTableSizeForCount(int32_t item_count) const {
// These table sizes are selected to be the maximum prime number less than
// a "convenient" multiple of 1K.
static const int table_sizes[] = {
@@ -1112,7 +1116,7 @@ void VisitedLinkMaster::OnTableRebuildComplete(
void VisitedLinkMaster::WriteToFile(FILE** file,
off_t offset,
void* data,
- int32 data_size) {
+ int32_t data_size) {
DCHECK(persist_to_disk_);
DCHECK(!table_is_loading_from_file_);
PostIOTask(FROM_HERE,
@@ -1165,11 +1169,10 @@ bool VisitedLinkMaster::ReadFromFile(FILE* file,
VisitedLinkMaster::TableBuilder::TableBuilder(
VisitedLinkMaster* master,
- const uint8 salt[LINK_SALT_LENGTH])
- : master_(master),
- success_(true) {
+ const uint8_t salt[LINK_SALT_LENGTH])
+ : master_(master), success_(true) {
fingerprints_.reserve(4096);
- memcpy(salt_, salt, LINK_SALT_LENGTH * sizeof(uint8));
+ memcpy(salt_, salt, LINK_SALT_LENGTH * sizeof(uint8_t));
}
// TODO(brettw): Do we want to try to cancel the request if this happens? It
diff --git a/components/visitedlink/browser/visitedlink_master.h b/components/visitedlink/browser/visitedlink_master.h
index 7111575..ebdcf41 100644
--- a/components/visitedlink/browser/visitedlink_master.h
+++ b/components/visitedlink/browser/visitedlink_master.h
@@ -5,9 +5,9 @@
#ifndef COMPONENTS_VISITEDLINK_BROWSER_VISITEDLINK_MASTER_H_
#define COMPONENTS_VISITEDLINK_BROWSER_VISITEDLINK_MASTER_H_
-#if defined(OS_WIN)
-#include <windows.h>
-#endif
+#include <stddef.h>
+#include <stdint.h>
+
#include <set>
#include <vector>
@@ -15,12 +15,18 @@
#include "base/callback_forward.h"
#include "base/files/file_path.h"
#include "base/gtest_prod_util.h"
+#include "base/macros.h"
#include "base/memory/ref_counted.h"
#include "base/memory/shared_memory.h"
#include "base/memory/weak_ptr.h"
#include "base/threading/sequenced_worker_pool.h"
+#include "build/build_config.h"
#include "components/visitedlink/common/visitedlink_common.h"
+#if defined(OS_WIN)
+#include <windows.h>
+#endif
+
#if defined(UNIT_TEST) || defined(PERF_TEST) || !defined(NDEBUG)
#include "base/logging.h"
#endif
@@ -90,7 +96,7 @@ class VisitedLinkMaster : public VisitedLinkCommon {
bool persist_to_disk,
bool suppress_rebuild,
const base::FilePath& filename,
- int32 default_table_size);
+ int32_t default_table_size);
~VisitedLinkMaster() override;
// Must be called immediately after object creation. Nothing else will work
@@ -145,9 +151,7 @@ class VisitedLinkMaster : public VisitedLinkCommon {
}
// returns the number of items in the table for testing verification
- int32 GetUsedCount() const {
- return used_items_;
- }
+ int32_t GetUsedCount() const { return used_items_; }
// Returns the listener.
VisitedLinkMaster::Listener* GetListener() const {
@@ -178,17 +182,17 @@ class VisitedLinkMaster : public VisitedLinkCommon {
class TableBuilder;
// Byte offsets of values in the header.
- static const int32 kFileHeaderSignatureOffset;
- static const int32 kFileHeaderVersionOffset;
- static const int32 kFileHeaderLengthOffset;
- static const int32 kFileHeaderUsedOffset;
- static const int32 kFileHeaderSaltOffset;
+ static const int32_t kFileHeaderSignatureOffset;
+ static const int32_t kFileHeaderVersionOffset;
+ static const int32_t kFileHeaderLengthOffset;
+ static const int32_t kFileHeaderUsedOffset;
+ static const int32_t kFileHeaderSaltOffset;
// The signature at the beginning of a file.
- static const int32 kFileSignature;
+ static const int32_t kFileSignature;
// version of the file format this module currently uses
- static const int32 kFileCurrentVersion;
+ static const int32_t kFileCurrentVersion;
// Bytes in the file header, including the salt.
static const size_t kFileHeaderSize;
@@ -251,16 +255,16 @@ class VisitedLinkMaster : public VisitedLinkCommon {
// and the number of nonzero fingerprints in used_count. This will fail if
// the version of the file is not the current version of the database.
static bool ReadFileHeader(FILE* hfile,
- int32* num_entries,
- int32* used_count,
- uint8 salt[LINK_SALT_LENGTH]);
+ int32_t* num_entries,
+ int32_t* used_count,
+ uint8_t salt[LINK_SALT_LENGTH]);
// Fills *filename with the name of the link database filename
bool GetDatabaseFileName(base::FilePath* filename);
// Wrapper around Window's WriteFile using asynchronous I/O. This will proxy
// the write to a background thread.
- void WriteToFile(FILE** hfile, off_t offset, void* data, int32 data_size);
+ void WriteToFile(FILE** hfile, off_t offset, void* data, int32_t data_size);
// Helper function to schedule and asynchronous write of the used count to
// disk (this is a common operation).
@@ -309,14 +313,14 @@ class VisitedLinkMaster : public VisitedLinkCommon {
// Allocates the Fingerprint structure and length. Structure is filled with 0s
// and shared header with salt and used_items_ is set to 0.
- bool CreateURLTable(int32 num_entries);
+ bool CreateURLTable(int32_t num_entries);
// Allocates the Fingerprint structure and length. Returns true on success.
// Structure is filled with 0s and shared header with salt. The result of
// allocation is saved into |shared_memory| and |hash_table| points to the
// beginning of Fingerprint table in |shared_memory|.
- static bool CreateApartURLTable(int32 num_entries,
- const uint8 salt[LINK_SALT_LENGTH],
+ static bool CreateApartURLTable(int32_t num_entries,
+ const uint8_t salt[LINK_SALT_LENGTH],
scoped_ptr<base::SharedMemory>* shared_memory,
VisitedLinkCommon::Fingerprint** hash_table);
@@ -329,7 +333,7 @@ class VisitedLinkMaster : public VisitedLinkCommon {
//
// Returns true on success. On failure, the old table will be restored. The
// caller should not attemp to release the pointer/handle in this case.
- bool BeginReplaceURLTable(int32 num_entries);
+ bool BeginReplaceURLTable(int32_t num_entries);
// unallocates the Fingerprint table
void FreeURLTable();
@@ -341,13 +345,13 @@ class VisitedLinkMaster : public VisitedLinkCommon {
// Resizes the table (growing or shrinking) as necessary to accomodate the
// current count.
- void ResizeTable(int32 new_size);
+ void ResizeTable(int32_t new_size);
// Returns the default table size. It can be overrided in unit tests.
- uint32 DefaultTableSize() const;
+ uint32_t DefaultTableSize() const;
// Returns the desired table size for |item_count| URLs.
- uint32 NewTableSizeForCount(int32 item_count) const;
+ uint32_t NewTableSizeForCount(int32_t item_count) const;
// Computes the table load as fraction. For example, if 1/4 of the entries are
// full, this value will be 0.25
@@ -433,10 +437,10 @@ class VisitedLinkMaster : public VisitedLinkCommon {
// When we generate new tables, we increment the serial number of the
// shared memory object.
- int32 shared_memory_serial_;
+ int32_t shared_memory_serial_;
// Number of non-empty items in the table, used to compute fullness.
- int32 used_items_;
+ int32_t used_items_;
// We set this to true to avoid writing to the database file.
bool table_is_loading_from_file_;
@@ -453,7 +457,7 @@ class VisitedLinkMaster : public VisitedLinkCommon {
base::FilePath database_name_override_;
// When nonzero, overrides the table size for new databases for testing
- int32 table_size_override_;
+ int32_t table_size_override_;
// When set, indicates the task that should be run after the next rebuild from
// history is complete.
@@ -474,8 +478,8 @@ class VisitedLinkMaster : public VisitedLinkCommon {
#if defined(UNIT_TEST) || defined(PERF_TEST) || !defined(NDEBUG)
inline void VisitedLinkMaster::DebugValidate() {
- int32 used_count = 0;
- for (int32 i = 0; i < table_length_; i++) {
+ int32_t used_count = 0;
+ for (int32_t i = 0; i < table_length_; i++) {
if (hash_table_[i])
used_count++;
}
diff --git a/components/visitedlink/common/visitedlink_common.cc b/components/visitedlink/common/visitedlink_common.cc
index 7576231..b052142 100644
--- a/components/visitedlink/common/visitedlink_common.cc
+++ b/components/visitedlink/common/visitedlink_common.cc
@@ -78,7 +78,7 @@ bool VisitedLinkCommon::IsVisited(Fingerprint fingerprint) const {
VisitedLinkCommon::Fingerprint VisitedLinkCommon::ComputeURLFingerprint(
const char* canonical_url,
size_t url_len,
- const uint8 salt[LINK_SALT_LENGTH]) {
+ const uint8_t salt[LINK_SALT_LENGTH]) {
DCHECK(url_len > 0) << "Canonical URLs should not be empty";
base::MD5Context ctx;
@@ -95,8 +95,8 @@ VisitedLinkCommon::Fingerprint VisitedLinkCommon::ComputeURLFingerprint(
// on arbitrary alignment on some processors. This reinterpret_casts it
// down to a char array of the same size as fingerprint, and then does the
// bit cast, which amounts to a memcpy. This does not handle endian issues.
- return bit_cast<Fingerprint, uint8[8]>(
- *reinterpret_cast<uint8(*)[8]>(&digest.a));
+ return bit_cast<Fingerprint, uint8_t[8]>(
+ *reinterpret_cast<uint8_t(*)[8]>(&digest.a));
}
} // namespace visitedlink
diff --git a/components/visitedlink/common/visitedlink_common.h b/components/visitedlink/common/visitedlink_common.h
index 37afe1d..0a0401d 100644
--- a/components/visitedlink/common/visitedlink_common.h
+++ b/components/visitedlink/common/visitedlink_common.h
@@ -5,9 +5,12 @@
#ifndef COMPONENTS_VISITEDLINK_COMMON_VISITEDLINK_COMMON_H_
#define COMPONENTS_VISITEDLINK_COMMON_VISITEDLINK_COMMON_H_
+#include <stddef.h>
+#include <stdint.h>
+
#include <vector>
-#include "base/basictypes.h"
+#include "base/macros.h"
class GURL;
@@ -45,11 +48,11 @@ namespace visitedlink {
class VisitedLinkCommon {
public:
// A number that identifies the URL.
- typedef uint64 Fingerprint;
+ typedef uint64_t Fingerprint;
typedef std::vector<Fingerprint> Fingerprints;
// A hash value of a fingerprint
- typedef int32 Hash;
+ typedef int32_t Hash;
// A fingerprint or hash value that does not exist
static const Fingerprint null_fingerprint_;
@@ -73,7 +76,7 @@ class VisitedLinkCommon {
#ifdef UNIT_TEST
// Returns statistics about DB usage
- void GetUsageStatistics(int32* table_size,
+ void GetUsageStatistics(int32_t* table_size,
VisitedLinkCommon::Fingerprint** fingerprints) {
*table_size = table_length_;
*fingerprints = hash_table_;
@@ -85,16 +88,16 @@ class VisitedLinkCommon {
// can get stats on the table
struct SharedHeader {
// see goes into table_length_
- uint32 length;
+ uint32_t length;
// goes into salt_
- uint8 salt[LINK_SALT_LENGTH];
+ uint8_t salt[LINK_SALT_LENGTH];
};
// Returns the fingerprint at the given index into the URL table. This
// function should be called instead of accessing the table directly to
// contain endian issues.
- Fingerprint FingerprintAt(int32 table_offset) const {
+ Fingerprint FingerprintAt(int32_t table_offset) const {
if (!hash_table_)
return null_fingerprint_;
return hash_table_[table_offset];
@@ -104,13 +107,14 @@ class VisitedLinkCommon {
// same algorithm can be re-used by the table rebuilder, so you will have to
// pass the salt as a parameter. See the non-static version above if you
// want to use the current class' salt.
- static Fingerprint ComputeURLFingerprint(const char* canonical_url,
- size_t url_len,
- const uint8 salt[LINK_SALT_LENGTH]);
+ static Fingerprint ComputeURLFingerprint(
+ const char* canonical_url,
+ size_t url_len,
+ const uint8_t salt[LINK_SALT_LENGTH]);
// Computes the hash value of the given fingerprint, this is used as a lookup
// into the hashtable.
- static Hash HashFingerprint(Fingerprint fingerprint, int32 table_length) {
+ static Hash HashFingerprint(Fingerprint fingerprint, int32_t table_length) {
if (table_length == 0)
return null_hash_;
return static_cast<Hash>(fingerprint % table_length);
@@ -124,10 +128,10 @@ class VisitedLinkCommon {
VisitedLinkCommon::Fingerprint* hash_table_;
// the number of items in the hash table
- int32 table_length_;
+ int32_t table_length_;
// salt used for each URL when computing the fingerprint
- uint8 salt_[LINK_SALT_LENGTH];
+ uint8_t salt_[LINK_SALT_LENGTH];
private:
DISALLOW_COPY_AND_ASSIGN(VisitedLinkCommon);
diff --git a/components/visitedlink/common/visitedlink_messages.h b/components/visitedlink/common/visitedlink_messages.h
index 95b9338..f2c1d88 100644
--- a/components/visitedlink/common/visitedlink_messages.h
+++ b/components/visitedlink/common/visitedlink_messages.h
@@ -3,9 +3,11 @@
// found in the LICENSE file.
// Multiply-included file, no traditional include guard.
+
+#include <stdint.h>
+
#include <vector>
-#include "base/basictypes.h"
#include "base/memory/shared_memory.h"
#include "content/public/common/common_param_traits_macros.h"
#include "ipc/ipc_message_macros.h"
@@ -20,7 +22,7 @@ IPC_MESSAGE_CONTROL1(ChromeViewMsg_VisitedLink_NewTable,
// History system notification that a link has been added and the link
// coloring state for the given hash must be re-calculated.
-IPC_MESSAGE_CONTROL1(ChromeViewMsg_VisitedLink_Add, std::vector<uint64>)
+IPC_MESSAGE_CONTROL1(ChromeViewMsg_VisitedLink_Add, std::vector<uint64_t>)
// History system notification that one or more history items have been
// deleted, which at this point means that all link coloring state must be
diff --git a/components/visitedlink/renderer/visitedlink_slave.cc b/components/visitedlink/renderer/visitedlink_slave.cc
index e43f0ae..c159aba 100644
--- a/components/visitedlink/renderer/visitedlink_slave.cc
+++ b/components/visitedlink/renderer/visitedlink_slave.cc
@@ -4,6 +4,9 @@
#include "components/visitedlink/renderer/visitedlink_slave.h"
+#include <stddef.h>
+#include <stdint.h>
+
#include "base/logging.h"
#include "base/memory/shared_memory.h"
#include "components/visitedlink/common/visitedlink_messages.h"
@@ -52,7 +55,7 @@ void VisitedLinkSlave::OnUpdateVisitedLinks(base::SharedMemoryHandle table) {
SharedHeader* header =
static_cast<SharedHeader*>(shared_memory_->memory());
DCHECK(header);
- int32 table_len = header->length;
+ int32_t table_len = header->length;
memcpy(salt_, header->salt, sizeof(salt_));
shared_memory_->Unmap();
diff --git a/components/visitedlink/renderer/visitedlink_slave.h b/components/visitedlink/renderer/visitedlink_slave.h
index e372036..6db2f32 100644
--- a/components/visitedlink/renderer/visitedlink_slave.h
+++ b/components/visitedlink/renderer/visitedlink_slave.h
@@ -6,6 +6,7 @@
#define COMPONENTS_VISITEDLINK_RENDERER_VISITEDLINK_SLAVE_H_
#include "base/compiler_specific.h"
+#include "base/macros.h"
#include "base/memory/shared_memory.h"
#include "components/visitedlink/common/visitedlink_common.h"
#include "content/public/renderer/render_process_observer.h"
diff --git a/components/visitedlink/test/visitedlink_unittest.cc b/components/visitedlink/test/visitedlink_unittest.cc
index 89dad11..29a155d 100644
--- a/components/visitedlink/test/visitedlink_unittest.cc
+++ b/components/visitedlink/test/visitedlink_unittest.cc
@@ -2,12 +2,16 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
+#include <stddef.h>
+#include <stdint.h>
+
#include <cstdio>
#include <string>
#include <vector>
#include "base/files/file_util.h"
#include "base/location.h"
+#include "base/macros.h"
#include "base/memory/shared_memory.h"
#include "base/process/process_handle.h"
#include "base/run_loop.h"
@@ -260,7 +264,7 @@ TEST_F(VisitedLinkTest, DatabaseIO) {
// Checks that we can delete things properly when there are collisions.
TEST_F(VisitedLinkTest, Delete) {
- static const int32 kInitialSize = 17;
+ static const int32_t kInitialSize = 17;
ASSERT_TRUE(InitVisited(kInitialSize, true, true));
// Add a cluster from 14-17 wrapping around to 0. These will all hash to the
@@ -303,13 +307,13 @@ TEST_F(VisitedLinkTest, BigDelete) {
// Add the base set of URLs that won't be deleted.
// Reload() will test for these.
- for (int32 i = 0; i < g_test_count; i++)
+ for (int32_t i = 0; i < g_test_count; i++)
master_->AddURL(TestURL(i));
// Add more URLs than necessary to trigger this case.
const int kTestDeleteCount = VisitedLinkMaster::kBigDeleteThreshold + 2;
URLs urls_to_delete;
- for (int32 i = g_test_count; i < g_test_count + kTestDeleteCount; i++) {
+ for (int32_t i = g_test_count; i < g_test_count + kTestDeleteCount; i++) {
GURL url(TestURL(i));
master_->AddURL(url);
urls_to_delete.push_back(url);
@@ -369,7 +373,7 @@ TEST_F(VisitedLinkTest, DeleteAll) {
// full, notifies its slaves of the change, and updates the disk.
TEST_F(VisitedLinkTest, Resizing) {
// Create a very small database.
- const int32 initial_size = 17;
+ const int32_t initial_size = 17;
ASSERT_TRUE(InitVisited(initial_size, true, true));
// ...and a slave
@@ -380,7 +384,7 @@ TEST_F(VisitedLinkTest, Resizing) {
slave.OnUpdateVisitedLinks(new_handle);
g_slaves.push_back(&slave);
- int32 used_count = master_->GetUsedCount();
+ int32_t used_count = master_->GetUsedCount();
ASSERT_EQ(used_count, 0);
for (int i = 0; i < g_test_count; i++) {
@@ -390,7 +394,7 @@ TEST_F(VisitedLinkTest, Resizing) {
}
// Verify that the table got resized sufficiently.
- int32 table_size;
+ int32_t table_size;
VisitedLinkCommon::Fingerprint* table;
master_->GetUsageStatistics(&table_size, &table);
used_count = master_->GetUsedCount();
@@ -400,11 +404,11 @@ TEST_F(VisitedLinkTest, Resizing) {
// Verify that the slave got the resize message and has the same
// table information.
- int32 child_table_size;
+ int32_t child_table_size;
VisitedLinkCommon::Fingerprint* child_table;
slave.GetUsageStatistics(&child_table_size, &child_table);
ASSERT_EQ(table_size, child_table_size);
- for (int32 i = 0; i < table_size; i++) {
+ for (int32_t i = 0; i < table_size; i++) {
ASSERT_EQ(table[i], child_table[i]);
}
@@ -593,7 +597,7 @@ class VisitRelayingRenderProcessHost : public MockRenderProcessHost {
if (msg->type() == ChromeViewMsg_VisitedLink_Add::ID) {
base::PickleIterator iter(*msg);
- std::vector<uint64> fingerprints;
+ std::vector<uint64_t> fingerprints;
CHECK(IPC::ReadParam(msg, &iter, &fingerprints));
counting_context->CountAddEvent(fingerprints.size());
} else if (msg->type() == ChromeViewMsg_VisitedLink_Reset::ID) {
diff --git a/components/wallpaper/wallpaper_manager_base.h b/components/wallpaper/wallpaper_manager_base.h
index a022da7..5f75e00 100644
--- a/components/wallpaper/wallpaper_manager_base.h
+++ b/components/wallpaper/wallpaper_manager_base.h
@@ -5,12 +5,15 @@
#ifndef COMPONENTS_WALLPAPER_WALLPAPER_MANAGER_BASE_H_
#define COMPONENTS_WALLPAPER_WALLPAPER_MANAGER_BASE_H_
+#include <stddef.h>
+
#include <deque>
#include <map>
#include <string>
#include <vector>
#include "base/files/file_path.h"
+#include "base/macros.h"
#include "base/memory/ref_counted_memory.h"
#include "base/memory/scoped_ptr.h"
#include "base/memory/weak_ptr.h"
diff --git a/components/wallpaper/wallpaper_resizer.h b/components/wallpaper/wallpaper_resizer.h
index 21fb7db..658f7bb 100644
--- a/components/wallpaper/wallpaper_resizer.h
+++ b/components/wallpaper/wallpaper_resizer.h
@@ -5,6 +5,9 @@
#ifndef COMPONENTS_WALLPAPER_WALLPAPER_RESIZER_H_
#define COMPONENTS_WALLPAPER_WALLPAPER_RESIZER_H_
+#include <stdint.h>
+
+#include "base/macros.h"
#include "base/memory/weak_ptr.h"
#include "base/observer_list.h"
#include "components/wallpaper/wallpaper_layout.h"
diff --git a/components/wallpaper/wallpaper_resizer_unittest.cc b/components/wallpaper/wallpaper_resizer_unittest.cc
index edf3829..809c0ab 100644
--- a/components/wallpaper/wallpaper_resizer_unittest.cc
+++ b/components/wallpaper/wallpaper_resizer_unittest.cc
@@ -2,6 +2,9 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
+#include <stdint.h>
+
+#include "base/macros.h"
#include "base/message_loop/message_loop.h"
#include "base/test/sequenced_worker_pool_owner.h"
#include "components/wallpaper/wallpaper_resizer.h"
diff --git a/components/web_cache/browser/web_cache_manager.cc b/components/web_cache/browser/web_cache_manager.cc
index 3972ea5..7d43b45 100644
--- a/components/web_cache/browser/web_cache_manager.cc
+++ b/components/web_cache/browser/web_cache_manager.cc
@@ -4,6 +4,8 @@
#include "components/web_cache/browser/web_cache_manager.h"
+#include <string.h>
+
#include <algorithm>
#include "base/bind.h"
diff --git a/components/web_cache/browser/web_cache_manager.h b/components/web_cache/browser/web_cache_manager.h
index 230d6fd..2d6d300 100644
--- a/components/web_cache/browser/web_cache_manager.h
+++ b/components/web_cache/browser/web_cache_manager.h
@@ -8,13 +8,15 @@
#ifndef COMPONENTS_WEB_CACHE_BROWSER_WEB_CACHE_MANAGER_H_
#define COMPONENTS_WEB_CACHE_BROWSER_WEB_CACHE_MANAGER_H_
+#include <stddef.h>
+
#include <list>
#include <map>
#include <set>
-#include "base/basictypes.h"
#include "base/compiler_specific.h"
#include "base/gtest_prod_util.h"
+#include "base/macros.h"
#include "base/memory/weak_ptr.h"
#include "base/time/time.h"
#include "content/public/browser/notification_observer.h"
diff --git a/components/web_cache/browser/web_cache_manager_unittest.cc b/components/web_cache/browser/web_cache_manager_unittest.cc
index bc8bcbd..826552e 100644
--- a/components/web_cache/browser/web_cache_manager_unittest.cc
+++ b/components/web_cache/browser/web_cache_manager_unittest.cc
@@ -2,6 +2,8 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
+#include <stddef.h>
+
#include <string>
#include "base/message_loop/message_loop.h"
diff --git a/components/web_cache/common/web_cache_messages.h b/components/web_cache/common/web_cache_messages.h
index a521399..5ff9f25 100644
--- a/components/web_cache/common/web_cache_messages.h
+++ b/components/web_cache/common/web_cache_messages.h
@@ -3,6 +3,9 @@
// found in the LICENSE file.
// Multiply-included file, no traditional include guard.
+
+#include <stddef.h>
+
#include "ipc/ipc_message_macros.h"
#include "ipc/ipc_message_utils.h"
diff --git a/components/web_cache/renderer/web_cache_render_process_observer.h b/components/web_cache/renderer/web_cache_render_process_observer.h
index 06ffc53..6ae6916 100644
--- a/components/web_cache/renderer/web_cache_render_process_observer.h
+++ b/components/web_cache/renderer/web_cache_render_process_observer.h
@@ -5,6 +5,8 @@
#ifndef COMPONENTS_WEB_CACHE_RENDERER_WEB_CACHE_RENDER_PROCESS_OBSERVER_H_
#define COMPONENTS_WEB_CACHE_RENDERER_WEB_CACHE_RENDER_PROCESS_OBSERVER_H_
+#include <stddef.h>
+
#include "base/compiler_specific.h"
#include "base/macros.h"
#include "content/public/renderer/render_process_observer.h"
diff --git a/components/web_contents_delegate_android/color_chooser_android.cc b/components/web_contents_delegate_android/color_chooser_android.cc
index 984f3f9..838be6c 100644
--- a/components/web_contents_delegate_android/color_chooser_android.cc
+++ b/components/web_contents_delegate_android/color_chooser_android.cc
@@ -4,6 +4,8 @@
#include "components/web_contents_delegate_android/color_chooser_android.h"
+#include <stddef.h>
+
#include "base/android/jni_array.h"
#include "base/android/jni_string.h"
#include "content/public/browser/android/content_view_core.h"
diff --git a/components/web_contents_delegate_android/color_chooser_android.h b/components/web_contents_delegate_android/color_chooser_android.h
index d59c491..ebc4c7c 100644
--- a/components/web_contents_delegate_android/color_chooser_android.h
+++ b/components/web_contents_delegate_android/color_chooser_android.h
@@ -6,9 +6,10 @@
#define COMPONENTS_WEB_CONTENTS_DELEGATE_ANDROID_COLOR_CHOOSER_ANDROID_H_
#include <vector>
+
#include "base/android/jni_android.h"
-#include "base/basictypes.h"
#include "base/compiler_specific.h"
+#include "base/macros.h"
#include "base/strings/string16.h"
#include "content/public/browser/color_chooser.h"
diff --git a/components/web_contents_delegate_android/component_jni_registrar.cc b/components/web_contents_delegate_android/component_jni_registrar.cc
index 3d1bc60..7a3c8dd 100644
--- a/components/web_contents_delegate_android/component_jni_registrar.cc
+++ b/components/web_contents_delegate_android/component_jni_registrar.cc
@@ -6,6 +6,7 @@
#include "base/android/jni_android.h"
#include "base/android/jni_registrar.h"
+#include "base/macros.h"
#include "components/web_contents_delegate_android/color_chooser_android.h"
#include "components/web_contents_delegate_android/validation_message_bubble_android.h"
#include "components/web_contents_delegate_android/web_contents_delegate_android.h"
diff --git a/components/web_contents_delegate_android/web_contents_delegate_android.cc b/components/web_contents_delegate_android/web_contents_delegate_android.cc
index b535eb3..6a6558e 100644
--- a/components/web_contents_delegate_android/web_contents_delegate_android.cc
+++ b/components/web_contents_delegate_android/web_contents_delegate_android.cc
@@ -95,8 +95,7 @@ WebContents* WebContentsDelegateAndroid::OpenURLFromTab(
params.browser_initiated_post_data.get() &&
params.browser_initiated_post_data.get()->size()) {
post_data = base::android::ToJavaByteArray(
- env,
- params.browser_initiated_post_data.get()->front_as<uint8>(),
+ env, params.browser_initiated_post_data.get()->front_as<uint8_t>(),
params.browser_initiated_post_data.get()->size());
}
Java_WebContentsDelegateAndroid_openNewTab(env,
@@ -282,9 +281,9 @@ void WebContentsDelegateAndroid::MoveContents(WebContents* source,
bool WebContentsDelegateAndroid::AddMessageToConsole(
WebContents* source,
- int32 level,
+ int32_t level,
const base::string16& message,
- int32 line_no,
+ int32_t line_no,
const base::string16& source_id) {
JNIEnv* env = AttachCurrentThread();
ScopedJavaLocalRef<jobject> obj = GetJavaDelegate(env);
diff --git a/components/web_contents_delegate_android/web_contents_delegate_android.h b/components/web_contents_delegate_android/web_contents_delegate_android.h
index 2f22cac..1105673 100644
--- a/components/web_contents_delegate_android/web_contents_delegate_android.h
+++ b/components/web_contents_delegate_android/web_contents_delegate_android.h
@@ -5,6 +5,8 @@
#ifndef COMPONENTS_WEB_CONTENTS_DELEGATE_ANDROID_WEB_CONTENTS_DELEGATE_ANDROID_H_
#define COMPONENTS_WEB_CONTENTS_DELEGATE_ANDROID_WEB_CONTENTS_DELEGATE_ANDROID_H_
+#include <stdint.h>
+
#include "base/android/jni_weak_ref.h"
#include "base/android/scoped_java_ref.h"
#include "base/compiler_specific.h"
@@ -88,9 +90,9 @@ class WebContentsDelegateAndroid : public content::WebContentsDelegate {
void MoveContents(content::WebContents* source,
const gfx::Rect& pos) override;
bool AddMessageToConsole(content::WebContents* source,
- int32 level,
+ int32_t level,
const base::string16& message,
- int32 line_no,
+ int32_t line_no,
const base::string16& source_id) override;
void UpdateTargetURL(content::WebContents* source, const GURL& url) override;
void HandleKeyboardEvent(
diff --git a/components/web_modal/single_web_contents_dialog_manager.h b/components/web_modal/single_web_contents_dialog_manager.h
index e222232..7d85368 100644
--- a/components/web_modal/single_web_contents_dialog_manager.h
+++ b/components/web_modal/single_web_contents_dialog_manager.h
@@ -5,6 +5,7 @@
#ifndef COMPONENTS_WEB_MODAL_SINGLE_WEB_CONTENTS_DIALOG_MANAGER_H_
#define COMPONENTS_WEB_MODAL_SINGLE_WEB_CONTENTS_DIALOG_MANAGER_H_
+#include "base/macros.h"
#include "ui/gfx/native_widget_types.h"
namespace content {
diff --git a/components/web_modal/test_web_contents_modal_dialog_host.h b/components/web_modal/test_web_contents_modal_dialog_host.h
index 28c7c2f..8348f68 100644
--- a/components/web_modal/test_web_contents_modal_dialog_host.h
+++ b/components/web_modal/test_web_contents_modal_dialog_host.h
@@ -7,8 +7,8 @@
#include "components/web_modal/web_contents_modal_dialog_host.h"
-#include "base/basictypes.h"
#include "base/compiler_specific.h"
+#include "base/macros.h"
#include "ui/gfx/geometry/size.h"
#include "ui/gfx/native_widget_types.h"
diff --git a/components/web_modal/test_web_contents_modal_dialog_manager_delegate.h b/components/web_modal/test_web_contents_modal_dialog_manager_delegate.h
index 2abb386..8221424 100644
--- a/components/web_modal/test_web_contents_modal_dialog_manager_delegate.h
+++ b/components/web_modal/test_web_contents_modal_dialog_manager_delegate.h
@@ -7,8 +7,8 @@
#include "components/web_modal/web_contents_modal_dialog_manager_delegate.h"
-#include "base/basictypes.h"
#include "base/compiler_specific.h"
+#include "base/macros.h"
namespace web_modal {
diff --git a/components/web_modal/web_contents_modal_dialog_manager.h b/components/web_modal/web_contents_modal_dialog_manager.h
index 07a0da2..f5d50111 100644
--- a/components/web_modal/web_contents_modal_dialog_manager.h
+++ b/components/web_modal/web_contents_modal_dialog_manager.h
@@ -7,6 +7,7 @@
#include <deque>
+#include "base/macros.h"
#include "base/memory/scoped_ptr.h"
#include "components/web_modal/single_web_contents_dialog_manager.h"
#include "content/public/browser/web_contents_observer.h"
diff --git a/components/web_modal/web_contents_modal_dialog_manager_unittest.cc b/components/web_modal/web_contents_modal_dialog_manager_unittest.cc
index 3afafff..c103c20 100644
--- a/components/web_modal/web_contents_modal_dialog_manager_unittest.cc
+++ b/components/web_modal/web_contents_modal_dialog_manager_unittest.cc
@@ -6,6 +6,7 @@
#include <map>
+#include "base/macros.h"
#include "base/memory/scoped_ptr.h"
#include "components/web_modal/single_web_contents_dialog_manager.h"
#include "components/web_modal/test_web_contents_modal_dialog_manager_delegate.h"
diff --git a/components/web_resource/eula_accepted_notifier.cc b/components/web_resource/eula_accepted_notifier.cc
index 8faa234..b4ff13f 100644
--- a/components/web_resource/eula_accepted_notifier.cc
+++ b/components/web_resource/eula_accepted_notifier.cc
@@ -7,6 +7,7 @@
#include "base/bind.h"
#include "base/logging.h"
#include "base/prefs/pref_service.h"
+#include "build/build_config.h"
#include "components/web_resource/web_resource_pref_names.h"
namespace web_resource {
diff --git a/components/web_resource/eula_accepted_notifier.h b/components/web_resource/eula_accepted_notifier.h
index 552b53c..6a05b06 100644
--- a/components/web_resource/eula_accepted_notifier.h
+++ b/components/web_resource/eula_accepted_notifier.h
@@ -5,7 +5,7 @@
#ifndef COMPONENTS_WEB_RESOURCE_EULA_ACCEPTED_NOTIFIER_H_
#define COMPONENTS_WEB_RESOURCE_EULA_ACCEPTED_NOTIFIER_H_
-#include "base/basictypes.h"
+#include "base/macros.h"
#include "base/prefs/pref_change_registrar.h"
class PrefService;
diff --git a/components/web_resource/eula_accepted_notifier_unittest.cc b/components/web_resource/eula_accepted_notifier_unittest.cc
index f0374d5..b88156f 100644
--- a/components/web_resource/eula_accepted_notifier_unittest.cc
+++ b/components/web_resource/eula_accepted_notifier_unittest.cc
@@ -4,6 +4,7 @@
#include "components/web_resource/eula_accepted_notifier.h"
+#include "base/macros.h"
#include "base/prefs/pref_registry_simple.h"
#include "base/prefs/testing_pref_service.h"
#include "components/web_resource/web_resource_pref_names.h"
diff --git a/components/web_resource/notification_promo.cc b/components/web_resource/notification_promo.cc
index 73e7d4b..f0e9e71 100644
--- a/components/web_resource/notification_promo.cc
+++ b/components/web_resource/notification_promo.cc
@@ -4,10 +4,13 @@
#include "components/web_resource/notification_promo.h"
+#include <stddef.h>
+
#include <cmath>
#include <vector>
#include "base/bind.h"
+#include "base/macros.h"
#include "base/prefs/pref_registry_simple.h"
#include "base/prefs/pref_service.h"
#include "base/rand_util.h"
@@ -17,6 +20,7 @@
#include "base/threading/thread_restrictions.h"
#include "base/time/time.h"
#include "base/values.h"
+#include "build/build_config.h"
#include "components/pref_registry/pref_registry_syncable.h"
#include "components/version_info/version_info.h"
#include "components/web_resource/promo_resource_service.h"
diff --git a/components/web_resource/notification_promo.h b/components/web_resource/notification_promo.h
index 213f404..f26bcae 100644
--- a/components/web_resource/notification_promo.h
+++ b/components/web_resource/notification_promo.h
@@ -7,7 +7,7 @@
#include <string>
-#include "base/basictypes.h"
+#include "base/macros.h"
#include "base/memory/ref_counted.h"
#include "base/memory/scoped_ptr.h"
#include "url/gurl.h"
diff --git a/components/web_resource/notification_promo_mobile_ntp.h b/components/web_resource/notification_promo_mobile_ntp.h
index 29bbf1e..510e2e3 100644
--- a/components/web_resource/notification_promo_mobile_ntp.h
+++ b/components/web_resource/notification_promo_mobile_ntp.h
@@ -7,7 +7,7 @@
#include <string>
-#include "base/basictypes.h"
+#include "base/macros.h"
#include "components/web_resource/notification_promo.h"
namespace base {
diff --git a/components/web_resource/promo_resource_service.cc b/components/web_resource/promo_resource_service.cc
index 6c23da2..6d3f6a7d 100644
--- a/components/web_resource/promo_resource_service.cc
+++ b/components/web_resource/promo_resource_service.cc
@@ -4,15 +4,19 @@
#include "components/web_resource/promo_resource_service.h"
+#include <stddef.h>
+
#include "base/bind.h"
#include "base/command_line.h"
#include "base/location.h"
+#include "base/macros.h"
#include "base/prefs/pref_registry_simple.h"
#include "base/prefs/pref_service.h"
#include "base/single_thread_task_runner.h"
#include "base/thread_task_runner_handle.h"
#include "base/threading/thread_restrictions.h"
#include "base/values.h"
+#include "build/build_config.h"
#include "components/pref_registry/pref_registry_syncable.h"
#include "components/web_resource/notification_promo.h"
#include "components/web_resource/web_resource_pref_names.h"
@@ -118,10 +122,10 @@ void PromoResourceService::ScheduleNotification(
const double promo_end = notification_promo.EndTime();
if (promo_start > 0 && promo_end > 0) {
- const int64 ms_until_start = static_cast<int64>(
+ const int64_t ms_until_start = static_cast<int64_t>(
(base::Time::FromDoubleT(promo_start) - base::Time::Now())
.InMilliseconds());
- const int64 ms_until_end = static_cast<int64>(
+ const int64_t ms_until_end = static_cast<int64_t>(
(base::Time::FromDoubleT(promo_end) - base::Time::Now())
.InMilliseconds());
if (ms_until_start > 0) {
@@ -154,7 +158,7 @@ void PromoResourceService::ScheduleNotificationOnInit() {
}
}
-void PromoResourceService::PostNotification(int64 delay_ms) {
+void PromoResourceService::PostNotification(int64_t delay_ms) {
// Note that this could cause re-issuing a notification every time
// we receive an update from a server if something goes wrong.
// Given that this couldn't happen more frequently than every
diff --git a/components/web_resource/promo_resource_service.h b/components/web_resource/promo_resource_service.h
index d36e07d..438f0da 100644
--- a/components/web_resource/promo_resource_service.h
+++ b/components/web_resource/promo_resource_service.h
@@ -5,10 +5,13 @@
#ifndef COMPONENTS_WEB_RESOURCE_PROMO_RESOURCE_SERVICE_H_
#define COMPONENTS_WEB_RESOURCE_PROMO_RESOURCE_SERVICE_H_
+#include <stdint.h>
+
#include <string>
#include "base/callback_forward.h"
#include "base/callback_list.h"
+#include "base/macros.h"
#include "base/memory/weak_ptr.h"
#include "components/web_resource/web_resource_service.h"
@@ -71,7 +74,7 @@ class PromoResourceService : public WebResourceService {
// If delay_ms is positive, schedule notification with the delay.
// If delay_ms is 0, notify immediately by calling WebResourceStateChange().
// If delay_ms is negative, do nothing.
- void PostNotification(int64 delay_ms);
+ void PostNotification(int64_t delay_ms);
// Notify listeners that the state of a web resource has changed.
void PromoResourceStateChange();
diff --git a/components/web_resource/promo_resource_service_mobile_ntp_unittest.cc b/components/web_resource/promo_resource_service_mobile_ntp_unittest.cc
index 760b7eb..e7387bc 100644
--- a/components/web_resource/promo_resource_service_mobile_ntp_unittest.cc
+++ b/components/web_resource/promo_resource_service_mobile_ntp_unittest.cc
@@ -2,6 +2,8 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
+#include <stddef.h>
+
#include <vector>
#include "base/json/json_reader.h"
diff --git a/components/web_resource/promo_resource_service_unittest.cc b/components/web_resource/promo_resource_service_unittest.cc
index 4fe7a73..1e07b1a 100644
--- a/components/web_resource/promo_resource_service_unittest.cc
+++ b/components/web_resource/promo_resource_service_unittest.cc
@@ -2,6 +2,8 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
+#include <stddef.h>
+
#include <utility>
#include <vector>
diff --git a/components/web_resource/resource_request_allowed_notifier.h b/components/web_resource/resource_request_allowed_notifier.h
index 890e700c5..aa80b1a 100644
--- a/components/web_resource/resource_request_allowed_notifier.h
+++ b/components/web_resource/resource_request_allowed_notifier.h
@@ -5,6 +5,7 @@
#ifndef COMPONENTS_WEB_RESOURCE_RESOURCE_REQUEST_ALLOWED_NOTIFIER_H_
#define COMPONENTS_WEB_RESOURCE_RESOURCE_REQUEST_ALLOWED_NOTIFIER_H_
+#include "base/macros.h"
#include "components/web_resource/eula_accepted_notifier.h"
#include "net/base/network_change_notifier.h"
diff --git a/components/web_resource/resource_request_allowed_notifier_test_util.h b/components/web_resource/resource_request_allowed_notifier_test_util.h
index efae951..e1c3d1e 100644
--- a/components/web_resource/resource_request_allowed_notifier_test_util.h
+++ b/components/web_resource/resource_request_allowed_notifier_test_util.h
@@ -5,6 +5,7 @@
#ifndef COMPONENTS_WEB_RESOURCE_RESOURCE_REQUEST_ALLOWED_NOTIFIER_TEST_UTIL_H_
#define COMPONENTS_WEB_RESOURCE_RESOURCE_REQUEST_ALLOWED_NOTIFIER_TEST_UTIL_H_
+#include "base/macros.h"
#include "base/memory/scoped_ptr.h"
#include "components/web_resource/resource_request_allowed_notifier.h"
diff --git a/components/web_resource/resource_request_allowed_notifier_unittest.cc b/components/web_resource/resource_request_allowed_notifier_unittest.cc
index 3383c8b..557faff 100644
--- a/components/web_resource/resource_request_allowed_notifier_unittest.cc
+++ b/components/web_resource/resource_request_allowed_notifier_unittest.cc
@@ -2,6 +2,7 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
+#include "base/macros.h"
#include "base/prefs/testing_pref_service.h"
#include "components/web_resource/eula_accepted_notifier.h"
#include "components/web_resource/resource_request_allowed_notifier_test_util.h"
diff --git a/components/web_resource/web_resource_service.cc b/components/web_resource/web_resource_service.cc
index 1afd22e..d7fa9fb 100644
--- a/components/web_resource/web_resource_service.cc
+++ b/components/web_resource/web_resource_service.cc
@@ -97,7 +97,7 @@ void WebResourceService::OnURLFetchComplete(const net::URLFetcher* source) {
// Delay initial load of resource data into cache so as not to interfere
// with startup time.
-void WebResourceService::ScheduleFetch(int64 delay_ms) {
+void WebResourceService::ScheduleFetch(int64_t delay_ms) {
base::ThreadTaskRunnerHandle::Get()->PostDelayedTask(
FROM_HERE, base::Bind(&WebResourceService::StartFetch,
weak_ptr_factory_.GetWeakPtr()),
@@ -163,7 +163,7 @@ void WebResourceService::OnUnpackError(const std::string& error_message) {
}
void WebResourceService::OnResourceRequestsAllowed() {
- int64 delay = start_fetch_delay_ms_;
+ int64_t delay = start_fetch_delay_ms_;
// Check whether we have ever put a value in the web resource cache;
// if so, pull it out and see if it's time to update again.
if (prefs_->HasPrefPath(last_update_time_pref_name_)) {
@@ -172,9 +172,9 @@ void WebResourceService::OnResourceRequestsAllowed() {
if (!last_update_pref.empty()) {
double last_update_value;
base::StringToDouble(last_update_pref, &last_update_value);
- int64 ms_until_update =
+ int64_t ms_until_update =
cache_update_delay_ms_ -
- static_cast<int64>(
+ static_cast<int64_t>(
(base::Time::Now() - base::Time::FromDoubleT(last_update_value))
.InMilliseconds());
// Wait at least |start_fetch_delay_ms_|.
diff --git a/components/web_resource/web_resource_service.h b/components/web_resource/web_resource_service.h
index 85cd899..b6ad154 100644
--- a/components/web_resource/web_resource_service.h
+++ b/components/web_resource/web_resource_service.h
@@ -5,9 +5,12 @@
#ifndef COMPONENTS_WEB_RESOURCE_WEB_RESOURCE_SERVICE_H_
#define COMPONENTS_WEB_RESOURCE_WEB_RESOURCE_SERVICE_H_
+#include <stdint.h>
+
#include <string>
#include "base/callback_forward.h"
+#include "base/macros.h"
#include "base/memory/ref_counted.h"
#include "base/memory/scoped_ptr.h"
#include "base/memory/weak_ptr.h"
@@ -72,7 +75,7 @@ class WebResourceService
void OnURLFetchComplete(const net::URLFetcher* source) override;
// Schedules a fetch after |delay_ms| milliseconds.
- void ScheduleFetch(int64 delay_ms);
+ void ScheduleFetch(int64_t delay_ms);
// Starts fetching data from the server.
void StartFetch();
diff --git a/components/web_view/client_initiated_frame_connection.h b/components/web_view/client_initiated_frame_connection.h
index 6ad1980..1b65b5c 100644
--- a/components/web_view/client_initiated_frame_connection.h
+++ b/components/web_view/client_initiated_frame_connection.h
@@ -5,7 +5,7 @@
#ifndef COMPONENTS_WEB_VIEW_CLIENT_INITIATED_FRAME_CONNECTION_H_
#define COMPONENTS_WEB_VIEW_CLIENT_INITIATED_FRAME_CONNECTION_H_
-#include "base/basictypes.h"
+#include "base/macros.h"
#include "components/web_view/frame_user_data.h"
#include "components/web_view/public/interfaces/frame.mojom.h"
diff --git a/components/web_view/find_controller.h b/components/web_view/find_controller.h
index cb17a9f..8250079 100644
--- a/components/web_view/find_controller.h
+++ b/components/web_view/find_controller.h
@@ -5,9 +5,11 @@
#ifndef COMPONENTS_WEB_VIEW_FIND_CONTROLLER_H_
#define COMPONENTS_WEB_VIEW_FIND_CONTROLLER_H_
+#include <stdint.h>
+
#include <vector>
-#include "base/basictypes.h"
+#include "base/macros.h"
#include "base/memory/weak_ptr.h"
#include "components/web_view/local_find_options.h"
#include "components/web_view/public/interfaces/web_view.mojom.h"
diff --git a/components/web_view/frame.cc b/components/web_view/frame.cc
index 090a52a..37690f3 100644
--- a/components/web_view/frame.cc
+++ b/components/web_view/frame.cc
@@ -4,6 +4,8 @@
#include "components/web_view/frame.h"
+#include <stddef.h>
+
#include <algorithm>
#include "base/auto_reset.h"
@@ -164,7 +166,7 @@ double Frame::GatherProgress(int* frame_count) const {
return progress_;
}
-void Frame::Find(int32 request_id,
+void Frame::Find(int32_t request_id,
const mojo::String& search_text,
mojom::FindOptionsPtr options,
bool wrap_within_frame,
@@ -292,7 +294,7 @@ void Frame::OnWillNavigateAck(
mojom::FrameClient* frame_client,
scoped_ptr<FrameUserData> user_data,
mus::mojom::WindowTreeClientPtr window_tree_client,
- uint32 app_id,
+ uint32_t app_id,
base::TimeTicks navigation_start_time) {
DCHECK(waiting_for_on_will_navigate_ack_);
DVLOG(2) << "Frame::OnWillNavigateAck id=" << id_;
diff --git a/components/web_view/frame.h b/components/web_view/frame.h
index 3fa2ff3..ec7c6ca 100644
--- a/components/web_view/frame.h
+++ b/components/web_view/frame.h
@@ -5,10 +5,12 @@
#ifndef COMPONENTS_WEB_VIEW_FRAME_H_
#define COMPONENTS_WEB_VIEW_FRAME_H_
+#include <stdint.h>
+
#include <map>
#include <vector>
-#include "base/basictypes.h"
+#include "base/macros.h"
#include "base/memory/scoped_ptr.h"
#include "base/time/time.h"
#include "components/mus/common/types.h"
@@ -176,7 +178,7 @@ class Frame : public mus::WindowObserver, public mojom::Frame {
void OnWillNavigateAck(mojom::FrameClient* frame_client,
scoped_ptr<FrameUserData> user_data,
mus::mojom::WindowTreeClientPtr window_tree_client,
- uint32 app_id,
+ uint32_t app_id,
base::TimeTicks navigation_start_time);
// Completes a navigation request; swapping the existing FrameClient to the
@@ -184,7 +186,7 @@ class Frame : public mus::WindowObserver, public mojom::Frame {
void ChangeClient(mojom::FrameClient* frame_client,
scoped_ptr<FrameUserData> user_data,
mus::mojom::WindowTreeClientPtr window_tree_client,
- uint32 app_id,
+ uint32_t app_id,
base::TimeTicks navigation_start_time);
void SetWindow(mus::Window* window);
diff --git a/components/web_view/frame_apptest.cc b/components/web_view/frame_apptest.cc
index d25d56e..0b8aca9 100644
--- a/components/web_view/frame_apptest.cc
+++ b/components/web_view/frame_apptest.cc
@@ -4,13 +4,17 @@
#include "components/web_view/frame.h"
+#include <stdint.h>
+
#include "base/bind.h"
#include "base/location.h"
#include "base/logging.h"
+#include "base/macros.h"
#include "base/message_loop/message_loop.h"
#include "base/run_loop.h"
#include "base/test/test_timeouts.h"
#include "base/time/time.h"
+#include "build/build_config.h"
#include "components/mus/public/cpp/window_observer.h"
#include "components/mus/public/cpp/window_tree_connection.h"
#include "components/mus/public/cpp/window_tree_delegate.h"
diff --git a/components/web_view/frame_connection.cc b/components/web_view/frame_connection.cc
index 4d40337..afb973d 100644
--- a/components/web_view/frame_connection.cc
+++ b/components/web_view/frame_connection.cc
@@ -6,6 +6,7 @@
#include "base/bind.h"
#include "base/callback.h"
+#include "build/build_config.h"
#include "components/clipboard/public/interfaces/clipboard.mojom.h"
#include "components/mus/public/interfaces/gpu.mojom.h"
#include "components/mus/public/interfaces/window_tree_host.mojom.h"
diff --git a/components/web_view/frame_connection.h b/components/web_view/frame_connection.h
index 1d52fb0..c78acfb 100644
--- a/components/web_view/frame_connection.h
+++ b/components/web_view/frame_connection.h
@@ -5,8 +5,10 @@
#ifndef COMPONENTS_WEB_VIEW_FRAME_CONNECTION_H_
#define COMPONENTS_WEB_VIEW_FRAME_CONNECTION_H_
-#include "base/basictypes.h"
+#include <stdint.h>
+
#include "base/callback.h"
+#include "base/macros.h"
#include "base/memory/scoped_ptr.h"
#include "components/mus/public/interfaces/window_tree.mojom.h"
#include "components/web_view/frame_tree_delegate.h"
diff --git a/components/web_view/frame_devtools_agent.cc b/components/web_view/frame_devtools_agent.cc
index a9bceeb..54c11a0 100644
--- a/components/web_view/frame_devtools_agent.cc
+++ b/components/web_view/frame_devtools_agent.cc
@@ -12,6 +12,7 @@
#include "base/guid.h"
#include "base/json/json_reader.h"
#include "base/logging.h"
+#include "base/macros.h"
#include "base/values.h"
#include "components/web_view/frame_devtools_agent_delegate.h"
#include "mojo/application/public/cpp/application_impl.h"
diff --git a/components/web_view/frame_devtools_agent.h b/components/web_view/frame_devtools_agent.h
index deaa2f1..13686f0 100644
--- a/components/web_view/frame_devtools_agent.h
+++ b/components/web_view/frame_devtools_agent.h
@@ -5,6 +5,8 @@
#ifndef COMPONENTS_WEB_VIEW_FRAME_DEVTOOLS_AGENT_H_
#define COMPONENTS_WEB_VIEW_FRAME_DEVTOOLS_AGENT_H_
+#include <stdint.h>
+
#include <map>
#include <string>
diff --git a/components/web_view/frame_tree.h b/components/web_view/frame_tree.h
index ae7f1b8..56b28c7 100644
--- a/components/web_view/frame_tree.h
+++ b/components/web_view/frame_tree.h
@@ -5,6 +5,9 @@
#ifndef COMPONENTS_WEB_VIEW_FRAME_TREE_H_
#define COMPONENTS_WEB_VIEW_FRAME_TREE_H_
+#include <stdint.h>
+
+#include "base/macros.h"
#include "base/time/time.h"
#include "components/mus/public/interfaces/window_tree.mojom.h"
#include "components/web_view/frame.h"
diff --git a/components/web_view/frame_tree_delegate.h b/components/web_view/frame_tree_delegate.h
index 55c3315..1b1b6cf 100644
--- a/components/web_view/frame_tree_delegate.h
+++ b/components/web_view/frame_tree_delegate.h
@@ -5,6 +5,8 @@
#ifndef COMPONENTS_WEB_VIEW_FRAME_TREE_DELEGATE_H_
#define COMPONENTS_WEB_VIEW_FRAME_TREE_DELEGATE_H_
+#include <stdint.h>
+
#include <string>
#include "base/callback_forward.h"
diff --git a/components/web_view/navigation_controller.h b/components/web_view/navigation_controller.h
index 635dfe5..519d583 100644
--- a/components/web_view/navigation_controller.h
+++ b/components/web_view/navigation_controller.h
@@ -7,6 +7,7 @@
#include "base/memory/scoped_vector.h"
+#include "base/macros.h"
#include "components/web_view/public/interfaces/web_view.mojom.h"
#include "url/gurl.h"
diff --git a/components/web_view/navigation_entry.h b/components/web_view/navigation_entry.h
index 2e5f6a1..fbb24ab 100644
--- a/components/web_view/navigation_entry.h
+++ b/components/web_view/navigation_entry.h
@@ -7,6 +7,7 @@
#include "components/web_view/url_request_cloneable.h"
+#include "base/macros.h"
#include "url/gurl.h"
namespace web_view {
diff --git a/components/web_view/pending_web_view_load.h b/components/web_view/pending_web_view_load.h
index b7070bd..ac8415b 100644
--- a/components/web_view/pending_web_view_load.h
+++ b/components/web_view/pending_web_view_load.h
@@ -7,6 +7,7 @@
#include <string>
+#include "base/macros.h"
#include "base/memory/scoped_ptr.h"
#include "base/time/time.h"
#include "mojo/services/network/public/interfaces/url_loader.mojom.h"
diff --git a/components/web_view/public/cpp/web_view.cc b/components/web_view/public/cpp/web_view.cc
index 0aee765..e8f581d 100644
--- a/components/web_view/public/cpp/web_view.cc
+++ b/components/web_view/public/cpp/web_view.cc
@@ -4,6 +4,8 @@
#include "components/web_view/public/cpp/web_view.h"
+#include <stdint.h>
+
#include "base/bind.h"
#include "components/mus/public/cpp/window.h"
#include "mojo/application/public/cpp/application_impl.h"
@@ -11,7 +13,7 @@
namespace web_view {
namespace {
-void OnEmbed(bool success, uint16 connection_id) {
+void OnEmbed(bool success, uint16_t connection_id) {
CHECK(success);
}
diff --git a/components/web_view/test_frame_tree_delegate.h b/components/web_view/test_frame_tree_delegate.h
index 21cb581..7506678 100644
--- a/components/web_view/test_frame_tree_delegate.h
+++ b/components/web_view/test_frame_tree_delegate.h
@@ -5,7 +5,7 @@
#ifndef COMPONENTS_WEB_VIEW_TEST_FRAME_TREE_DELEGATE_H_
#define COMPONENTS_WEB_VIEW_TEST_FRAME_TREE_DELEGATE_H_
-#include "base/basictypes.h"
+#include "base/macros.h"
#include "base/memory/scoped_ptr.h"
#include "components/web_view/frame_tree_delegate.h"
diff --git a/components/web_view/test_runner/test_runner_application_delegate.cc b/components/web_view/test_runner/test_runner_application_delegate.cc
index 2131441..b2b2584 100644
--- a/components/web_view/test_runner/test_runner_application_delegate.cc
+++ b/components/web_view/test_runner/test_runner_application_delegate.cc
@@ -15,6 +15,7 @@
#include "base/path_service.h"
#include "base/thread_task_runner_handle.h"
#include "base/threading/thread_restrictions.h"
+#include "build/build_config.h"
#include "components/mus/public/cpp/scoped_window_ptr.h"
#include "components/mus/public/cpp/window.h"
#include "components/mus/public/cpp/window_tree_connection.h"
diff --git a/components/web_view/test_runner/test_runner_application_delegate.h b/components/web_view/test_runner/test_runner_application_delegate.h
index 5867ffe..49a0ee1 100644
--- a/components/web_view/test_runner/test_runner_application_delegate.h
+++ b/components/web_view/test_runner/test_runner_application_delegate.h
@@ -5,7 +5,10 @@
#ifndef COMPONENTS_WEB_VIEW__TEST_RUNNER_TEST_RUNNER_APPLICATION_DELEGATE_H_
#define COMPONENTS_WEB_VIEW__TEST_RUNNER_TEST_RUNNER_APPLICATION_DELEGATE_H_
+#include <stdint.h>
+
#include "base/command_line.h"
+#include "base/macros.h"
#include "base/memory/scoped_ptr.h"
#include "components/mus/public/cpp/window_tree_delegate.h"
#include "components/mus/public/interfaces/window_tree_host.mojom.h"
diff --git a/components/web_view/url_request_cloneable.cc b/components/web_view/url_request_cloneable.cc
index db601a5..c8e7446 100644
--- a/components/web_view/url_request_cloneable.cc
+++ b/components/web_view/url_request_cloneable.cc
@@ -4,6 +4,8 @@
#include "components/web_view/url_request_cloneable.h"
+#include <stddef.h>
+
#include "base/logging.h"
#include "mojo/common/data_pipe_utils.h"
#include "mojo/common/url_type_converters.h"
diff --git a/components/web_view/url_request_cloneable.h b/components/web_view/url_request_cloneable.h
index 18f3b3e..24948597 100644
--- a/components/web_view/url_request_cloneable.h
+++ b/components/web_view/url_request_cloneable.h
@@ -5,10 +5,12 @@
#ifndef COMPONENTS_WEB_VIEW_URL_REQUEST_CLONEABLE_H_
#define COMPONENTS_WEB_VIEW_URL_REQUEST_CLONEABLE_H_
+#include <stdint.h>
+
#include <string>
#include <vector>
-#include "base/basictypes.h"
+#include "base/macros.h"
#include "base/time/time.h"
#include "mojo/services/network/public/interfaces/url_loader.mojom.h"
#include "url/gurl.h"
diff --git a/components/web_view/web_view_apptest.cc b/components/web_view/web_view_apptest.cc
index f1453bd..de791f0 100644
--- a/components/web_view/web_view_apptest.cc
+++ b/components/web_view/web_view_apptest.cc
@@ -4,10 +4,13 @@
#include "components/web_view/public/cpp/web_view.h"
+#include <stdint.h>
+
#include "base/base_paths.h"
#include "base/files/file_path.h"
#include "base/files/file_util.h"
#include "base/logging.h"
+#include "base/macros.h"
#include "base/path_service.h"
#include "base/run_loop.h"
#include "components/mus/public/cpp/scoped_window_ptr.h"
diff --git a/components/web_view/web_view_impl.h b/components/web_view/web_view_impl.h
index 7647adc..28e6866 100644
--- a/components/web_view/web_view_impl.h
+++ b/components/web_view/web_view_impl.h
@@ -5,6 +5,8 @@
#ifndef COMPONENTS_WEB_VIEW_WEB_VIEW_IMPL_H_
#define COMPONENTS_WEB_VIEW_WEB_VIEW_IMPL_H_
+#include <stdint.h>
+
#include <deque>
#include <string>
diff --git a/components/webcrypto/algorithms/aes.cc b/components/webcrypto/algorithms/aes.cc
index 09dbfd4..7ba9a50 100644
--- a/components/webcrypto/algorithms/aes.cc
+++ b/components/webcrypto/algorithms/aes.cc
@@ -4,6 +4,8 @@
#include "components/webcrypto/algorithms/aes.h"
+#include <stddef.h>
+
#include "base/logging.h"
#include "components/webcrypto/algorithms/secret_key_util.h"
#include "components/webcrypto/blink_key_handle.h"
diff --git a/components/webcrypto/algorithms/aes.h b/components/webcrypto/algorithms/aes.h
index 62cc3b1..65b82d7 100644
--- a/components/webcrypto/algorithms/aes.h
+++ b/components/webcrypto/algorithms/aes.h
@@ -5,6 +5,8 @@
#ifndef COMPONENTS_WEBCRYPTO_ALGORITHMS_AES_H_
#define COMPONENTS_WEBCRYPTO_ALGORITHMS_AES_H_
+#include <stdint.h>
+
#include "components/webcrypto/algorithm_implementation.h"
namespace webcrypto {
diff --git a/components/webcrypto/algorithms/aes_cbc.cc b/components/webcrypto/algorithms/aes_cbc.cc
index 2cda785..5ac18bd 100644
--- a/components/webcrypto/algorithms/aes_cbc.cc
+++ b/components/webcrypto/algorithms/aes_cbc.cc
@@ -4,6 +4,8 @@
#include <openssl/aes.h>
#include <openssl/evp.h>
+#include <stddef.h>
+#include <stdint.h>
#include "base/logging.h"
#include "base/numerics/safe_math.h"
diff --git a/components/webcrypto/algorithms/aes_cbc_unittest.cc b/components/webcrypto/algorithms/aes_cbc_unittest.cc
index 7fe9409..26af37d 100644
--- a/components/webcrypto/algorithms/aes_cbc_unittest.cc
+++ b/components/webcrypto/algorithms/aes_cbc_unittest.cc
@@ -2,6 +2,10 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
+#include <stddef.h>
+#include <stdint.h>
+
+#include "base/macros.h"
#include "base/values.h"
#include "components/webcrypto/algorithm_dispatch.h"
#include "components/webcrypto/algorithms/test_helpers.h"
diff --git a/components/webcrypto/algorithms/aes_ctr.cc b/components/webcrypto/algorithms/aes_ctr.cc
index 39ca087..631d2ad 100644
--- a/components/webcrypto/algorithms/aes_ctr.cc
+++ b/components/webcrypto/algorithms/aes_ctr.cc
@@ -4,6 +4,9 @@
#include <openssl/aes.h>
#include <openssl/evp.h>
+#include <stddef.h>
+#include <stdint.h>
+#include <string.h>
#include "base/logging.h"
#include "base/macros.h"
diff --git a/components/webcrypto/algorithms/aes_ctr_unittest.cc b/components/webcrypto/algorithms/aes_ctr_unittest.cc
index 9668ca5..16edd20 100644
--- a/components/webcrypto/algorithms/aes_ctr_unittest.cc
+++ b/components/webcrypto/algorithms/aes_ctr_unittest.cc
@@ -2,6 +2,10 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
+#include <stddef.h>
+#include <stdint.h>
+
+#include "base/macros.h"
#include "base/values.h"
#include "components/webcrypto/algorithm_dispatch.h"
#include "components/webcrypto/algorithms/test_helpers.h"
@@ -73,7 +77,7 @@ TEST_F(WebCryptoAesCtrTest, InvalidCounterBlockLength) {
const unsigned int kBadCounterBlockLengthBytes[] = {0, 15, 17};
blink::WebCryptoKey key = ImportSecretKeyFromRaw(
- std::vector<uint8>(16), // 128-bit key of all zeros.
+ std::vector<uint8_t>(16), // 128-bit key of all zeros.
CreateAlgorithm(blink::WebCryptoAlgorithmIdAesCtr),
blink::WebCryptoKeyUsageEncrypt | blink::WebCryptoKeyUsageDecrypt);
@@ -98,7 +102,7 @@ TEST_F(WebCryptoAesCtrTest, InvalidCounterLength) {
const uint8_t kBadCounterLengthBits[] = {0, 129};
blink::WebCryptoKey key = ImportSecretKeyFromRaw(
- std::vector<uint8>(16), // 128-bit key of all zeros.
+ std::vector<uint8_t>(16), // 128-bit key of all zeros.
CreateAlgorithm(blink::WebCryptoAlgorithmIdAesCtr),
blink::WebCryptoKeyUsageEncrypt | blink::WebCryptoKeyUsageDecrypt);
@@ -131,7 +135,7 @@ TEST_F(WebCryptoAesCtrTest, OverflowAndRepeatCounter) {
const uint8_t kStartCounter[] = {0, 1, 15};
blink::WebCryptoKey key = ImportSecretKeyFromRaw(
- std::vector<uint8>(16), // 128-bit key of all zeros.
+ std::vector<uint8_t>(16), // 128-bit key of all zeros.
CreateAlgorithm(blink::WebCryptoAlgorithmIdAesCtr),
blink::WebCryptoKeyUsageEncrypt | blink::WebCryptoKeyUsageDecrypt);
diff --git a/components/webcrypto/algorithms/aes_gcm.cc b/components/webcrypto/algorithms/aes_gcm.cc
index 3685bd9..f8417f2 100644
--- a/components/webcrypto/algorithms/aes_gcm.cc
+++ b/components/webcrypto/algorithms/aes_gcm.cc
@@ -3,6 +3,8 @@
// found in the LICENSE file.
#include <openssl/evp.h>
+#include <stddef.h>
+#include <stdint.h>
#include <vector>
#include "base/logging.h"
diff --git a/components/webcrypto/algorithms/aes_gcm_unittest.cc b/components/webcrypto/algorithms/aes_gcm_unittest.cc
index d912cbd..982dfd4 100644
--- a/components/webcrypto/algorithms/aes_gcm_unittest.cc
+++ b/components/webcrypto/algorithms/aes_gcm_unittest.cc
@@ -2,6 +2,10 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
+#include <stddef.h>
+#include <stdint.h>
+
+#include "base/macros.h"
#include "base/values.h"
#include "components/webcrypto/algorithm_dispatch.h"
#include "components/webcrypto/algorithms/test_helpers.h"
diff --git a/components/webcrypto/algorithms/aes_kw.cc b/components/webcrypto/algorithms/aes_kw.cc
index 295d911..306272e 100644
--- a/components/webcrypto/algorithms/aes_kw.cc
+++ b/components/webcrypto/algorithms/aes_kw.cc
@@ -3,6 +3,8 @@
// found in the LICENSE file.
#include <openssl/evp.h>
+#include <stddef.h>
+#include <stdint.h>
#include <vector>
#include "base/logging.h"
diff --git a/components/webcrypto/algorithms/aes_kw_unittest.cc b/components/webcrypto/algorithms/aes_kw_unittest.cc
index 3002544..4f7f1f1 100644
--- a/components/webcrypto/algorithms/aes_kw_unittest.cc
+++ b/components/webcrypto/algorithms/aes_kw_unittest.cc
@@ -2,6 +2,10 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
+#include <stddef.h>
+#include <stdint.h>
+
+#include "base/macros.h"
#include "base/stl_util.h"
#include "base/values.h"
#include "components/webcrypto/algorithm_dispatch.h"
diff --git a/components/webcrypto/algorithms/asymmetric_key_util.cc b/components/webcrypto/algorithms/asymmetric_key_util.cc
index 9abd47c..74eb6c4 100644
--- a/components/webcrypto/algorithms/asymmetric_key_util.cc
+++ b/components/webcrypto/algorithms/asymmetric_key_util.cc
@@ -5,6 +5,7 @@
#include "components/webcrypto/algorithms/asymmetric_key_util.h"
#include <openssl/pkcs12.h>
+#include <stdint.h>
#include "components/webcrypto/algorithms/util.h"
#include "components/webcrypto/blink_key_handle.h"
diff --git a/components/webcrypto/algorithms/ec.cc b/components/webcrypto/algorithms/ec.cc
index e489b87..11d4c58 100644
--- a/components/webcrypto/algorithms/ec.cc
+++ b/components/webcrypto/algorithms/ec.cc
@@ -8,8 +8,10 @@
#include <openssl/ec_key.h>
#include <openssl/evp.h>
#include <openssl/pkcs12.h>
+#include <stddef.h>
#include "base/logging.h"
+#include "base/macros.h"
#include "components/webcrypto/algorithms/asymmetric_key_util.h"
#include "components/webcrypto/algorithms/util.h"
#include "components/webcrypto/blink_key_handle.h"
diff --git a/components/webcrypto/algorithms/ec.h b/components/webcrypto/algorithms/ec.h
index bebf87b..1e9bd3e 100644
--- a/components/webcrypto/algorithms/ec.h
+++ b/components/webcrypto/algorithms/ec.h
@@ -5,6 +5,8 @@
#ifndef COMPONENTS_WEBCRYPTO_ALGORITHMS_EC_H_
#define COMPONENTS_WEBCRYPTO_ALGORITHMS_EC_H_
+#include <stdint.h>
+
#include "components/webcrypto/algorithm_implementation.h"
namespace webcrypto {
diff --git a/components/webcrypto/algorithms/ecdh.cc b/components/webcrypto/algorithms/ecdh.cc
index b4bff4c..67f4f1a 100644
--- a/components/webcrypto/algorithms/ecdh.cc
+++ b/components/webcrypto/algorithms/ecdh.cc
@@ -5,6 +5,8 @@
#include <openssl/ec.h>
#include <openssl/ecdh.h>
#include <openssl/evp.h>
+#include <stddef.h>
+#include <stdint.h>
#include "base/logging.h"
#include "components/webcrypto/algorithm_implementation.h"
diff --git a/components/webcrypto/algorithms/ecdh_unittest.cc b/components/webcrypto/algorithms/ecdh_unittest.cc
index 961c6d5..3852bf0 100644
--- a/components/webcrypto/algorithms/ecdh_unittest.cc
+++ b/components/webcrypto/algorithms/ecdh_unittest.cc
@@ -2,6 +2,9 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
+#include <stddef.h>
+#include <stdint.h>
+
#include "base/stl_util.h"
#include "components/webcrypto/algorithm_dispatch.h"
#include "components/webcrypto/algorithms/ec.h"
diff --git a/components/webcrypto/algorithms/ecdsa.cc b/components/webcrypto/algorithms/ecdsa.cc
index 8a283af1..d6f7590 100644
--- a/components/webcrypto/algorithms/ecdsa.cc
+++ b/components/webcrypto/algorithms/ecdsa.cc
@@ -5,6 +5,8 @@
#include <openssl/ec.h>
#include <openssl/ec_key.h>
#include <openssl/evp.h>
+#include <stddef.h>
+#include <stdint.h>
#include "base/logging.h"
#include "components/webcrypto/algorithm_implementation.h"
diff --git a/components/webcrypto/algorithms/ecdsa_unittest.cc b/components/webcrypto/algorithms/ecdsa_unittest.cc
index 4b2e651..1b63865 100644
--- a/components/webcrypto/algorithms/ecdsa_unittest.cc
+++ b/components/webcrypto/algorithms/ecdsa_unittest.cc
@@ -2,6 +2,9 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
+#include <stddef.h>
+#include <stdint.h>
+
#include "base/stl_util.h"
#include "components/webcrypto/algorithm_dispatch.h"
#include "components/webcrypto/algorithms/test_helpers.h"
diff --git a/components/webcrypto/algorithms/hkdf.cc b/components/webcrypto/algorithms/hkdf.cc
index 2f5dc07..b9834fd 100644
--- a/components/webcrypto/algorithms/hkdf.cc
+++ b/components/webcrypto/algorithms/hkdf.cc
@@ -4,6 +4,7 @@
#include <openssl/err.h>
#include <openssl/hkdf.h>
+#include <stdint.h>
#include "base/logging.h"
#include "components/webcrypto/algorithm_implementation.h"
diff --git a/components/webcrypto/algorithms/hmac.cc b/components/webcrypto/algorithms/hmac.cc
index 33d60bb..82d6428 100644
--- a/components/webcrypto/algorithms/hmac.cc
+++ b/components/webcrypto/algorithms/hmac.cc
@@ -3,6 +3,8 @@
// found in the LICENSE file.
#include <openssl/hmac.h>
+#include <stddef.h>
+#include <stdint.h>
#include "base/logging.h"
#include "base/numerics/safe_math.h"
diff --git a/components/webcrypto/algorithms/hmac_unittest.cc b/components/webcrypto/algorithms/hmac_unittest.cc
index f7ae170..b0381d3 100644
--- a/components/webcrypto/algorithms/hmac_unittest.cc
+++ b/components/webcrypto/algorithms/hmac_unittest.cc
@@ -2,6 +2,9 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
+#include <stddef.h>
+#include <stdint.h>
+
#include "base/logging.h"
#include "base/values.h"
#include "components/webcrypto/algorithm_dispatch.h"
diff --git a/components/webcrypto/algorithms/pbkdf2.cc b/components/webcrypto/algorithms/pbkdf2.cc
index 6c78f51..291c5f1 100644
--- a/components/webcrypto/algorithms/pbkdf2.cc
+++ b/components/webcrypto/algorithms/pbkdf2.cc
@@ -2,6 +2,8 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
+#include <stdint.h>
+
#include "base/stl_util.h"
#include "components/webcrypto/algorithm_implementation.h"
#include "components/webcrypto/algorithms/secret_key_util.h"
diff --git a/components/webcrypto/algorithms/rsa.h b/components/webcrypto/algorithms/rsa.h
index c0c919b..840c627 100644
--- a/components/webcrypto/algorithms/rsa.h
+++ b/components/webcrypto/algorithms/rsa.h
@@ -5,6 +5,8 @@
#ifndef COMPONENTS_WEBCRYPTO_ALGORITHMS_RSA_H_
#define COMPONENTS_WEBCRYPTO_ALGORITHMS_RSA_H_
+#include <stdint.h>
+
#include "components/webcrypto/algorithm_implementation.h"
namespace webcrypto {
diff --git a/components/webcrypto/algorithms/rsa_oaep.cc b/components/webcrypto/algorithms/rsa_oaep.cc
index 6fdc41c..8e4452e 100644
--- a/components/webcrypto/algorithms/rsa_oaep.cc
+++ b/components/webcrypto/algorithms/rsa_oaep.cc
@@ -3,6 +3,8 @@
// found in the LICENSE file.
#include <openssl/evp.h>
+#include <stddef.h>
+#include <stdint.h>
#include "components/webcrypto/algorithms/rsa.h"
#include "components/webcrypto/algorithms/util.h"
diff --git a/components/webcrypto/algorithms/rsa_oaep_unittest.cc b/components/webcrypto/algorithms/rsa_oaep_unittest.cc
index 66368ad7..de1d66f 100644
--- a/components/webcrypto/algorithms/rsa_oaep_unittest.cc
+++ b/components/webcrypto/algorithms/rsa_oaep_unittest.cc
@@ -2,8 +2,12 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
+#include <stddef.h>
+#include <stdint.h>
+
#include "base/base64url.h"
#include "base/logging.h"
+#include "base/macros.h"
#include "components/webcrypto/algorithm_dispatch.h"
#include "components/webcrypto/algorithms/test_helpers.h"
#include "components/webcrypto/crypto_data.h"
diff --git a/components/webcrypto/algorithms/rsa_pss.cc b/components/webcrypto/algorithms/rsa_pss.cc
index 14166bd..05c6787 100644
--- a/components/webcrypto/algorithms/rsa_pss.cc
+++ b/components/webcrypto/algorithms/rsa_pss.cc
@@ -2,6 +2,8 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
+#include <stdint.h>
+
#include "components/webcrypto/algorithms/rsa.h"
#include "components/webcrypto/algorithms/rsa_sign.h"
#include "components/webcrypto/status.h"
diff --git a/components/webcrypto/algorithms/rsa_pss_unittest.cc b/components/webcrypto/algorithms/rsa_pss_unittest.cc
index e8b2bfd..98ef227 100644
--- a/components/webcrypto/algorithms/rsa_pss_unittest.cc
+++ b/components/webcrypto/algorithms/rsa_pss_unittest.cc
@@ -2,6 +2,9 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
+#include <stddef.h>
+#include <stdint.h>
+
#include "base/logging.h"
#include "base/stl_util.h"
#include "components/webcrypto/algorithm_dispatch.h"
diff --git a/components/webcrypto/algorithms/rsa_sign.cc b/components/webcrypto/algorithms/rsa_sign.cc
index 1ea0b8e..20f2306 100644
--- a/components/webcrypto/algorithms/rsa_sign.cc
+++ b/components/webcrypto/algorithms/rsa_sign.cc
@@ -2,6 +2,8 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
+#include <stddef.h>
+
#include "base/numerics/safe_math.h"
#include "components/webcrypto/algorithms/rsa_sign.h"
#include "components/webcrypto/algorithms/util.h"
diff --git a/components/webcrypto/algorithms/rsa_ssa.cc b/components/webcrypto/algorithms/rsa_ssa.cc
index 54eefbb..aa68065 100644
--- a/components/webcrypto/algorithms/rsa_ssa.cc
+++ b/components/webcrypto/algorithms/rsa_ssa.cc
@@ -2,6 +2,8 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
+#include <stdint.h>
+
#include "components/webcrypto/algorithms/rsa.h"
#include "components/webcrypto/algorithms/rsa_sign.h"
#include "components/webcrypto/status.h"
diff --git a/components/webcrypto/algorithms/rsa_ssa_unittest.cc b/components/webcrypto/algorithms/rsa_ssa_unittest.cc
index 360bdb9..2c47fe1 100644
--- a/components/webcrypto/algorithms/rsa_ssa_unittest.cc
+++ b/components/webcrypto/algorithms/rsa_ssa_unittest.cc
@@ -2,7 +2,11 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
+#include <stddef.h>
+#include <stdint.h>
+
#include "base/logging.h"
+#include "base/macros.h"
#include "base/values.h"
#include "components/webcrypto/algorithm_dispatch.h"
#include "components/webcrypto/algorithms/test_helpers.h"
diff --git a/components/webcrypto/algorithms/secret_key_util.h b/components/webcrypto/algorithms/secret_key_util.h
index cfef769..5a0adfb 100644
--- a/components/webcrypto/algorithms/secret_key_util.h
+++ b/components/webcrypto/algorithms/secret_key_util.h
@@ -5,6 +5,8 @@
#ifndef COMPONENTS_WEBCRYPTO_ALGORITHMS_SECRET_KEY_UTIL_
#define COMPONENTS_WEBCRYPTO_ALGORITHMS_SECRET_KEY_UTIL_
+#include <stdint.h>
+
#include <string>
#include <vector>
diff --git a/components/webcrypto/algorithms/sha.cc b/components/webcrypto/algorithms/sha.cc
index 69135cf..4c4b47b 100644
--- a/components/webcrypto/algorithms/sha.cc
+++ b/components/webcrypto/algorithms/sha.cc
@@ -4,6 +4,7 @@
#include <openssl/evp.h>
#include <openssl/sha.h>
+#include <stdint.h>
#include <vector>
#include "base/logging.h"
diff --git a/components/webcrypto/algorithms/sha_unittest.cc b/components/webcrypto/algorithms/sha_unittest.cc
index cab9239..d7de97d 100644
--- a/components/webcrypto/algorithms/sha_unittest.cc
+++ b/components/webcrypto/algorithms/sha_unittest.cc
@@ -2,6 +2,9 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
+#include <stddef.h>
+#include <stdint.h>
+
#include "base/logging.h"
#include "base/values.h"
#include "components/webcrypto/algorithm_dispatch.h"
diff --git a/components/webcrypto/algorithms/test_helpers.cc b/components/webcrypto/algorithms/test_helpers.cc
index 6ba14d7..617b23f 100644
--- a/components/webcrypto/algorithms/test_helpers.cc
+++ b/components/webcrypto/algorithms/test_helpers.cc
@@ -4,6 +4,8 @@
#include "components/webcrypto/algorithms/test_helpers.h"
+#include <stddef.h>
+
#include <algorithm>
#include "base/base64url.h"
@@ -11,6 +13,7 @@
#include "base/json/json_reader.h"
#include "base/json/json_writer.h"
#include "base/logging.h"
+#include "base/macros.h"
#include "base/path_service.h"
#include "base/strings/string_number_conversions.h"
#include "base/strings/string_util.h"
diff --git a/components/webcrypto/algorithms/test_helpers.h b/components/webcrypto/algorithms/test_helpers.h
index 3cc87d2..7819793 100644
--- a/components/webcrypto/algorithms/test_helpers.h
+++ b/components/webcrypto/algorithms/test_helpers.h
@@ -5,6 +5,8 @@
#ifndef COMPONENTS_WEBCRYPTO_ALGORITHMS_TEST_HELPERS_H_
#define COMPONENTS_WEBCRYPTO_ALGORITHMS_TEST_HELPERS_H_
+#include <stdint.h>
+
#include <ostream>
#include <string>
#include <vector>
diff --git a/components/webcrypto/algorithms/util.h b/components/webcrypto/algorithms/util.h
index 8fa2926..2132683 100644
--- a/components/webcrypto/algorithms/util.h
+++ b/components/webcrypto/algorithms/util.h
@@ -9,6 +9,8 @@
#include <vector>
#include <openssl/base.h>
+#include <stddef.h>
+#include <stdint.h>
#include "third_party/WebKit/public/platform/WebCryptoAlgorithm.h"
#include "third_party/WebKit/public/platform/WebCryptoKey.h"
diff --git a/components/webcrypto/crypto_data.h b/components/webcrypto/crypto_data.h
index 0056a20..b66a16a 100644
--- a/components/webcrypto/crypto_data.h
+++ b/components/webcrypto/crypto_data.h
@@ -8,7 +8,6 @@
#include <string>
#include <vector>
-#include "base/basictypes.h"
#include "third_party/WebKit/public/platform/WebVector.h"
namespace webcrypto {
diff --git a/components/webcrypto/jwk.cc b/components/webcrypto/jwk.cc
index 318d209..f2f7afb 100644
--- a/components/webcrypto/jwk.cc
+++ b/components/webcrypto/jwk.cc
@@ -4,11 +4,14 @@
#include "components/webcrypto/jwk.h"
+#include <stddef.h>
+
#include <set>
#include "base/base64url.h"
#include "base/json/json_reader.h"
#include "base/json/json_writer.h"
+#include "base/macros.h"
#include "base/stl_util.h"
#include "base/strings/string_piece.h"
#include "base/strings/stringprintf.h"
diff --git a/components/webcrypto/status.h b/components/webcrypto/status.h
index 7143a29..2772e32 100644
--- a/components/webcrypto/status.h
+++ b/components/webcrypto/status.h
@@ -5,6 +5,8 @@
#ifndef COMPONENTS_WEBCRYPTO_STATUS_H_
#define COMPONENTS_WEBCRYPTO_STATUS_H_
+#include <stddef.h>
+
#include <string>
#include "third_party/WebKit/public/platform/WebCrypto.h"
diff --git a/components/webcrypto/webcrypto_impl.cc b/components/webcrypto/webcrypto_impl.cc
index 47a0237..cfa880c 100644
--- a/components/webcrypto/webcrypto_impl.cc
+++ b/components/webcrypto/webcrypto_impl.cc
@@ -4,6 +4,8 @@
#include "components/webcrypto/webcrypto_impl.h"
+#include <stdint.h>
+
#include "base/bind.h"
#include "base/lazy_instance.h"
#include "base/location.h"
diff --git a/components/webcrypto/webcrypto_impl.h b/components/webcrypto/webcrypto_impl.h
index 068a65c..af5f6fc 100644
--- a/components/webcrypto/webcrypto_impl.h
+++ b/components/webcrypto/webcrypto_impl.h
@@ -5,8 +5,8 @@
#ifndef COMPONENTS_WEBCRYPTO_WEBCRYPTO_IMPL_H_
#define COMPONENTS_WEBCRYPTO_WEBCRYPTO_IMPL_H_
-#include "base/basictypes.h"
#include "base/compiler_specific.h"
+#include "base/macros.h"
#include "third_party/WebKit/public/platform/WebCrypto.h"
#include "third_party/WebKit/public/platform/WebCryptoAlgorithm.h"
#include "third_party/WebKit/public/platform/WebVector.h"
diff --git a/components/webdata/common/web_data_request_manager.h b/components/webdata/common/web_data_request_manager.h
index 06d13e2..695d310 100644
--- a/components/webdata/common/web_data_request_manager.h
+++ b/components/webdata/common/web_data_request_manager.h
@@ -11,12 +11,13 @@
#include <map>
+#include "base/macros.h"
#include "base/memory/ref_counted.h"
#include "base/synchronization/lock.h"
-#include "components/webdata/common/web_database_service.h"
#include "components/webdata/common/web_data_results.h"
#include "components/webdata/common/web_data_service_base.h"
#include "components/webdata/common/web_data_service_consumer.h"
+#include "components/webdata/common/web_database_service.h"
class WebDataServiceConsumer;
class WebDataRequestManager;
diff --git a/components/webdata/common/web_data_results.h b/components/webdata/common/web_data_results.h
index d6d07fd..8f04c7f 100644
--- a/components/webdata/common/web_data_results.h
+++ b/components/webdata/common/web_data_results.h
@@ -5,8 +5,11 @@
#ifndef COMPONENTS_WEBDATA_COMMON_WEB_DATA_RESULTS_H_
#define COMPONENTS_WEBDATA_COMMON_WEB_DATA_RESULTS_H_
-#include "base/basictypes.h"
+#include <stdint.h>
+
#include "base/callback.h"
+#include "base/macros.h"
+#include "build/build_config.h"
#include "components/webdata/common/webdata_export.h"
class WDTypedResult;
@@ -15,20 +18,20 @@ class WDTypedResult;
// Result types for WebDataService.
//
typedef enum {
- BOOL_RESULT = 1, // WDResult<bool>
- KEYWORDS_RESULT, // WDResult<WDKeywordsResult>
- INT64_RESULT, // WDResult<int64>
+ BOOL_RESULT = 1, // WDResult<bool>
+ KEYWORDS_RESULT, // WDResult<WDKeywordsResult>
+ INT64_RESULT, // WDResult<int64_t>
#if defined(OS_WIN)
- PASSWORD_IE7_RESULT, // WDResult<IE7PasswordInfo>
+ PASSWORD_IE7_RESULT, // WDResult<IE7PasswordInfo>
#endif
- WEB_APP_IMAGES, // WDResult<WDAppImagesResult>
- TOKEN_RESULT, // WDResult<std::vector<std::string>>
- AUTOFILL_VALUE_RESULT, // WDResult<std::vector<base::string16>>
- AUTOFILL_CHANGES, // WDResult<std::vector<AutofillChange>>
- AUTOFILL_PROFILE_RESULT, // WDResult<AutofillProfile>
- AUTOFILL_PROFILES_RESULT, // WDResult<std::vector<AutofillProfile*>>
- AUTOFILL_CREDITCARD_RESULT, // WDResult<CreditCard>
- AUTOFILL_CREDITCARDS_RESULT, // WDResult<std::vector<CreditCard*>>
+ WEB_APP_IMAGES, // WDResult<WDAppImagesResult>
+ TOKEN_RESULT, // WDResult<std::vector<std::string>>
+ AUTOFILL_VALUE_RESULT, // WDResult<std::vector<base::string16>>
+ AUTOFILL_CHANGES, // WDResult<std::vector<AutofillChange>>
+ AUTOFILL_PROFILE_RESULT, // WDResult<AutofillProfile>
+ AUTOFILL_PROFILES_RESULT, // WDResult<std::vector<AutofillProfile*>>
+ AUTOFILL_CREDITCARD_RESULT, // WDResult<CreditCard>
+ AUTOFILL_CREDITCARDS_RESULT, // WDResult<std::vector<CreditCard*>>
} WDResultType;
diff --git a/components/webdata/common/web_data_service_base.h b/components/webdata/common/web_data_service_base.h
index de5a3e9..797e329 100644
--- a/components/webdata/common/web_data_service_base.h
+++ b/components/webdata/common/web_data_service_base.h
@@ -7,6 +7,7 @@
#include "base/callback.h"
#include "base/files/file_path.h"
+#include "base/macros.h"
#include "base/memory/ref_counted.h"
#include "base/memory/ref_counted_delete_on_message_loop.h"
#include "base/memory/scoped_ptr.h"
diff --git a/components/webdata/common/web_database.h b/components/webdata/common/web_database.h
index c6d0c1d..3522c69 100644
--- a/components/webdata/common/web_database.h
+++ b/components/webdata/common/web_database.h
@@ -7,6 +7,7 @@
#include <map>
+#include "base/macros.h"
#include "base/memory/scoped_ptr.h"
#include "components/webdata/common/web_database_table.h"
#include "components/webdata/common/webdata_export.h"
diff --git a/components/webdata/common/web_database_backend.h b/components/webdata/common/web_database_backend.h
index 9dc918e..7448cb3 100644
--- a/components/webdata/common/web_database_backend.h
+++ b/components/webdata/common/web_database_backend.h
@@ -5,10 +5,10 @@
#ifndef COMPONENTS_WEBDATA_COMMON_WEB_DATABASE_BACKEND_H_
#define COMPONENTS_WEBDATA_COMMON_WEB_DATABASE_BACKEND_H_
-#include "base/basictypes.h"
#include "base/callback_forward.h"
#include "base/compiler_specific.h"
#include "base/files/file_path.h"
+#include "base/macros.h"
#include "base/memory/ref_counted.h"
#include "base/memory/ref_counted_delete_on_message_loop.h"
#include "base/memory/scoped_ptr.h"
diff --git a/components/webdata/common/web_database_migration_unittest.cc b/components/webdata/common/web_database_migration_unittest.cc
index a5f371b..0436618 100644
--- a/components/webdata/common/web_database_migration_unittest.cc
+++ b/components/webdata/common/web_database_migration_unittest.cc
@@ -7,6 +7,7 @@
#include "base/files/file_util.h"
#include "base/files/scoped_temp_dir.h"
#include "base/guid.h"
+#include "base/macros.h"
#include "base/message_loop/message_loop.h"
#include "base/path_service.h"
#include "base/stl_util.h"
diff --git a/components/webdata/common/web_database_service.cc b/components/webdata/common/web_database_service.cc
index e56c7c3..6fcc9f0 100644
--- a/components/webdata/common/web_database_service.cc
+++ b/components/webdata/common/web_database_service.cc
@@ -4,6 +4,8 @@
#include "components/webdata/common/web_database_service.h"
+#include <stddef.h>
+
#include "base/bind.h"
#include "base/location.h"
#include "base/thread_task_runner_handle.h"
diff --git a/components/webdata/common/web_database_service.h b/components/webdata/common/web_database_service.h
index 7f5d1bc..8dc7618 100644
--- a/components/webdata/common/web_database_service.h
+++ b/components/webdata/common/web_database_service.h
@@ -9,10 +9,10 @@
#ifndef COMPONENTS_WEBDATA_COMMON_WEB_DATABASE_SERVICE_H_
#define COMPONENTS_WEBDATA_COMMON_WEB_DATABASE_SERVICE_H_
-#include "base/basictypes.h"
#include "base/callback_forward.h"
#include "base/compiler_specific.h"
#include "base/files/file_path.h"
+#include "base/macros.h"
#include "base/memory/ref_counted.h"
#include "base/memory/ref_counted_delete_on_message_loop.h"
#include "base/memory/scoped_ptr.h"
diff --git a/components/webdata/common/web_database_table.h b/components/webdata/common/web_database_table.h
index d931c87..ff75082 100644
--- a/components/webdata/common/web_database_table.h
+++ b/components/webdata/common/web_database_table.h
@@ -6,6 +6,7 @@
#define COMPONENTS_WEBDATA_COMMON_WEB_DATABASE_TABLE_H_
#include "base/logging.h"
+#include "base/macros.h"
#include "components/webdata/common/webdata_export.h"
namespace sql {
diff --git a/components/webdata_services/web_data_service_test_util.h b/components/webdata_services/web_data_service_test_util.h
index 4c260a1..95f8012 100644
--- a/components/webdata_services/web_data_service_test_util.h
+++ b/components/webdata_services/web_data_service_test_util.h
@@ -5,7 +5,7 @@
#ifndef COMPONENTS_WEBDATA_SERVICES_WEB_DATA_SERVICE_TEST_UTIL_H__
#define COMPONENTS_WEBDATA_SERVICES_WEB_DATA_SERVICE_TEST_UTIL_H__
-#include "base/basictypes.h"
+#include "base/macros.h"
#include "base/message_loop/message_loop.h"
#include "components/signin/core/browser/webdata/token_web_data.h"
#include "components/webdata_services/web_data_service_wrapper.h"
diff --git a/components/webdata_services/web_data_service_wrapper.cc b/components/webdata_services/web_data_service_wrapper.cc
index 4de1cce..398660f 100644
--- a/components/webdata_services/web_data_service_wrapper.cc
+++ b/components/webdata_services/web_data_service_wrapper.cc
@@ -8,6 +8,7 @@
#include "base/callback.h"
#include "base/files/file_path.h"
#include "base/single_thread_task_runner.h"
+#include "build/build_config.h"
#include "components/autofill/core/browser/webdata/autocomplete_syncable_service.h"
#include "components/autofill/core/browser/webdata/autofill_profile_syncable_service.h"
#include "components/autofill/core/browser/webdata/autofill_table.h"
diff --git a/components/webdata_services/web_data_service_wrapper.h b/components/webdata_services/web_data_service_wrapper.h
index 03d1582..ecc8c33 100644
--- a/components/webdata_services/web_data_service_wrapper.h
+++ b/components/webdata_services/web_data_service_wrapper.h
@@ -10,6 +10,7 @@
#include "base/callback_forward.h"
#include "base/macros.h"
#include "base/memory/ref_counted.h"
+#include "build/build_config.h"
#include "components/keyed_service/core/keyed_service.h"
#include "sql/init_status.h"
#include "sync/api/syncable_service.h"
diff --git a/components/webp_transcode/webp_decoder.h b/components/webp_transcode/webp_decoder.h
index ab2509e..1fa93f7 100644
--- a/components/webp_transcode/webp_decoder.h
+++ b/components/webp_transcode/webp_decoder.h
@@ -6,6 +6,7 @@
#define COMPONENTS_WEBP_TRANSCODE_WEBP_DECODER_H_
#import <Foundation/Foundation.h>
+#include <stddef.h>
#include "base/mac/scoped_nsobject.h"
#include "base/memory/ref_counted.h"
diff --git a/components/webp_transcode/webp_decoder.mm b/components/webp_transcode/webp_decoder.mm
index 05c834b..38ae361 100644
--- a/components/webp_transcode/webp_decoder.mm
+++ b/components/webp_transcode/webp_decoder.mm
@@ -5,6 +5,7 @@
#include "components/webp_transcode/webp_decoder.h"
#import <Foundation/Foundation.h>
+#include <stdint.h>
#import <UIKit/UIKit.h>
#include "base/logging.h"
diff --git a/components/webp_transcode/webp_decoder_unittest.mm b/components/webp_transcode/webp_decoder_unittest.mm
index b4084d0..eb294ab 100644
--- a/components/webp_transcode/webp_decoder_unittest.mm
+++ b/components/webp_transcode/webp_decoder_unittest.mm
@@ -6,6 +6,8 @@
#import <CoreGraphics/CoreGraphics.h>
#import <Foundation/Foundation.h>
+#include <stddef.h>
+#include <stdint.h>
#include "base/base_paths.h"
#include "base/files/file_path.h"
@@ -13,9 +15,11 @@
#include "base/logging.h"
#include "base/mac/scoped_cftyperef.h"
#include "base/mac/scoped_nsobject.h"
+#include "base/macros.h"
#include "base/memory/ref_counted.h"
#include "base/path_service.h"
#include "base/strings/sys_string_conversions.h"
+#include "build/build_config.h"
#include "testing/gmock/include/gmock/gmock.h"
#include "testing/gtest/include/gtest/gtest.h"
diff --git a/components/webp_transcode/webp_network_client.mm b/components/webp_transcode/webp_network_client.mm
index 307e198..9a9bd40 100644
--- a/components/webp_transcode/webp_network_client.mm
+++ b/components/webp_transcode/webp_network_client.mm
@@ -4,6 +4,8 @@
#import "components/webp_transcode/webp_network_client.h"
+#include <stddef.h>
+
#include "base/bind.h"
#include "base/compiler_specific.h"
#include "base/location.h"
diff --git a/components/webp_transcode/webp_network_client_unittest.mm b/components/webp_transcode/webp_network_client_unittest.mm
index c5c425b..e017b91 100644
--- a/components/webp_transcode/webp_network_client_unittest.mm
+++ b/components/webp_transcode/webp_network_client_unittest.mm
@@ -4,7 +4,10 @@
#include "components/webp_transcode/webp_network_client.h"
+#include <stddef.h>
+
#include "base/mac/scoped_nsobject.h"
+#include "base/macros.h"
#include "base/memory/weak_ptr.h"
#include "base/message_loop/message_loop.h"
#include "base/thread_task_runner_handle.h"
diff --git a/components/webusb/webusb_detector.h b/components/webusb/webusb_detector.h
index 2695d96..cbf5a62 100644
--- a/components/webusb/webusb_detector.h
+++ b/components/webusb/webusb_detector.h
@@ -5,6 +5,7 @@
#ifndef COMPONENTS_WEBUSB_WEBUSB_DETECTOR_H_
#define COMPONENTS_WEBUSB_WEBUSB_DETECTOR_H_
+#include "base/macros.h"
#include "base/scoped_observer.h"
#include "device/usb/usb_service.h"
diff --git a/components/wifi/network_properties.cc b/components/wifi/network_properties.cc
index 68af452..4e12aae 100644
--- a/components/wifi/network_properties.cc
+++ b/components/wifi/network_properties.cc
@@ -84,7 +84,7 @@ bool NetworkProperties::UpdateFromValue(const base::DictionaryValue& value) {
return false;
}
-std::string NetworkProperties::MacAddressAsString(const uint8 mac_as_int[6]) {
+std::string NetworkProperties::MacAddressAsString(const uint8_t mac_as_int[6]) {
// mac_as_int is big-endian. Write in byte chunks.
// Format is XX:XX:XX:XX:XX:XX.
static const char* const kMacFormatString = "%02x:%02x:%02x:%02x:%02x:%02x";
diff --git a/components/wifi/network_properties.h b/components/wifi/network_properties.h
index 8483e98..8f90768 100644
--- a/components/wifi/network_properties.h
+++ b/components/wifi/network_properties.h
@@ -5,6 +5,8 @@
#ifndef COMPONENTS_WIFI_NETWORK_PROPERTIES_H_
#define COMPONENTS_WIFI_NETWORK_PROPERTIES_H_
+#include <stdint.h>
+
#include <list>
#include <set>
#include <string>
@@ -14,7 +16,7 @@
namespace wifi {
-typedef int32 Frequency;
+typedef int32_t Frequency;
enum FrequencyEnum {
kFrequencyAny = 0,
@@ -43,7 +45,7 @@ struct WIFI_EXPORT NetworkProperties {
// once operation is completed.
std::string password;
// WiFi Signal Strength. 0..100
- uint32 signal_strength;
+ uint32_t signal_strength;
bool auto_connect;
Frequency frequency;
FrequencySet frequency_set;
@@ -51,7 +53,7 @@ struct WIFI_EXPORT NetworkProperties {
scoped_ptr<base::DictionaryValue> ToValue(bool network_list) const;
// Updates only properties set in |value|.
bool UpdateFromValue(const base::DictionaryValue& value);
- static std::string MacAddressAsString(const uint8 mac_as_int[6]);
+ static std::string MacAddressAsString(const uint8_t mac_as_int[6]);
static bool OrderByType(const NetworkProperties& l,
const NetworkProperties& r);
};
diff --git a/components/wifi/wifi_service.h b/components/wifi/wifi_service.h
index a1cd910..3c10c12 100644
--- a/components/wifi/wifi_service.h
+++ b/components/wifi/wifi_service.h
@@ -11,6 +11,7 @@
#include <vector>
#include "base/callback.h"
+#include "base/macros.h"
#include "base/memory/ref_counted.h"
#include "base/threading/sequenced_worker_pool.h"
#include "base/values.h"
diff --git a/components/wifi/wifi_service_mac.mm b/components/wifi/wifi_service_mac.mm
index 3c9d8a7..576d09f 100644
--- a/components/wifi/wifi_service_mac.mm
+++ b/components/wifi/wifi_service_mac.mm
@@ -13,6 +13,7 @@
#include "base/mac/scoped_cftyperef.h"
#include "base/mac/scoped_nsobject.h"
#include "base/mac/sdk_forward_declarations.h"
+#include "base/macros.h"
#include "base/message_loop/message_loop.h"
#include "base/strings/sys_string_conversions.h"
#include "components/onc/onc_constants.h"
diff --git a/components/wifi/wifi_service_win.cc b/components/wifi/wifi_service_win.cc
index 2716136..e4edf6a 100644
--- a/components/wifi/wifi_service_win.cc
+++ b/components/wifi/wifi_service_win.cc
@@ -6,6 +6,8 @@
#include <iphlpapi.h>
#include <objbase.h>
+#include <stddef.h>
+#include <stdint.h>
#include <wlanapi.h>
#include <set>
@@ -13,6 +15,7 @@
#include "base/base_paths_win.h"
#include "base/bind.h"
#include "base/files/file_path.h"
+#include "base/macros.h"
#include "base/memory/ref_counted.h"
#include "base/message_loop/message_loop.h"
#include "base/path_service.h"
@@ -229,7 +232,7 @@ class WiFiServiceImpl : public WiFiService {
void GetConnectedNetworkSSID(std::string* ssid, std::string* error) override;
private:
- typedef int32 EncryptionType;
+ typedef int32_t EncryptionType;
enum EncryptionTypeEnum {
kEncryptionTypeAny = 0,
kEncryptionTypeAES = 1,
diff --git a/components/wifi/wifi_test.cc b/components/wifi/wifi_test.cc
index 31e615b..d99ee86 100644
--- a/components/wifi/wifi_test.cc
+++ b/components/wifi/wifi_test.cc
@@ -20,6 +20,7 @@
#include "base/strings/stringprintf.h"
#include "base/strings/utf_string_conversions.h"
#include "base/time/time.h"
+#include "build/build_config.h"
#include "components/wifi/wifi_service.h"
#if defined(OS_MACOSX)
diff --git a/components/wifi_sync/wifi_config_delegate_chromeos_unittest.cc b/components/wifi_sync/wifi_config_delegate_chromeos_unittest.cc
index 1ff94f8..e1996eb 100644
--- a/components/wifi_sync/wifi_config_delegate_chromeos_unittest.cc
+++ b/components/wifi_sync/wifi_config_delegate_chromeos_unittest.cc
@@ -4,6 +4,8 @@
#include "components/wifi_sync/wifi_config_delegate_chromeos.h"
+#include <stddef.h>
+
#include "base/logging.h"
#include "base/macros.h"
#include "base/values.h"
diff --git a/components/wifi_sync/wifi_credential_syncable_service_factory.cc b/components/wifi_sync/wifi_credential_syncable_service_factory.cc
index 395b5d8..6d1b27c 100644
--- a/components/wifi_sync/wifi_credential_syncable_service_factory.cc
+++ b/components/wifi_sync/wifi_credential_syncable_service_factory.cc
@@ -8,6 +8,7 @@
#include "base/logging.h"
#include "base/memory/scoped_ptr.h"
+#include "build/build_config.h"
#include "components/keyed_service/content/browser_context_dependency_manager.h"
#include "components/wifi_sync/wifi_config_delegate.h"
#include "components/wifi_sync/wifi_credential_syncable_service.h"
diff --git a/components/wifi_sync/wifi_credential_syncable_service_factory.h b/components/wifi_sync/wifi_credential_syncable_service_factory.h
index c006cb3..88ece2a 100644
--- a/components/wifi_sync/wifi_credential_syncable_service_factory.h
+++ b/components/wifi_sync/wifi_credential_syncable_service_factory.h
@@ -8,6 +8,7 @@
#include "base/macros.h"
#include "base/memory/scoped_ptr.h"
#include "base/memory/singleton.h"
+#include "build/build_config.h"
#include "components/keyed_service/content/browser_context_keyed_service_factory.h"
namespace content {
diff --git a/components/wifi_sync/wifi_credential_syncable_service_unittest.cc b/components/wifi_sync/wifi_credential_syncable_service_unittest.cc
index 13c8092..81132c0 100644
--- a/components/wifi_sync/wifi_credential_syncable_service_unittest.cc
+++ b/components/wifi_sync/wifi_credential_syncable_service_unittest.cc
@@ -4,6 +4,8 @@
#include "components/wifi_sync/wifi_credential_syncable_service.h"
+#include <stdint.h>
+
#include <string>
#include <vector>
diff --git a/components/wifi_sync/wifi_security_class.h b/components/wifi_sync/wifi_security_class.h
index 1b2f1bd..1802b35 100644
--- a/components/wifi_sync/wifi_security_class.h
+++ b/components/wifi_sync/wifi_security_class.h
@@ -7,6 +7,7 @@
#include <string>
+#include "build/build_config.h"
#include "sync/protocol/sync.pb.h"
namespace wifi_sync {