A brief tutorial on parsing and lexing is in order.
应该给出关于解析和词法分析的一个简短指南。
Lexing and parsing through the HOP framework are introduced and developed.
这一章介绍并开发了通过HOP框架进行制定规则和分析的功能。
This process is known more formally as parsing (or to be more precise, tokenizing, lexing, and parsing).
这个过程更正式的称呼是解析(parsing)(更准确地说,是标记解释(tokenizing)、词法解析(lexing)和语法解析)。
Perl 5 offers no built-in parsing facilities, but it does offer lexing facilities through regular expressions.
Perl5提供了非内置的解析工具,但是它没有通过正则表达式提供词法分析工具。
Tokenizing/Lexing: breaking up a string of characters into meaningful (to the language) chunks, called tokens.
分词/词法分析:分词指将一段字符串破成有意义的(相对于这门语言)小块。
Like p: : RD, those grammars use simple rules to do lexing, and then use more complex rules to parse the lexed input.
类似于P:RD,那些语法使用简单的规则来进行词法分析,然后使用更复杂的规则来解析经过词法分析后的输入内容。
Lexing, to give one definition, is the act of breaking up input into meaningful words (also called lexing tokens or lexemes).
从定义来看,词法分析是将输入内容分解为有意义的单词(也叫做词法分析记号(lexing tokens)或词位(lexemes))的动作。
When lexing is finished, a meaningless stream of data has been transformed into a sequence of words meaningful to the parser.
词法分析结束后,无意义的数据流被转变为一个有意义的单词序列,提供给解析器。
If you want to understand Perl 6 grammars, you'll have to learn more about lexing and parsing that you probably ever wanted to.
如果您想要理解Perl6语法,就不得不去深入学习您可能曾经想过要学的lexing和parsing。
It's no surprise that parsing and lexing in Perl 6 is done in a very similar way to the Perl 5 and p: : RD combination described above.
Perl6中解析与词法分析的完成方式与上面所描述的Perl5和P:RD的组合非常类似,这是不足为奇的。
The downside of Parse: : RecDescent is that it is moderately slow because it USES extensible grammar rules and on-the-fly lexing and parsing.
RecDescent的缺点是:由于它使用可扩展文法规则并且实时地进行记载和解析,所以比较慢。
While lexing does not have to be done through regular expressions, they tend to be a handy vehicle through the jungle of programming and data languages.
尽管词法分析不是必须通过正则表达式来完成,但是它们往往可以便捷地解决程序编制和数据语言的难题。
For lexing purposes, this means that the lexer definition of an integer number, for example, can be used to build the lexer definition of a real number and a fraction.
例如,对于词法分析目的而言,这意味着可以用整数的词法分析器定义来构建实数和分数的词法分析器定义。
This section is intended only as an introduction to the rules of building a Parse: : RecDescent syntax and will include actions, remembering the state, rejecting productions, and lexing text.
这一节只准备介绍构建Parse:recdescent语法的规则,将包括操作、记忆状态、拒绝产品和对文本进行记载。
This section is intended only as an introduction to the rules of building a Parse: : RecDescent syntax and will include actions, remembering the state, rejecting productions, and lexing text.
这一节只准备介绍构建Parse:recdescent语法的规则,将包括操作、记忆状态、拒绝产品和对文本进行记载。
应用推荐