Izzy a écrit :
> why shouldn't I use them? With the arrays I have direct access to
> memory location of the array,
This is the problem, you have to understand why it doesn't work ;) I
attach an example of code that don't run as expected. The explanation is
the objects stored in the array are accessed like based object and not
as the real object type. This break everything. I guess you are in the
> while using containers looping with iterators take a precious CPU time.
Maybe because it makes the work you didn't when allocating you're array ?
> But this is another thing, programing style and
> preferance of using or STL or simple arrays. It should work with both,
> but it didn't.
No, It couldn't, you seen it :) In the boost project, it was added
boost::array<> template, to provide a safe-type c-array style.
It is not a programming style, it is about well programming in C++.
Actually, it is considered harmfull to use widely the new operator, and
it is worse to use new  operator.
Mickaël Wolff aka Lupus Michaelis
Attachment: [text/x-c++src] array.cpp