Modern C++ Best Practices

7.5 credits

Syllabus, Bachelor's level, 5SD818

A revised version of the syllabus is available.
Code
5SD818
Education cycle
First cycle
Main field(s) of study and in-depth level
Game Design G1F, Software Engineering G1F
Grading system
Pass with distinction (VG), Pass (G), Fail (U)
Finalised by
The Department Board, 22 May 2024
Responsible department
Department of Game Design

Entry requirements

15 credits in C++ - specific courses, alternatively 22.5 c. in Software Engineering with at least 15 c. in programming.

Learning outcomes

In terms of knowledge and comprehension, after completed course the student should be able to:

  • identify and explain idiomatic resource and object lifecycle management in C++, such as Resource Acquisition Is Initialization (RAII) and the Rule of Five
  • discuss the design rationales behind the Standard Library containers, iterators and algorithms
  • discuss the principles of Strong Typing in C++ and its role in enhancing interface expressivity, reducing errors, and improving efficiency
  • account for the advantages and disadvantages of different error handling solutions.

In terms of skill and ability, after completed course the student should be able to:

  • use stack based resource management, and implement the Rule of Five
  • employ unit testing and to ensure code functionality and robustness
  • use functions, named algorithms, custom types and standard library types to increase expressivity, safety / correctness, or semantic accuracy of C++ code
  • make use of various error handling mechanisms, such as exceptions, assertions, and optional or expected return types to signal and handle errors.

In terms of evaluation and analysis, after completed course the student should be able to:

  • with reference to the literature, static analysis, documentation or the Core Guidelines, evaluate code quality as a function of semantic accuracy, safety / correctness, testability, error handling, and performance.

Content

The purpose of this course is to help developers to adopt modern C++ and learn to make their code simpler, more readable and safer than most existing C++ code, without loss of performance. The student will get to know the modern C++ Standard Library, the C++ Core Guidelines, and how these help developers avoid common defect attractors which often lead to errors, spurious complexity and poor performance. The course will demonstrate tools such as static analyzers and automated testing, to help students adhere to best practices and write idiomatic Modern C++.

Instruction

Lectures and workshops

Assessment

The course is assessed through active participation in mandatory workshops, as well as through project work and oral presentations

If there are special reasons for doing so, an examiner may make an exception from the method of assessment indicated and allow a student to be assessed by another method. An example of special reasons might be a certificate regarding special pedagogical support from the University´s disability coordinator.

Other regulations

The course overlaps 5SD815, API Design and Best Practices, 7.5 credits

FOLLOW UPPSALA UNIVERSITY ON

Uppsala University on Facebook
Uppsala University on Instagram
Uppsala University on Youtube
Uppsala University on Linkedin