Ticket #10830: param_not_found_static_instance.patch

File param_not_found_static_instance.patch, 868 bytes (added by Diego Barrios Romero <eldruin@…>, 6 years ago)

Workaround on boost 1.62 sources to get MSVC14 to compile

  • named_function_params.hpp

     
    227227    }
    228228  };
    229229
    230   struct param_not_found {};
     230  struct param_not_found {
     231    static param_not_found& instance()
     232    {
     233      static param_not_found instance_;
     234      return instance_;
     235    }
     236  };
    231237
    232238  template <typename Tag, typename Args>
    233239  struct get_param_type:
     
    237243  inline
    238244  const typename lookup_named_param_def<Tag, Args, param_not_found>::type&
    239245  get_param(const Args& p, Tag) {
    240     return lookup_named_param_def<Tag, Args, param_not_found>::get(p, param_not_found());
     246    return lookup_named_param_def<Tag, Args, param_not_found>::get(p, param_not_found::instance());
    241247  }
    242248
    243249  template <class P, class Default>