fork download
  1. #define SOLUTION 0
  2.  
  3. template <class T>
  4. constexpr int one = 1;
  5.  
  6. template <class T>
  7. struct A {
  8. static constexpr int o = one<A<T>>;
  9.  
  10. void call() {
  11. static_assert(one<A<T>> == 1, "Failure");
  12. }
  13. };
  14.  
  15. int main() {
  16. #if SOLUTION
  17. A<int> object;
  18. #endif
  19.  
  20. [](A<int> a) {
  21. a.call();
  22. };
  23.  
  24. return 0;
  25. }
Success #stdin #stdout 0s 15240KB
stdin
Standard input is empty
stdout
Standard output is empty