Advertisement
Guest User

Untitled

a guest
Dec 11th, 2019
105
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 7.14 KB | None | 0 0
  1. floop@pine /tmp $ g++ concept.cpp
  2.  
  3. In file included from /usr/include/range/v3/range/concepts.hpp:30,
  4. from /usr/include/range/v3/action/concepts.hpp:23,
  5. from /usr/include/range/v3/action/action.hpp:23,
  6. from /usr/include/range/v3/action.hpp:17,
  7. from /usr/include/range/v3/all.hpp:17,
  8. from concept.cpp:1:
  9. /usr/include/range/v3/range/access.hpp: In instantiation of ‘constexpr const bool ranges::container<const char*>’:
  10. concept.cpp:7:1: required by substitution of ‘template<class Rng, class CPP_true_, typename std::enable_if<(container<Rng> && CPP_true_{}), int>::type <anonymous> > void foo(Rng) [with Rng = const char*; CPP_true_ = std::integral_constant<bool, true>; typename std::enable_if<(container<Rng> && CPP_true_{}), int>::type <anonymous> = <missing>]’
  11. concept.cpp:14:14: required from here
  12. /usr/include/range/v3/range/access.hpp:665:38: error: no match for call to ‘(const ranges::_begin_::fn) (const char*&)’
  13. 665 | using iterator_t = decltype(begin(std::declval<Rng &>()));
  14. | ~~~~~^~~~~~~~~~~~~~~~~~~~~~~
  15. /usr/include/range/v3/range/access.hpp:112:18: note: candidate: ‘template<class R, long unsigned int N> void ranges::_begin_::fn::operator()(R (&&)[N]) const’ <deleted>
  16. 112 | void operator()(R(&&)[N]) const = delete;
  17. | ^~~~~~~~
  18. /usr/include/range/v3/range/access.hpp:112:18: note: template argument deduction/substitution failed:
  19. /usr/include/range/v3/range/access.hpp:665:38: note: mismatched types ‘R [N]’ and ‘const char*’
  20. 665 | using iterator_t = decltype(begin(std::declval<Rng &>()));
  21. | ~~~~~^~~~~~~~~~~~~~~~~~~~~~~
  22. /usr/include/range/v3/range/access.hpp:115:27: note: candidate: ‘template<class R, long unsigned int N> constexpr R* ranges::_begin_::fn::operator()(R (&)[N]) const’
  23. 115 | constexpr R * operator()(R (&array)[N]) const noexcept
  24. | ^~~~~~~~
  25. /usr/include/range/v3/range/access.hpp:115:27: note: template argument deduction/substitution failed:
  26. /usr/include/range/v3/range/access.hpp:665:38: note: mismatched types ‘R [N]’ and ‘const char*’
  27. 665 | using iterator_t = decltype(begin(std::declval<Rng &>()));
  28. | ~~~~~^~~~~~~~~~~~~~~~~~~~~~~
  29. In file included from /usr/include/range/v3/range_fwd.hpp:22,
  30. from /usr/include/range/v3/action/action.hpp:21,
  31. from /usr/include/range/v3/action.hpp:17,
  32. from /usr/include/range/v3/all.hpp:17,
  33. from concept.cpp:1:
  34. /usr/include/range/v3/range/access.hpp:127:28: note: candidate: ‘template<class R> constexpr auto ranges::_begin_::fn::operator()(R&&, std::enable_if_t<((_safe_range<R> && (has_member_begin<R> || has_non_member_begin<R>)) && concepts::detail::CPP_true(concepts::detail::Nil{})), concepts::detail::Nil>) const’
  35. 127 | constexpr auto CPP_fun(operator())(R && r)(
  36. | ^~~~~~~
  37. /usr/include/range/v3/range/access.hpp:127:28: note: template argument deduction/substitution failed:
  38. In file included from /usr/include/range/v3/action/action.hpp:17,
  39. from /usr/include/range/v3/action.hpp:17,
  40. from /usr/include/range/v3/all.hpp:17,
  41. from concept.cpp:1:
  42. /usr/include/c++/9.2.0/type_traits: In substitution of ‘template<bool _Cond, class _Tp> using enable_if_t = typename std::enable_if::type [with bool _Cond = ((((bool)ranges::detail::_safe_range<const char*&>) && (((bool)ranges::_begin_::has_member_begin<const char*&>) || ((bool)ranges::_begin_::has_non_member_begin<const char*&>))) && concepts::detail::CPP_true((concepts::detail::Nil{}, concepts::detail::Nil())).std::integral_constant<bool, true>::operator std::integral_constant<bool, true>::value_type()); _Tp = concepts::detail::Nil]’:
  43. /usr/include/range/v3/range/access.hpp:127:28: required by substitution of ‘template<class R> constexpr auto ranges::_begin_::fn::operator()(R&&, std::enable_if_t<((_safe_range<R> && (has_member_begin<R> || has_non_member_begin<R>)) && concepts::detail::CPP_true(concepts::detail::Nil{})), concepts::detail::Nil>) const [with R = const char*&]’
  44. /usr/include/range/v3/range/access.hpp:665:38: required from ‘constexpr const bool ranges::container<const char*>’
  45. concept.cpp:7:1: required by substitution of ‘template<class Rng, class CPP_true_, typename std::enable_if<(container<Rng> && CPP_true_{}), int>::type <anonymous> > void foo(Rng) [with Rng = const char*; CPP_true_ = std::integral_constant<bool, true>; typename std::enable_if<(container<Rng> && CPP_true_{}), int>::type <anonymous> = <missing>]’
  46. concept.cpp:14:14: required from here
  47. /usr/include/c++/9.2.0/type_traits:2384:11: error: no type named ‘type’ in ‘struct std::enable_if<false, concepts::detail::Nil>’
  48. 2384 | using enable_if_t = typename enable_if<_Cond, _Tp>::type;
  49. | ^~~~~~~~~~~
  50. In file included from /usr/include/range/v3/range/concepts.hpp:30,
  51. from /usr/include/range/v3/action/concepts.hpp:23,
  52. from /usr/include/range/v3/action/action.hpp:23,
  53. from /usr/include/range/v3/action.hpp:17,
  54. from /usr/include/range/v3/all.hpp:17,
  55. from concept.cpp:1:
  56. /usr/include/range/v3/range/access.hpp: In instantiation of ‘constexpr const bool ranges::container<const char*>’:
  57. concept.cpp:7:1: required by substitution of ‘template<class Rng, class CPP_true_, typename std::enable_if<(container<Rng> && CPP_true_{}), int>::type <anonymous> > void foo(Rng) [with Rng = const char*; CPP_true_ = std::integral_constant<bool, true>; typename std::enable_if<(container<Rng> && CPP_true_{}), int>::type <anonymous> = <missing>]’
  58. concept.cpp:14:14: required from here
  59. /usr/include/range/v3/range/access.hpp:140:13: note: candidate: ‘template<class T, class Fn> constexpr decltype (Fn{}(ref.get())) ranges::_begin_::fn::operator()(std::reference_wrapper<_Tp>) const’
  60. 140 | operator()(std::reference_wrapper<T> ref) const
  61. | ^~~~~~~~
  62. /usr/include/range/v3/range/access.hpp:140:13: note: template argument deduction/substitution failed:
  63. /usr/include/range/v3/range/access.hpp:665:38: note: mismatched types ‘std::reference_wrapper<_Tp>’ and ‘const char*’
  64. 665 | using iterator_t = decltype(begin(std::declval<Rng &>()));
  65. | ~~~~~^~~~~~~~~~~~~~~~~~~~~~~
  66. /usr/include/range/v3/range/access.hpp:151:13: note: candidate: ‘template<class T, class Fn> constexpr decltype (Fn{}(ref.get())) ranges::_begin_::fn::operator()(ranges::reference_wrapper<T>) const’
  67. 151 | operator()(ranges::reference_wrapper<T> ref) const
  68. | ^~~~~~~~
  69. /usr/include/range/v3/range/access.hpp:151:13: note: template argument deduction/substitution failed:
  70. /usr/include/range/v3/range/access.hpp:665:38: note: mismatched types ‘ranges::reference_wrapper<T>’ and ‘const char*’
  71. 665 | using iterator_t = decltype(begin(std::declval<Rng &>()));
  72. |
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement