El 21/09/2016 a las 6:58, Ram escribió:
Hi,
I simplified my problem to make sure it was not because of my class or something like
that, this is the exact content(related to boost::multi_index) in the header file,

Hi,

First of all, please follow this list's posting guidelines and do use inline replies after a small
portion of the post you're replying to for context, just like I'm doing here and is explained at

http://www.boost.org/community/policy.html#quoting

Now to your question.

example.h

#include <boost/multi_index_container.hpp>
#include <boost/multi_index/mem_fun.hpp>
#include <boost/multi_index/hashed_index.hpp>

[...]

In the corresponding cpp file
example.cpp
void MgrABC::_handler() {
<already existing code 4 or 5 lines of variable declarations>
.
.
.

this->sample1.insert(1);

OK, let's try a couple of things:

1. Can you please fetch your local
c:\sample\common\lib\boost\boost\detail\allocator_utilities.hpp file and
send it back attached?
2. Where your testing code says

  this->sample1.insert(1);

remove that statement and write the following:

  int x=0,y=0;
  boost::detail::allocator::construct(&x,y);

What is the observed behavior on compilation?

Joaquín M López Muñoz