Formalization of metaprogramming for real
Giorgio Levi, Davide Ramundo · 1993
The paper formally shows that the S-semantics is adequate for reasoning about the soundness and completeness of real Prolog metainterpreters, based on the non-ground representation of object-level variables. The paper extends some recent results by De Schreye and Martens, by proving the "equivalence" between the object program and its version metainterpreted by vanilla for any positive logic program. The same construction is applied to obtain a soundness and completeness result for an enhanced metainterpreter defining various inheritance mechanisms on structured logic programs. We then consider the specialization of metainterpreters by means of partial deduction techniques, both in the case of vanilla and of the inheritance metainterpreter. We prove that success derivations have exactly the same length in the specialized program and in the "corresponding" object-level program. 1 Introduction One of the most relevant and successful features of PROLOG is its set of primitives oriented t...