[RISCV] Fix mgather -> riscv.masked.strided.load combine not extending indices (...
[llvm-project.git] / libcxx / test / std / thread / futures / futures.task / futures.task.members / ctor1.verify.cpp
blob3c61c76ea9802ad1cf955900b26a07437a08535f
1 //===----------------------------------------------------------------------===//
2 //
3 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4 // See https://llvm.org/LICENSE.txt for license information.
5 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6 //
7 //===----------------------------------------------------------------------===//
8 //
9 // UNSUPPORTED: no-threads
10 // UNSUPPORTED: c++03
12 // <future>
14 // class packaged_task<R(ArgTypes...)>
15 // template <class F>
16 // packaged_task(F&& f);
17 // These constructors shall not participate in overload resolution if
18 // decay<F>::type is the same type as std::packaged_task<R(ArgTypes...)>.
20 #include <future>
21 #include <cassert>
23 struct A {};
24 typedef std::packaged_task<A(int, char)> PT;
25 typedef volatile std::packaged_task<A(int, char)> VPT;
28 int main(int, char**)
30 VPT init{};
31 auto const& c_init = init;
32 PT p1{init}; // expected-error {{no matching constructor}}
33 PT p2{c_init}; // expected-error {{no matching constructor}}
34 PT p3{std::move(init)}; // expected-error {{no matching constructor for initialization of 'PT' (aka 'packaged_task<A (int, char)>')}}
36 return 0;