facebook / fbthrift

Facebook's branch of Apache Thrift, including a new C++ server.
Apache License 2.0
2.55k stars 607 forks source link

Add missing include for std::pair #589

Closed earies closed 6 months ago

earies commented 6 months ago

Add missing dependency brought in by commit https://github.com/facebook/fbthrift/commit/feac5a544abf4326abce30f32b3a864161a70a14

/tmp/fbthrift/./thrift/lib/cpp2/async/ServerRequestData.h:48:44: error: ‘pair’ in namespace ‘std’ does not name a template type
   48 |   using RoundRobinRequestPileBucket = std::pair<size_t, size_t>;
      |                                            ^~~~
/tmp/fbthrift/./thrift/lib/cpp2/async/ServerRequestData.h:22:1: note: ‘std::pair’ is defined in header ‘<utility>’; did you forget to ‘#include <utility>’?
   21 | #include <optional>
  +++ |+#include <utility>
   22 |
/tmp/fbthrift/./thrift/lib/cpp2/async/ServerRequestData.h:49:17: error: ‘RoundRobinRequestPileBucket’ was not declared in this scope
   49 |   std::optional<RoundRobinRequestPileBucket> bucket;
      |                 ^~~~~~~~~~~~~~~~~~~~~~~~~~~
/tmp/fbthrift/./thrift/lib/cpp2/async/ServerRequestData.h:49:44: error: template argument 1 is invalid
   49 |   std::optional<RoundRobinRequestPileBucket> bucket;
      |                                            ^
make[2]: *** [thrift/lib/cpp2/CMakeFiles/thriftcpp2.dir/build.make:496: thrift/lib/cpp2/CMakeFiles/thriftcpp2.dir/async/ServerRequestData.cpp.o] Error 1
make[2]: *** Waiting for unfinished jobs....
facebook-github-bot commented 6 months ago

@vitaut has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator.

facebook-github-bot commented 6 months ago

@vitaut merged this pull request in facebook/fbthrift@f31ba2499e61d7acd843fc0fd22ff351aa009bc0.