Yes, this is the best answer. This also works with `-fsanitize=unsigned-integer-overflow`.
One particularly famous example of a bug: https://projectzero.google/2023/01/exploiting-null-dereferen...
We usually get away with ignoring unsigned rollover because most application counts don't exceed 2**32 or 2**64. However, many can exceed these values, and in those cases, explicitly handling this case in critical systems is often better than ignoring potentially erroneous behavior.
Another concern, some people might have about this is the performance implications or what to do when you want to allow overflow. In that case you can locally disable overflow protections.