## LEAP: A Language with Eval And Polymorphism

### Cached

### Download Links

Citations: | 2 - 1 self |

### BibTeX

@MISC{Pfenning_leap:a,

author = {Frank Pfenning and Peter Lee},

title = {LEAP: A Language with Eval And Polymorphism},

year = {}

}

### OpenURL

### Abstract

We describe the core of a new strongly-typed functional programming language called LEAP, a \Language with Eval And Polymorphism. " Pure LEAP is an extension of the!-order polymorphic-calculus (F!) by global de nitions that allows the representation of programs and the de nition of versions of reify, reflect, and eval for all of F!. Pure LEAP is therefore highly re exive and strongly typed. We believe that Pure LEAP can be extended to a practical and e cient metalanguage in the ML tradition. At present we are experimenting with a prototype implementation of Pure LEAP. 1

### Citations

936 | A theory of type polymorphism in progra.mming
- Milner
- 1978
(Show Context)
Citation Context ...F !, we need to allow global de nition of types and functions with free variables ranging over kinds. Such variables are generic in the same way that some type variables are generic in ML (see Milner =-=[12]-=-). We will use the concrete syntax: global de nition of to stand for x M global de nition of x to stand for M for global de nitions of types and terms, respectively. This addition to F ! is benign in ... |

364 |
Towards a theory of type structure
- Reynolds
- 1974
(Show Context)
Citation Context ... and concise de nitions of rei cation and re ection. Somewhat unexpectedly for us, the \tower" begins with an interpreter for the secondorder polymorphic -calculus (F2) (see Girard [5,6] and Reynolds =-=[16]-=-) written in the thirdorder polymorphic -calculus (F3). This does not easily extend to higher orders|only This research was supported in part by the O ce of Naval Research under contract N00014-84-K-0... |

320 | The Calculi of Lambda Conversion - Church - 1941 |

285 |
Interpre'tation fonctionelle et e'limination des coupures duns l'arithme'tique d'ordre supe'rieure
- Girard
- 1972
(Show Context)
Citation Context ... have found elegant and concise de nitions of rei cation and re ection. Somewhat unexpectedly for us, the \tower" begins with an interpreter for the secondorder polymorphic -calculus (F2) (see Girard =-=[5,6]-=- and Reynolds [16]) written in the thirdorder polymorphic -calculus (F3). This does not easily extend to higher orders|only This research was supported in part by the O ce of Naval Research under cont... |

227 |
Une extension de l'int,erpretat,ion de Godel & l'analyse, et son application & 1'Climination des coupures dans l'ana,lyse et la t,heorie des t.ypes
- Girard
- 1971
(Show Context)
Citation Context ... have found elegant and concise de nitions of rei cation and re ection. Somewhat unexpectedly for us, the \tower" begins with an interpreter for the secondorder polymorphic -calculus (F2) (see Girard =-=[5,6]-=- and Reynolds [16]) written in the thirdorder polymorphic -calculus (F3). This does not easily extend to higher orders|only This research was supported in part by the O ce of Naval Research under cont... |

190 |
Reflection and semantics in lisp
- Smith
- 1984
(Show Context)
Citation Context ... the answer was \No." Our answer is \Almost." After a brief review of F ! in Section 3, we explain this answer in Sections 4 and 5 by giving a construction reminiscent of the re ective tower of Smith =-=[18,19]-=-. Wand and Friedman's analysis of the re ective tower [3,22] emphasizes rei cation, the translation from programs to data, and re ection, the translation from data to programs, as central concepts. In... |

93 | Operational Semantics and Polymorphic Type Inference
- Tofte
- 1988
(Show Context)
Citation Context ...e found that the explicit polymorphism in Pure LEAP with suitable restrictions which can be easily checked, provide an extra degree of control which eliminates the need for \weak" [7] or \imperative" =-=[21]-=- type variables. 7 Conclusions As we stated in the introduction, our original goal was to design an practical, staticallytyped language suitable for use as a metalanguage for manipulating programs, pr... |

81 | Partial polymorphic type inference and higher-order unification
- Pfenning
- 1988
(Show Context)
Citation Context ...: Terms M ::= x j x: : M j M N j 3 :K : M j M [ ] We will not give the formal type inference system for this language here, but merely explain it informally. A more formal development can be found in =-=[14]-=-. The symbol is used to construct functions that can be applied to a term, yielding a term, and also to build functions that can be applied to a type, yielding a type. The symbol 3 constructs function... |

71 |
Three approaches to type structure
- Reynolds
- 1985
(Show Context)
Citation Context ...xplicitly de ne common data types and operations on them, such as natural numbers (int 1 : ) ( ) ) ) ), products, disjoint sum, and lists (list : 1 : ( ) ) ) ) ) ). For a good exposition see Reynolds =-=[15]-=- or Bohm [1]. We will give an alternative way of de ning some of these data types in Section 6.1.3. Next we de ne the judgments of the inference system that allow us to for terms and kinds for types. ... |

