Re: [Boost-bugs] [Boost C++ Libraries] #4191: c++ library using regex included in objective-c needs rename of variable id

Subject: Re: [Boost-bugs] [Boost C++ Libraries] #4191: c++ library using regex included in objective-c needs rename of variable id
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2010-08-02 11:59:15


#4191: c++ library using regex included in objective-c needs rename of variable id
--------------------------------+-------------------------------------------
  Reporter: lydisworld@… | Owner: johnmaddock
      Type: Patches | Status: closed
 Milestone: Boost 1.43.0 | Component: regex
   Version: Boost 1.42.0 | Severity: Problem
Resolution: fixed | Keywords:
--------------------------------+-------------------------------------------

Comment (by anonymous):

 I use FSF's gcc-4.2.4 objc++ compiler and, as opposed to Apple's compiler,
 this one also chokes on variables / template params with the name
 'Protocol'. A simple workaround so far is to redefine these before
 including boost, but it's quite a mess. Would it be viable to change all
 instances of Protocol (and presumably protocol) also ;)?

 In any case, I can imagine someone coming across the same issue, the
 work-around is as follows:
 {{{
 #define id cpp_id
 #define Protocol cpp_Protocol
 #include <boost/asio.hpp>
 #undef id
 #undef Protocol
 }}}

-- 
Ticket URL: <https://svn.boost.org/trac/boost/ticket/4191#comment:2>
Boost C++ Libraries <http://www.boost.org/>
Boost provides free peer-reviewed portable C++ source libraries.

This archive was generated by hypermail 2.1.7 : 2017-02-16 18:50:04 UTC