diff --git a/source/ub.tex b/source/ub.tex index 8a339c44aa..02daa55aed 100644 --- a/source/ub.tex +++ b/source/ub.tex @@ -575,9 +575,9 @@ int main() { // Assuming $32$-bit \tcode{int}, the range of values is: $-2,147,483,648$ to $2,147,483,647$. int x1 = std::numeric_limits::max() + 1; - // undefined behavior, $2,147,483,647 + 1$ is not representable as an int + // undefined behavior, $2,147,483,647 + 1$ is not representable as an \tcode{int} int x2 = std::numeric_limits::min() / -1; - // undefined behavior, $-2,147,483,648 / -1$ is not representable as an int + // undefined behavior, $-2,147,483,648 / -1$ is not representable as an \tcode{int} } \end{codeblock} \end{example}