Boost logo

Boost :

From: Ronald Garcia (garcia_at_[hidden])
Date: 2004-10-11 14:44:00

Greetings Anders,

On Oct 11, 2004, at 12:18 PM, Anders Edin wrote:

> It appears multi_array uses a boost::array internally to store this
> information, and uses the data() method to return a pointer in the
> above
> methods. Wouldn't it be better to return a reference to the array
> directly:

The multi_array class template matches the requirements of the
MultiArray concept, which specifies that the member functions that you
mention return pointers. Other types in the Boost.MultiArray library,
such as views and subarrays also implement MultiArray, but subarrays
for example do not store the same information in boost::arrays. Thus
the various types share a common interface so that they can be used

Hope this helps,


Boost list run by bdawes at, gregod at, cpdaniel at, john at