fork download
  1. struct a {};
  2.  
  3. int main() {
  4. a* ptr = &a();
  5. return 0;
  6. }
Compilation error #stdin compilation error #stdout 0s 0KB
stdin
Standard input is empty
compilation info
prog.cpp: In function ‘int main()’:
prog.cpp:4:14: error: taking address of temporary [-fpermissive]
  a* ptr = &a();
              ^
stdout
Standard output is empty