Path: csiph.com!x330-a1.tempe.blueboxinc.net!usenet.pasdenom.info!aioe.org!news.swapon.de!fu-berlin.de!uni-berlin.de!individual.net!not-for-mail From: Ian Collins Newsgroups: comp.lang.c++ Subject: Re: Understanding ValArray slices Date: Thu, 14 Apr 2011 09:50:36 +1200 Lines: 28 Message-ID: <90mk5cFeeiU8@mid.individual.net> References: Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Trace: individual.net 2O09XEAza+uFd+UIS83kZw0101l+kWyR//E0MlqwT/0k7sk/no Cancel-Lock: sha1:4WCs+HDckaxS+Ama70rEJxJ3Ox8= User-Agent: Mozilla/5.0 (X11; U; SunOS i86pc; en-US; rv:1.9.2.9) Gecko/20101021 Lightning/1.0b2 Thunderbird/3.1.4 In-Reply-To: Xref: x330-a1.tempe.blueboxinc.net comp.lang.c++:3608 On 04/14/11 09:44 AM, jacob navia wrote: > Hi > > I have some trouble understanding what are the ValArray slices classes. > > Are they just like pointers in the sense that they do not copy the data > but just select it? They a a collection of indices into a valarray. > Or are they arrays of their own with their own data. > > Or do they produce an array of indices? Yes. > ValArray classes aren't even mentioned in the C++ Primer book (Lippman > et al) not are they mentioned in the one of Plaugher. The only docs are > some scanty web pages and the standard, what is not that easy to > understand. > > Thanks in advance for some short tutorial or a pointer to one. The standard (and excellent) reference is "The C++ Standard Library" by Nicolai M. Josuttis. -- Ian Collins