LLmessage.c 540 B

12345678910111213141516171819202122232425
  1. /*
  2. * (c) copyright 1987 by the Vrije Universiteit, Amsterdam, The Netherlands.
  3. * See the copyright notice in the ACK home directory, in the file "Copyright".
  4. */
  5. /* $Header$ */
  6. /* PARSER ERROR ADMINISTRATION */
  7. #include "arith.h"
  8. #include "LLlex.h"
  9. #include "Lpars.h"
  10. extern char *symbol2str();
  11. LLmessage(tk) {
  12. err_occurred = 1;
  13. if (tk < 0)
  14. error("garbage at end of line");
  15. else if (tk) {
  16. error("%s missing", symbol2str(tk));
  17. if (DOT != EOF) SkipToNewLine(0);
  18. DOT = EOF;
  19. }
  20. else
  21. error("%s deleted", symbol2str(DOT));
  22. }