
15 Jun
2009
15 Jun
'09
7:44 p.m.
Amit Kumar skrev:
Please consider the following code:
#include "boost/ptr_container/ptr_map.hpp"
int main() { typedef boost::ptr_multimap<char, const int> M;
M m; char c = 'c';
int* j = new int(7);
m.insert(c, j);
return 0; }
The gcc 4.3.3 compiler fails to compiler the above code. Am I doing something wrong by inserting a non-const? Can't I store a pointer to const in the multimap?
This is currently unsupported, though I might get it to work. I'll put it on my todo list. -Thorsten