------- Comment #21 from jb at gcc dot gnu dot org  2010-04-28 15:43 -------
(In reply to comment #19)
> (In reply to comment #18)
> >  3) for the same reason you can also drop the + 1 in computing the 
> > allocation
> > size which is currently (ubound - lbound + 1) * 4
> 
> Sorry, but isn't +1 needed because bounds are inclusive?
> 

Yes.

As an aside, for the 4.6 array descriptor update, there has been some
discussion to move from the current (lbound, ubound, stride) triplet for every
dimension to (lbound, stride, extent). Which would change these kinds of
expressions.


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=42958

Reply via email to