{"title":"Repairing Syntax Errors in LR-based Parsers","authors":"C. Cerecke","doi":"10.1145/563857.563804","DOIUrl":null,"url":null,"abstract":"When a compiler encounters a syntax error, it usually attempts to restart parsing to check the remainder of the input for any further errors. One common method of recovering from syntax errors is to repair the incorrect input string, allowing parsing to continue. This research presents a language independent method for repairing the input string to an LALR(1) parser. The method results in much faster repairs in general than an existing method, enabling some errors to be repaired that were previously too costly. Results are based on repairing syntax errors in Java programs from first year computer science students.","PeriodicalId":136130,"journal":{"name":"Australasian Computer Science Conference","volume":"182 1","pages":"0"},"PeriodicalIF":0.0000,"publicationDate":"1900-01-01","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":"12","resultStr":null,"platform":"Semanticscholar","paperid":null,"PeriodicalName":"Australasian Computer Science Conference","FirstCategoryId":"1085","ListUrlMain":"https://doi.org/10.1145/563857.563804","RegionNum":0,"RegionCategory":null,"ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":null,"EPubDate":"","PubModel":"","JCR":"","JCRName":"","Score":null,"Total":0}
引用次数: 12
Abstract
When a compiler encounters a syntax error, it usually attempts to restart parsing to check the remainder of the input for any further errors. One common method of recovering from syntax errors is to repair the incorrect input string, allowing parsing to continue. This research presents a language independent method for repairing the input string to an LALR(1) parser. The method results in much faster repairs in general than an existing method, enabling some errors to be repaired that were previously too costly. Results are based on repairing syntax errors in Java programs from first year computer science students.