Prevent infinite loops when BYXXX specified with FREQ=XXX. Some performance enhancement as well.
Prevent infinite loops when BYXXX specified with FREQ=XXX. Some performance enhancement as well.

Signed-off-by: Paul G <96dd8d96902e9c5af3b96b1eaa9c80cbc615d290@example.com>

abalkin/dateutil,sprymix/python-dateutil,pganssle/dateutil-test-codecov,mjschultz/dateutil,abalkin/dateutil,pganssle/dateutil-test-codecov,Bachmann1234/dateutil,sprymix/dateutil,jenshnielsen/dateutil