Study-Unit Description

Study-Unit Description


CODE CPS3238

 
TITLE Principles of Programming Languages

 
UM LEVEL 03 - Years 2, 3, 4 in Modular Undergraduate Course

 
MQF LEVEL 6

 
ECTS CREDITS 5

 
DEPARTMENT Computer Science

 
DESCRIPTION Programming languages are the main vehicle for constructing computational artefacts. They provide the means for specifying computational problems, designing solutions to such problems and automating these solutions as executable algorithms. Programming languages vary substantially from one another in terms of abstraction levels (e.g. access to memory), programming constructs (e.g. iteration versus recursion) and development support (e.g. static type checking versus dynamic typechecking). As a result, the choice of programming language has a considerable impact on the computational artefact produced, in terms of aspects such as ease-of-development, efficiency and maintainability.

This study-unit provides an introduction to the science of this subject matter, exploring some of the theoretical principles underpinning the programming language technologies of today. In particular, it introduces the semantics for a number of programming languages from different paradigms using a structural, operational approach. The operational semantics provides a high-level description of the compiler implementations of the respective languages and allows one to formally state and prove properties about these languages. The study unit also introduces the subject of type systems, reasoning systems used to analyse programs written in such languages and rule our erroneous code. It presents the design space for such systems and uses the formally specified operational semantics of the languages to prove soundness for the type systems presented

Aims:

• Induct the student to programming language semantics in terms of operational specifications for programming language behavior and static syntactic analysis through logic-based sequent rules;
• Provide the student with mathematical tools to establish correspondences between the two forms of semantics.

Learning Outcomes:

Knowledge and Understanding:
By the end of the unit, the student will be able to:

- Compare and contrast the various forms of operational semantics such as big-step and small-step semantics;
- Recall the difference between the static semantics of a language, defined through a static type system, and the dynamic semantics, defined through the operational semantics. In particular, the student should appreciate better how the static semantics needs to approximate conservatively the dynamic semantics of Turing-complete languages for it to be sound;
- Identify the impact of various programming language mechanisms (e.g. static versus dynamic scoping) on the respective semantics of the language and the programs constructed with it;
- Understand and compare at a conceptual level the differences underpinning present programming language technologies and paradigms.

Skills:
By the end of the unit, the student will be able to:

- Utilise better the constructs and support provided by the language technology of choice, thus producing more reliable computational artefacts more efficiently;
- Select better the appropriate language paradigm/technology for the computational task at hand;
- Adapt more quickly to future programming languages and paradigms;
- Design better programming abstractions such as libraries and domain specific languages.

Textbooks:

- Pierce, B.C. (2002). Types and programming languages. MIT Press
- Hennessy, M. (1990). The semantics of programming languages. Wiley

Supplementary texts:

- Winskel, G. (1993). The formal semantics of programming languages. MIT Press
- Harper, R. (2012). Practical Foundations for Programming Languages. Cambridge University Press

 
ADDITIONAL NOTES Students taking this study-unit are assumed to have knowledge of the material covered in the following study-units:
- CPS1002;
- CPS1005 or CPS2007;
- CPS2000 or CPS2006;
- CPS2001;
- CPS2004;
- CPS2005.

 
STUDY-UNIT TYPE Lecture

 
METHOD OF ASSESSMENT
Assessment Component/s Assessment Due Sept. Asst Session Weighting
Examination (3 Hours) SEM1 Yes 100%

 
LECTURER/S Adrian Francalanza (Co-ord.)

 

 
The University makes every effort to ensure that the published Courses Plans, Programmes of Study and Study-Unit information are complete and up-to-date at the time of publication. The University reserves the right to make changes in case errors are detected after publication.
The availability of optional units may be subject to timetabling constraints.
Units not attracting a sufficient number of registrations may be withdrawn without notice.
It should be noted that all the information in the description above applies to study-units available during the academic year 2023/4. It may be subject to change in subsequent years.

https://www.um.edu.mt/course/studyunit