程式語言之屬性文法(20點)

想請教一下何謂屬性文法 ( attribute grammar )

如果可以希望有詳細說明@@

拜託各位大大了

1 Answer

Rating
  • 鳳綾
    Lv 4
    1 decade ago
    Favorite Answer

    An Attribute grammar is a formal way to define attributes for the productions of a formal grammar, associating these attributes to values. The evaluation occurs in the nodes of the abstract syntax tree, when the language is processed by some parser or compiler.

    from Wiki~

    其上有介紹 L,S,LR,ECLR 4 種 attributed grammar

Still have questions? Get your answers by asking now.