Skip to content

Commit

Permalink
Update the docstring for Python 2.6 even though it's uglier
Browse files Browse the repository at this point in the history
  • Loading branch information
acatton committed Feb 4, 2018
1 parent 36d8eac commit 9a75073
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions boltons/dictutils.py
Original file line number Diff line number Diff line change
Expand Up @@ -807,9 +807,9 @@ def subdict(d, restrict_to=None, omit=None):
>>> from pprint import pprint as pp
>>> pp(subdict({'a': 1, 'b': 2}))
{'a': 1, 'b': 2}
>>> subdict({'a': 1, 'b': 2, 'c': 3}, omit={'b', 'c'})
>>> subdict({'a': 1, 'b': 2, 'c': 3}, omit=set(['b', 'c']))
{'a': 1}
>>> pp(subdict({'a': 1, 'b': 2, 'c': 3}, restrict_to={'a', 'c'}))
>>> pp(subdict({'a': 1, 'b': 2, 'c': 3}, restrict_to=set(['a', 'c']))
{'a': 1, 'c': 3}
"""
if restrict_to is None:
Expand Down

0 comments on commit 9a75073

Please sign in to comment.