About: Higher-order programming is a research topic. Over the lifetime, 175 publications have been published within this topic receiving 6179 citations.
TL;DR: This chapter discusses Functional Programming in a Typed Language, which combines Functional Programming with Lists, and Object-Oriented Programming in C++, a Dialect of Lisp.
Abstract: I. INTRODUCTION. 1. The Role of Programming Languages. Toward Higher-Level Languages. Problems of Scale. Programming Paradigms. Language Implementation: Bridging the Gap. Exercises. Bibliographic Notes. 2. Language Description: Syntactic Structure. Expression Notations. Abstract Syntax Trees. Lexical Syntax. Context-Free Grammars. Grammars for Expressions. Variants of Grammars. Exercises. Bibliographic Notes. II. IMPERATIVE PROGRAMMING. 3. Statements: Structured Programming. The Need for Structured Programming. Syntax-Directed Control Flow. Design Considerations: Syntax. Handling Special Cases in Loops. Programming with Invariants. Proof Rules for Partial Correctness. Control flow in C. Exercises. Bibliographic Notes. 4. Types: Data Representation. The Role of Types. Basic Types. Arrays: Sequences of Elements. Records: Named Fields. Unions and Variant Records. Sets. Pointers: Efficiency and Dynamic Allocation. Two String Tables. Types and Error Checking. Exercises. Bibliographic Notes. 5. Procedure Activations. Introduction to Procedures. Parameter-Passing Methods. Scope Rules for Names. Nested Scopes in the Source Text. Activation Records. Lexical Scope: Procedures as in C. Lexical Scope: Nested Procedures and Pascal. Exercises. Bibliographic Notes. III. OBJECT-ORIENTED PROGRAMMING. 6. Groupings of Data and Operations. Constructs for Program Structuring. Information Hiding. Program Design with Modules. Modules and Defined Types. Class Declarations in C++. Dynamic Allocation in C++. Templates: Parameterized Types. Implementation of Objects in C++. Exercises. Bibliographic Notes. 7. Object-Oriented Programming. What is an Object? Object-Oriented Thinking. Inheritance. Object-Oriented Programming in C++. An Extended C++ Example. Derived Classes and Information Hiding. Objects in Smalltalk. Smalltalk Objects have a Self. Exercises. Bibliographic Notes. IV. FUNCTIONAL PROGRAMMING. 8. Elements of Functional Programming. A Little Language of Expressions. Types: Values and Operations. Function Declarations. Approaches to Expression Evaluation. Lexical Scope. Type Checking. Exercises. Bibliographic Notes. 9. Functional Programming in a Typed Language. Exploring a List. Function Declaration by Cases. Functions as First-Class Values. ML: Implicit Types. Data Types. Exception Handling in ML. Little Quilt in Standard ML. Exercises. Bibliographic Notes. 10. Functional Programming with Lists. Scheme, a Dialect of Lisp. The Structure of Lists. List Manipulation. A Motivating Example: Differentiation. Simplification of Expressions. Storage Allocation for Lists. Exercises. Bibliographic Notes. V. OTHER PARADIGMS. 11. Logic Programming. Computing with Relations. Introduction to Prolog. Data Structures in Prolog. Programming Techniques. Control in Prolog. Cuts. Exercises. Bibliographic Notes. 12. An Introduction to Concurrent Programming. Parallelism in Hardware. Streams: Implicit Synchronization. Concurrency as Interleaving. Liveness Properties. Safe Access to Shared Data. Concurrency in Ada. Synchronized Access to Shared Variables. Exercises. Bibliographic Notes. VI. LANGUAGE DESCRIPTION. 13. Semantic Methods. Synthesized Attributes. Attribute Grammars. Natural Semantics. Denotational Semantics. A Calculator in Scheme. Lexically Scoped Lambda Expressions. An Interpreter. An Extension: Recursive Functions. Exercises. Bibliographic Notes. 14. Static Types and the Lambda Calculus. Equality of Pure Lambda Terms. Substitution Revisited. Computation with Pure Lambda Terms. Programming Constructs as Lambda-Terms. The Typed Lambda Calculus. Polymorphic Types. Exercises. Bibliographic Notes. 15. A Look at Some Languages. Pascal: A Teaching Language. C: Systems Programming. C++: A Range of Programming Styles. Smalltalk, the Language. Standard ML. Scheme, a Dialect of Lisp. Prolog. Bibliography. Credits. Index. 0201590654T04062001
TL;DR: It is argued that CommonLoops' small kernel is powerful enough to implement the major object-oriented systems in use today, and its extensive use of meta-objects make practical both efficient implementation and experimentation with new ideas for object- oriented programming.
Abstract: CommonLoops blends object-oriented programming smoothly and tightly with the procedure-oriented design of Lisp. Functions and methods are combined in a more general abstraction. Message passing is invoked via normal Lisp function call. Methods are viewed as partial descriptions of procedures. Lisp data types are integrated with object classes. With these integrations, it is easy to incrementally move a program between the procedure and object-oriented styles.
One of the most important properties of CommonLoops is its extensive use of meta-objects. We discuss three kinds of meta-objects: objects for classes, objects for methods, and objects for discriminators. We argue that these meta-objects make practical both efficient implementation and experimentation with new ideas for object-oriented programming.
CommonLoops' small kernel is powerful enough to implement the major object-oriented systems in use today.
TL;DR: ContextJ is the authors' COP implementation for Java that properly integrates COP’s layer concept into the Java type system and provides both better performance and higher-level abstraction mechanisms than its Java-based predecessors.
Abstract: Context-oriented programming (COP) allows for the modularization of context-dependent behavioral variations. So far, COP has been implemented for dynamically-typed languages such as Lisp, Smalltalk, Python, and Ruby relying on reflection mechanisms, and for the statically-typed programming language Java based on a library and a pre-processor. ContextJ is our COP implementation for Java. It properly integrates COP’s layer concept into the Java type system. ContextJ is compiler-based. As confirmed by a benchmark and a case study, it provides both better performance and higher-level abstraction mechanisms than its Java-based predecessors. In this paper, we present the ContextJ language and explain its constructs and semantics. Further, we give an overview of the implementation of our compiler and discuss run-time benchmarks.
TL;DR: This paper shows that typical higher order programming examples can be captured with just rst order functions, by the systematic use of parameterized modules, in a style that is called parameterized programming.
Abstract: It is often claimed that the essence of functional programming is the use of functions as values, i.e., of higher order functions, and many interesting examples have been given showing the power of this approach. Unfortunately, the logic of higher order functions is diicult, and in particular, higher order uniication is undecidable. Moreover (and closely related), higher order expressions are notoriously diicult for humans to read and write correctly. However, this paper shows that typical higher order programming examples can be captured with just rst order functions, by the systematic use of parameterized modules, in a style that we call parameterized programming. This has the advantages that correctness proofs can be done entirely within rst order logic, and that interpreters and compilers can be simpler and more eecient. Moreover, it is natural to impose semantic requirements on modules, and hence on functions. A more subtle point is that higher order logic does not always mix well with subsorts, which can nonetheless be very useful in functional programming by supporting the clean and rigorous treatment of partially deened functions, exceptions, overloading, multiple representation, and coercion. Although higher order logic cannot always be avoided in speciication and veriication, it should be avoided wherever possible, for the same reasons as in programming. This paper contains several examples, including one in hardware veriication. An appendix shows how to extend standard equational logic with quantiication over functions, and justiies a perhaps surprising technique for proving such equations using only ground term reduction.