【24h】

Syntax Error Search Using Parser Combinators

机译:使用Parser组合器搜索语法错误

获取原文

摘要

Parser combinators is a popular approach to parsing sequences generated by context-free grammars, which can be specialized data formats (e.g. JSON, YAML), markup languages like XML or HTML. At the same time, this approach is rarely used for parsing programming languages.The purpose of this paper is to study the application of parser combinators for programming languages processing, and more precisely for searching of syntax errors. The method that had been developed during this research was compared with an algorithm of syntax analysis of programming languages using parser-generators. Parser combinator takes less time on average to find a syntax error in the source code. Its average time complexity is linear with respect to the length of the input sequence, while the parser generator has an average quadratic complexity. Moreover, a parser combinator requires less memory than a parser generator.These results can be used for building intelligent code completion tools for fast syntax error detection.
机译:解析器组合器是一种流行的方法来解析由无内容语法生成的序列,它可以是专门的数据格式(例如JSON,YAML),如XML或HTML等标记语言。与此同时,这种方法很少用于解析编程语言。本文的目的是研究解析器组合器用于编程语言处理,更精确地搜索语法错误。将该研究中开发的方法与使用解析器发生器的编程语言的语法分析算法进行了比较。 Parser Combinator平均需要更少的时间来查找源代码中的语法错误。其平均时间复杂度对于输入序列的长度是线性的,而解析器发生器具有平均二次复杂度。此外,解析器组合器需要比解析器生成器更少的内存。这些结果可用于构建快速语法错误检测的智能代码完成工具。

著录项

相似文献

  • 外文文献
  • 中文文献
  • 专利
获取原文

客服邮箱:kefu@zhangqiaokeyan.com

京公网安备:11010802029741号 ICP备案号:京ICP备15016152号-6 六维联合信息科技 (北京) 有限公司©版权所有
  • 客服微信

  • 服务号