Wandbox
SettingsLog
SettingsLog
Language
GitHubLogin
Ran/Viewed Log

Author

anonymous

over 6 years ago

Language

C++

Compiler

gcc 9.1.0

Options
Warnings
Boost 1.70.0
C++2a(GNU)
no pedantic

Author

anonymous

over 6 years ago

$ g++ prog.cc -Wall -Wextra -I/opt/wandbox/boost-1.70.0/gcc-9.1.0/include -std=gnu++2a
prog.cc: In instantiation of 'struct conjunction<valid_except_void<void> >':
prog.cc:5:39:   required from 'struct conjunction<valid_except_void<int>, valid_except_void<void> >'
prog.cc:10:42:   required from 'constexpr const auto test<int, void>'
prog.cc:12:23:   required from here
prog.cc:5:39: error: no match for 'operator&&' (operand types are 'valid_except_void<void>' and 'conjunction<>')
    5 |     std::integral_constant<bool, B1{} && conjunction<Bn...>{}> { };
      |                                  ~~~~~^~~~~~~~~~~~~~~~~~~~~~~
prog.cc:5:39: note: candidate: 'operator&&(bool, std::integral_constant<bool, true>::value_type {aka bool})' <built-in>
prog.cc:5:39: note:   no known conversion for argument 1 from 'valid_except_void<void>' to 'bool'
prog.cc: In instantiation of 'struct conjunction<valid_except_void<int>, valid_except_void<void> >':
prog.cc:10:42:   required from 'constexpr const auto test<int, void>'
prog.cc:12:23:   required from here
prog.cc:5:39: error: no match for 'operator&&' (operand types are 'valid_except_void<int>' and 'conjunction<valid_except_void<void> >')
prog.cc:5:39: note: candidate: 'operator&&(std::integral_constant<bool, false>::value_type {aka bool}, bool)' <built-in>
prog.cc:5:39: note:   no known conversion for argument 2 from 'conjunction<valid_except_void<void> >' to 'bool'
prog.cc: In instantiation of 'constexpr const auto test<int, void>':
prog.cc:12:23:   required from here
prog.cc:10:42: error: 'value' is not a member of 'conjunction<valid_except_void<int>, valid_except_void<void> >'
   10 | template <typename... Ts> constexpr auto test = /*std::*/conjunction<valid_except_void<Ts>...>::value;
      |                                          ^~~~
prog.cc:12:23: error: unable to deduce 'const auto' from 'test<int, void>'
   12 | constexpr auto inst = test<int, void>;
      |                       ^~~~~~~~~~~~~~~
prog.cc:12:16: warning: 'inst' defined but not used [-Wunused-variable]
   12 | constexpr auto inst = test<int, void>;
      |                ^~~~
Exit Code:
1