Skip to content

Commit

Permalink
bpo-43971: Add spaces around annotated arg default '=' (GH-25702)
Browse files Browse the repository at this point in the history
Result: "quantity_on_hand: int = 0".
(cherry picked from commit e726a90)

Co-authored-by: Mohamed Moselhy <look4d@gmail.com>

Co-authored-by: Mohamed Moselhy <look4d@gmail.com>
  • Loading branch information
miss-islington and moselhy committed May 1, 2021
1 parent e377ecf commit 606bb1c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Doc/library/dataclasses.rst
Expand Up @@ -33,7 +33,7 @@ using :pep:`526` type annotations. For example this code::

Will add, among other things, a :meth:`__init__` that looks like::

def __init__(self, name: str, unit_price: float, quantity_on_hand: int=0):
def __init__(self, name: str, unit_price: float, quantity_on_hand: int = 0):
self.name = name
self.unit_price = unit_price
self.quantity_on_hand = quantity_on_hand
Expand Down

0 comments on commit 606bb1c

Please sign in to comment.