This is the mail archive of the libstdc++@gcc.gnu.org mailing list for the libstdc++ project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [[patch] valarray (was Re: valarray_copy implementation question)


Gaby

dest.size() after the array assignment also reports 1.

dest[b] = src;

std::cout << dest.size() << std:: endl;

Christian BRUEL wrote:
Hello Gaby,

I'm sorry to insist, but the array expression dest[b] has length 1. so all arrays have equal length.

if you want to check from the debuger or with

std::cout << b.size() << std:: endl;

Best Regards

Christian


the array expression `dest[b]' has length 0; the array expression `src' has length 1. That violates the equal length precondition.

 return 0;
}

is it a user error also ?

yes; it is user confusion; the same as we discussed before.


-- Gaby




Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]