Programming Language Fundamentals by Example

Book description

Surveying the major programming languages that have hallmarked the evolution of computing, Programming Language Fundamentals by Example provides an understanding of the many languages and notations used in computer science, the formal models used to design phases, and the foundations of languages including linguistics. This textbook guides students through the process of implementing a simple interpreter with case-based exercises, questions, and a semester-long project that encompasses all of the concepts and theories presented in the book into one concrete example. It covers also such topics as formal grammars, automata, denotational and axiomatic semantics, and rule-based presentation.

Table of contents

  1. Cover
  2. Half Title
  3. Title Page
  4. Copyright Page
  5. Table of Contents
  6. List of Figures
  7. The Author
  8. Preface
  9. 1 A Word about Using This Text
    1. 1.1 Expectations for the Student and Instructor
    2. 1.2 Opening Comments
    3. 1.3 Possible Semester Course
      1. 1.3.1 General Planning
        1. 1.3.1.1 Learning Principle 1: Prior Knowledge
        2. 1.3.1.2 Learning Principle 2: Foundational Knowledge
        3. 1.3.1.3 Learning Principle 3: Metacognition
    4. 1.4 Detailed Semester Plan
      1. 1.4.1 Milestone Maps
  10. 2 Introduction to the Problem
    1. 2.1 Memorandum from the President
    2. 2.2 Background
      1. 2.2.1 Cambridge Polish
      2. 2.2.2 A Note on Notation
      3. 2.2.3 A Note on Names
    3. 2.3 SOL
    4. 2.4 Primitive Data and Primitive Operations
      1. 2.4.1 Constants
      2. 2.4.2 Variables
        1. 2.4.2.1 Arrays
        2. 2.4.2.2 Assignment
    5. 2.5 Primitive Data Operations
      1. 2.5.1 Stack Control Operations
        1. 2.5.1.1 Stack Position Variable
        2. 2.5.1.2 Stack Operations
    6. 2.6 Control Structures
      1. 2.6.1 If-Selection
      2. 2.6.2 Select-Selection
        1. 2.6.2.1 While
        2. 2.6.2.2 Compound Statement: Begin-End
    7. 2.7 Expressions
    8. 2.8 Input File Structures and File Scope
    9. 2.9 Derived Types
    10. 2.10 Scope and Persistence
      1. 2.10.1 Scope Definition
      2. 2.10.2 Scoping within Functions and Compound Statements
    11. 2.11 Type System
    12. 2.12 Primitive Functions and Arguments
    13. 2.13 Built-In Values, Functions, and Pseudo-Functions
      1. 2.13.1 Reads, Writes, and File Operations
    14. 2.14 Type Conversions
  11. PART I: MILESTONES
    1. 3 General Information
      1. 3.1 General Information on Milestones
        1. 3.1.1 Contract Grading
      2. 3.2 Milestone Report
        1. 3.2.1 Design Information
        2. 3.2.2 Software Project Management
        3. 3.2.3 Metacognitive Reflection
      3. 3.3 General Resources
      4. 3.4 Makefile Prototype
      5. Milestone I Learning a New Language, Gforth
      6. Milestone II Lexical Structure and Scanner
      7. Milestone III Parsing
      8. Milestone IV Type Checking
      9. Milestone V Elementary Compiling: Constants Only
      10. Milestone VI Scoping and Local Variables
      11. Milestone VII User-Defined Functions
      12. Milestone VIII User-Defined Complex Data
      13. Milestone IX Classes and Objects
  12. PART II: GENERAL INFORMATION
    1. 4 Project
      1. 4.1 Class
        1. 4.1.1 Week 1
        2. 4.1.2 Week 2
      2. 4.2 Mind Maps
        1. 4.2.1 The Exercise
        2. 4.2.2 Why It Works
    2. 5 Introduction to Linguistics
      1. 5.1 Focus Problem
        1. 5.1.1 Technical Vocabulary
        2. 5.1.2 Deliverable
      2. 5.2 Philosophy of Linguistics
      3. 5.3 Meaning: Language, Mind, and World
      4. 5.4 What Is Syntax?
      5. 5.5 Grammar
      6. 5.6 Semantics
      7. 5.7 Focused SQRRR
        1. 5.7.1 Survey and Question
        2. 5.7.2 Read
        3. 5.7.3 Recite
        4. 5.7.4 Review
    3. 6 Linguistics for Programming Languages
      1. 6.1 Metalanguage versus Object Language
      2. 6.2 Surface Structure and Deep Structure
      3. 6.3 Structural Induction
      4. 6.4 Interpretation Semantics
      5. 6.5 What about Pragmatics?
    4. 7 What Is a General Structure for Compiling?
      1. 7.1 A General Framework
      2. 7.2 Types
      3. 7.3 Recap
      4. 7.4 Defining a Language
        1. 7.4.1 Algorithms and Data Representation
        2. 7.4.2 Evolution
        3. 7.4.3 Implications for the Project
    5. 8 A Unified Approach to Design
      1. 8.1 Introduction to Design
      2. 8.2 Two Elements
        1. 8.2.1 Linguistic Issues
        2. 8.2.2 Schemata
      3. 8.3 Using These Ideas in Design
        1. 8.3.1 Understanding the Semantics of Grammars
          1. 8.3.1.1 Reading Terminals
          2. 8.3.1.2 Dealing with Nonterminals
        2. 8.3.2 Designing a Postfix Printer Program
        3. 8.3.3 Calculator
      4. 8.4 Design Recap
    6. 9 Technical Foundations in Programming Languages
      1. 9.1 Introduction
      2. 9.2 Binding Times: When Do We Know?
      3. 9.3 Scope
      4. 9.4 The λ-Calculus Model
        1. 9.4.1 Syntax
          1. 9.4.1.1 Variables
          2. 9.4.1.2 Introducing Variable Names
        2. 9.4.2 Semantics
        3. 9.4.3 Substitution and Rewriting
        4. 9.4.4 Recursion and the Unfolding Model
        5. 9.4.5 Arguments, Prologues, and Epilogues
          1. 9.4.5.1 Argument Passing
      5. 9.5 Implementation Issues
    7. 10 Storage Management Issues
      1. 10.1 Computer Memory
      2. 10.2 Determining the Size Required
        1. 10.2.1 Compiler-Defined Primitive Data
        2. 10.2.2 Space for Structures
        3. 10.2.3 Arrays
          1. 10.2.3.1 One-Dimensional Array Addressing Polynomials
          2. 10.2.3.2 One-Dimensional Arrays with Nonstandard Origins
        4. 10.2.4 Multidimensional Arrays
      3. 10.3 Runtime Storage Management
        1. 10.3.1 Scoping as a Visibility Function
        2. 10.3.2 Stack Frame
    8. 11 Personal Software Design Process Portfolio
      1. 11.1 Time Management for Computer Science Students
        1. 11.1.1 There Are Not Twenty-Four Hours in a Day
        2. 11.1.2 A Three-Credit Course Is Nine Hours
        3. 11.1.3 The Key Is Finding Out How You Spend Your Time
        4. 11.1.4 Keeping Track of Programming Time
      2. 11.2 Discovering How Long It Takes to Write a Program
        1. 11.2.1 Problem Decomposition
        2. 11.2.2 Work Breakdown Structure
      3. 11.3 Earned Value Computations
        1. 11.3.1 Baseline and Schedule Variance Computations
        2. 11.3.2 Rebudgeting
        3. 11.3.3 Process
        4. 11.3.4 Templates
      4. 11.4 Summary Information for PDSPP0
      5. 11.5 Requirements Template (RWT)
      6. 11.6 Time Recording Log (TRT)
      7. 11.7 Schedule Planning Template (SPT)
      8. 11.8 Defect Log Template (DLT)
    9. 12 How Did We Get Here? Where Do We Go from Here?
      1. 12.1 Looking Behind
        1. 12.1.1 The Difference Engine
        2. 12.1.2 The Golden Age of Mathematics
        3. 12.1.3 Arab Mathematics
        4. 12.1.4 Hindu Number Systems and Algebra
        5. 12.1.5 Greek Geometrical Algebra
        6. 12.1.6 Egyptian Algebra
        7. 12.1.7 Babylonian Algebra
        8. 12.1.8 What We Can Learn
      2. 12.2 The Role of the λ-Calculus
        1. 12.2.1 The Influence of Logic
        2. 12.2.2 Computability
      3. 12.3 Moving Forward from 1954
      4. 12.4 From 1954 until 1965
        1. 12.4.1 Imperative Languages from 1954 to 1965
        2. 12.4.2 Lisp and the Functional Paradigm
        3. 12.4.3 SNOBOL and Pattern Matching
        4. 12.4.4 APL and Matrices
      5. 12.5 Programming Languages from 1965 to 1980
        1. 12.5.1 Structured Programming
        2. 12.5.2 The Advent of Logical Programming
        3. 12.5.3 ML and Types
        4. 12.5.4 Our Old Friend: Forth
      6. 12.6 The 1980s and 1990s: The Object-Oriented Paradigm
      7. 12.7 The Parallel Processing Revolution
        1. 12.7.1 Architecture Nomenclature
        2. 12.7.2 Languages for Non-SISD Architectures
      8. 12.8 Critique of the Present
  13. Appendix A
  14. References
  15. Index

Product information

  • Title: Programming Language Fundamentals by Example
  • Author(s): D.E. Stevenson
  • Release date: November 2006
  • Publisher(s): Auerbach Publications
  • ISBN: 9781000654646