fork(2) download
  1. #include <stdio.h>
  2.  
  3. typedef struct T1
  4. {
  5. int id;
  6. } T1;
  7.  
  8. typedef struct T2
  9. {
  10. int id;
  11. } T2;
  12.  
  13. void f(T1 *ptr) {
  14. printf("f called\n");
  15. }
  16.  
  17. int main(void) {
  18. T2 obj;
  19. T2 *ptr = &obj;
  20. f(ptr);
  21. return 0;
  22. }
  23.  
  24.  
Success #stdin #stdout 0s 2248KB
stdin
Standard input is empty
stdout
f called