Opened 7 years ago

#6353 new Support Requests

memory layout specifiers doc clarification

Reported by: cppljevans Owned by: Ronald Garcia
Milestone: To Be Determined Component: multi_array
Version: Boost 1.48.0 Severity: Cosmetic
Keywords: stride docs Cc:


Contains an ambiguous specification of storage ordering. This lead me to making the wrong assumption about the meaning as shown by the following post:

As indicated in that post, *if* I had read the page:

the meaning or storage ordering would have been clear; however, I thought reading the reference.html#memory_layout page would have been the most unambiguous doc since it is the reference manual.

I think the following snippet of code, or something similar, on the reference.html#memory_layout would make the meaning clearer:

  ( std::vector<unsigned> const& a_permut 
      //storage order(a permutaion 0..a_lengths.size()-1)
  , std::vector<unsigned> const& a_lengths
      //length of axes.
    unsigned const n=a_lengths.size();
    std::vector<unsigned> strides(n);
    for( unsigned i=1; i<n; ++i) 
        unsigned i_prev=permut_i[i-1];
    return strides;//strides of the axes

Change History (0)

Note: See TracTickets for help on using tickets.