Commit 368266c3 authored by Hans Fugal's avatar Hans Fugal Committed by Tudor Bosman

s/setCallback_/setCallback/ for detail::State

Summary: This isn't really an internal-to-this-class method. :-/

Test Plan: builds

Reviewed By: hannesr@fb.com

Subscribers: jsedgwick, net-systems@, fugalh, exa

FB internal diff: D1412008
parent 82ab3bae
...@@ -59,7 +59,7 @@ template <class T> ...@@ -59,7 +59,7 @@ template <class T>
template <class F> template <class F>
void Future<T>::setCallback_(F&& func) { void Future<T>::setCallback_(F&& func) {
throwIfInvalid(); throwIfInvalid();
state_->setCallback_(std::move(func)); state_->setCallback(std::move(func));
state_ = nullptr; state_ = nullptr;
} }
......
...@@ -47,9 +47,9 @@ class State { ...@@ -47,9 +47,9 @@ class State {
} }
template <typename F> template <typename F>
void setCallback_(F func) { void setCallback(F func) {
if (callback_) { if (callback_) {
throw std::logic_error("setCallback_ called twice"); throw std::logic_error("setCallback called twice");
} }
callback_ = std::move(func); callback_ = std::move(func);
......
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