Issue #16335: Fix integer overflow in unicode-escape decoder.
Fix memory error in test_ucn.
unicode-escape decoder requires memory for result corresponding to input size.
Fixes test for issue #16335.