If we are out of memory, we can't try to allocate a string that could
fail as well. When Error is converted to String, this would result in an
endless OOM-throwing loop. Instead, pre-allocate the string on the VM,
and use it to construct the Error.
Note that as of this commit, the OOM string is still a DeprecatedString.
This is just preporatory for Error's conversion to String.
Not an issue currently, but while developing, it's easy to miss cases
where an infallible AK::StringBuilder method is still used. By making
this inheritance private, and explicitly pulling in base methods we
can safely use, we get extra help from the compiler to indicate such
mistakes immediately.
ThrowableStringBuilder is a thin wrapper around StringBuilder to map
results from the try_* methods to a throw completion. This will let us
try to throw on OOM conditions rather than just blowing up.