Implemented panic recovery, but it still has problems in parsing.