A blog post on choosing more specific types rather than general ones like list and dict.

  • @o11c
    link
    59 months ago

    The problem is that there’s a severe hole in the ABCs: there is no distinction between “container whose elements are mutable” and “container whose elements and size are mutable”.

    (related, there’s no distinction for supporting slice operations or not, e.g. deque)

    • MeadSteveOP
      link
      fedilink
      29 months ago

      Yeah there’s definitely a lot of room for improvement here