I need to work with array from several threads, so I use CRITICAL SECTION to give it an exclusive access to the data. Here is my template:
#include \"std
so, it`s something wrong with access rights. I made size() method non-const and now it is ok.