diff options
author | Mark Dickinson <dickinsm@gmail.com> | 2010-01-06 16:22:15 (GMT) |
---|---|---|
committer | Mark Dickinson <dickinsm@gmail.com> | 2010-01-06 16:22:15 (GMT) |
commit | c53796e14776459d59aca991ee4c9fb610b16a56 (patch) | |
tree | a1871c6048a49a1b2dd8745fef85e94a47b6a4b9 /Lib | |
parent | ede6c2aff6f2bf8842147ca286493e06ac0a99b0 (diff) | |
download | cpython-c53796e14776459d59aca991ee4c9fb610b16a56.zip cpython-c53796e14776459d59aca991ee4c9fb610b16a56.tar.gz cpython-c53796e14776459d59aca991ee4c9fb610b16a56.tar.bz2 |
Merged revisions 77324 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk
........
r77324 | mark.dickinson | 2010-01-06 16:20:22 +0000 (Wed, 06 Jan 2010) | 2 lines
Add missing docstring for Context.divmod. Thanks Juan José Conti.
........
Diffstat (limited to 'Lib')
-rw-r--r-- | Lib/decimal.py | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/Lib/decimal.py b/Lib/decimal.py index 82d3256..d0d54fc 100644 --- a/Lib/decimal.py +++ b/Lib/decimal.py @@ -4132,6 +4132,13 @@ class Context(object): return a.__floordiv__(b, context=self) def divmod(self, a, b): + """Return (a // b, a % b) + + >>> ExtendedContext.divmod(Decimal(8), Decimal(3)) + (Decimal('2'), Decimal('2')) + >>> ExtendedContext.divmod(Decimal(8), Decimal(4)) + (Decimal('2'), Decimal('0')) + """ return a.__divmod__(b, context=self) def exp(self, a): |