Commit 356d04f6 authored by Christopher Dykes's avatar Christopher Dykes Committed by Facebook Github Bot

Don't explicitly disable the C++1y-extensions warning in ForEach-inl and WhenN-inl

Summary: We are fully on C++14 now, so these warnings should never be firing.

Reviewed By: yfeldblum

Differential Revision: D5179124

fbshipit-source-id: 31c6ddbce5c45b60fe73990f49d65ac95d17fe87
parent 7c600a5a
......@@ -49,10 +49,6 @@ inline void forEach(InputIterator first, InputIterator last, F&& f) {
std::exception_ptr e;
Baton baton;
#ifdef __clang__
#pragma clang diagnostic push // ignore generalized lambda capture warning
#pragma clang diagnostic ignored "-Wc++1y-extensions"
#endif
auto taskFunc = [&tasksTodo, &e, &f, &baton](size_t id, FuncType&& func) {
return [
id,
......@@ -72,9 +68,6 @@ inline void forEach(InputIterator first, InputIterator last, F&& f) {
}
};
};
#ifdef __clang__
#pragma clang diagnostic pop
#endif
auto firstTask = first;
++first;
......
......@@ -53,10 +53,6 @@ collectN(InputIterator first, InputIterator last, size_t n) {
await([first, last, context](Promise<void> promise) mutable {
context->promise = std::move(promise);
for (size_t i = 0; first != last; ++i, ++first) {
#ifdef __clang__
#pragma clang diagnostic push // ignore generalized lambda capture warning
#pragma clang diagnostic ignored "-Wc++1y-extensions"
#endif
addTask([ i, context, f = std::move(*first) ]() {
try {
auto result = f();
......@@ -74,9 +70,6 @@ collectN(InputIterator first, InputIterator last, size_t n) {
context->promise->setValue();
}
});
#ifdef __clang__
#pragma clang diagnostic pop
#endif
}
});
......@@ -114,10 +107,6 @@ collectN(InputIterator first, InputIterator last, size_t n) {
await([first, last, context](Promise<void> promise) mutable {
context->promise = std::move(promise);
for (size_t i = 0; first != last; ++i, ++first) {
#ifdef __clang__
#pragma clang diagnostic push // ignore generalized lambda capture warning
#pragma clang diagnostic ignored "-Wc++1y-extensions"
#endif
addTask([ i, context, f = std::move(*first) ]() {
try {
f();
......@@ -135,9 +124,6 @@ collectN(InputIterator first, InputIterator last, size_t n) {
context->promise->setValue();
}
});
#ifdef __clang__
#pragma clang diagnostic pop
#endif
}
});
......
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