fork(1) download
  1. #include <iostream>
  2.  
  3. template<typename T>
  4. unsigned long f(void *) { return 0; }
  5.  
  6. struct A { char c; };
  7. struct B { char c[100]; };
  8.  
  9. typedef unsigned long ftype(void*);
  10.  
  11. int main() {
  12. std::cout << (ftype*)f<A> << std::endl;
  13. std::cout << (ftype*)f<B> << std::endl;
  14. return 0;
  15. }
Success #stdin #stdout 0.02s 2724KB
stdin
Standard input is empty
stdout
1
1