Commit 75bbd63e authored by Jan Wilken Dörrie's avatar Jan Wilken Dörrie Committed by Commit Bot

[base] Apply BindOnceRewriter in //mojo

This change applies the BindOnceRewriter in //mojo.
This rewriter replaces calls to base::Bind and base::BindRepeating with
calls to base::BindOnce, in case the result is immediately assigned to a
base::OnceCallback. Given that base::RepeatingCallback is implicitly
convertible to base::OnceCallback, there is no change in functionality.

Steps:
  1. run_tool.py --tool base_bind_rewriters \
                 --tool-arg='--rewriter=bind_to_bind_once'
  2. git cl format

This CL was uploaded by git cl split.

R=sky@chromium.org

Bug: 714018
Change-Id: Iad24325ddf3b59c0f89c48cb3549331fc8ac3495
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2132395
Auto-Submit: Jan Wilken Dörrie <jdoerrie@chromium.org>
Commit-Queue: Scott Violet <sky@chromium.org>
Reviewed-by: default avatarScott Violet <sky@chromium.org>
Cr-Commit-Position: refs/heads/master@{#760502}
parent d81108a6
......@@ -31,8 +31,8 @@ class IPCSupport {
~IPCSupport() {
base::WaitableEvent wait(base::WaitableEvent::ResetPolicy::MANUAL,
base::WaitableEvent::InitialState::NOT_SIGNALED);
mojo::core::Core::Get()->RequestShutdown(base::BindRepeating(
&base::WaitableEvent::Signal, base::Unretained(&wait)));
mojo::core::Core::Get()->RequestShutdown(
base::BindOnce(&base::WaitableEvent::Signal, base::Unretained(&wait)));
wait.Wait();
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment