File tree 1 file changed +2
-2
lines changed
1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change 37
37
Why would you want to write ``customer[2] `` instead of ``customer.first_name ``?
38
38
39
39
Don't get me started when you add nesting.
40
- If you've never ran into mysterious tuples you had no idea what the hell they meant while debugging, you're much smarter then yours truly.
40
+ If you've never run into mysterious tuples you had no idea what the hell they meant while debugging, you're much smarter than yours truly.
41
41
42
42
Using proper classes with names and types makes program code much more readable and comprehensible _.
43
43
Especially when trying to grok a new piece of software or returning to old code after several months.
@@ -123,7 +123,7 @@ With ``attrs`` your users won't notice a difference because it creates regular,
123
123
.. [#history ] The word is that ``namedtuple ``\ s were added to the Python standard library as a way to make tuples in return values more readable.
124
124
And indeed that is something you see throughout the standard library.
125
125
126
- Looking at what for the makers of ``namedtuple ``\ s use it themselves is a good guideline for deciding on your own use cases.
126
+ Looking at what the makers of ``namedtuple ``\ s use it for themselves is a good guideline for deciding on your own use cases.
127
127
.. [#pollution ] ``attrs `` only adds a single attribute: ``__attrs_attrs__ `` for introspection.
128
128
All helpers are functions in the ``attr `` package.
129
129
Since they take the instance as first argument, you can easily attach them to your classes under a name of your own choice.
You can’t perform that action at this time.
0 commit comments