1. package com.sun.java_cup.internal;
  2. /** Exception subclass for reporting internal errors in JavaCup. */
  3. public class internal_error extends Exception
  4. {
  5. /** Constructor with a message */
  6. public internal_error(String msg)
  7. {
  8. super(msg);
  9. }
  10. /** Method called to do a forced error exit on an internal error
  11. for cases when we can't actually throw the exception. */
  12. public void crash()
  13. {
  14. System.err.println("JavaCUP Fatal Internal Error Detected");
  15. System.err.println(getMessage());
  16. printStackTrace();
  17. System.exit(-1);
  18. }
  19. }