41 | History of LISP
- McCarthy
- 1981
(Show Context)
Citation Context ...simple, untyped functional language within itself. This was pursued further by Steele and Sussman [20] and others. In fact, writing metacircular interpreters has long been a standard practice in LISP =-=[8,9]-=-. Smith, in [18,19], introduces the notion of the re ective tower, illustrating it in the language 3-LISP. Friedman and Wand give their own analysis of the re ective tower in [4] and [3,22], isolating... |

37 |
The Standard ML Core Language
- Milner
- 1985
(Show Context)
Citation Context ... Our initial motivation came from the problem of nding a strongly-typed language suitable for use as a metalanguage for manipulating programs, proofs, and other similar symbolic data. The language ML =-=[11]-=- seemed to satisfy many of our criteria, but was not powerful enough to serve as its own metalanguage in a natural way. (We discuss what we mean by \natural" in Section 2.) This then led us to the que... |

23 |
and Gopalan Nadathur. Higher-order logic programming
- Miller
- 1986
(Show Context)
Citation Context ...a complete semi-decision procedure based on higher-order uni cation. More extensive experiments are necessary in order to gauge the practicality of this algorithm. Our current prototype uses a Prolog =-=[10]-=- implementation of this algorithm, with very encouraging preliminary results. 6.1.2 Generic polymorphism and the * syntax In the -calculus, the construction let x = N in M is taken as an abbreviation ... |

15 |
Re ection and semantics in a procedural language
- Smith
- 1982
(Show Context)
Citation Context ... the answer was \No." Our answer is \Almost." After a brief review of F ! in Section 3, we explain this answer in Sections 4 and 5 by giving a construction reminiscent of the re ective tower of Smith =-=[18,19]-=-. Wand and Friedman's analysis of the re ective tower [3,22] emphasizes rei cation, the translation from programs to data, and re ection, the translation from data to programs, as central concepts. In... |

13 |
The mystery of the tower revealed: A non-re ective description of the re ective tower
- Wand, Friedman
- 1988
(Show Context)
Citation Context ...eview of F ! in Section 3, we explain this answer in Sections 4 and 5 by giving a construction reminiscent of the re ective tower of Smith [18,19]. Wand and Friedman's analysis of the re ective tower =-=[3,22]-=- emphasizes rei cation, the translation from programs to data, and re ection, the translation from data to programs, as central concepts. In the setting of a strongly-typed functional language, we hav... |

13 |
The art of the interpreter or, the modularity complex (parts zero, one
- Sussman
(Show Context)
Citation Context ... in both the early and the recent literature. In [17] Reynolds gives a metacircular interpreter for a simple, untyped functional language within itself. This was pursued further by Steele and Sussman =-=[20]-=- and others. In fact, writing metacircular interpreters has long been a standard practice in LISP [8,9]. Smith, in [18,19], introduces the notion of the re ective tower, illustrating it in the languag... |

11 |
De nitional interpreters for higher-order programming languages
- Reynolds
- 1972
(Show Context)
Citation Context ...riteria, but was not powerful enough to serve as its own metalanguage in a natural way. (We discuss what we mean by \natural" in Section 2.) This then led us to the question, rst posed by Reynolds in =-=[17]-=-, of whether stronglytyped languages admit metacircular interpreters. Conventional wisdom seemed to indicate that the answer was \No." Our answer is \Almost." After a brief review of F ! in Section 3,... |

8 |
A.Berarducci: Automatic synthesis of typed l-programs on term algebras
- Böhm
- 1985
(Show Context)
Citation Context ...ion 4.) The second trick is the solution to the technical challenge of dealing with inductively de ned data types with polymorphic constructors. This problem had been addressed in the literature (see =-=[1]-=- and [11] for two di erent approaches) only for the case where types are guaranteed to be uniform over any given element of the inductive type (such as lists: a list of type has sublists only of type ... |

8 |
Rei cation: Re ection without Metaphysics
- Friedman, Wand
- 1984
(Show Context)
Citation Context ...rd practice in LISP [8,9]. Smith, in [18,19], introduces the notion of the re ective tower, illustrating it in the language 3-LISP. Friedman and Wand give their own analysis of the re ective tower in =-=[4]-=- and [3,22], isolating rei cation and re ection as key concepts. This paper reports on our attempt to model rei cation and re ection in a strongly-typed language. Our results may be summarized as foll... |

4 |
References and weak polymorphism
- MacQueen
- 1988
(Show Context)
Citation Context ...d exceptions, we have found that the explicit polymorphism in Pure LEAP with suitable restrictions which can be easily checked, provide an extra degree of control which eliminates the need for \weak" =-=[7]-=- or \imperative" [21] type variables. 7 Conclusions As we stated in the introduction, our original goal was to design an practical, staticallytyped language suitable for use as a metalanguage for mani... |

4 |
Inductively De ned Types in the Calculus of Constructions
- Pfenning, Paulin-Mohring
(Show Context)
Citation Context ...ctively de ned type is given by a list of its \constructors" and their types. This is an extension of the datatype construction in ML, since constructors may be explicitly polymorphic. It is shown in =-=[13]-=- (extending ideas of Bohm & Berarducci [1]) that these types do not require an addition to the core language, since inductively de ned types are representable by closed types. With this in mind, we ca... |