tb0181.pp 764 B

1234567891011121314151617181920212223242526272829303132
  1. { %OPT=-St }
  2. { Old file: tbs0214.pp }
  3. { bugs for static methods OK 0.99.11 (PM) }
  4. Program SttcTest;
  5. { Note: I've cut a lot out of this program, it did originally have
  6. constructors, destructors and instanced objects, but this
  7. is the minimum required to produce the problem, and I think
  8. that this should work, unless I've misunderstood the use of
  9. the static keyword. }
  10. Type
  11. TObjectType1 = Object
  12. Procedure Setup; static;
  13. Procedure Weird; static;
  14. End;
  15. Procedure TObjectType1.Setup;
  16. Begin
  17. End;
  18. Procedure TObjectType1.Weird;
  19. Begin
  20. End;
  21. Begin
  22. TObjectType1.Setup;
  23. TObjectType1.Weird;
  24. TObjectType1.Weird; // GPFs before exiting "Weird"
  25. Writeln('THE END.');
  26. End.