add root/checkedint.h and .c

This is a direct translation of druntime's core.checkedint to C++. The idea is to replace the several ad-hoc overflow checks in dmd with these. Even includes unit tests!