fork(2) download
  1. #include <iostream>
  2.  
  3. struct S
  4. {
  5. void foo()
  6. {
  7. std::cout << std::boolalpha << (this == nullptr) << std::endl;
  8. }
  9. };
  10.  
  11. int main()
  12. {
  13. reinterpret_cast<S*>(0)->foo();
  14. }
Success #stdin #stdout 0s 15232KB
stdin
Standard input is empty
stdout
true