summaryrefslogtreecommitdiffstats
path: root/Lib/turtle.py
diff options
context:
space:
mode:
authorSerhiy Storchaka <storchaka@gmail.com>2020-09-07 15:55:22 (GMT)
committerGitHub <noreply@github.com>2020-09-07 15:55:22 (GMT)
commitfd4cafd4700dc03cb05fc2e5263c2666d785d6e3 (patch)
tree3a4b527fd7b3d71d53a3f4570c33460d0a40c25d /Lib/turtle.py
parent1baf030a902392fe92d934ed0fb6a385cf7d8869 (diff)
downloadcpython-fd4cafd4700dc03cb05fc2e5263c2666d785d6e3.zip
cpython-fd4cafd4700dc03cb05fc2e5263c2666d785d6e3.tar.gz
cpython-fd4cafd4700dc03cb05fc2e5263c2666d785d6e3.tar.bz2
bpo-41720: Add "return NotImplemented" in turtle.Vec2D.__rmul__(). (GH-22092)
Diffstat (limited to 'Lib/turtle.py')
-rw-r--r--Lib/turtle.py1
1 files changed, 1 insertions, 0 deletions
diff --git a/Lib/turtle.py b/Lib/turtle.py
index 92d4e5d..81cfcfe 100644
--- a/Lib/turtle.py
+++ b/Lib/turtle.py
@@ -258,6 +258,7 @@ class Vec2D(tuple):
def __rmul__(self, other):
if isinstance(other, int) or isinstance(other, float):
return Vec2D(self[0]*other, self[1]*other)
+ return NotImplemented
def __sub__(self, other):
return Vec2D(self[0]-other[0], self[1]-other[1])
def __neg__(self):