Commit 088fab7c authored by Uladzislau Paulovich's avatar Uladzislau Paulovich Committed by Facebook Github Bot

folly | Remove unnecessary reinterpret_cast in Executor

Summary: Input and output types for the cast are the same (except const qualifier) and therefore it's not required.

Reviewed By: milend

Differential Revision: D15694981

fbshipit-source-id: d5a811d97cc145ba9c232b79f6c8fa52041b0cf0
parent 6c7906af
...@@ -215,8 +215,7 @@ class Executor { ...@@ -215,8 +215,7 @@ class Executor {
*/ */
template <typename ExecutorT> template <typename ExecutorT>
static bool isKeepAliveDummy(const KeepAlive<ExecutorT>& keepAlive) { static bool isKeepAliveDummy(const KeepAlive<ExecutorT>& keepAlive) {
return reinterpret_cast<uintptr_t>(keepAlive.storage_) & return keepAlive.storage_ & KeepAlive<ExecutorT>::kDummyFlag;
KeepAlive<ExecutorT>::kDummyFlag;
} }
// Acquire a keep alive token. Should return false if keep-alive mechanism // Acquire a keep alive token. Should return false if keep-alive mechanism
......
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