Status: New
Owner: liuj...@google.com
Labels: Type-Defect Priority-Medium

New issue 445 by muka...@gmail.com: "reference to 'map' is ambiguous" error on solaris-10
http://code.google.com/p/protobuf/issues/detail?id=445

What steps will reproduce the problem?
1. Build generated code on Solaris-10

What is the expected output? What do you see instead?
                In file included from monitor/head/protobuf/Stream.pb.h:24:0,
from monitor/head/modules/test/../spout/protocol_engine.hh:11, from monitor/head/modules/test/mock_spout_protocol_engine.hh:10,
                                 from 
monitor/head/modules/test/mock_ctors_dtors.cc:11:
protobuf/head/target/include/google/protobuf/extension_set.h:484:3: error: reference to 'map' is ambiguous In file included from boost/head/target/include/boost/asio/detail/socket_types.hpp:70:0, from boost/head/target/include/boost/asio/detail/posix_fd_set_adapter.hpp:24, from boost/head/target/include/boost/asio/detail/fd_set_adapter.hpp:19, from boost/head/target/include/boost/asio/detail/select_reactor.hpp:27, from boost/head/target/include/boost/asio/detail/reactor.hpp:27, from boost/head/target/include/boost/asio/detail/impl/task_io_service.ipp:24, from boost/head/target/include/boost/asio/detail/task_io_service.hpp:217, from boost/head/target/include/boost/asio/impl/io_service.hpp:71, from boost/head/target/include/boost/asio/io_service.hpp:767, from boost/head/target/include/boost/asio/basic_io_object.hpp:19, from boost/head/target/include/boost/asio/basic_socket.hpp:19, from boost/head/target/include/boost/asio/basic_datagram_socket.hpp:20,
                                 from 
boost/head/target/include/boost/asio.hpp:20,
                                 from libnomxx/head/nommt/cc/mgr.hh:12,
                                 from libnomxx/head/nommt/cc/conn.hh:17,
                                 from libnomxx/head/nommt/actor/cc/mgr.hh:16,
from monitor/head/modules/include/modules/search/algo.hh:16,
                                 from monitor/head/modules/test/mock_algo.hh:12,
                                 from 
monitor/head/modules/test/mock_ctors_dtors.cc:7:
                /usr/include/net/if.h:99:9: error: candidates are: struct map
In file included from /usr/local/nombuild/2012-1/lib/gcc/sparc64-sun-solaris2.10/4.7.1/../../../../include/c++/4.7.1/map:61:0, from googlemock/head/gmock-1.6.0/include/gmock/gmock-spec-builders.h:63, from googlemock/head/gmock-1.6.0/include/gmock/gmock-generated-function-mockers.h:43, from googlemock/head/gmock-1.6.0/include/gmock/gmock.h:61,
                                 from monitor/head/modules/test/mock_algo.hh:10,
                                 from 
monitor/head/modules/test/mock_ctors_dtors.cc:7:
/usr/local/nombuild/2012-1/lib/gcc/sparc64-sun-solaris2.10/4.7.1/../../../../include/c++/4.7.1/bits/stl_map.h:90:11: error: template<class _Key, class _Tp, class _Compare, class _Alloc> class std::map
                In file included from monitor/head/protobuf/Stream.pb.h:24:0,
from monitor/head/modules/test/../spout/protocol_engine.hh:11, from monitor/head/modules/test/mock_spout_protocol_engine.hh:10,
                                 from 
monitor/head/modules/test/mock_ctors_dtors.cc:11:
protobuf/head/target/include/google/protobuf/extension_set.h:484:3: error: 'map' does not name a type

What version of the product are you using? On what operating system?
protobuf-2.4.1
solaris-10 (both sparc and x86)
gcc version 4.7.1 (GCC)

Please provide any additional information below.
Proposed patch attached.


Attachments:
        ambiguous_map.patch  494 bytes

--
You received this message because you are subscribed to the Google Groups "Protocol 
Buffers" group.
To post to this group, send email to protobuf@googlegroups.com.
To unsubscribe from this group, send email to 
protobuf+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/protobuf?hl=en.

Reply via email to