From 710d65fc9c99e62e197ff31e578aa16e4467aa50 Mon Sep 17 00:00:00 2001 From: Ned Batchelder Date: Fri, 8 May 2020 06:08:40 -0400 Subject: [PATCH] Make the first example more useful --- Doc/library/dataclasses.rst | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Doc/library/dataclasses.rst b/Doc/library/dataclasses.rst index c125a1130a9603..fe63d20671dd74 100644 --- a/Doc/library/dataclasses.rst +++ b/Doc/library/dataclasses.rst @@ -19,6 +19,8 @@ in :pep:`557`. The member variables to use in these generated methods are defined using :pep:`526` type annotations. For example this code:: + from dataclasses import dataclass + @dataclass class InventoryItem: '''Class for keeping track of an item in inventory.''' pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy