Hi Steve,
Thanks for your reply. While dataclass provide a cleaner API than DictRow (you can access `
row.id` instead of `row["id"]`).
However, dataclass still use the built in `__dict__` instead of `__slots__`.
```
>>> @dataclass
... class InventoryItem:
... '''Class for keeping track of an item in inventory.'''
... name: str
... unit_price: float
... quantity_on_hand: int = 0
...
>>> cf = InventoryItem("cornflakes", 0.99, 123)
>>> cf
InventoryItem(name='cornflakes', unit_price=0.99, quantity_on_hand=123)
>>> cf.__dict__
{'name': 'cornflakes', 'unit_price': 0.99, 'quantity_on_hand': 123}
```
This means that the users reading large files won't see the suggested memory improvements.
On the other hand, I'm willing to implement CSVReader classes for both. `DataClassCSVReader` does offer the
benefit of row instances being mutable, `NamedTupleCSVReader` can be useful for people leaning toward functional
programming style, where queries on CSV are only meant to find items or calculate quantities quickly without actually
modifying the rows.
I would be more than happy to know whether such PR would accept.
Best regards
Oz