GeezerVisonThe World Wide Web, restored to 800 pixels of glory. | |||||||
| Home|About|Gaming cabinet|Archives|How it works|Starter sites | |||||||
GeezerVison is showing cplusplus.com — std::begin (valarray) Reference
valarray
function template
<valarray>
std::begin (valarray)
Iterator to beginning
Note that valarray objects have no member function begin defined nor have iterator member types: The iterator returned is a random-access iterator of an unspecified type whose value_type is T and its reference type is T& for (1) and const T& for (2) (it is a mutable iterator for (1), and a constant iterator for (2)).If the object is an empty valarray, the returned value shall not be dereferenced. This is an overload of begin, defined in <iterator> (among other headers).Parameters
Return ValueA random-access iterator to the first element of x.Example
Output:
ComplexityDepends on library implementation.Iterator validityNo changes: Other valid iterators, references and sub-arrays keep their validity.Data racesThe valarray is accessed, and in some library implementations, version (1) may also modify it (such as in copy-on-reference implementations).The iterator returned can be used to access or modify the elements of the valarray. Exception safetyIf the function implementation performs operations on the elements, and any such operation throws an exception, it causes undefined behavior.If the function needs to allocate storage and fails, it may throw an exception (such as bad_alloc), although this is not mandated. See also
Home page | Privacy policy
© cplusplus.com, 2000-2026 - All rights reserved - v3.3.4s Spotted an error? contact us | |||||||
| You are visitor 01402503 — GeezerVison does not store the pages you look up. Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required. |