error.h 796 B

1234567891011121314151617181920212223242526272829303132333435
  1. /*
  2. * error.h - Error reporting
  3. *
  4. * Written 2009, 2010 by Werner Almesberger
  5. * Copyright 2009, 2010 by Werner Almesberger
  6. *
  7. * This program is free software; you can redistribute it and/or modify
  8. * it under the terms of the GNU General Public License as published by
  9. * the Free Software Foundation; either version 2 of the License, or
  10. * (at your option) any later version.
  11. */
  12. #ifndef ERROR_H
  13. #define ERROR_H
  14. extern int lineno;
  15. extern void (*reporter)(const char *s);
  16. void yywarn(const char *s);
  17. void yyerrorf(const char *fmt, ...)
  18. __attribute__((format(printf, 1, 2)));
  19. void yyerror(const char *s);
  20. void report_to_stderr(const char *s);
  21. void report_parse_error(const char *s);
  22. void fail(const char *fmt, ...)
  23. __attribute__((format(printf, 1, 2)));
  24. #endif /* !ERROR_H */