Home | History | Annotate | Download | only in futures.overview
      1 //===----------------------------------------------------------------------===//
      2 //
      3 //                     The LLVM Compiler Infrastructure
      4 //
      5 // This file is dual licensed under the MIT and the University of Illinois Open
      6 // Source Licenses. See LICENSE.TXT for details.
      7 //
      8 //===----------------------------------------------------------------------===//
      9 //
     10 // UNSUPPORTED: libcpp-has-no-threads
     11 
     12 // <future>
     13 
     14 // enum class future_errc
     15 // {
     16 //     future_already_retrieved = 1,
     17 //     promise_already_satisfied,
     18 //     no_state
     19 //     broken_promise,
     20 // };
     21 
     22 #include <future>
     23 
     24 int main()
     25 {
     26     static_assert(static_cast<int>(std::future_errc::future_already_retrieved) == 1, "");
     27     static_assert(static_cast<int>(std::future_errc::promise_already_satisfied) == 2, "");
     28     static_assert(static_cast<int>(std::future_errc::no_state) == 3, "");
     29     static_assert(static_cast<int>(std::future_errc::broken_promise) == 4, "");
     30 }
     31