Want more features on Pastebin? Sign Up, it's FREE!
Guest

clang++ -std=c++11 a2.cpp

By: a guest on Nov 9th, 2012  |  syntax: None  |  size: 2.62 KB  |  views: 27  |  expires: Never
download  |  raw  |  embed  |  report abuse  |  print
Text below is selected. Please press Ctrl+C to copy to your clipboard. (⌘+C on Mac)
  1. a2.cpp:34:12: error: no matching function for call to 'is_constexpr_impl'
  2.     return is_constexpr_impl<F, FP, Args...>(0);
  3.            ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  4. a2.cpp:60:18: note: in instantiation of function template specialization
  5.       'is_constexpr<int (int, int), f, int, int>' requested here
  6.     std::cout << is_constexpr<decltype(f), &f>(1, 1) << std::endl;
  7.                  ^
  8. a2.cpp:14:16: note: candidate template ignored: substitution failure [with F =
  9.       int (int, int), FP = f, Args = <int, int>]: non-type template argument is
  10.       not a constant expression
  11. constexpr bool is_constexpr_impl(bool&&)
  12.                ^
  13. a2.cpp:34:12: error: no matching function for call to 'is_constexpr_impl'
  14.     return is_constexpr_impl<F, FP, Args...>(0);
  15.            ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  16. a2.cpp:61:18: note: in instantiation of function template specialization
  17.       'is_constexpr<float (float, float), g, float, float>' requested here
  18.     std::cout << is_constexpr<decltype(g), &g>(1.0f, 1.0f) << std::endl;
  19.                  ^
  20. a2.cpp:14:16: note: candidate template ignored: substitution failure [with F =
  21.       float (float, float), FP = g, Args = <float, float>]: non-type template
  22.       argument is not a constant expression
  23. constexpr bool is_constexpr_impl(bool&&)
  24.                ^
  25. a2.cpp:34:12: error: no matching function for call to 'is_constexpr_impl'
  26.     return is_constexpr_impl<F, FP, Args...>(0);
  27.            ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  28. a2.cpp:62:18: note: in instantiation of function template specialization
  29.       'is_constexpr<int (int, int), h, int, int>' requested here
  30.     std::cout << is_constexpr<decltype(h), &h>(1, 1) << std::endl;
  31.                  ^
  32. a2.cpp:14:16: note: candidate template ignored: substitution failure [with F =
  33.       int (int, int), FP = h, Args = <int, int>]: non-type template argument is
  34.       not a constant expression
  35. constexpr bool is_constexpr_impl(bool&&)
  36.                ^
  37. a2.cpp:34:12: error: no matching function for call to 'is_constexpr_impl'
  38.     return is_constexpr_impl<F, FP, Args...>(0);
  39.            ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  40. a2.cpp:63:18: note: in instantiation of function template specialization
  41.       'is_constexpr<float (float, float), i, float, float>' requested here
  42.     std::cout << is_constexpr<decltype(i), &i>(1.0f, 1.0f) << std::endl;
  43.                  ^
  44. a2.cpp:14:16: note: candidate template ignored: substitution failure [with F =
  45.       float (float, float), FP = i, Args = <float, float>]: non-type template
  46.       argument is not a constant expression
  47. constexpr bool is_constexpr_impl(bool&&)
  48.                ^
  49. 4 errors generated.
clone this paste RAW Paste Data