Ticket #10347: program_options_without_rtti.patch

File program_options_without_rtti.patch, 1.2 KB (added by Minmin Gong <gongminmin@…>, 8 years ago)
  • boost/boost/program_options/value_semantic.hpp

    diff -r 72f5890881c2 boost/boost/program_options/value_semantic.hpp
    a b  
    1212#include <boost/any.hpp>
    1313#include <boost/function/function1.hpp>
    1414#include <boost/lexical_cast.hpp>
     15#include <boost/core/typeinfo.hpp>
    1516
    1617
    1718#include <string>
    1819#include <vector>
    19 #include <typeinfo>
    2020
    2121namespace boost { namespace program_options {
    2222
     
    167167    public:
    168168        // Returns the type of the value described by this
    169169        // object.
    170         virtual const std::type_info& value_type() const = 0;
     170        virtual const boost::core::typeinfo& value_type() const = 0;
    171171        // Not really needed, since deletion from this
    172172        // class is silly, but just in case.
    173173        virtual ~typed_value_base() {}
     
    350350
    351351    public: // typed_value_base overrides
    352352       
    353         const std::type_info& value_type() const
     353        const boost::core::typeinfo& value_type() const
    354354        {
    355             return typeid(T);
     355            return BOOST_CORE_TYPEID(T);
    356356        }
    357357       
    358358