Compiling Prolog to Forth
The fact that the focus of a Prolog computation is the structure of the program leads directly to a view of a Prolog compiler as a procedure that takes a collection of Prolog clauses and produces a description of their structure that just happens to be executable. Forth lends itself naturally to the description of both structures and processes. In fact, some hold that Forth programming involves creating the parts of speech required to describe an application. This article proposes that for this reason, Forth is a very good language for prototyping Prolog compilers. A simple object language for a Prolog to Forth compiler is presented and discussed.