CBMC
|
Go to the source code of this file.
Classes | |
class | copy_on_writet< T > |
A utility class for writing types with copy-on-write behaviour (like irep). More... | |
class | copy_on_write_pointeet< Num > |
A helper class to store use-counts of copy-on-write objects. More... | |
Functions | |
template<typename Num > | |
void | pointee_increment_use_count (copy_on_write_pointeet< Num > &p) |
The following functions are required by copy_on_writet, and by default pass through to the member functions of copy_on_write_pointeet by the same name. More... | |
template<typename Num > | |
void | pointee_decrement_use_count (copy_on_write_pointeet< Num > &p) |
template<typename Num > | |
Num | pointee_use_count (const copy_on_write_pointeet< Num > &p) |
template<typename Num , typename T > | |
void | pointee_set_use_count (copy_on_write_pointeet< Num > &p, T count) |
template<typename Num > | |
void | pointee_set_shareable (copy_on_write_pointeet< Num > &p, bool u) |
template<typename Num > | |
bool | pointee_is_shareable (const copy_on_write_pointeet< Num > &p) |
|
inline |
|
inline |
The following functions are required by copy_on_writet, and by default pass through to the member functions of copy_on_write_pointeet by the same name.
We provide these as non-members just in case a future client wants to implement a copy-on-write class, which is unable to inherit from copy_on_write_pointeet for some reason. In this case, new overloads for the functions below can be provided, with appropriate behavior for the new type.
|
inline |
|
inline |
|
inline |
|
inline |