"Josue Gomes" wrote in message
news:cvkdik$qjk$1@sea.gmane.org...
| Hi,
|
|
| Take this code:
[snip]
| It compiles fine with VC 7.1. However g++ 3.3 and 3.4
| (both on Linux) refuse to compile it.
|
| See the error message (excerpt):
|
| sample.cpp:36: instantiated from here
| /usr/include/c++/3.4/bits/stl_pair.h:90: error: call of overloaded
| `map(const boost::assign_detail::generic_list > > >&)' is ambiguous
| /usr/include/c++/3.4/bits/stl_map.h:166: note: candidates are:
| Any ideas of what is going on here?
it seems that several map constructors together with a implicit convertion
operator
creates an ambiguity.
I must admit a deeper look might be necessary. Until then, I would try to use
insert( my_map ) to remove the outer most call to map_list_of().
Secondly, using list_of can also have a positive effect.
-Thorsten