Closes issue #20858: Enhancements/fixes to pure-python datetime module

This patch brings the pure-python datetime more in-line with the C
module.  Patch contributed by Brian Kearns, a PyPy developer.  PyPy
project has been running these modifications in PyPy2 stdlib.

This commit includes:

- General PEP8/cleanups;
- Better testing of argument types passed to constructors;
- Removal of duplicate operations;
- Optimization of timedelta creation;
- Caching the result of __hash__ like the C accelerator;
- Enhancements/bug fixes in tests.
diff --git a/Misc/ACKS b/Misc/ACKS
index fceea3b..84dfd02 100644
--- a/Misc/ACKS
+++ b/Misc/ACKS
@@ -689,6 +689,7 @@
 Anton Kasyanov
 Lou Kates
 Hiroaki Kawai
+Brian Kearns
 Sebastien Keim
 Ryan Kelly
 Dan Kenigsberg