valarray();
Effects:
Constructs a
valarray
that has zero length
. explicit valarray(size_t n);
Effects:
Constructs a
valarray that has length
n. Each element of the array is value-initialized (
[dcl.init])
.valarray(const T& v, size_t n);
Effects:
Constructs a
valarray that has length
n. Each element of the array is initialized with
v.valarray(const T* p, size_t n);
Requires:
p points to an array (
[dcl.array]) of at least
n elements
. Effects:
Constructs a
valarray that has length
n. The values of the elements of the array are initialized with the
first
n
values pointed to by the first argument
.valarray(const valarray& v);
Effects:
Constructs a
valarray that has the same length as
v. The elements are initialized with the values of the corresponding
elements of
v.valarray(valarray&& v) noexcept;
Effects:
Constructs a
valarray that has the same length as
v. The elements are initialized with the values of the corresponding
elements of
v.valarray(initializer_list<T> il);
Effects: Equivalent to
valarray(il.begin(), il.size()). valarray(const slice_array<T>&);
valarray(const gslice_array<T>&);
valarray(const mask_array<T>&);
valarray(const indirect_array<T>&);
These conversion constructors convert one of the four reference templates
to a
valarray.~valarray();
Effects:
The destructor is applied to every element of
*this;
an implementation may return all allocated memory
.