摘要:
Parser (语义分析器) 1. 概述 Parser是编译器front-end的第二步,Parser将Scanner识别出的词语按照语义进行分类,并将词语构建成源编程语言的语法模型。 “ The parser derives a syntactic structure for the progra 阅读全文
摘要:
现代编译器的结构: 上图中,IR: Intermediate Representations:原书的解释:A compiler uses some set of data structures to represent the code that it processes 源代码转换到目标程序,在编 阅读全文
摘要:
3-1不要对边缘效应的调用顺序产生依赖 Side effect: Modifying an object (如 ++,--) Calling a library IO function Accessing a volatile-qualified value 避免在同一行代码中调用多次变量且含++等 阅读全文