We show that there exist translations between polymorphic lambda-calculus and a subsystem of minimal logic with existential types, which form a Galois insertion (embedding). The translation from polymorphic lambda-cal...
详细信息
We show that there exist translations between polymorphic lambda-calculus and a subsystem of minimal logic with existential types, which form a Galois insertion (embedding). The translation from polymorphic lambda-calculus into the existential type system is the so-called call-by-name CPS-translation that can be expounded as an adjoint from the neat connection. The construction of an inverse translation is investigated from it viewpoint of residuated mappings. The duality appears not only in the reduction relations but also in the proof structures, such as paths between the source and the target calculi. From a programming point of view, this result means that abstract data types can interpret polymorphic functions under the CPS-translation. We may regard abstract data types as a dual notion of polymorphic functions. (C) 2009 Elsevier B.V. All rights reserved.
The C programming language is a foundational technology for modern computing with millions of lines of code implementing everything from hobby projects to commercial operating systems. This installation base and the p...
详细信息
The C programming language is a foundational technology for modern computing with millions of lines of code implementing everything from hobby projects to commercial operating systems. This installation base and the programmers producing it represent a massive software engineering investment spanning decades and likely to continue for decades more. Nevertheless, C, which was first standardized almost 30 years ago, lacks many features that make programming in more modern languages safer and more productive. The goal of the C for all project (pronounced "C for all") is to create an extension of C that provides modern safety and productivity features while still ensuring strong backward compatibility with C and its programmers. Prior projects have attempted similar goals but failed to honor the C programming style;for instance, adding object-oriented or functional programming with garbage collection is a nonstarter for many C developers. Specifically, C for all is designed to have an orthogonal feature set based closely on the C programming paradigm, so that C for all features can be added incrementally to existing C code bases, and C programmers can learn C for all extensions on an as-needed basis, preserving investment in existing code and programmers. This paper presents a quick tour of C for all features, showing how their design avoids shortcomings of similar features in C and other C-like languages. Experimental results are presented to validate several of the new features.
暂无评论