libycxx

constructor · 12 overloads

std::polymorphic::polymorphic

Header
<memory>
Scope
std::polymorphic
cppreference
<memory> nearest page

Constructors

Overloads

  1. explicit constexpr polymorphic()  requires is_default_constructible_v<Allocator>;
    (1)
  2. constexpr polymorphic(const polymorphic& other);
    (2)
  3. constexpr polymorphic(polymorphic&& other) noexcept;
    (3)
  4. template<class U = T>
      requires (!is_same_v<remove_cvref_t<U>, polymorphic>) && owned-ok<remove_cvref_t<U>, U> &&
                (!is-in-place-type<remove_cvref_t<U>>) && is_default_constructible_v<Allocator>
    explicit constexpr polymorphic(U&& u);
    (4)
  5. explicit constexpr polymorphic(allocator_arg_t, const Allocator& a);
    (5)
  6. template<class U, class... Ts>
      requires is_same_v<remove_cvref_t<U>, U> && owned-ok<U, Ts...> && is_default_constructible_v<Allocator>
    explicit constexpr polymorphic(in_place_type_t<U>, Ts&&... ts);
    (6)
  7. constexpr polymorphic(
        allocator_arg_t,
        const Allocator& a,
        const polymorphic& other);
    (7)
  8. constexpr polymorphic(
        allocator_arg_t,
        const Allocator& a,
        polymorphic&& other) noexcept(traits::is_always_equal::value);
    (8)
  9. template<class U = T>
      requires (!is_same_v<remove_cvref_t<U>, polymorphic>) && owned-ok<remove_cvref_t<U>, U> &&
                (!is-in-place-type<remove_cvref_t<U>>)
    explicit constexpr polymorphic(allocator_arg_t, const Allocator& a, U&& u);
    (9)
  10. template<class U, class I, class... Us>
      requires is_same_v<remove_cvref_t<U>, U> && owned-ok<U, initializer_list<I>&, Us...> &&
                 is_default_constructible_v<Allocator>
    explicit constexpr polymorphic(
        in_place_type_t<U>,
        initializer_list<I> ilist,
        Us&&... us);
    (10)
  11. template<class U, class... Ts>
      requires is_same_v<remove_cvref_t<U>, U> && owned-ok<U, Ts...>
    explicit constexpr polymorphic(
        allocator_arg_t,
        const Allocator& a,
        in_place_type_t<U>,
        Ts&&... ts);
    (11)
  12. template<class U, class I, class... Us>
      requires is_same_v<remove_cvref_t<U>, U> && owned-ok<U, initializer_list<I>&, Us...>
    explicit constexpr polymorphic(
        allocator_arg_t,
        const Allocator& a,
        in_place_type_t<U>,
        initializer_list<I> ilist,
        Us&&... us);
    (12)