tb0359.pp 360 B

123456789101112131415161718192021222324
  1. { %version=1.1 }
  2. {$ifdef unix}
  3. {$linklib c}
  4. type
  5. tprintfproc=procedure(t:pchar);varargs;cdecl;
  6. procedure printf(t:pchar);varargs;cdecl;external;
  7. var
  8. t : tprintfproc;
  9. begin
  10. printf('Proc test %d %s %f'#10,1,'test',1234.5678);
  11. t:=@printf;
  12. t('Procvar test %d %s %f'#10,2,'test',1234.5678);
  13. {$else}
  14. begin
  15. writeln('Unix only test');
  16. {$endif}
  17. end.