summaryrefslogtreecommitdiff
path: root/Lib/datetime.py
diff options
context:
space:
mode:
authorSerhiy Storchaka <storchaka@gmail.com>2015-03-12 22:01:30 +0200
committerSerhiy Storchaka <storchaka@gmail.com>2015-03-12 22:01:30 +0200
commitc2ccce791ccbe35bee0edea2dedabb0fc7ea5906 (patch)
treec31fcb2d158d17ab07038f26ec016b37e5b8cea0 /Lib/datetime.py
parentda0870c87aeb7843f0211d3fd9220f6f5b58f688 (diff)
parenta60c2fe4807e89a5844979fe46b3ea39572fc3be (diff)
downloadcpython-git-c2ccce791ccbe35bee0edea2dedabb0fc7ea5906.tar.gz
Issue #23641: Cleaned out legacy dunder names from tests and docs.
Fixed 2 to 3 porting bug in pynche.ColorDB. Added few tests for __truediv__, __floordiv__ and __matmul__.
Diffstat (limited to 'Lib/datetime.py')
-rw-r--r--Lib/datetime.py7
1 files changed, 4 insertions, 3 deletions
diff --git a/Lib/datetime.py b/Lib/datetime.py
index de574724b8..db13b12ef3 100644
--- a/Lib/datetime.py
+++ b/Lib/datetime.py
@@ -651,7 +651,7 @@ class date:
Operators:
__repr__, __str__
- __cmp__, __hash__
+ __eq__, __le__, __lt__, __ge__, __gt__, __hash__
__add__, __radd__, __sub__ (add/radd only with timedelta arg)
Methods:
@@ -786,7 +786,8 @@ class date:
"""day (1-31)"""
return self._day
- # Standard conversions, __cmp__, __hash__ (and helpers)
+ # Standard conversions, __eq__, __le__, __lt__, __ge__, __gt__,
+ # __hash__ (and helpers)
def timetuple(self):
"Return local time tuple compatible with time.localtime()."
@@ -1010,7 +1011,7 @@ class time:
Operators:
__repr__, __str__
- __cmp__, __hash__
+ __eq__, __le__, __lt__, __ge__, __gt__, __hash__
Methods: