mirror of
https://github.com/boostorg/contract.git
synced 2026-01-28 07:02:16 +00:00
12 lines
203 B
C++
12 lines
203 B
C++
|
|
//[no_contracts
|
|
int inc(int& x)
|
|
// Precondition: x < std::numeric_limits<int>::max()
|
|
// Postcondition: x == oldof(x) + 1
|
|
// result == oldof(x)
|
|
{
|
|
return x++;
|
|
}
|
|
//]
|
|
|