zettelkasten

Implicit Contract With Free Store Manager

Last updated: 1/9/2025

Whenever you allocate memory to the free store you make an implicit contract with the free store manager that has three clauses:

Clause 1:

Having no pointer to a bit of allocated memory (Memory leak)

Clause 2:

Deallocating the memory but not setting the pointer to point to nullptr (Dangling pointer)

Clause 3:

Deallocating from memory that was never allocated. (Runtime error)

See Also

  1. [[computer-science]]
  2. free-store-manager