We have applied multiple different strategies with regard to overflow during calendrical calculation, including capping input Date and clipping Julian day calculation with artificial bounds. Those are still insufficient as there are too many paths where numeric overflow may happen.
This patch patches those places by throwing whenever applicable. Also adds fuzzing tests to cover many more Calendar API.
We have applied multiple different strategies with regard to overflow during calendrical calculation, including capping input
Date
and clipping Julian day calculation with artificial bounds. Those are still insufficient as there are too many paths where numeric overflow may happen.This patch patches those places by
throw
ing whenever applicable. Also adds fuzzing tests to cover many more Calendar API.Resolves rdar://133558250