Abstract
Increasing attention is being paid to Gödel, a new declarative programming language aimed at diminishing the gap between theory and practice of programming with logic. An intriguing question is whether or not existing logic programs can be suitably re-used in Gödel. We investigate the possibility of employing Gödel as a meta-language for re-using and composing existing definite programs. Two alternative implementations of a set of meta-level operations for composing definite programs are presented. The first implementation consists of an extended vanilla meta-interpreter using the non-ground representation of object level programs. The second implementation exploits the meta-programming facilities offered by Gödel, which support the construction of meta-interpreters using the ground representation of object level programs.
This is a preview of subscription content, log in via an institution.
Preview
Unable to display preview. Download preview PDF.
References
K. R. Apt. Logic programming. In J. van Leeuwen, editor, Handbook of Theoretical Computer Science, pages 493–574. Elsevier, 1990. Vol. B.
K. R. Apt. Declarative programming in Prolog. In D. Miller, editor, Proc. International Symposium on Logic Programming, pages 11–35. MIT Press, 1993.
R. Barbuti and R. Giacobazzi. A bottom-up polymorphic type inference in logic programming. Science of Computer Programming, 19(3):281–313, 1992.
A. Brogi. Program Construction in Computational Logic. PhD thesis, University of Pisa, March 1993.
A. Brogi, P. Mancarella, D. Pedreschi, and F. Turini. Hierarchies through Basic Metalevel Operators. In M. Bruynooghe, editor, Proceedings of the Second Workshop on Meta-programming in Logic, pages 381–396, 1990.
A. Brogi, P. Mancarella, D. Pedreschi, and F. Turini. Modular Logic Programming. ACM Transactions on Programming Languages and Systems, 16(3), 1994.
A. Brogi and F. Turini. Metalogic for Knowledge Representation. In J.A. Allen, R. Fikes, and E. Sandewall, editors, Principles of Knowledge Representation and Reasoning: Proceedings of the Second International Conference, pages 100–106. Morgan Kaufmann, 1990.
A. Brogi and F. Turini. Semantics of meta-logic in an algebra of programs. In S. Abramski, editor, Proceedings Ninth Annual IEEE Symposium on Logic in Computer Science. IEEE Society Press, 1994.
K.L Clark, F.G. McCabe, and S. Gregory. IC-Prolog language features. In K.L. Clark and S.A. Tarnlund, editors, Logic Programming, pages 253–266. Academic Press, 1982.
C.A. Gurr. A guide to specialising Gödel programs with the partial evaluator sage. Technical report, University of Edinburgh, 1994.
C.A. Gurr. A self-applicable partial evaluator for the logic programming language Gödel. PhD thesis, University of Bristol, 1994.
P.M. Hill. A parameterised module system for constructing typed logic programs. In R. Bajcsy, editor, Proceedings IJCAI'93, pages 874–880. Morgan Kaufmann, 1993.
P.M. Hill and J.W. Lloyd. Analysis of metaprograms. In H.D. Abramson and M.H. Rogers, editors, Metaprogramming in Logic Programming, pages 23–52. The MIT Press, 1989.
P.M. Hill and J.W. Lloyd. The Gödel Programming Language. The MIT Press, 1994.
R.A. Kowalski. Predicate logic as a programming language. In IFIP 74, pages 569–574, 1974.
R.A. Kowalski. Problems and Promises of Computational Logic. In J.W. Lloyd, editor, Computational Logic, Symposium Proceedings, pages 1–36. Springer-Verlag, 1990.
G. Levi and D. Ramundo. A Formalization of Metaprogramming for Real. In D.S. Warren, editor, Proceedings Tenth International Conference on Logic Programming, pages 354–373. The MIT Press, 1993.
J.W. Lloyd. Foundations of logic programming. Springer-Verlag, second edition, 1987.
P. Mancarella and D. Pedreschi. An algebra of logic programs. In R. A. Kowalski and K. A. Bowen, editors, Proceedings Fifth International Conference on Logic Programming, pages 1006–1023. The MIT Press, 1988.
B. Martens and D. De Schreye. Why untyped non-ground meta-programming is not (much of) a problem. Technical Report CW159, Departement Computer-wetenschappen, K.U. Leuven, Belgium, December 1992. Revised November 1993, Abridged version to appear in The Journal of Logic Programming.
L. Monteiro and A. Porto. Contextual logic programming. In G. Levi and M. Martelli, editors, Proceedings Sixth International Conference on Logic Programming, pages 284–302. The MIT Press, 1989.
L. Naish. Negation and quantifiers in NU-Prolog. In E. Shapiro, editor, Proceedings Third International Conference on Logic Programming, pages 624–634. Springer-Verlag, 1987.
D. De Schreye and B. Martens. A Sensible Least Herbrand Semantics for Untyped Vanilla Meta-Programming and its Extension to a Limited Form of Amalgamation. In A. Pettorossi, editor, Proceedings of the Third Workshop on Meta-programming in Logic, pages 127–141, 1992.
L. Sterling and E. Shapiro. The Art of Prolog. The MIT Press, 1986.
M. H. van Emden and R. A. Kowalski. The semantics of predicate logic as a programming language. Journal of the ACM, 23(4):733–742, 1976.
Author information
Authors and Affiliations
Editor information
Rights and permissions
Copyright information
© 1994 Springer-Verlag Berlin Heidelberg
About this paper
Cite this paper
Brogi, A., Contiero, S. (1994). Gödel as a meta-language for composing logic programs. In: Fribourg, L., Turini, F. (eds) Logic Program Synthesis and Transformation — Meta-Programming in Logic. META LOPSTR 1994 1994. Lecture Notes in Computer Science, vol 883. Springer, Berlin, Heidelberg. https://doi.org/10.1007/3-540-58792-6_23
Download citation
DOI: https://doi.org/10.1007/3-540-58792-6_23
Published:
Publisher Name: Springer, Berlin, Heidelberg
Print ISBN: 978-3-540-58792-7
Online ISBN: 978-3-540-49104-0
eBook Packages: Springer Book Archive