Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Could not complile under FreeBSD 10.3, Clang 3.4.1, Boost 1.55: #129

Open
abclogin opened this issue Jun 1, 2016 · 7 comments
Open

Could not complile under FreeBSD 10.3, Clang 3.4.1, Boost 1.55: #129

abclogin opened this issue Jun 1, 2016 · 7 comments

Comments

@abclogin
Copy link

abclogin commented Jun 1, 2016

Could not complile under FreeBSD 10.3, Clang 3.4.1, Boost 1.55
Branch issue/126/fix-long-long-upgrade
New error is:

/usr/home/username/blackhole/src/formatter/json.cpp:271:9: error: call to object of type
      'blackhole::v1::formatter::<anonymous>::visitor_t' is ambiguous
        visitor(value);
        ^~~~~~~

Full log

Scanning dependencies of target blackhole
[  3%] Building CXX object CMakeFiles/blackhole.dir/src/attribute.cpp.o
In file included from /usr/home/username/blackhole/src/attribute.cpp:8:
In file included from /usr/home/username/blackhole/include/blackhole/detail/attribute.hpp:3:
In file included from /usr/local/include/boost/variant/variant.hpp:32:
/usr/local/include/boost/variant/detail/forced_return.hpp:53:1: warning: function 'forced_return<void>' could be
      declared with attribute 'noreturn' [-Wmissing-noreturn]
{
^
In file included from /usr/home/username/blackhole/src/attribute.cpp:8:
In file included from /usr/home/username/blackhole/include/blackhole/detail/attribute.hpp:3:
/usr/local/include/boost/variant/variant.hpp:997:20: warning: comparing floating point with == or != is unsafe
      [-Wfloat-equal]
        return lhs == rhs;
               ~~~ ^  ~~~
/usr/local/include/boost/variant/variant.hpp:979:16: note: in instantiation of function template specialization
      'boost::detail::variant::equal_comp::operator()<double>' requested here
        return Comp()(lhs_content, rhs_content);
               ^
/usr/local/include/boost/variant/variant.hpp:1048:16: note: in instantiation of function template specialization
      'boost::detail::variant::comparer<boost::variant<boost::detail::variant::over_sequence<boost::mpl::vector<nullptr_t,
      bool, long, unsigned long, double, blackhole::v1::cpp17::basic_string_view<char, std::__1::char_traits<char> >,
      blackhole::v1::attribute::view_t::function_type, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na,
      mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na> >, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_>,
      boost::detail::variant::equal_comp>::operator()<double>' requested here
        return visitor_(operand);
               ^
/usr/local/include/boost/variant/detail/visitation_impl.hpp:128:20: note: in instantiation of function template
      specialization
      'boost::detail::variant::invoke_visitor<boost::detail::variant::comparer<boost::variant<boost::detail::variant::over_sequence<boost::mpl::vector<nullptr_t,
      bool, long, unsigned long, double, blackhole::v1::cpp17::basic_string_view<char, std::__1::char_traits<char> >,
      blackhole::v1::attribute::view_t::function_type, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na,
      mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na> >, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_>,
      boost::detail::variant::equal_comp> >::internal_visit<const double>' requested here
    return visitor.internal_visit(
                   ^
/usr/local/include/boost/variant/detail/visitation_impl.hpp:170:13: note: in instantiation of function template
      specialization
      'boost::detail::variant::visitation_impl_invoke_impl<boost::detail::variant::invoke_visitor<boost::detail::variant::comparer<boost::variant<boost::detail::variant::over_sequence<boost::mpl::vector<nullptr_t,
      bool, long, unsigned long, double, blackhole::v1::cpp17::basic_string_view<char, std::__1::char_traits<char> >,
      blackhole::v1::attribute::view_t::function_type, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na,
      mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na> >, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_>,
      boost::detail::variant::equal_comp> >, const void *, double>' requested here
    return (visitation_impl_invoke_impl)(
            ^
/usr/local/include/boost/variant/detail/visitation_impl.hpp:258:11: note: in instantiation of function template
      specialization
      'boost::detail::variant::visitation_impl_invoke<boost::detail::variant::invoke_visitor<boost::detail::variant::comparer<boost::variant<boost::detail::variant::over_sequence<boost::mpl::vector<nullptr_t,
      bool, long, unsigned long, double, blackhole::v1::cpp17::basic_string_view<char, std::__1::char_traits<char> >,
      blackhole::v1::attribute::view_t::function_type, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na,
      mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na> >, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_>,
      boost::detail::variant::equal_comp> >, const void *, double,
      boost::variant<boost::detail::variant::over_sequence<boost::mpl::vector<nullptr_t, bool, long, unsigned long,
      double, blackhole::v1::cpp17::basic_string_view<char, std::__1::char_traits<char> >,
      blackhole::v1::attribute::view_t::function_type, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na,
      mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na> >, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_>::has_fallback_type_>'
      requested here
        , BOOST_VARIANT_AUX_APPLY_VISITOR_STEP_CASE
          ^
/usr/local/include/boost/preprocessor/repetition/repeat.hpp:38:60: note: expanded from macro 'BOOST_PP_REPEAT_1'
# define BOOST_PP_REPEAT_1(c, m, d) BOOST_PP_REPEAT_1_I(c, m, d)
                                                           ^
/usr/local/include/boost/preprocessor/repetition/repeat.hpp:43:63: note: expanded from macro 'BOOST_PP_REPEAT_1_I'
# define BOOST_PP_REPEAT_1_I(c, m, d) BOOST_PP_REPEAT_1_ ## c(m, d)
                                                              ^
/usr/local/include/boost/preprocessor/repetition/repeat.hpp:71:58: note: expanded from macro 'BOOST_PP_REPEAT_1_20'
# define BOOST_PP_REPEAT_1_20(m, d) BOOST_PP_REPEAT_1_19(m, d) m(2, 19, d)
                                                         ^
note: (skipping 13 expansions in backtrace; use -fmacro-backtrace-limit=0 to see all)
/usr/local/include/boost/preprocessor/repetition/repeat.hpp:57:56: note: expanded from macro 'BOOST_PP_REPEAT_1_6'
# define BOOST_PP_REPEAT_1_6(m, d) BOOST_PP_REPEAT_1_5(m, d) m(2, 5, d)
                                                       ^
/usr/local/include/boost/preprocessor/repetition/repeat.hpp:56:62: note: expanded from macro 'BOOST_PP_REPEAT_1_5'
# define BOOST_PP_REPEAT_1_5(m, d) BOOST_PP_REPEAT_1_4(m, d) m(2, 4, d)
                                                             ^
/usr/local/include/boost/variant/detail/visitation_impl.hpp:249:17: note: expanded from macro
      'BOOST_VARIANT_AUX_APPLY_VISITOR_STEP_CASE'
        return (visitation_impl_invoke)( \
                ^
/usr/local/include/boost/variant/variant.hpp:2362:33: note: in instantiation of function template specialization
      'boost::detail::variant::visitation_impl<mpl_::int_<0>,
      boost::detail::variant::visitation_impl_step<boost::mpl::v_iter<boost::mpl::v_item<blackhole::v1::attribute::view_t::function_type,
      boost::mpl::v_item<blackhole::v1::cpp17::basic_string_view<char, std::__1::char_traits<char> >,
      boost::mpl::v_item<double, boost::mpl::v_item<unsigned long, boost::mpl::v_item<long, boost::mpl::v_item<bool,
      boost::mpl::v_item<nullptr_t, boost::mpl::vector0<mpl_::na>, 0>, 0>, 0>, 0>, 0>, 0>, 0>, 0>,
      boost::mpl::v_iter<boost::mpl::v_item<blackhole::v1::attribute::view_t::function_type,
      boost::mpl::v_item<blackhole::v1::cpp17::basic_string_view<char, std::__1::char_traits<char> >,
      boost::mpl::v_item<double, boost::mpl::v_item<unsigned long, boost::mpl::v_item<long, boost::mpl::v_item<bool,
      boost::mpl::v_item<nullptr_t, boost::mpl::vector0<mpl_::na>, 0>, 0>, 0>, 0>, 0>, 0>, 0>, 7> >,
      boost::detail::variant::invoke_visitor<boost::detail::variant::comparer<boost::variant<boost::detail::variant::over_sequence<boost::mpl::vector<nullptr_t,
      bool, long, unsigned long, double, blackhole::v1::cpp17::basic_string_view<char, std::__1::char_traits<char> >,
      blackhole::v1::attribute::view_t::function_type, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na,
      mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na> >, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_>,
      boost::detail::variant::equal_comp> >, const void *,
      boost::variant<boost::detail::variant::over_sequence<boost::mpl::vector<nullptr_t, bool, long, unsigned long,
      double, blackhole::v1::cpp17::basic_string_view<char, std::__1::char_traits<char> >,
      blackhole::v1::attribute::view_t::function_type, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na,
      mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na> >, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_>::has_fallback_type_>'
      requested here
        return detail::variant::visitation_impl(
                                ^
/usr/local/include/boost/variant/variant.hpp:2387:16: note: in instantiation of function template specialization
      'boost::variant<boost::detail::variant::over_sequence<boost::mpl::vector<nullptr_t, bool, long, unsigned long,
      double, blackhole::v1::cpp17::basic_string_view<char, std::__1::char_traits<char> >,
      blackhole::v1::attribute::view_t::function_type, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na,
      mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na> >, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_>::internal_apply_visitor_impl<boost::detail::variant::invoke_visitor<boost::detail::variant::comparer<boost::variant<boost::detail::variant::over_sequence<boost::mpl::vector<nullptr_t,
      bool, long, unsigned long, double, blackhole::v1::cpp17::basic_string_view<char, std::__1::char_traits<char> >,
      blackhole::v1::attribute::view_t::function_type, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na,
      mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na> >, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_>,
      boost::detail::variant::equal_comp> >, const void *>' requested here
        return internal_apply_visitor_impl(
               ^
/usr/local/include/boost/variant/variant.hpp:2411:22: note: in instantiation of function template specialization
      'boost::variant<boost::detail::variant::over_sequence<boost::mpl::vector<nullptr_t, bool, long, unsigned long,
      double, blackhole::v1::cpp17::basic_string_view<char, std::__1::char_traits<char> >,
      blackhole::v1::attribute::view_t::function_type, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na,
      mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na> >, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_>::internal_apply_visitor<boost::detail::variant::invoke_visitor<boost::detail::variant::comparer<boost::variant<boost::detail::variant::over_sequence<boost::mpl::vector<nullptr_t,
      bool, long, unsigned long, double, blackhole::v1::cpp17::basic_string_view<char, std::__1::char_traits<char> >,
      blackhole::v1::attribute::view_t::function_type, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na,
      mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na> >, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_>,
      boost::detail::variant::equal_comp> > >' requested here
        return this->internal_apply_visitor(invoker);
                     ^
/usr/local/include/boost/variant/variant.hpp:2310:20: note: in instantiation of function template specialization
      'boost::variant<boost::detail::variant::over_sequence<boost::mpl::vector<nullptr_t, bool, long, unsigned long,
      double, blackhole::v1::cpp17::basic_string_view<char, std::__1::char_traits<char> >,
      blackhole::v1::attribute::view_t::function_type, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na,
      mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na> >, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_>::apply_visitor<boost::detail::variant::comparer<boost::variant<boost::detail::variant::over_sequence<boost::mpl::vector<nullptr_t,
      bool, long, unsigned long, double, blackhole::v1::cpp17::basic_string_view<char, std::__1::char_traits<char> >,
      blackhole::v1::attribute::view_t::function_type, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na,
      mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na> >, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_>,
      boost::detail::variant::equal_comp> >' requested here
        return rhs.apply_visitor(visitor);
                   ^
/usr/home/username/blackhole/src/attribute.cpp:248:26: note: in instantiation of member function
      'boost::variant<boost::detail::variant::over_sequence<boost::mpl::vector<nullptr_t, bool, long, unsigned long,
      double, blackhole::v1::cpp17::basic_string_view<char, std::__1::char_traits<char> >,
      blackhole::v1::attribute::view_t::function_type, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na,
      mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na> >, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_,
      boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_>::operator=='
      requested here
    return inner().value == other.inner().value;
                         ^
2 warnings generated.
[  6%] Building CXX object CMakeFiles/blackhole.dir/src/config/factory.cpp.o
[  9%] Building CXX object CMakeFiles/blackhole.dir/src/config/json.cpp.o
In file included from /usr/home/username/blackhole/src/config/json.cpp:8:
In file included from /usr/home/username/blackhole/include/blackhole/detail/config/json.hpp:5:
In file included from /usr/local/include/boost/lexical_cast.hpp:159:
In file included from /usr/local/include/boost/numeric/conversion/cast.hpp:33:
In file included from /usr/local/include/boost/numeric/conversion/converter.hpp:14:
/usr/local/include/boost/numeric/conversion/converter_policies.hpp:139:39: warning: dynamic exception specifications are
      deprecated [-Wdeprecated]
    virtual const char * what() const throw()
                                      ^~~~~~~
/usr/local/include/boost/numeric/conversion/converter_policies.hpp:139:39: note: use 'noexcept' instead
    virtual const char * what() const throw()
                                      ^~~~~~~
                                      noexcept
/usr/local/include/boost/numeric/conversion/converter_policies.hpp:147:39: warning: dynamic exception specifications are
      deprecated [-Wdeprecated]
    virtual const char * what() const throw()
                                      ^~~~~~~
/usr/local/include/boost/numeric/conversion/converter_policies.hpp:147:39: note: use 'noexcept' instead
    virtual const char * what() const throw()
                                      ^~~~~~~
                                      noexcept
/usr/local/include/boost/numeric/conversion/converter_policies.hpp:154:39: warning: dynamic exception specifications are
      deprecated [-Wdeprecated]
    virtual const char * what() const throw()
                                      ^~~~~~~
/usr/local/include/boost/numeric/conversion/converter_policies.hpp:154:39: note: use 'noexcept' instead
    virtual const char * what() const throw()
                                      ^~~~~~~
                                      noexcept
In file included from /usr/home/username/blackhole/src/config/json.cpp:8:
In file included from /usr/home/username/blackhole/include/blackhole/detail/config/json.hpp:5:
In file included from /usr/local/include/boost/lexical_cast.hpp:169:
In file included from /usr/local/include/boost/range/iterator_range_core.hpp:31:
In file included from /usr/local/include/boost/range/algorithm/equal.hpp:14:
In file included from /usr/local/include/boost/range/concepts.hpp:19:
/usr/local/include/boost/concept_check.hpp:883:8: warning: extra ';' after member function definition [-Wextra-semi]
      };
       ^
In file included from /usr/home/username/blackhole/src/config/json.cpp:8:
In file included from /usr/home/username/blackhole/include/blackhole/detail/config/json.hpp:5:
In file included from /usr/local/include/boost/lexical_cast.hpp:169:
/usr/local/include/boost/range/iterator_range_core.hpp:637:20: warning: parameter 'Range' not found in the function
      declaration [-Wdocumentation]
            \param Range An input range
                   ^~~~~
/usr/local/include/boost/range/iterator_range_core.hpp:637:20: note: did you mean 'r'?
            \param Range An input range
                   ^~~~~
                   r
In file included from /usr/home/username/blackhole/src/config/json.cpp:8:
In file included from /usr/home/username/blackhole/include/blackhole/detail/config/json.hpp:5:
In file included from /usr/local/include/boost/lexical_cast.hpp:170:
/usr/local/include/boost/container/container_fwd.hpp:160:5: warning: unknown command tag name
      [-Wdocumentation-unknown-command]
/// @cond
    ^
In file included from /usr/home/username/blackhole/src/config/json.cpp:8:
In file included from /usr/home/username/blackhole/include/blackhole/detail/config/json.hpp:5:
/usr/local/include/boost/lexical_cast.hpp:1707:50: warning: implicit conversion changes signedness: 'long' to 'size_t'
      (aka 'unsigned long') [-Wsign-conversion]
                end = begin + swprintf(begin, end-begin,
                              ~~~~~~~~        ~~~^~~~~~
/usr/local/include/boost/lexical_cast.hpp:1717:50: warning: implicit conversion changes signedness: 'long' to 'size_t'
      (aka 'unsigned long') [-Wsign-conversion]
                end = begin + swprintf(begin, end-begin,
                              ~~~~~~~~        ~~~^~~~~~
/usr/local/include/boost/lexical_cast.hpp:1725:50: warning: implicit conversion changes signedness: 'long' to 'size_t'
      (aka 'unsigned long') [-Wsign-conversion]
                end = begin + swprintf(begin, end-begin,
                              ~~~~~~~~        ~~~^~~~~~
In file included from /usr/home/username/blackhole/src/config/json.cpp:8:
/usr/home/username/blackhole/include/blackhole/detail/config/json.hpp:185:52: warning: will never be executed
      [-Wunreachable-code]
        throw config::type_mismatch(cursor.empty() ? "/" : cursor, expected, type());
                                                   ^
/usr/home/username/blackhole/src/config/json.cpp:34:36: warning: unused parameter 'other' [-Wunused-parameter]
factory<json_t>::factory(factory&& other) noexcept = default;
                                   ^
/usr/home/username/blackhole/src/config/json.cpp:38:43: warning: unused parameter 'other' [-Wunused-parameter]
auto factory<json_t>::operator=(factory&& other) noexcept -> factory& = default;
                                          ^
In file included from /usr/home/username/blackhole/src/config/json.cpp:8:
In file included from /usr/home/username/blackhole/include/blackhole/detail/config/json.hpp:5:
In file included from /usr/local/include/boost/lexical_cast.hpp:168:
/usr/local/include/boost/math/special_functions/fpclassify.hpp:168:18: warning: comparing floating point with == or !=
      is unsafe [-Wfloat-equal]
      return (at != 0) ? FP_SUBNORMAL : FP_ZERO;
              ~~ ^  ~
/usr/local/include/boost/math/special_functions/fpclassify.hpp:250:32: note: in instantiation of function template
      specialization 'boost::math::detail::fpclassify_imp<long double>' requested here
   return boost::math::detail::fpclassify_imp(t, generic_tag<true>());
                               ^
/usr/local/include/boost/math/special_functions/fpclassify.hpp:445:20: warning: comparing floating point with == or !=
      is unsafe [-Wfloat-equal]
            && ( x == std::numeric_limits<T>::infinity()
                 ~ ^  ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/local/include/boost/math/special_functions/fpclassify.hpp:489:32: note: in instantiation of function template
      specialization 'boost::math::detail::isinf_impl<long double>' requested here
   return boost::math::detail::isinf_impl(t, generic_tag<true>());
                               ^
/usr/local/include/boost/math/special_functions/fpclassify.hpp:446:23: warning: comparing floating point with == or !=
      is unsafe [-Wfloat-equal]
                 || x == -std::numeric_limits<T>::infinity());
                    ~ ^  ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from /usr/home/username/blackhole/src/config/json.cpp:8:
In file included from /usr/home/username/blackhole/include/blackhole/detail/config/json.hpp:5:
/usr/local/include/boost/lexical_cast.hpp:126:17: warning: definition of implicit copy constructor for
      'bad_lexical_cast' is deprecated because it has a user-declared destructor [-Wdeprecated]
        virtual ~bad_lexical_cast() BOOST_NOEXCEPT
                ^
/usr/local/include/boost/lexical_cast.hpp:2375:19: note: in instantiation of function template specialization
      'boost::throw_exception<boost::bad_lexical_cast>' requested here
                  BOOST_LCAST_THROW_BAD_CAST(Source, Target);
                  ^
/usr/local/include/boost/lexical_cast.hpp:69:5: note: expanded from macro 'BOOST_LCAST_THROW_BAD_CAST'
    throw_exception(bad_lexical_cast(typeid(Source), typeid(Target)))
    ^
/usr/local/include/boost/lexical_cast.hpp:2543:29: note: in instantiation of member function
      'boost::detail::lexical_cast_do_cast<std::__1::basic_string<char>, unsigned long>::lexical_cast_impl' requested
      here
        return caster_type::lexical_cast_impl(arg);
                            ^
/usr/home/username/blackhole/include/blackhole/detail/config/json.hpp:177:38: note: in instantiation of function template
      specialization 'boost::lexical_cast<std::__1::basic_string<char>, unsigned long>' requested here
        return cursor + "/" + boost::lexical_cast<std::string>(idx);
                                     ^
/usr/local/include/boost/exception/exception.hpp:320:9: note: implicit copy constructor for 'bad_lexical_cast' first
      required here
        error_info_injector:
        ^
16 warnings generated.
[ 12%] Building CXX object CMakeFiles/blackhole.dir/src/config/node.cpp.o
[ 15%] Building CXX object CMakeFiles/blackhole.dir/src/config/option.cpp.o
[ 18%] Building CXX object CMakeFiles/blackhole.dir/src/datetime/generator.linux.cpp.o
[ 21%] Building CXX object CMakeFiles/blackhole.dir/src/datetime/generator.other.cpp.o
[ 24%] Building CXX object CMakeFiles/blackhole.dir/src/format.cpp.o
[ 27%] Building CXX object CMakeFiles/blackhole.dir/src/formatter/json.cpp.o
In file included from /usr/home/username/blackhole/src/formatter/json.cpp:24:
In file included from /usr/home/username/blackhole/include/blackhole/detail/attribute.hpp:3:
In file included from /usr/local/include/boost/variant/variant.hpp:32:
/usr/local/include/boost/variant/detail/forced_return.hpp:53:1: warning: function 'forced_return<void>' could be
      declared with attribute 'noreturn' [-Wmissing-noreturn]
{
^
/usr/home/username/blackhole/src/formatter/json.cpp:205:7: warning: '__APPLE__' is not defined, evaluates to 0 [-Wundef]
#elif __APPLE__
      ^
/usr/home/username/blackhole/src/formatter/json.cpp:271:9: error: call to object of type
      'blackhole::v1::formatter::<anonymous>::visitor_t' is ambiguous
        visitor(value);
        ^~~~~~~
/usr/home/username/blackhole/src/formatter/json.cpp:230:13: note: in instantiation of function template specialization
      'blackhole::v1::formatter::json_t::inner_t::builder<rapidjson::GenericDocument<rapidjson::UTF8<char>,
      rapidjson::MemoryPoolAllocator<rapidjson::CrtAllocator>, rapidjson::MemoryPoolAllocator<rapidjson::CrtAllocator> >
      >::apply<long long>' requested here
            apply("timestamp", timestamp);
            ^
/usr/home/username/blackhole/src/formatter/json.cpp:353:13: note: in instantiation of member function
      'blackhole::v1::formatter::json_t::inner_t::builder<rapidjson::GenericDocument<rapidjson::UTF8<char>,
      rapidjson::MemoryPoolAllocator<rapidjson::CrtAllocator>, rapidjson::MemoryPoolAllocator<rapidjson::CrtAllocator> >
      >::timestamp' requested here
    builder.timestamp();
            ^
/usr/home/username/blackhole/src/formatter/json.cpp:44:10: note: candidate function
    auto operator()(bool value) -> void {
         ^
/usr/home/username/blackhole/src/formatter/json.cpp:48:10: note: candidate function
    auto operator()(std::int64_t value) -> void {
         ^
/usr/home/username/blackhole/src/formatter/json.cpp:52:10: note: candidate function
    auto operator()(std::uint64_t value) -> void {
         ^
/usr/home/username/blackhole/src/formatter/json.cpp:56:10: note: candidate function
    auto operator()(double value) -> void {
         ^
2 warnings and 1 error generated.
*** Error code 1

Stop.
make[2]: stopped in /usr/home/username/blackhole
*** Error code 1

Stop.
make[1]: stopped in /usr/home/username/blackhole
*** Error code 1

Stop.
make: stopped in /usr/home/username/blackhole
3Hren added a commit that referenced this issue Jun 1, 2016
Blackhole can handle both signed int64 and unsigned integers,
but std::chrono representation type is long long, which may
vary depending on architecture where building occurs. Thus,
it may lead to ambiguous integer promotion when it's time
to format.

This commit does explicit cast to resolve ambiguity.

This should fix #126 and #129.
@3Hren
Copy link
Owner

3Hren commented Jun 1, 2016

Actually it's the same error as in #126. Check again please, I've updated the PR.

@abclogin
Copy link
Author

abclogin commented Jun 1, 2016

Yes.
It is fixed.

Other error:

/usr/home/username/bh126/src/formatter/string.cpp:193:27: error: no member named
      'pthread_getname_np' in the global namespace
        const auto rc = ::pthread_getname_np(record.tid(), buffer.data()...
                        ~~^

Full log:

Scanning dependencies of target blackhole
[  2%] Building CXX object CMakeFiles/blackhole.dir/src/config/json.cpp.o
In file included from /usr/home/username/bh126/src/config/json.cpp:8:
In file included from /usr/home/username/bh126/include/blackhole/detail/config/json.hpp:5:
In file included from /usr/local/include/boost/lexical_cast.hpp:159:
In file included from /usr/local/include/boost/numeric/conversion/cast.hpp:33:
In file included from /usr/local/include/boost/numeric/conversion/converter.hpp:14:
/usr/local/include/boost/numeric/conversion/converter_policies.hpp:139:39: warning:
      dynamic exception specifications are deprecated [-Wdeprecated]
    virtual const char * what() const throw()
                                      ^~~~~~~
/usr/local/include/boost/numeric/conversion/converter_policies.hpp:139:39: note:
      use 'noexcept' instead
    virtual const char * what() const throw()
                                      ^~~~~~~
                                      noexcept
/usr/local/include/boost/numeric/conversion/converter_policies.hpp:147:39: warning:
      dynamic exception specifications are deprecated [-Wdeprecated]
    virtual const char * what() const throw()
                                      ^~~~~~~
/usr/local/include/boost/numeric/conversion/converter_policies.hpp:147:39: note:
      use 'noexcept' instead
    virtual const char * what() const throw()
                                      ^~~~~~~
                                      noexcept
/usr/local/include/boost/numeric/conversion/converter_policies.hpp:154:39: warning:
      dynamic exception specifications are deprecated [-Wdeprecated]
    virtual const char * what() const throw()
                                      ^~~~~~~
/usr/local/include/boost/numeric/conversion/converter_policies.hpp:154:39: note:
      use 'noexcept' instead
    virtual const char * what() const throw()
                                      ^~~~~~~
                                      noexcept
In file included from /usr/home/username/bh126/src/config/json.cpp:8:
In file included from /usr/home/username/bh126/include/blackhole/detail/config/json.hpp:5:
In file included from /usr/local/include/boost/lexical_cast.hpp:169:
In file included from /usr/local/include/boost/range/iterator_range_core.hpp:31:
In file included from /usr/local/include/boost/range/algorithm/equal.hpp:14:
In file included from /usr/local/include/boost/range/concepts.hpp:19:
/usr/local/include/boost/concept_check.hpp:883:8: warning: extra ';' after
      member function definition [-Wextra-semi]
      };
       ^
In file included from /usr/home/username/bh126/src/config/json.cpp:8:
In file included from /usr/home/username/bh126/include/blackhole/detail/config/json.hpp:5:
In file included from /usr/local/include/boost/lexical_cast.hpp:169:
/usr/local/include/boost/range/iterator_range_core.hpp:637:20: warning:
      parameter 'Range' not found in the function declaration [-Wdocumentation]
            \param Range An input range
                   ^~~~~
/usr/local/include/boost/range/iterator_range_core.hpp:637:20: note: did you
      mean 'r'?
            \param Range An input range
                   ^~~~~
                   r
In file included from /usr/home/username/bh126/src/config/json.cpp:8:
In file included from /usr/home/username/bh126/include/blackhole/detail/config/json.hpp:5:
In file included from /usr/local/include/boost/lexical_cast.hpp:170:
/usr/local/include/boost/container/container_fwd.hpp:160:5: warning: unknown
      command tag name [-Wdocumentation-unknown-command]
/// @cond
    ^
In file included from /usr/home/username/bh126/src/config/json.cpp:8:
In file included from /usr/home/username/bh126/include/blackhole/detail/config/json.hpp:5:
/usr/local/include/boost/lexical_cast.hpp:1707:50: warning: implicit conversion
      changes signedness: 'long' to 'size_t' (aka 'unsigned long')
      [-Wsign-conversion]
                end = begin + swprintf(begin, end-begin,
                              ~~~~~~~~        ~~~^~~~~~
/usr/local/include/boost/lexical_cast.hpp:1717:50: warning: implicit conversion
      changes signedness: 'long' to 'size_t' (aka 'unsigned long')
      [-Wsign-conversion]
                end = begin + swprintf(begin, end-begin,
                              ~~~~~~~~        ~~~^~~~~~
/usr/local/include/boost/lexical_cast.hpp:1725:50: warning: implicit conversion
      changes signedness: 'long' to 'size_t' (aka 'unsigned long')
      [-Wsign-conversion]
                end = begin + swprintf(begin, end-begin,
                              ~~~~~~~~        ~~~^~~~~~
In file included from /usr/home/username/bh126/src/config/json.cpp:8:
/usr/home/username/bh126/include/blackhole/detail/config/json.hpp:185:52: warning:
      will never be executed [-Wunreachable-code]
        throw config::type_mismatch(cursor.empty() ? "/" : cursor, expec...
                                                   ^
/usr/home/username/bh126/src/config/json.cpp:34:36: warning: unused parameter 'other'
      [-Wunused-parameter]
factory<json_t>::factory(factory&& other) noexcept = default;
                                   ^
/usr/home/username/bh126/src/config/json.cpp:38:43: warning: unused parameter 'other'
      [-Wunused-parameter]
auto factory<json_t>::operator=(factory&& other) noexcept -> factory& = default;
                                          ^
In file included from /usr/home/username/bh126/src/config/json.cpp:8:
In file included from /usr/home/username/bh126/include/blackhole/detail/config/json.hpp:5:
In file included from /usr/local/include/boost/lexical_cast.hpp:168:
/usr/local/include/boost/math/special_functions/fpclassify.hpp:168:18: warning:
      comparing floating point with == or != is unsafe [-Wfloat-equal]
      return (at != 0) ? FP_SUBNORMAL : FP_ZERO;
              ~~ ^  ~
/usr/local/include/boost/math/special_functions/fpclassify.hpp:250:32: note: in
      instantiation of function template specialization
      'boost::math::detail::fpclassify_imp<long double>' requested here
   return boost::math::detail::fpclassify_imp(t, generic_tag<true>());
                               ^
/usr/local/include/boost/math/special_functions/fpclassify.hpp:445:20: warning:
      comparing floating point with == or != is unsafe [-Wfloat-equal]
            && ( x == std::numeric_limits<T>::infinity()
                 ~ ^  ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/local/include/boost/math/special_functions/fpclassify.hpp:489:32: note: in
      instantiation of function template specialization
      'boost::math::detail::isinf_impl<long double>' requested here
   return boost::math::detail::isinf_impl(t, generic_tag<true>());
                               ^
/usr/local/include/boost/math/special_functions/fpclassify.hpp:446:23: warning:
      comparing floating point with == or != is unsafe [-Wfloat-equal]
                 || x == -std::numeric_limits<T>::infinity());
                    ~ ^  ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from /usr/home/username/bh126/src/config/json.cpp:8:
In file included from /usr/home/username/bh126/include/blackhole/detail/config/json.hpp:5:
/usr/local/include/boost/lexical_cast.hpp:126:17: warning: definition of
      implicit copy constructor for 'bad_lexical_cast' is deprecated because it
      has a user-declared destructor [-Wdeprecated]
        virtual ~bad_lexical_cast() BOOST_NOEXCEPT
                ^
/usr/local/include/boost/lexical_cast.hpp:2375:19: note: in instantiation of
      function template specialization
      'boost::throw_exception<boost::bad_lexical_cast>' requested here
                  BOOST_LCAST_THROW_BAD_CAST(Source, Target);
                  ^
/usr/local/include/boost/lexical_cast.hpp:69:5: note: expanded from macro
      'BOOST_LCAST_THROW_BAD_CAST'
    throw_exception(bad_lexical_cast(typeid(Source), typeid(Target)))
    ^
/usr/local/include/boost/lexical_cast.hpp:2543:29: note: in instantiation of
      member function
      'boost::detail::lexical_cast_do_cast<std::__1::basic_string<char>,
      unsigned long>::lexical_cast_impl' requested here
        return caster_type::lexical_cast_impl(arg);
                            ^
/usr/home/username/bh126/include/blackhole/detail/config/json.hpp:177:38: note: in
      instantiation of function template specialization
      'boost::lexical_cast<std::__1::basic_string<char>, unsigned long>'
      requested here
        return cursor + "/" + boost::lexical_cast<std::string>(idx);
                                     ^
/usr/local/include/boost/exception/exception.hpp:320:9: note: implicit copy
      constructor for 'bad_lexical_cast' first required here
        error_info_injector:
        ^
16 warnings generated.
[  5%] Building CXX object CMakeFiles/blackhole.dir/src/config/node.cpp.o
[  8%] Building CXX object CMakeFiles/blackhole.dir/src/config/option.cpp.o
[ 11%] Building CXX object CMakeFiles/blackhole.dir/src/datetime/generator.linux.cpp.o
[ 14%] Building CXX object CMakeFiles/blackhole.dir/src/datetime/generator.other.cpp.o
[ 17%] Building CXX object CMakeFiles/blackhole.dir/src/format.cpp.o
[ 20%] Building CXX object CMakeFiles/blackhole.dir/src/formatter/json.cpp.o
In file included from /usr/home/username/bh126/src/formatter/json.cpp:24:
In file included from /usr/home/username/bh126/include/blackhole/detail/attribute.hpp:3:
In file included from /usr/local/include/boost/variant/variant.hpp:32:
/usr/local/include/boost/variant/detail/forced_return.hpp:53:1: warning:
      function 'forced_return<void>' could be declared with attribute 'noreturn'
      [-Wmissing-noreturn]
{
^
/usr/home/username/bh126/src/formatter/json.cpp:205:7: warning: '__APPLE__' is not
      defined, evaluates to 0 [-Wundef]
#elif __APPLE__
      ^
2 warnings generated.
[ 23%] Building CXX object CMakeFiles/blackhole.dir/src/formatter/mod.cpp.o
[ 26%] Building CXX object CMakeFiles/blackhole.dir/src/formatter/string.cpp.o
In file included from /usr/home/username/bh126/src/formatter/string.cpp:1:
/usr/home/username/bh126/include/blackhole/formatter/string.hpp:54:6: warning:
      '\param' command used in a comment that is not attached to a function
      declaration [-Wdocumentation]
/// \param severity an integer representation of current log severity.
     ^~~~~
/usr/home/username/bh126/include/blackhole/formatter/string.hpp:55:6: warning:
      '\param' command used in a comment that is not attached to a function
      declaration [-Wdocumentation]
/// \param spec the format specification as it was provided with the ini...
     ^~~~~
/usr/home/username/bh126/include/blackhole/formatter/string.hpp:56:6: warning:
      '\param' command used in a comment that is not attached to a function
      declaration [-Wdocumentation]
/// \param writer result writer.
     ^~~~~
In file included from /usr/home/username/bh126/src/formatter/string.cpp:8:
In file included from /usr/local/include/boost/variant/variant.hpp:32:
/usr/local/include/boost/variant/detail/forced_return.hpp:53:1: warning:
      function 'forced_return<void>' could be declared with attribute 'noreturn'
      [-Wmissing-noreturn]
{
^
/usr/home/username/bh126/src/formatter/string.cpp:186:7: warning: '__APPLE__' is not
      defined, evaluates to 0 [-Wundef]
#elif __APPLE__
      ^
/usr/home/username/bh126/src/formatter/string.cpp:179:43: warning: unused parameter
      'token' [-Wunused-parameter]
    auto operator()(const ph::thread<id>& token) const -> void {
                                          ^
/usr/home/username/bh126/src/formatter/string.cpp:179:64: warning: function
      'operator()' could be declared with attribute 'noreturn'
      [-Wmissing-noreturn]
    auto operator()(const ph::thread<id>& token) const -> void {
                                                               ^
/usr/home/username/bh126/src/formatter/string.cpp:183:44: warning: unused parameter
      'token' [-Wunused-parameter]
    auto operator()(const ph::thread<hex>& token) const -> void {
                                           ^
/usr/home/username/bh126/src/formatter/string.cpp:193:27: error: no member named
      'pthread_getname_np' in the global namespace
        const auto rc = ::pthread_getname_np(record.tid(), buffer.data()...
                        ~~^
8 warnings and 1 error generated.
*** Error code 1

Stop.
make[2]: stopped in /usr/home/username/bh126
*** Error code 1

Stop.
make[1]: stopped in /usr/home/username/bh126
*** Error code 1

Stop.
make: stopped in /usr/home/username/bh126

@3Hren
Copy link
Owner

3Hren commented Jun 1, 2016

Well, this may be tricky. I'm not sure of FreeBSD pthread support, because this function is not portable at all.

Can you just try to add #include <pthread.h> at top of "src/formatter/string.cpp"?

@abclogin
Copy link
Author

abclogin commented Jun 1, 2016

Can you just try to add #include <pthread.h> at top of "src/formatter/string.cpp"?

I did it. Same error.

I found:
FreeBSD contains pthread support in standard libc.
But FreeBSD contains not pthread_getname_np:
https://www.gnu.org/software/gnulib/manual/html_node/pthread_005fgetname_005fnp.html

http://www.mzan.com/article/2369738-can-i-set-the-name-of-a-thread-in-pthreads-linux.shtml

#include <pthread.h> 
// or <pthread_np.h> ? 
// Linux, NetBSD: 
int pthread_getname_np(pthread_t th, char *buf, size_t len); 
// some implementations don't have a safe buffer (see MKS/IBM below) 
int pthread_getname_np(pthread_t thread, const char **name); 
int pthread_getname_np(pthread_t thread, char *name); 
// FreeBSD & OpenBSD: dont' seem to have getname/get_name equivalent? 
// but I'd imagine there's some other mechanism to read it directly for say gdb 
// Mac OS X: 
int pthread_getname_np(pthread_t, char*, size_t);

FreeBSD contains pthread_set_name_np function only:

#include <pthread.h>  // or maybe <pthread_np.h> for some OSes

// Linux
int pthread_setname_np(pthread_t thread, const char *name);

// NetBSD: name + arg work like printf(name, arg)
int pthread_setname_np(pthread_t thread, const char *name, void *arg);

// FreeBSD & OpenBSD: function name is slightly different, and has no return value
void pthread_set_name_np(pthread_t tid, const char *name);

// Mac OS X: must be set from within the thread (can't specify thread ID)
int pthread_setname_np(const char*);

@3Hren
Copy link
Owner

3Hren commented Jun 2, 2016

Is there anything with similar functionality?

@3Hren
Copy link
Owner

3Hren commented Jun 6, 2016

Okay, it takes significant time for me to configure FreeBSD virtual machine to be able to declare its support. Since, PR's are welcome, you can speedup the process.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants