Author
anonymous
over 5 years ago
Language
Compiler
Options
Author
anonymous
over 5 years ago
$ prog.cc: In function 'int main()':
prog.cc:122:36: error: use of function 'std::string cpt::to_json(const T&) [with T = X; std::string = std::__cxx11::basic_string<char>]' with unsatisfied constraints
122 | std::cout << cpt::to_json(X{42}) << std::endl;
| ^
prog.cc:103:20: note: declared here
103 | inline std::string to_json(const T& t)
| ^~~~~~~
prog.cc:103:20: note: constraints not satisfied
prog.cc: In instantiation of 'std::string cpt::to_json(const T&) [with T = X; std::string = std::__cxx11::basic_string<char>]':
prog.cc:122:36: required from here
prog.cc:33:9: required for the satisfaction of 'supported_types<T>' [with T = X]
prog.cc:38:34: note: no operand of the disjunction is satisfied
34 | std::same_as<T, bool> ||
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
35 | std::integral<T> ||
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
36 | std::floating_point<T> ||
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
37 | std::same_as<T, std::string> ||
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
38 | map_like_container<T> ||
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~
39 | vector_like_container<T> ;
| ~~~~~~~~~~~~~~~~~~~~~~~~
cc1plus: note: set '-fconcepts-diagnostics-depth=' to at least 2 for more detail
Exit Code:
1