Project

General

Profile

Actions

Bug #2290

closed

C++11 implicit conversion error in boost

Added by soratobu kuroneko over 10 years ago. Updated over 10 years ago.

Status:
Closed
Priority:
Normal
Assignee:
Target version:
Start date:
10/06/2013
Due date:
% Done:

0%

Estimated time:

Description

With WT_CPP_11_MODE=-std=c++11, BUILD_EXAMPLES=ON and INSTALL_EXAMPLES=ON

When building examples/feature/locale/locale.C in C++11, the compiler gives an error about implicit conversion in boost

See workaround: http://stackoverflow.com/questions/15234527/boost-1-53-local-date-time-compiler-error-with-std-c0x

In file included from /usr/local/include/boost/date_time/local_time/local_time_types.hpp:18:0,
                 from /usr/local/include/boost/date_time/local_time/local_time.hpp:13,
                 from test.h:4,
                 from test.cpp:1: /usr/local/include/boost/date_time/local_time/custom_time_zone.hpp: In instantiation of ‘bool boost::local_time::custom_time_zone_base<CharT>::has_dst() const [with CharT = char]’: test.cpp:11:1:   required from here /usr/local/include/boost/date_time/local_time/custom_time_zone.hpp:67:30: error: cannot convert ‘const boost::shared_ptr<boost::date_time::dst_day_calc_rule<boost::gregorian::date>>’ to ‘bool’ in return

Compilers tested:

- gcc version 4.8.1 20130725

  • clang version 3.3 (tags/RELEASE_33/final)
    OS: Arch Linux x86_64
    boost version: 1.54.0

Files

workaround-boost-c 11-locale-example.patch (522 Bytes) workaround-boost-c 11-locale-example.patch workaround to build locale.C in C++11 soratobu kuroneko, 10/06/2013 10:38 PM
Actions #1

Updated by Koen Deforche over 10 years ago

  • Status changed from New to Resolved
  • Assignee set to Koen Deforche
  • Target version set to 3.3.1

Hey,

Thanks for the patch. I stumbled on this too but didn't think a workaround was possible!

koen

Actions #2

Updated by Koen Deforche over 10 years ago

  • Status changed from Resolved to Closed
Actions

Also available in: Atom PDF