New issue
Advanced search Search tips

Issue 732437 link

Starred by 1 user

Issue metadata

Status: Fixed
Owner:
Closed: Jun 2017
Cc:
EstimatedDays: ----
NextAction: ----
OS: Linux
Pri: 3
Type: Bug



Sign in to add a comment

content::V8ValueConverter::create() should return a unique_ptr

Project Member Reported by rdevlin....@chromium.org, Jun 12 2017

Issue description

content::V8ValueConverter::create() should return a unique_ptr.

While we're at it, may as well also format it as Create() (capital-C).
 
Project Member

Comment 1 by bugdroid1@chromium.org, Jun 13 2017

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/694c6057a16e65dca77d04ba04c3cb35440b9f44

commit 694c6057a16e65dca77d04ba04c3cb35440b9f44
Author: rdevlin.cronin <rdevlin.cronin@chromium.org>
Date: Tue Jun 13 22:07:35 2017

[Content] Update V8ValueConverter::create to return a std::unique_ptr

Instead of returning a raw pointer with ownership, have
content::V8ValueConverter::Create return a unique_ptr. This is a)
safer, since ownership is clear and safe by default and b) has the
added bonus of making inline calls easier (e.g.,
V8ValueConverter::Create()->ToV8Value()).

Also s/create()/Create() to match Chromium style.

BUG= 732437 

Review-Url: https://codereview.chromium.org/2931393003
Cr-Commit-Position: refs/heads/master@{#479172}

[modify] https://crrev.com/694c6057a16e65dca77d04ba04c3cb35440b9f44/chrome/renderer/extensions/app_bindings_core.cc
[modify] https://crrev.com/694c6057a16e65dca77d04ba04c3cb35440b9f44/chrome/renderer/extensions/cast_streaming_native_handler.cc
[modify] https://crrev.com/694c6057a16e65dca77d04ba04c3cb35440b9f44/chrome/renderer/extensions/platform_keys_natives.cc
[modify] https://crrev.com/694c6057a16e65dca77d04ba04c3cb35440b9f44/chrome/renderer/sandbox_status_extension_android.cc
[modify] https://crrev.com/694c6057a16e65dca77d04ba04c3cb35440b9f44/components/plugins/renderer/loadable_plugin_placeholder.cc
[modify] https://crrev.com/694c6057a16e65dca77d04ba04c3cb35440b9f44/content/child/v8_value_converter_impl.cc
[modify] https://crrev.com/694c6057a16e65dca77d04ba04c3cb35440b9f44/content/public/child/v8_value_converter.h
[modify] https://crrev.com/694c6057a16e65dca77d04ba04c3cb35440b9f44/content/renderer/gpu/gpu_benchmarking_extension.cc
[modify] https://crrev.com/694c6057a16e65dca77d04ba04c3cb35440b9f44/content/renderer/java/gin_java_bridge_value_converter.cc
[modify] https://crrev.com/694c6057a16e65dca77d04ba04c3cb35440b9f44/content/renderer/skia_benchmarking_extension.cc
[modify] https://crrev.com/694c6057a16e65dca77d04ba04c3cb35440b9f44/content/renderer/web_ui_extension.cc
[modify] https://crrev.com/694c6057a16e65dca77d04ba04c3cb35440b9f44/extensions/renderer/activity_log_converter_strategy_unittest.cc
[modify] https://crrev.com/694c6057a16e65dca77d04ba04c3cb35440b9f44/extensions/renderer/api_activity_logger.cc
[modify] https://crrev.com/694c6057a16e65dca77d04ba04c3cb35440b9f44/extensions/renderer/api_binding_test_util.cc
[modify] https://crrev.com/694c6057a16e65dca77d04ba04c3cb35440b9f44/extensions/renderer/api_event_handler.cc
[modify] https://crrev.com/694c6057a16e65dca77d04ba04c3cb35440b9f44/extensions/renderer/api_event_listeners.cc
[modify] https://crrev.com/694c6057a16e65dca77d04ba04c3cb35440b9f44/extensions/renderer/api_request_handler.cc
[modify] https://crrev.com/694c6057a16e65dca77d04ba04c3cb35440b9f44/extensions/renderer/api_signature.cc
[modify] https://crrev.com/694c6057a16e65dca77d04ba04c3cb35440b9f44/extensions/renderer/argument_spec.cc
[modify] https://crrev.com/694c6057a16e65dca77d04ba04c3cb35440b9f44/extensions/renderer/dispatcher.cc
[modify] https://crrev.com/694c6057a16e65dca77d04ba04c3cb35440b9f44/extensions/renderer/display_source_custom_bindings.cc
[modify] https://crrev.com/694c6057a16e65dca77d04ba04c3cb35440b9f44/extensions/renderer/dom_activity_logger.cc
[modify] https://crrev.com/694c6057a16e65dca77d04ba04c3cb35440b9f44/extensions/renderer/event_bindings.cc
[modify] https://crrev.com/694c6057a16e65dca77d04ba04c3cb35440b9f44/extensions/renderer/guest_view/guest_view_internal_custom_bindings.cc
[modify] https://crrev.com/694c6057a16e65dca77d04ba04c3cb35440b9f44/extensions/renderer/guest_view/mime_handler_view/mime_handler_view_container.cc
[modify] https://crrev.com/694c6057a16e65dca77d04ba04c3cb35440b9f44/extensions/renderer/i18n_custom_bindings.cc
[modify] https://crrev.com/694c6057a16e65dca77d04ba04c3cb35440b9f44/extensions/renderer/messaging_bindings.cc
[modify] https://crrev.com/694c6057a16e65dca77d04ba04c3cb35440b9f44/extensions/renderer/runtime_custom_bindings.cc
[modify] https://crrev.com/694c6057a16e65dca77d04ba04c3cb35440b9f44/extensions/renderer/script_context.cc
[modify] https://crrev.com/694c6057a16e65dca77d04ba04c3cb35440b9f44/extensions/renderer/script_injection.cc
[modify] https://crrev.com/694c6057a16e65dca77d04ba04c3cb35440b9f44/extensions/renderer/send_request_natives.cc
[modify] https://crrev.com/694c6057a16e65dca77d04ba04c3cb35440b9f44/extensions/renderer/test_features_native_handler.cc
[modify] https://crrev.com/694c6057a16e65dca77d04ba04c3cb35440b9f44/extensions/renderer/web_request_hooks.cc

Status: Fixed (was: Started)

Sign in to add a comment