4 ms·
> 2. Use consistent spacing and use whitespace liberally. The very definition of a formatting bikeshed. > 1. No instance variables. I'm not convinced here -
by RyanZAG 13y ago
> 2. Use consistent spacing and use whitespace liberally.
The very definition of a formatting bikeshed.
> 1. No instance variables.
I'm not convinced here - he certainly doesn't explain why you shouldn't use them. I guess he likes to use self.var rather than var - but it's important to note that this does have some performance implications.
> 4. Modularize and model.
I'll give you 4 though - using compiler recognizable types is always a boon. I'm not sure if anybody really needs to be told to modularize and model, most people would understand that without being told. It does lock-in your public API though, making changes to a library require updating all apps that use the library. Meanwhile, adding a new field into a dict means existing apps can upgrade the library easily. Still, I'd definitely agree that types are always a better bet in the long run.
- lyinsteve 13y agoWhoops, sorry, I meant 1, 4, 5, and 8. You're right about 2.