Abstract
In the traditional formulation of attribute grammars (AGs) circularities are not allowed, that is, no attribute-instance in any derivation tree may be defined in terms of itself. Elsewhere in mathematics and computing, though, circular (or recursive) definitions are commonplace, and even essential. Given appropriate constraints, recursive definitions are well-founded, and the least fixed-points they denote are computable. This is also the case for circular AGs.
This paper presents constraints on individual attributes and semantic functions of an AG that are sufficient to guarantee that a circular AG specifies a well-defined translation and that circularly-defined attribute-instances can be computed via successive approximation. AGs that satisfy these constraints are called finitely recursive.
An attribute evaluation paradigm is presented that incorporates successive approximation to evaluate circular attribute-instances, along with an algorithm to automatically construct such an evaluator. The attribute evaluators so produced are static in the sense that the order of evaluation at each production-instance in the derivation-tree is determined at the time that each translator is generated.
A final algorithm is presented that tells which individual attributes and functions must satisfy the constraints.
Publisher
Association for Computing Machinery (ACM)
Subject
Computer Graphics and Computer-Aided Design,Software
Cited by
33 articles.
订阅此论文施引文献
订阅此论文施引文献,注册后可以免费订阅5篇论文的施引文献,订阅后可以查看论文全部施引文献
1. Interactive Abstract Interpretation with Demanded Summarization;ACM Transactions on Programming Languages and Systems;2024-03-29
2. Nanopass Attribute Grammars;Proceedings of the 16th ACM SIGPLAN International Conference on Software Language Engineering;2023-10-23
3. Sharing Trees and Contextual Information: Re-imagining Forwarding in Attribute Grammars;Proceedings of the 16th ACM SIGPLAN International Conference on Software Language Engineering;2023-10-23
4. Incremental causal connection for self-adaptive systems based on relational reference attribute grammars;Proceedings of the 25th International Conference on Model Driven Engineering Languages and Systems;2022-10-23
5. Demanded abstract interpretation;Proceedings of the 42nd ACM SIGPLAN International Conference on Programming Language Design and Implementation;2021-06-18