tstring5.pp 513 B

12345678910111213141516171819202122232425262728293031323334353637383940
  1. uses
  2. erroru;
  3. var
  4. a1,a2 : ansistring;
  5. function f1 : ansistring;
  6. begin
  7. f1:='';
  8. end;
  9. function f2 : ansistring;
  10. begin
  11. f2:='Hello';
  12. end;
  13. begin
  14. a1:='';
  15. a2:='Hello';
  16. if a1<>'' then
  17. do_error(1000);
  18. if a2='' then
  19. do_error(1001);
  20. if ''<>a1 then
  21. do_error(1002);
  22. if ''=a2 then
  23. do_error(1003);
  24. if f1<>'' then
  25. do_error(1004);
  26. if f2='' then
  27. do_error(1005);
  28. if ''<>f1 then
  29. do_error(1006);
  30. if ''=f2 then
  31. do_error(1007);
  32. end.