~/talk

“Contract Programming in C++(20) (part 1 of 2)”

Talkat CppCon 2018 · 2018-09-23..09-28· [software-architecture]
links:none on file
slides:none on file

Defines contracts as explicit preconditions/postconditions/invariants, explains the C++ standard’s 1,500‑page contract promise and undefined behavior consequences, and gives concrete specs: sort needs a valid multipass range, swappable elements, comparator applicability and permutation/stability/complexity postconditions; compares guarantees (basic, transactional, no‑fail), shows sum overflow handling strategies (detect, widen type, or document narrower domain), and discusses adding contracts incrementally to existing code. Good if you want actionable rules and examples for C++ APIs.

AI-written summary · about

  1. 0:00Intro
  2. 0:31Two Talks
  3. 2:10Quick Survey
  4. 5:27What is a Contract?
  5. 7:08Examples
  6. 12:33Preconditions
  7. 16:10Invariants
  8. 17:03Error Reporting
  9. 18:18Useful Guarantees
  10. 20:59Changing a Contract
  11. 25:37Useful Terminology
  12. 31:59Example of a Contract
  13. 41:10Additional Concerns
  14. 45:43Second Example
  15. 50:31A Simple Correction?
  16. 51:13A Portable Correction
  17. 51:38Simple vs. Complex Constraints
  18. 54:21Closing Advice
~/search
type to search 6,249 conferences, 138,987 speakers and 185,172 talks
~/help
cmdctrl k
search every conference, speaker and series
/
focus the filter search
h
home
c
conferences
s
speakers
e
series
t
light / dark — the status bar button does the same
?
this help
esc
close this, then clear every filter — or just the search, while you are typing in it

Ignored while you are typing. Pages without a filter rail have no search to focus.