24 research outputs found

    Generating Bijections between HOAS and the Natural Numbers

    Full text link
    A provably correct bijection between higher-order abstract syntax (HOAS) and the natural numbers enables one to define a "not equals" relationship between terms and also to have an adequate encoding of sets of terms, and maps from one term family to another. Sets and maps are useful in many situations and are preferably provided in a library of some sort. I have released a map and set library for use with Twelf which can be used with any type for which a bijection to the natural numbers exists. Since creating such bijections is tedious and error-prone, I have created a "bijection generator" that generates such bijections automatically together with proofs of correctness, all in the context of Twelf.Comment: In Proceedings LFMTP 2010, arXiv:1009.218

    Descriptional Composition of Compiler Components

    No full text
    New machine architectures and new programming languages are always appearing, and thus the need for new compilers continues unabated. Even experimental languages and machines need compilers. Compiler writers developing new and/or experimental compilers face competing pressures when designing their large-scale structure. On the one hand, a more modular structure will make it easier to maintain, modify or reuse pieces of the compiler. A more modular compiler is more likely to be correct, and reusable compiler components lead to consistent semantics among the compilers using them. On the other hand, a highly modular structure may lead to ine ciencies in implementation. Suppose one uses an intermediate representation and divides up the compiler into two parts, one which compiles the source to the intermediate representation and another which translates a program in the intermediate representation to the target machine language. Doing so may make the compiler easier to understand, and furthermore, a wellchosen intermediate representation may prove a suitable target for other source languages, or a suitable source for translating to other machines. On the other hand, the need to creat

    Incremental Evaluators for Remote Attribute Grammars

    Get PDF
    AbstractRemote attribute grammars use objects with separately defined fields to induce direct non-local dependencies in attribute grammars. Fields of an object may be read remotely from where it is created, and special “collection” fields may be written remotely as well. Building on earlier work which shows that remote attribute grammars can be scheduled statically, this paper shows how they may be implemented incrementally. The static schedule is used to ensure an object's fields are defined before they are read and that we never re-evaluate an attribute multiple times per edit-cycle. Dynamic dependencies are used to mark remote use sites as affected when a field is changed. The result is an efficient and practical incremental evaluation

    LIPIcs, Volume 37, ECOOP\u2715, Complete Volume

    No full text
    LIPIcs, Volume 37, ECOOP\u2715, Complete Volum

    Front Matter, Table of Contents, Preface, Artifacts, Conference Organization

    No full text
    Front Matter, Table of Contents, Preface, Artifacts, Conference Organizatio
    corecore