1. 28 Ock, 2018 4 kayıt (commit)
    • Martin Teichmann's avatar
      bpo-30306: release arguments of contextmanager (GH-1500) · dd0e087e
      Martin Teichmann yazdı
      The arguments to a generator function which is declared as a
      contextmanager are stored inside the context manager, and
      thus are kept alive, even when it is used as a regular context
      manager, and not as a function decorator (where it needs
      the original arguments to recreate the generator on each
      call).
      
      This is a possible unnecessary memory leak, so this changes
      contextmanager.__enter__ to release the saved arguments,
      as that method being called means that particular CM instance
      isn't going to need to recreate the underlying generator.
      
      Patch by Martin Teichmann.
      dd0e087e
    • Eric V. Smith's avatar
      Pep 557 What's New (GH-5371) · c4b12483
      Eric V. Smith yazdı
      Add PEP 557 Data CLasses to What's New.
      c4b12483
    • INADA Naoki's avatar
      bea57060
    • Eric V. Smith's avatar
      bpo-32513: Make it easier to override dunders in dataclasses. (GH-5366) · ea8fc52e
      Eric V. Smith yazdı
      Class authors no longer need to specify repr=False if they want to provide a custom __repr__ for dataclasses. The same thing applies for the other dunder methods that the dataclass decorator adds. If dataclass finds that a dunder methods is defined in the class, it will not overwrite it.
      ea8fc52e
  2. 27 Ock, 2018 19 kayıt (commit)
  3. 26 Ock, 2018 11 kayıt (commit)
  4. 25 Ock, 2018 6 kayıt (commit)